diff --git a/src/views/liquid/index.vue b/src/views/liquid/index.vue index 44b179f..970ee98 100644 --- a/src/views/liquid/index.vue +++ b/src/views/liquid/index.vue @@ -98,6 +98,10 @@ const onStartAddLiquid = async () => { FtMessage.warning('加液容量不能大于总容量') return } + if (drainWorkState.value.workState !== 'idle') { + ElMessage.warning('正在排液中,不可进行加液操作') + return + } const params = { className: 'AddLiquidService', fnName: 'start', @@ -123,6 +127,10 @@ const onStopAddLiquid = async () => { } // 开始排液 const onStartDrainLiquid = async () => { + if (addWorkState.value.workState !== 'idle') { + ElMessage.warning('正在加液中,不可进行排液操作') + return + } const statusName = getDeviceStatus() if (statusName) { FtMessageBox.error(statusName) @@ -140,10 +148,6 @@ const onStartDrainLiquid = async () => { } const onStopDrainLiquid = async () => { - if (drainWorkState.value.workState === 'idle') { - ElMessage.warning('正在加液中,不可进行排液操作') - return - } const params = { className: 'DrainLiquidService', fnName: 'stop',