【优化】日志列表修改为点击详情按钮时再请求详细数据

pull/181/head
vchao 2023-12-05 16:04:50 +08:00
parent 4b6a04538a
commit 1483629049
2 changed files with 12 additions and 1 deletions

View File

@ -22,6 +22,10 @@ export default {
logPage(data) {
return request('page', data, 'get')
},
// 获取日志详情
logDetail(data) {
return request('detail', data, 'get')
},
// 获取访问日志折线图数据
logVisLineChartData(data) {
return request('vis/lineChartData', data, 'get')

View File

@ -53,7 +53,7 @@
</template>
<template v-if="column.dataIndex === 'action'">
<a-space>
<a @click="detailRef.onOpen(record)"></a>
<a @click="getDetail(record.id)"></a>
</a-space>
</template>
</template>
@ -119,6 +119,13 @@
width: '100px'
}
]
//
const getDetail = (id) => {
let param = { id: id }
logApi.logDetail(param).then((data) => {
detailRef.value.onOpen(data)
})
}
//
const opLogTypeClock = (value) => {
searchFormState.category = value