From 1bdd5c276ff1e35e0b9b469194bb5191f9631690 Mon Sep 17 00:00:00 2001 From: hwj Date: Sat, 9 May 2026 17:34:02 +0800 Subject: [PATCH] =?UTF-8?q?style=EF=BC=9A=E4=BA=A7=E8=83=BD=E6=8A=A5?= =?UTF-8?q?=E8=A1=A8-=E5=88=A0=E9=99=A4=E7=8A=B6=E6=80=81=E5=AD=97?= =?UTF-8?q?=E6=AE=B5?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/views/mes/capacityReport/index.vue | 47 -------------------------- 1 file changed, 47 deletions(-) diff --git a/src/views/mes/capacityReport/index.vue b/src/views/mes/capacityReport/index.vue index ce7cd84e..26e8de5f 100644 --- a/src/views/mes/capacityReport/index.vue +++ b/src/views/mes/capacityReport/index.vue @@ -35,17 +35,6 @@ class="!w-240px" /> - - - - - - - - - @@ -135,7 +114,6 @@ const queryParams = reactive({ deviceCode: undefined, deviceName: undefined, deviceType: undefined, - deviceStatus: undefined, workshop: undefined }) const queryFormRef = ref() @@ -148,31 +126,6 @@ const selectedIds = ref([]) const toggleFilters = () => { showAllFilters.value = !showAllFilters.value } -const deviceStatusUpdatingMap = ref>({}) - -const isDeviceLedgerEnabled = (row: CapacityReportVO) => { - return Number(row.deviceStatus) === 0 -} - -const handleDeviceStatusChange = async (row: CapacityReportVO, value: boolean) => { - if (!row?.id) return - const oldValue = Number(row.deviceStatus) - const nextValue = value ? 0 : 1 - row.deviceStatus = nextValue - deviceStatusUpdatingMap.value[row.id] = true - try { - await DeviceLedgerApi.updateDeviceLedger({ - id: row.id, - deviceStatus: nextValue - }) - message.success(t('common.updateSuccess')) - } catch { - row.deviceStatus = oldValue - message.error(t('common.updateFail')) - } finally { - deviceStatusUpdatingMap.value[row.id] = false - } -} const getList = async () => { loading.value = true