feat:操作日志
All checks were successful
构建并部署前端到测试环境 / build-and-deploy (push) Successful in 4m10s

This commit is contained in:
sexygoat
2026-04-27 16:49:32 +08:00
parent a402f2329a
commit d5c5e07f77
5 changed files with 89 additions and 194 deletions

View File

@@ -490,6 +490,12 @@
:current-policy="currentRealnamePolicy"
@confirm="handleConfirmRealnamePolicy"
/>
<!-- 操作审计日志弹窗 -->
<OperationLogsDialog
v-model="operationLogsDialogVisible"
:identifier="operationLogsIdentifier"
/>
</ElCard>
</div>
</ArtTableFullScreen>
@@ -525,6 +531,7 @@
import { formatDateTime } from '@/utils/business/format'
import type { PackageSeriesResponse } from '@/types/api'
import RealnamePolicyDialog from '@/components/device/RealnamePolicyDialog.vue'
import OperationLogsDialog from '@/components/business/OperationLogsDialog.vue'
defineOptions({ name: 'DeviceList' })
@@ -540,6 +547,8 @@
const allocateDialogVisible = ref(false)
const recallDialogVisible = ref(false)
const selectedDevices = ref<Device[]>([])
const operationLogsDialogVisible = ref(false)
const operationLogsIdentifier = ref('')
const shopCascadeOptions = ref<any[]>([])
const shopCascadeProps = {
lazy: true,
@@ -1965,6 +1974,17 @@
})
}
if (hasAuth('device:operation_logs')) {
moreActions.push({
label: '操作审计日志',
handler: () => {
operationLogsIdentifier.value = row.virtual_no
operationLogsDialogVisible.value = true
},
type: 'primary'
})
}
// 如果有更多操作,添加到 actions 中
if (moreActions.length > 0) {
actions.push(...moreActions)