diff --git a/apps/web-antd/src/views/dataManger/ctwingLog/index.vue b/apps/web-antd/src/views/dataManger/ctwingLog/index.vue index 8abcd55..3a9bef1 100644 --- a/apps/web-antd/src/views/dataManger/ctwingLog/index.vue +++ b/apps/web-antd/src/views/dataManger/ctwingLog/index.vue @@ -38,14 +38,26 @@ const gridOptions: VxeGridProps = { proxyConfig: { ajax: { query: async ({ page }, formValues) => { - const { data } = await postCTWingLogInfoPage({ + // 构建查询参数 + const queryParams: any = { pageIndex: page.currentPage, pageSize: page.pageSize, - DeviceType, - DeviceId, - FocusAddress, - ...formValues, + }; + + // 如果有表单值,添加到查询参数中 + if (formValues) { + Object.assign(queryParams, formValues); + } + + // 添加路由参数 + if (DeviceType) queryParams.DeviceType = DeviceType; + if (DeviceId) queryParams.DeviceId = DeviceId; + if (FocusAddress) queryParams.FocusAddress = FocusAddress; + + const { data } = await postCTWingLogInfoPage({ + body: queryParams, }); + // 确保返回的数据包含totalCount字段 const result = { items: data.items || [], diff --git a/apps/web-antd/src/views/dataManger/onenetLog/index.vue b/apps/web-antd/src/views/dataManger/onenetLog/index.vue index 6d2f6fe..8e4fad1 100644 --- a/apps/web-antd/src/views/dataManger/onenetLog/index.vue +++ b/apps/web-antd/src/views/dataManger/onenetLog/index.vue @@ -38,14 +38,26 @@ const gridOptions: VxeGridProps = { proxyConfig: { ajax: { query: async ({ page }, formValues) => { - const { data } = await postOneNETLogInfoPage({ + // 构建查询参数 + const queryParams: any = { pageIndex: page.currentPage, pageSize: page.pageSize, - DeviceType, - DeviceId, - FocusAddress, - ...formValues, + }; + + // 如果有表单值,添加到查询参数中 + if (formValues) { + Object.assign(queryParams, formValues); + } + + // 添加路由参数 + if (DeviceType) queryParams.DeviceType = DeviceType; + if (DeviceId) queryParams.DeviceId = DeviceId; + if (FocusAddress) queryParams.FocusAddress = FocusAddress; + + const { data } = await postOneNETLogInfoPage({ + body: queryParams, }); + // 确保返回的数据包含totalCount字段 const result = { items: data.items || [],