Browse Source

feat(api): 添加销售端沟通记录功能

- 在 apiRoute.js 中新增 xs_communicationRecordsAdd 方法,用于添加沟通记录
- 在市场线索页面中调用该方法,实现电话沟通记录的添加
- 优化了电话拨打流程,添加了沟通记录保存逻辑
master
liutong 10 months ago
parent
commit
d4d17b2d88
  1. 8
      api/apiRoute.js
  2. 33
      pages/market/clue/index.vue

8
api/apiRoute.js

@ -198,6 +198,14 @@ export default {
})
},
//销售端-沟通记录-添加
xs_communicationRecordsAdd(data = {}) {
let url = '/communicationRecords/add'
return http.post(url, data).then(res => {
return res;
})
},

33
pages/market/clue/index.vue

@ -3,8 +3,6 @@
<fui-segmented-control :values="values" type="text" activeColor="#29d3b4" color="#fff"
@click="segmented"></fui-segmented-control>
<!--我的客户-->
<scroll-view
v-if="segmented_type == 1"
@ -471,22 +469,33 @@ export default {
return;
}
let param = {
sales_id: item.customerResource.id//线id
}
// let res = await marketApi.setCallUp(param)//
// if (res.code != 1) {
// uni.showToast({
// title: res.msg,
// icon: 'none'
// })
// return
// }
staff_id: this.userInfo.id,//id
resource_id: item.customerResource.id,//ID
resource_type: '',//
communication_type: 'phone',//: phone-, email-, meeting-, other-
communication_result: 'success',//: success-, failure-, pending-
remarks: null,//
tag: null,//
}
let res = await apiRoute.xs_communicationRecordsAdd(param)//
if (res.code != 1) {
uni.showToast({
title: res.msg,
icon: 'none'
})
return
}
uni.makePhoneCall({
phoneNumber: tel
})
},
//

Loading…
Cancel
Save