baseInfo.js 1.82 KB
/**
 * 新增参数sign 判断接口是否需要sign签名
 */
/**
 * 用法 : this.$apis.demo.GETLISTDEVICEFILEUNSTOCK(...)
 * @param {*} params
 * @returns
 */
import { http_config, http } from '@/main'
const getMerchantTree = params => {
  params.method = 'merchants.api.open.findSubMerchantbySupMerchantNo'
  return http({
    url: '/rop-merchants/router',
    method: 'POST',
    data: params,
    sign: true
  })
}
const findMerchantTreeList = params => {
  params.method = 'merchants.api.merchant.findEntMicroMerchantsByPage'
  return http({
    url: '/rop-merchants/router',
    method: 'POST',
    data: params,
    sign: true
  })
}
const getDepartment = params => {
  params.method = 'entmicro.api.department.listDepartment'
  return http_config({
    url: '/rop-scrm-entmicro/router',
    method: 'POST',
    data: params,
    sign: true
  })
}
const findDepartmentList = params => {
  params.method = 'entmicro.api.department.findDepartmentListByPage'
  return http_config({
    url: '/rop-scrm-entmicro/router',
    method: 'POST',
    data: params,
    sign: true
  })
}
const toGL = params => {
  params.method = 'entmicro.api.common.relevanceEntmicro.list'
  return http_config({
    url: '/rop-scrm-entmicro/router',
    method: 'POST',
    data: params,
    sign: true
  })
}
const merchantInfo = params => {
  params.method = 'entmicro.api.common.findMerchantInfoByMerchantNo.list'
  return http_config({
    url: '/rop-scrm-entmicro/router',
    method: 'POST',
    data: params,
    sign: true
  })
}
const brandList = params => {
  params.method = 'merchants.api.merchantCommon.getCarbrandTree'
  return http({
    url: '/rop-merchants/router',
    method: 'POST',
    data: params,
    sign: true
  })
}

export default {
  getMerchantTree,
  getDepartment,
  findDepartmentList,
  toGL,
  merchantInfo,
  brandList,
  findMerchantTreeList
}