eight
2024-08-13 b10adc8a3fd000901836e2219fa83462694e9866
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
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
import request from '@/config/axios'
 
export interface CrmStatisticsCustomerSummaryByDateRespVO {
  time: string
  customerCreateCount: number
  customerDealCount: number
}
 
export interface CrmStatisticsCustomerSummaryByUserRespVO {
  ownerUserName: string
  customerCreateCount: number
  customerDealCount: number
  contractPrice: number
  receivablePrice: number
}
 
export interface CrmStatisticsFollowUpSummaryByDateRespVO {
  time: string
  followUpRecordCount: number
  followUpCustomerCount: number
}
 
export interface CrmStatisticsFollowUpSummaryByUserRespVO {
  ownerUserName: string
  followupRecordCount: number
  followupCustomerCount: number
}
 
export interface CrmStatisticsFollowUpSummaryByTypeRespVO {
  followUpType: string
  followUpRecordCount: number
}
 
export interface CrmStatisticsCustomerContractSummaryRespVO {
  customerName: string
  contractName: string
  totalPrice: number
  receivablePrice: number
  customerType: string
  customerSource: string
  ownerUserName: string
  creatorUserName: string
  createTime: Date
  orderDate: Date
}
 
export interface CrmStatisticsPoolSummaryByDateRespVO {
  time: string
  customerPutCount: number
  customerTakeCount: number
}
 
export interface CrmStatisticsPoolSummaryByUserRespVO {
  ownerUserName: string
  customerPutCount: number
  customerTakeCount: number
}
 
export interface CrmStatisticsCustomerDealCycleByDateRespVO {
  time: string
  customerDealCycle: number
}
 
export interface CrmStatisticsCustomerDealCycleByUserRespVO {
  ownerUserName: string
  customerDealCycle: number
  customerDealCount: number
}
 
export interface CrmStatisticsCustomerDealCycleByAreaRespVO {
  areaName: string
  customerDealCycle: number
  customerDealCount: number
}
 
export interface CrmStatisticsCustomerDealCycleByProductRespVO {
  productName: string
  customerDealCycle: number
  customerDealCount: number
}
 
// 客户分析 API
export const StatisticsCustomerApi = {
  // 1.1 客户总量分析(按日期)
  getCustomerSummaryByDate: (params: any) => {
    return request.get({
      url: '/crm/statistics-customer/get-customer-summary-by-date',
      params
    })
  },
  // 1.2 客户总量分析(按用户)
  getCustomerSummaryByUser: (params: any) => {
    return request.get({
      url: '/crm/statistics-customer/get-customer-summary-by-user',
      params
    })
  },
  // 2.1 客户跟进次数分析(按日期)
  getFollowUpSummaryByDate: (params: any) => {
    return request.get({
      url: '/crm/statistics-customer/get-follow-up-summary-by-date',
      params
    })
  },
  // 2.2 客户跟进次数分析(按用户)
  getFollowUpSummaryByUser: (params: any) => {
    return request.get({
      url: '/crm/statistics-customer/get-follow-up-summary-by-user',
      params
    })
  },
  // 3.1 获取客户跟进方式统计数
  getFollowUpSummaryByType: (params: any) => {
    return request.get({
      url: '/crm/statistics-customer/get-follow-up-summary-by-type',
      params
    })
  },
  // 4.1 合同摘要信息(客户转化率页面)
  getContractSummary: (params: any) => {
    return request.get({
      url: '/crm/statistics-customer/get-contract-summary',
      params
    })
  },
  // 5.1 获取客户公海分析(按日期)
  getPoolSummaryByDate: (param: any) => {
    return request.get({
      url: '/crm/statistics-customer/get-pool-summary-by-date',
      params: param
    })
  },
  // 5.2 获取客户公海分析(按用户)
  getPoolSummaryByUser: (param: any) => {
    return request.get({
      url: '/crm/statistics-customer/get-pool-summary-by-user',
      params: param
    })
  },
  // 6.1 获取客户成交周期(按日期)
  getCustomerDealCycleByDate: (params: any) => {
    return request.get({
      url: '/crm/statistics-customer/get-customer-deal-cycle-by-date',
      params
    })
  },
  // 6.2 获取客户成交周期(按用户)
  getCustomerDealCycleByUser: (params: any) => {
    return request.get({
      url: '/crm/statistics-customer/get-customer-deal-cycle-by-user',
      params
    })
  },
  // 6.2 获取客户成交周期(按用户)
  getCustomerDealCycleByArea: (params: any) => {
    return request.get({
      url: '/crm/statistics-customer/get-customer-deal-cycle-by-area',
      params
    })
  },
  // 6.2 获取客户成交周期(按用户)
  getCustomerDealCycleByProduct: (params: any) => {
    return request.get({
      url: '/crm/statistics-customer/get-customer-deal-cycle-by-product',
      params
    })
  }
}