diff --git a/src/assets/img/liquid/oper.png b/src/assets/img/liquid/oper.png index 814f7e2..cad9399 100644 Binary files a/src/assets/img/liquid/oper.png and b/src/assets/img/liquid/oper.png differ diff --git a/src/components/LiquidHandle.vue b/src/components/LiquidHandle.vue index 6423984..a6bc859 100644 --- a/src/components/LiquidHandle.vue +++ b/src/components/LiquidHandle.vue @@ -6,7 +6,7 @@ type="number" v-model="addLiquidVal" :clickable="true" - :maxlength="3" + :maxlength="4" readonly @touchstart.stop="numberKeyboardShow = true" class="add_liquid_input" @@ -116,7 +116,7 @@ @@ -142,14 +142,14 @@ const props = defineProps({ }, }) -const addLiquidVal = ref(1) +const addLiquidVal = ref(2000) const tipModalVisible = ref(false) const webSocketStore = useWebSocketStore() const isPopLiquidStatus = ref(false) const startAdd = () => { - if (!operatorStore.replenishingFluidsWorkState) { + if (!(operatorStore.replenishingFluidsWorkState == 1)) { console.log(startReplenishingFluidsJSON(parseInt(addLiquidVal.value))) webSocketStore.sendCommandMsg( startReplenishingFluidsJSON(parseInt(addLiquidVal.value)), @@ -158,19 +158,19 @@ const startAdd = () => { } const stopAdd = () => { - if (operatorStore.replenishingFluidsWorkState) { + if (operatorStore.replenishingFluidsWorkState == 1) { webSocketStore.sendCommandMsg(stopReplenishingFluidsJSON) } } const stopPop = () => { - if (operatorStore.drainingWorkState) { + if (operatorStore.drainingWorkState == 1) { webSocketStore.sendCommandMsg(stopDrainingJSON) } } const startTabLiquid = () => { - if (!operatorStore.drainingWorkState) { + if (!(operatorStore.drainingWorkState == 1)) { tipModalVisible.value = true } } diff --git a/src/components/LoginForm.vue b/src/components/LoginForm.vue index ee5d8f7..04b2695 100644 --- a/src/components/LoginForm.vue +++ b/src/components/LoginForm.vue @@ -84,6 +84,7 @@ const handleLogin = () => { tip.value = '' webSocketStore?.sendCommandMsg(loginJSON(username.value, password.value)) // 前端自己校验 + console.log(userStore.allUserList) let flag = false userStore.allUserList?.map(item => { if (item.uid == username.value && password.value == item.passwd) { @@ -91,10 +92,11 @@ const handleLogin = () => { flag = true userStore.updatePermission(item.permission_level) userStore.updateLoginUser(item.uid) + window.location.href = 'http://127.0.0.1/' } }) - if (flag) { - router.push('/') + if (!flag) { + tip.value = '账号或密码错误' } } @@ -135,7 +137,7 @@ const handleLogin = () => { left: 120px; top: 142px; font-family: Source Han Sans CN; - font-size: 12px; + font-size: 18px; font-weight: 350; letter-spacing: 0.06em; } @@ -148,7 +150,7 @@ const handleLogin = () => { left: 120px; top: 209px; font-family: Source Han Sans CN; - font-size: 12px; + font-size: 18px; font-weight: 350; letter-spacing: 0.06em; } diff --git a/src/components/Operator.vue b/src/components/Operator.vue index d064108..b9aa356 100644 --- a/src/components/Operator.vue +++ b/src/components/Operator.vue @@ -121,7 +121,7 @@ const toDetail = () => { } const logVisible = ref(false) -const logVal = ref(1) +const logVal = ref('3') const roomSize = ref(0) watch(() => { @@ -148,7 +148,7 @@ const startDisinfect = () => { localStorage.removeItem('envir2') localStorage.clear() webSocketStore.sendCommandMsg( - startDisinfectionJSON(logVal.value, roomSize.value), + startDisinfectionJSON(parseInt(logVal.value), parseInt(roomSize.value)), ) props.changeShowOperator(false) } diff --git a/src/components/Progress.vue b/src/components/Progress.vue index cf24753..5760127 100644 --- a/src/components/Progress.vue +++ b/src/components/Progress.vue @@ -26,10 +26,20 @@ ? 'btn active' : 'btn' " + v-if="[1, 2].includes(operatorStore.disinfectStatus)" @click="stopDisinfect" > 停止消毒 +
+ 返回 +