jiangping
2024-07-26 2faa6546a9f9ddb29f81cbc9770fc25b95703695
wechat_staff/api/index.js
@@ -13,13 +13,21 @@
export const loginByPhone = (data) => {
  return request({
    url: '/web/personnel/loginByPhone',
    data
    datas
  })
}
// 发送验证码
export const sendSms = (data) => {
  return request({
    url: '/web/personnel/sendSms',
    data
  })
}
export const getUserCard = (data) => {
  return request({
    url: '/web/personnel/getUserCard',
    method: "POST",
    data
  })
}
@@ -31,6 +39,7 @@
    data
  })
}
// 绑定Openid
export const bindingOpenid = (data) => {
  return request({
@@ -142,9 +151,10 @@
    data
  })
}
export const getUserCard = (data) => {
// 批量添加喜欢给客户
export const batchAddLike = (data) => {
  return request({
    url: '/web/personnel/getUserCard',
    url: '/web/personnel/batchAddLike',
    method: "POST",
    data
  })
@@ -183,6 +193,13 @@
export const getShopDetail = (data) => {
  return request({
    url: '/web/personnel/shopDetail?shopId='+data,
    data
  })
}
// 获取门店详情
export const loadShopList= (data) => {
  return request({
    url: '/web/personnel/userShopList',
    data
  })
}
@@ -263,6 +280,14 @@
    data
  })
}
// 获取内容分享海报
export const getContentShareImg = (data) => {
  return request({
    url: '/web/personnel/getContentShareImg',
    method: 'POST',
    data
  })
}
// 0元定制信息
export const saveFreeCustomizationApply = (data) => {
  return request({
@@ -300,10 +325,25 @@
    data
  })
}
// 小程序注销
export const getCrmAuthUrl = (data) => {
  return request({
    url: '/web/customer/getCrmAuthUrl',
    data
  })
}
export const refreshEnjoy = (obj) =>{
  let child = obj.selectComponent('.buoyClient');
  // 调用子组件中定义的方法
  if(child){
    child.freshData();
  }
  var {info} = obj.data ;
  if(info){
    const enjoyList = wx.getStorageSync('enjoyList') || [];
    const index = enjoyList.findIndex( i => i.id === info.id );
    info.isEnjoy = index > -1;
    obj.setData({ info:info}) ;
  }
}