Explorar o código

fix: 点击空调开关按钮弹加班弹窗

chenzhen2 %!s(int64=2) %!d(string=hai) anos
pai
achega
298eb36d3b

+ 8 - 0
src/views/envmonitor/components/Air/manualIndex.vue

@@ -757,6 +757,14 @@ export default defineComponent({
       // 总控制改变空调状态
       airChange() {
         // 先不更新状态等确认框弹出后再更新状
+        // 操作空调
+        const domAirOpen = !proxyData.airData.isOpen;
+        if (proxyData.forceOverTimeFlag && domAirOpen) {
+          //需要强制加班
+          contx.emit("triggerWork", 2);
+          return;
+        }
+
         proxyData.airData.isOpen = !proxyData.airData.isOpen;
         proxyData.loadingAir = true;
         proxyData.loadingTimer = 0;

+ 1 - 1
src/views/envmonitor/components/Light/index.vue

@@ -158,7 +158,7 @@ export default defineComponent({
           if (type === "allLamp") {
             if (proxyData.forceOverTimeFlag && proxyData.lampSw) {
               // 强制加班开灯
-              contx.emit("triggerWork");
+              contx.emit("triggerWork",3);
               return;
             }
             //  总开关按钮所有灯

+ 16 - 0
src/views/envmonitor/components/ManualWork/index.vue

@@ -688,6 +688,22 @@ export default defineComponent({
           proxyData.nowData.equipmentList.map((item: any) => {
             item.isCheck = true;
           });
+        } else if (proxyData.enterType === 2) {
+          proxyData.nowData.equipmentList.map((item: any) => {
+            if (item.equipmentCategory !== "SELTLT") {
+              item.isCheck = true;
+            } else {
+              item.isCheck = false;
+            }
+          });
+        } else {
+          proxyData.nowData.equipmentList.map((item: any) => {
+            if (item.equipmentCategory !== "SELTLT") {
+              item.isCheck = false;
+            } else {
+              item.isCheck = true;
+            }
+          });
         }
       },
       setWorkTimeList() {