import request from '@/utils/request';

// id解密
export const idRemark = (data) => {
  return request({
    url: '/enterprise/remark',
    method: 'post',
    data: data
  });
};

// 认领用户
export const claim = function claim(param) {
  return request({
    url: '/customer/claim',
    method: 'post',
    data: param
  });
};
// 历史客户认领
export const historyClaim = function historyClaim(name) {
  return request({
    url: '/customer/historyClaim/' + name,
    method: 'Put',
  });
};

//获取大司空open 插件访问token
export function dskAccessToken() {
  return request({
    url: '/system/config/dsk/accessToken',
    method: 'get',
  });
}

/**
 * 获取地区
 * @returns {Array<object>}
 */
export const getAreaListApi = () => request({
  url: "/area/all/withoutRegion",
  method: "get"
});

//获取地区树
export const getAllAreaApi = () => request({
  url: '/area/all',
  method: 'get',
});
