restapi.js
2.34 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
const restapi = require('../../../utils/restapi.js');
import {api} from '../../../utils/util.js'
module.exports = {
/**
* 获取我的顾问
*/
getEmployeeOfAccount(success, fail) {
restapi.req('/web-dj-weapp/servicer/getEmployeeOfAccount', { }, {}, 'GET', 'json', 'text', success, fail);
},
/**
* 获取门店的服务顾问列表
*/
getEmployeesList(merchantId, accountGroupList, success, fail) {
if (!merchantId || merchantId == 'undefined') {
merchantId = 0;
}
restapi.req('/web-dj-weapp/servicer/getEmployeesList', { merchantId: merchantId, accountGroupList: accountGroupList }, { 'content-type': 'application/x-www-form-urlencoded' }, 'POST', 'json', 'text', success, fail);
},
/**
* 获取顾问信息
*/
getEmployee(employeeId, success) {
restapi.req('/web-dj-weapp/servicer/getEmployee', { employeeId: employeeId }, {}, 'GET', 'json', 'text', success);
},
/**
* 查询顾问的服务人
*/
getUserOfConsultant(record, success) {
restapi.req('/web-dj-weapp/servicer/getUserOfConsultant', record, {}, 'GET', 'json', 'text', success);
},
/**
* 设置顾问
*/
setConsultant(ref, success) {
restapi.req('/web-dj-weapp/servicer/setConsultant', ref, {}, 'Get', 'json', 'text', success);
},
/**
* 用户行为(浏览、点赞)
*/
makeAppraise(record, success, fail) {
restapi.req('/web-dj-weapp/servicer/makeAppraise', record, {}, 'Get', 'json', 'text', success, fail);
},
/**
* 获取员工分组列表
*/
getAccountGroupList(success, ) {
restapi.req('/web-dj-weapp/servicer/getAccountGroupList', {}, {}, 'GET', 'json', 'text', success);
},
/** 获取服务详情 */
getRemindServiceDetail(data, success) {
api.get('remindServiceInfo/getRemindServiceDetail', data, success)
},
/** 查看活动详情*/
getActivityDetail: function (data, success, fail) {
restapi.req('/web-dj-weapp/popularActivity/detail', JSON.stringify(data), { 'content-type': 'application/json' }, 'POST', 'json', 'text', success, fail);
},
/** 获取群二维码 */
getQrCodeInfo(success) {
api.get('remindServiceInfo/getQrCodeInfo', {}, success)
},
/**获取员工信息 */
getYqInfo(data, success){
api.get('smartcarlife/serviceMerchantRef/getYqInfo',data,success)
}
}