data.js 826 Bytes
//
import util from '../../utils/util';
import App from '../../utils/api';
const {regeneratorRuntime} = global
let getCates=async function(code){
  let res=await App.Reserve.GetCustomerConfig({code:code});
  let cates=[];
  res.data.cate.forEach(ca=>{
    cates.push({
		name:ca.name,
		cu:ca.cu
	});
  })
  return cates;
}
let getLabels=async function(code){
  let res=await App.Reserve.GetCustomerConfig({code:code});
  return res.data.pub_label;
}
let getCatesID=async function(index,code){
  let res=await App.Reserve.GetCustomerConfig({code:code});
  return res.data.cate[index].id;
}
let getCitys=async function(code){
  let res=await App.Reserve.GetCustomerConfig({code:code});
  return res.data.region_code;
}
export default {
  getCates:getCates,
  getCatesID:getCatesID,
  getCitys:getCitys,
  getLabels:getLabels,
}