File tree Expand file tree Collapse file tree 4 files changed +16
-10
lines changed
components/OperateLogV2/src
views/crm/customer/detail Expand file tree Collapse file tree 4 files changed +16
-10
lines changed Original file line number Diff line number Diff line change @@ -69,6 +69,6 @@ export const queryAllList = async () => {
69
69
}
70
70
71
71
// 查询客户操作日志
72
- export const getOperateLog = async ( id : number ) => {
73
- return await request . get ( { url : ` /crm/customer/operate-log?id=` + id } )
72
+ export const getOperateLogPage = async ( params ) => {
73
+ return await request . get ( { url : ' /crm/customer/operate-log-page' , params } )
74
74
}
Original file line number Diff line number Diff line change @@ -29,10 +29,11 @@ export type OperateLogV2VO = {
29
29
traceId : string
30
30
userType : number
31
31
userId : number
32
- module : string
33
- name : string
32
+ userName : string
33
+ type : string
34
+ subType : string
34
35
bizId : number
35
- content : string
36
+ action : string
36
37
extra : string
37
38
requestMethod : string
38
39
requestUrl : string
Original file line number Diff line number Diff line change 4
4
<el-timeline-item
5
5
v-for =" (log, index) in logDataList"
6
6
:key =" index"
7
- :timestamp =" formatDate(log.createTime! )"
7
+ :timestamp =" formatDate(log.createTime)"
8
8
placement =" top"
9
9
>
10
10
<div class =" el-timeline-right-content" >
11
11
<el-row >
12
12
<el-col :span =" 24" class =" mb-10px" >
13
13
=======================
14
- <el-tag class =" mr-10px" type =" success" >{{ log.creatorName }}</el-tag >
14
+ <el-tag class =" mr-10px" type =" success" >{{ log.userName }}</el-tag >
15
15
<span >{{ log.title }}</span >
16
16
=======================
17
17
</el-col >
@@ -91,11 +91,11 @@ const renderTags = (content: string) => {
91
91
}
92
92
const initLog = () => {
93
93
logDataList .value = props .logList .map ((logItem ) => {
94
- const keyValue = renderTags (logItem .content )
94
+ const keyValue = renderTags (logItem .action )
95
95
// 挂载数据
96
96
logItem .contentStrList = keyValue [0 ]
97
97
if (keyValue [0 ][0 ] === ' 从' ) {
98
- logItem .title = logItem .name
98
+ logItem .title = logItem .subType
99
99
} else {
100
100
logItem .title = keyValue [0 ][0 ]
101
101
logItem .contentStrList .splice (0 , 1 )
Original file line number Diff line number Diff line change @@ -66,7 +66,12 @@ const getOperateLog = async (customerId: number) => {
66
66
if (! customerId ) {
67
67
return
68
68
}
69
- logList .value = await CustomerApi .getOperateLog (customerId )
69
+ const data = await CustomerApi .getOperateLogPage ({
70
+ pageNo: 1 ,
71
+ pageSize: 10 ,
72
+ bizId: customerId
73
+ })
74
+ logList .value = data .list
70
75
}
71
76
/** 初始化 */
72
77
const { delView } = useTagsViewStore () // 视图操作
You can’t perform that action at this time.
0 commit comments