refactor: reorganize files

This commit is contained in:
yangsy
2025-11-22 01:46:16 +08:00
parent 00a961c346
commit a486f76aaf
148 changed files with 1440 additions and 1170 deletions

View File

@@ -1,5 +1,5 @@
<script setup lang="ts">
import { postNdmDeviceAlarmLogPage, type NdmDeviceAlarmLogResultVO, type NdmDeviceResultVO, type PageParams } from '@/apis';
import { pageDeviceAlarmLogApi, type NdmDeviceAlarmLogResultVO, type NdmDeviceResultVO, type PageParams } from '@/apis';
import { renderAlarmDateCell, renderAlarmTypeCell, renderFaultDescriptionCell, renderFaultLevelCell } from '@/components';
import { useMutation } from '@tanstack/vue-query';
import { NCard, NDataTable, type DataTableColumns, type DataTableRowData, type DatePickerProps, type PaginationProps } from 'naive-ui';
@@ -86,11 +86,16 @@ const { mutate: getDeviceAlarmLogList, isPending } = useMutation({
sort: 'id',
order: 'descending',
};
const res = await postNdmDeviceAlarmLogPage(stationCode.value, {
model: { deviceId },
extra: { alarmDate_ge, alarmDate_le },
...restParams,
});
const res = await pageDeviceAlarmLogApi(
{
model: { deviceId },
extra: { alarmDate_ge, alarmDate_le },
...restParams,
},
{
stationCode: stationCode.value,
},
);
return res;
},
onSuccess: ({ records, size, total }) => {