diff --git a/src/views/AlarmInformation/index.vue b/src/views/AlarmInformation/index.vue index 115a0bf..0ce3985 100644 --- a/src/views/AlarmInformation/index.vue +++ b/src/views/AlarmInformation/index.vue @@ -17,22 +17,22 @@
- 批量删除 -
--> - - + + + @@ -47,13 +47,13 @@ {{ row.fault_time ? dayjs(row.fault_time).format('YYYY-MM-DD HH:mm:ss') : '' }} - + - + @@ -98,18 +98,20 @@ const currentTime = ref('') const systemRuntime = ref('38分钟') // const commit_uid = sessionStorage.getItem('central_control_comm_uid') const commit_uid = sessionStorage.getItem('central_control_comm_uid') +// const commit_uid = '868656077692382' const loading = ref(false) const total = ref(0) -const pageSize = ref(10) +const pageSize = ref(8) const currentPage = ref(1) const handleSizeChange = () => { currentPage.value = 1 - getData() + // getData() } const handleCurrentChange = () => { - getData() + // getData() + showTableData.value = tableData.value.slice((currentPage.value - 1) * 8, (currentPage.value - 1) * 8 + 8) } const tableData = ref([]) @@ -165,10 +167,13 @@ const handleDeal = () => { }) } +const showTableData = ref([]) + const getData = () => { + currentPage.value = 1 const params = { - "limit": pageSize.value, - "page": currentPage.value, + // "limit": pageSize.value, + // "page": currentPage.value, "and": { "comm_uid": [ commit_uid @@ -185,8 +190,9 @@ const getData = () => { loading.value = true tableData.value = [] RPC.post('/m9z/fault/list', params).then(res => { - total.value = res.count || 0 + total.value = res.rows.length || 0 tableData.value = res.rows || [] + showTableData.value = tableData.value.slice(0, 8) }).finally(() => { loading.value = false }) diff --git a/vite.config.js b/vite.config.js index f2c35af..f5d34e5 100644 --- a/vite.config.js +++ b/vite.config.js @@ -59,7 +59,8 @@ export default defineConfig({ open: true, proxy: { '/jsonrpc': { - target: 'https://lamp-dev.ruixininfo.com', + // target: 'https://lamp-dev.ruixininfo.com', + target: 'http://10.21.77.100:71', changeOrigin: true, secure: false, },