From d8d792a6842832e8f6af6604274c438b25053afe Mon Sep 17 00:00:00 2001
From: longyvfengyun <496960745@qq.com>
Date: 星期一, 25 十二月 2023 09:00:32 +0800
Subject: [PATCH] 内容提交

---
 src/pages/dataTest/realTime.vue |   83 +++++++++++++++++++++++++++++------------
 1 files changed, 59 insertions(+), 24 deletions(-)

diff --git a/src/pages/dataTest/realTime.vue b/src/pages/dataTest/realTime.vue
index 21dd2fa..a1aee4c 100644
--- a/src/pages/dataTest/realTime.vue
+++ b/src/pages/dataTest/realTime.vue
@@ -916,7 +916,7 @@
       top="0"
       class="dialog-center"
       :modal-append-to-body="false"
-    > 
+    >
         <div class="wx_guides">
           <p>鍙傝�冪嚎锛�</p>
           <p><el-input v-model="guidesVal"></el-input></p>
@@ -943,6 +943,20 @@
       </div>
     </right-menu>
     <stop-outline-curing :dev-id="batt.FBSDeviceId" :stop-time="stopTime"></stop-outline-curing>
+	  <el-dialog
+		  title="浜鸿劯鏍¢獙"
+		  width="480px"
+		  :visible.sync="startFaceShow"
+		  :close-on-click-modal="false"
+		  top="0"
+		  :modal="false"
+		  class="dialog-center"
+		  :modal-append-to-body="false"
+		  :destroy-on-close="true">
+		  <check-face
+			  v-if="startFaceShow"
+			  @checkSuccess="startFaceSuccess"></check-face>
+	  </el-dialog>
   </flex-layout>
 </template>
 
@@ -1012,12 +1026,15 @@
 import AutoCheck from "@/pages/dataTest/dialogs/autoCheck";
 import const_9120 from "@/assets/js/const/const_9120";
 import LithiumPackTab from "@/pages/dataTest/components/lithiumPackTab";
+import CheckFace from "@/components/checkFace.vue";
+import config from "@/assets/js/config";
 
 /* import moment from "moment"; */
 let vol, resChart, temp, conduct, currChart, leakVol, monConnRes;
 let tblData = [];
 export default {
   components: {
+	  CheckFace,
     LithiumPackTab,
     AutoCheck,
     stopOutlineCuring,
@@ -1066,6 +1083,9 @@
         this.resize();
       });
     },
+    "$store.user.realTabsConfig"(pageConfig) {
+      this.pageConfig = pageConfig;
+    }
     // "diagram.type"(n) {
     //   // console.log(n, '===========娴嬭瘯绫诲瀷锛�');
     //   let batt = this.batt;
@@ -1080,6 +1100,7 @@
     let lastCapacityTest = const_61850.lastCapacityTest;
     let pageConfig = this.$store.getters["user/realTabsConfig"];
     return {
+	    startFaceShow: false,
       // 鎴愰兘鐭冲寲
       cdshStatus:this.cdshFan(),
       guidesDialog:false,
@@ -1092,7 +1113,7 @@
         leakVol:0
 
       },
-      // 
+      //
       loading: false,
       workPlanDialog: false,
       dcdcWorkDialog: false,
@@ -1605,7 +1626,7 @@
     cdshFan:function(){
       return this.$CFG.clientName.name;
     },
-    // 
+    //
     tabClick(tab) {
       this.acTabs = tab.name;
       // 鏍规嵁tab鏇存柊鐢佃矾鍥�
@@ -1942,6 +1963,16 @@
       if (regEquipType(data.FBSDeviceId, ["equip61850"])) {
         this.getLastCapacityTest(data);
       }
+
+      let keyList = ["eleLine", "vol", "res", "temp", "conduct", "monConnRes",
+        "curr", "leakVol", "tblData", "dianchigaojing", "niBianInfoTab", "jggdInfoTab", "elePrice", "bmsInfo"];
+      for(let i=0; i<keyList.length; i++) {
+        let key = keyList[i];
+        if(this.pageConfig[key]) {
+          this.acTabs = key;
+          break;
+        }
+      }
       this.loading = true;
       this.changeTabsName();
       this.$nextTick(()=>{
@@ -2154,7 +2185,7 @@
                         // }else{
                           obj[key] = vm.guidesData[key];
                         // }
-                        
+
                       }
                       return obj;
                     }();
@@ -2725,7 +2756,7 @@
         this.chargeMon = chargeMon;
         this.dischargeMon = dischargeMon;
         this.tdata = data;
-        
+
         // 鏇存柊琛ㄦ牸
         if (this.acTabs == "tblData") {
           this.table.datas = data;
@@ -3373,6 +3404,20 @@
     closeDisChargeDialog() {
       this.dischargeDialog.show = false;
     },
+	  startFaceSuccess() {
+			this.startFaceShow = false;
+		  let batt = this.batt;
+		  let loading = this.$layer.loading();
+		  this.$apis.outline.restart(batt.FBSDeviceId).then((res) => {
+			  let rs = JSON.parse(res.data.result);
+			  if (rs.code == 1) {
+				  this.$alert("鍙戦�侀噸鍚懡浠ゆ垚鍔�", "绯荤粺鎻愮ず");
+			  } else {
+				  this.$alert("鍙戦�侀噸鍚懡浠ゅけ璐�!", "绯荤粺鎻愮ず");
+			  }
+			  this.$layer.close(loading);
+		  }).catch((error) => {});
+	  },
     restartSystem() {
       let self = this;
       let batt = this.batt;
@@ -3381,27 +3426,17 @@
         confirmButtonText: "纭畾",
         cancelButtonText: "鍙栨秷",
         inputType: "password",
-      })
-        .then(({ value }) => {
+      }).then(({ value }) => {
           if (value == resetPwd) {
-            let loading = this.$layer.loading();
-            this.$apis.outline
-              .restart(batt.FBSDeviceId)
-              .then((res) => {
-                let rs = JSON.parse(res.data.result);
-                if (rs.code == 1) {
-                  this.$alert("鍙戦�侀噸鍚懡浠ゆ垚鍔�", "绯荤粺鎻愮ず");
-                } else {
-                  this.$alert("鍙戦�侀噸鍚懡浠ゅけ璐�!", "绯荤粺鎻愮ず");
-                }
-                this.$layer.close(loading);
-              })
-              .catch((error) => {});
+	          if (config.dischargeByFace.value) {
+							this.startFaceShow = true;
+	          }else {
+		          this.startFaceSuccess();
+	          }
           } else {
             this.$layer.msg("瀵嗙爜涓嶆纭�");
           }
-        })
-        .catch(() => {});
+        }).catch(() => {});
     },
     changeSkin() {
       this.$nextTick(() => {
@@ -3539,7 +3574,7 @@
       if(this.cdshStatus == "cdsh"){
         list.MonCount = this.inputs.MonCount;
         list.MonVolStd = this.inputs.MonVolStd + "V";
-        
+
       }
       if (this.inputs.batt_state === 3) {
         // 涓�0鏄笉鏇存柊鍓╀綑瀹归噺
@@ -3979,7 +4014,7 @@
 .wx_guides p {
   display: inline-block;
   margin-right: 10px;
-  
+
 }
 .wx_guides p /deep/.el-input__inner {
   color:#000;

--
Gitblit v1.9.1