longyvfengyun
2023-12-25 d8d792a6842832e8f6af6604274c438b25053afe
src/pages/dataTest/realTime.vue
@@ -6,10 +6,7 @@
      @toggleChange="toggleChange"
      @leaf-click="leafClick"
    ></home-list>
    <content-box
      style="margin-left: 4px; margin-right: 4px;"
      :title="battFullName"
    >
    <content-box style="margin-left: 4px; margin-right: 4px;" :title="battFullName" >
      <div slot="box-tools" class="box-tools">
        <el-tooltip
          class="item"
@@ -33,10 +30,19 @@
          ></i>
        </el-tooltip>
      </div>
      <div style="right: 72px;" slot="box-tools" class="box-tools">
        <el-tooltip
          class="item"
          effect="dark"
          content="通讯状态"
          placement="bottom">
          <hdw-light :type="isLink"></hdw-light>
        </el-tooltip>
      </div>
      <div
        slot="box-tools"
        class="box-tools"
        style="right: 72px;"
        style="right: 110px;"
        v-if="esVideoSn"
      >
        <el-tooltip
@@ -56,9 +62,55 @@
      <!--                    <i class="iconfont el-icon-icon-test" @click="nibian.show=true"></i>-->
      <!--                </el-tooltip>-->
      <!--            </div>-->
      <flex-layout :no-bg="true">
      <flex-layout :no-bg="true" :loading="loading">
        <div class="content-header" slot="header" :model="inputs">
          <div class="table-layout">
        <div class="table-layout" v-if="cdshStatus == 'cdsh'">
            <div class="table-row">
              <div class="table-cell text-right w80">电池状态:</div>
              <div class="table-cell">
                <el-input
                  :value="backInputs.batt_state"
                  size="small"
                  :disabled="true"
                ></el-input>
              </div>
              <div class="table-cell text-right w80">端电压:</div>
              <div class="table-cell">
                <el-input
                  :value="backInputs.group_online_vol"
                  size="small"
                  :disabled="true"
                ></el-input>
              </div>
              <div class="table-cell text-right w80">电池电流:</div>
              <div class="table-cell">
                <el-input
                  :value="backInputs.group_curr"
                  size="small"
                  :disabled="true"
                ></el-input>
              </div>
            </div>
            <div class="table-row">
              <div class="table-cell text-right w80">单体电池数量:</div>
              <div class="table-cell">
                <el-input
                  :value="backInputs.MonCount"
                  size="small"
                  :disabled="true"
                ></el-input>
              </div>
              <div class="table-cell text-right w80">标称单体电压:</div>
              <div class="table-cell">
                <el-input
                  :value="backInputs.MonVolStd"
                  size="small"
                  :disabled="true"
                ></el-input>
              </div>
            </div>
          </div>
          <div class="table-layout" v-else>
            <div class="table-row">
              <div class="table-cell text-right w80">电池状态:</div>
              <div class="table-cell">
@@ -134,6 +186,9 @@
            class="page-content-tools"
            v-if="control.show && isCanTest && isTestDev"
          >
            <button class="hdw-btn transparentBtn" @click="guidesDialog = true" v-if="(acTabs == 'vol'||acTabs == 'res'||acTabs == 'temp'||acTabs == 'conduct'||acTabs == 'leakVol')&&cdshStatus=='cdsh'">
              <span class="light-color">设置参考线</span>
            </button>
            <el-popover placement="bottom" trigger="hover">
              <div class="hdw-menu-list">
                <ul>
@@ -164,7 +219,7 @@
                      >削峰填谷计划</a
                    >
                  </li>
                  <li class="hdw-menu-item" v-if="isShowJunHeng">
                  <li class="hdw-menu-item" v-if="isShowJunHeng && control.data.juheng.show">
                    <a
                      @click="balanceControlDialog = true"
                      href="javascript:void(0);"
@@ -204,7 +259,7 @@
                    class="hdw-menu-item"
                    v-if="control.data.stopOutlineYH.show"
                  >
                    <a href="javascript:void(0);">停止离线养护</a>
                    <a href="javascript:void(0);" @click="stopOutLineCuring">停止离线养护</a>
                  </li>
                  <li class="hdw-menu-item" v-if="isRestartCircle">
                    <a
@@ -232,12 +287,12 @@
            class="flex-layout noborder"
            @tab-click="tabClick"
          >
            <el-tab-pane key="eleLine" label="电路拓扑图" name="eleLine" v-if="pageConfig.eleLine && !isLd9">
            <el-tab-pane key="eleLine" label="电路拓扑图" name="eleLine" v-if="pageConfig.eleLine">
              <div style="position: absolute;top: 8px; left: 8px">
                <science-box
                  style="position: relative"
                  no-header
                  v-show="stateListState"
                  v-show="stateListState && batt.FBSDeviceId"
                >
                  <div class="hdw-state-list table-layout">
                    <div
@@ -280,7 +335,7 @@
                <science-box
                  style="position: relative; margin-top: 8px"
                  no-header
                  v-show="stateListState"
                  v-show="stateListState && batt.FBSDeviceId && showHistoryStateList.length"
                >
                  <div class="hdw-state-list table-layout">
                    <div
@@ -304,8 +359,35 @@
                    </div>
                  </div>
                </science-box>
                <!-- 上次核容测试信息 -->
                <science-box
                  style="position: relative; margin-top: 8px"
                  title="上一次核容测试信息"
                  v-show="stateListState && batt.FBSDeviceId"
                >
                  <div class="hdw-state-list table-layout">
                    <div
                      v-for="state in lastCapacityTest.filter((item) => item.show)"
                      :key="state.text"
                      class="table-row"
                      :class="state.type"
                    >
                      <div class="table-cell text-right">
                        <i
                          v-if="state.icon"
                          class="iconfont"
                          :class="state.icon"
                        ></i
                        >{{ state.text }}
                      </div>
                      <div class="table-cell">
                        {{ state.value }}{{ state.unit }}
                      </div>
                    </div>
                  </div>
                </science-box>
              </div>
              <div style="position: absolute;top: 8px; left: 8px" v-if="isLithium">
              <div style="position: absolute;top: 8px; left: 8px" v-if="isLithium" v-show="batt.FBSDeviceId">
                <science-box
                  style="position: relative"
                  no-header>
@@ -330,6 +412,7 @@
                </science-box>
              </div>
              <circuit-diagram
                v-show="batt.FBSDeviceId"
                :batt="batt"
                :online-vol="inputs.online_vol"
                :group-vol="inputs.group_vol"
@@ -341,6 +424,9 @@
                :contact-res="diagram.contactRes"
                :drop-vol="diagram.dropVol"
                :dev-type="diagram.devType"
                :charge-mon="chargeMon"
                :discharge-mon="dischargeMon"
                :buscouple-switch="buscoupleSwitch"
              ></circuit-diagram>
            </el-tab-pane>
            <el-tab-pane
@@ -356,6 +442,19 @@
                :show-tools="true"
                @right-click="chartRightCLick"
              ></bar-chart>
            </el-tab-pane>
            <el-tab-pane
              key="lithiumPack"
              label="锂电池信息"
              name="lithiumPack" v-if="isLithiumPack">
              <lithium-pack-tab
                ref="lithiumPack"
                :update="acTabs=='lithiumPack'"
                :change-flag="dataChangeFlag"
                :mon-vols="monVols"
                :mon-temps="monTemps"
                :pack-vols="packVols"
                :pack-currs="packCurrs"></lithium-pack-tab>
            </el-tab-pane>
            <el-tab-pane
              key="res"
@@ -449,11 +548,11 @@
              label="数据表格"
              name="tblData"
              class="el-table-wrapper"
              v-if="pageConfig.tblData"
              v-if="pageConfig.tblData && !isLithiumPack"
            >
              <el-table stripe size="small" :data="table.datas" height="100%">
              <el-table stripe size="small" :data="table.datas" height="100%" :row-class-name="setTableRowClass">
                <el-table-column
                  v-for="header in table.headers"
                  v-for="header in dataHeaders"
                  :key="header.prop"
                  :prop="header.prop"
                  :label="header.label"
@@ -581,7 +680,7 @@
                    <el-table-column
                      prop="monRestCapAlarm"
                      align="center"
                      label="单体剩余容量告警"
                      label="单体预估容量告警"
                    >
                      <template slot-scope="scope">
                        <!-- <img :src="eleOffImg" class="lampImg"
@@ -620,7 +719,7 @@
            <el-tab-pane label="电价统计分析" name="elePrice" v-if="isLithium && pageConfig.elePrice">
              <ele-price-tpl ref="elePriceTpl" :devId="batt.FBSDeviceId" :name="acTabs" :batt="batt"></ele-price-tpl>
            </el-tab-pane>
            <el-tab-pane label="BMS信息" name="bmsInfo" v-if="isLithium" v-show="false">
            <el-tab-pane label="BMS信息" name="bmsInfo" v-if="isLithium || isLithiumPack" v-show="false">
              <bms-info ref="bmsInfo" :batt="batt" :real-update="acTabs=='bmsInfo'"></bms-info>
            </el-tab-pane>
          </el-tabs>
@@ -630,7 +729,7 @@
    <!-- 放电参数设置 -->
    <el-dialog
      :title="dischargeDialogTitle"
      width="700px"
      width="auto"
      :visible.sync="dischargeDialog.show"
      :close-on-click-modal="false"
      top="0"
@@ -639,6 +738,7 @@
    >
      <discharge-dialog-content
        v-if="dischargeDialog.show"
        :tdata="tdata"
        :batt="batt"
        @close="closeDisChargeDialog"
      >
@@ -808,6 +908,22 @@
        :batt="batt"
      ></work-plan>
    </el-dialog>
    <!-- 设置参考线 -->
    <el-dialog
      title="设置参考线"
      width="600px"
      :visible.sync="guidesDialog"
      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>
          <el-button type="primary" @click="setGuidesAlert()">设置</el-button>
          <el-button type="info" @click="guidesDialog = false">取消</el-button>
        </div>
    </el-dialog>
    <right-menu
      :visible.sync="rightMenu.show"
      :x="rightMenu.x"
@@ -826,10 +942,26 @@
        </ul>
      </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>
<script>
import stopOutlineCuring from "@/components/params/stopOutlineCuring";
import ContentBox from "../../components/ContentBox";
import HomeList from "./HomeList";
import BarChart from "../../components/chart/BarChart";
@@ -851,27 +983,32 @@
  realTimeNot,
  realTimeAdd,
  BattRtAlarmActionGetInfo,
  BattRsAlarmActionGetInfo, realTimeXuHang,
} from "../../assets/js/realTime";
import {
  BattRsAlarmActionGetInfo,
  // realTimeXuHang,
  realTimeSearch,
  realTimeGroup,
  realTimeAlarm,
  realTimePowerOff,
  realTimeLd9Data,
  realTimeStateList,
  inversionInfo,
  inversionInfo, inversionData,
} from "../../assets/js/realTime";
import {
  getLastCapacityTest
} from "../../assets/js/history";
import {
  formatSeconds,
  sethoubeiTime,
  Timeout,
  regEquipType,
  getBarNum,
  GetMonomerCap,
  GetHourRate,
  isHasPermit,
  getConduct,
  getConduct, getLabelByValue,
} from "../../assets/js/tools";
import { const_61850, const_9100 } from "../../assets/js/const";
import { const_61850, const_9100, const_ld_nine } from "../../assets/js/const";
import getMarkLineData from "@/components/chart/js/getMarkLineData";
import BarChartThreeD from "@/components/chart/BarChartThreeD";
import JggdInfoTab from "./components/jggdInfoTab.vue";
@@ -886,12 +1023,21 @@
import workPlan from "@/pages/dataTest/dialogs/dcdc/workPlan";
import ElePriceTpl from "@/pages/dataTest/components/elePriceTpl";
import BmsInfo from "@/pages/dataTest/components/bmsInfo";
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,
    BmsInfo,
    ElePriceTpl,
    EzVideo,
@@ -937,14 +1083,38 @@
        this.resize();
      });
    },
    "$store.user.realTabsConfig"(pageConfig) {
      this.pageConfig = pageConfig;
    }
    // "diagram.type"(n) {
    //   // console.log(n, '===========测试类型:');
    //   let batt = this.batt;
    //   this.getLastCapacityTest(batt);
    // }
  },
  data() {
    let permits = this.$store.state.user.permits;
    let isCanTest = isHasPermit("batt_test_op_permit", permits);
    let stateList = const_61850.stateList;
    let historyStateList = const_61850.historyStateList;
    let lastCapacityTest = const_61850.lastCapacityTest;
    let pageConfig = this.$store.getters["user/realTabsConfig"];
    return {
       startFaceShow: false,
      // 成都石化
      cdshStatus:this.cdshFan(),
      guidesDialog:false,
      guidesVal:"",
      guidesData:{
        monVol:0,
        monTemp:0,
        monRes:0,
        monConduct:0,
        leakVol:0
      },
      //
      loading: false,
      workPlanDialog: false,
      dcdcWorkDialog: false,
      balanceControlDialog: false,
@@ -959,6 +1129,7 @@
      dev_version: "",
      username: sessionStorage.getItem("username"),
      pageConfig: pageConfig,
      stopTime: 0,
      rightMenu: {
        show: false,
        x: 0,
@@ -976,50 +1147,63 @@
        batt_rest_cap: 0, // 剩余容量
        batt_state: 0 /* 电池状态 */,
        devTemperature: 0, // 环境温度
        devHumidity: 0, // 环境湿度
        devHumidity: 0, // 环境湿度,
        note: -1,   // 实际容量
        list: "",
      },
      chargeMon: "",
      dischargeMon: "",
      acTabs: "eleLine",
      tdata: [],
      table: {
        headers: [
          {
            prop: "num1",
            label: "单体编号",
            width: "",
            key1: "",
          },
          {
            prop: "vol1",
            label: "电压(V)",
            width: "",
            key1: "vol",
          },
          {
            prop: "res1",
            label: "内阻(mΩ)",
            width: "",
            key1: "res",
          },
          {
            prop: "temp1",
            label: "温度(℃)",
            width: "",
            key1: "temp",
          },
          {
            prop: "conduct1",
            label: "电导",
            width: "",
            key1: "conduct",
          },
          {
            prop: "monConnRes",
            label: "链接条阻值",
            width: ""
            width: "",
            key1: "monConnRes",
          },
          {
            prop: "curr1",
            label: "均衡电流(A)",
            width: "",
            key1: "curr"
          },
          {
            prop: "leakVol1",
            label: "漏液电压(V)",
            width: "",
            key1: "leakVol"
          },
        ],
        datas: [
@@ -1063,7 +1247,9 @@
      stateListShow: true,
      stateList: stateList,
      historyStateList: historyStateList,
      lastCapacityTest: lastCapacityTest,
      timer: new Timeout("realTime"),
      timer2: new Timeout("realTime"),
      diagram: {
        update: true,
        type: -1,
@@ -1155,6 +1341,12 @@
            typeShow: false,
            id: 20,
          },
          juheng: {
            // 均衡控制参数设置
            show: true,
            typeShow: false,
            id: 21,
          }
        },
      },
      powerChart: {
@@ -1416,9 +1608,25 @@
      lithiumParams: {
        analog: lithiumInfo.analog().params,
      },
      // 空开状态 0-断开 1-闭合
      buscoupleSwitch: 0,
      // 数据更新标识
      dataChangeFlag: 0,
      // 单体电压信息
      monVols: [],
      // 单体温度信息
      monTemps: [],
      // 包电压
      packVols:[],
      packCurrs: [],
    };
  },
  methods: {
    // 成都石化判断
    cdshFan:function(){
      return this.$CFG.clientName.name;
    },
    //
    tabClick(tab) {
      this.acTabs = tab.name;
      // 根据tab更新电路图
@@ -1445,26 +1653,24 @@
      let postData = {
        battGroupId: this.batt.BattGroupId,
      };
      BattRtAlarmActionGetInfo(postData)
        .then((res) => {
          let rs = JSON.parse(res.data.result);
          if (rs.code == 1) {
            this.table2.datas = rs.data;
          }
        })
        .catch((err) => {
          console.log(err);
        });
      BattRsAlarmActionGetInfo(postData)
        .then((res) => {
          let rs = JSON.parse(res.data.result);
          if (rs.code == 1) {
            this.table1.datas = rs.data;
          }
        })
        .catch((err) => {
          console.log(err);
        });
      if(this.tabsConfig.dianchigaojing && this.pageConfig.dianchigaojing) {
        BattRtAlarmActionGetInfo(postData).then((res) => {
            let rs = JSON.parse(res.data.result);
            if (rs.code == 1) {
              this.table2.datas = rs.data;
            }
          }).catch((err) => {
            console.log(err);
          });
        BattRsAlarmActionGetInfo(postData).then((res) => {
            let rs = JSON.parse(res.data.result);
            if (rs.code == 1) {
              this.table1.datas = rs.data;
            }
          }).catch((err) => {
            console.log(err);
          });
      }
    },
    toggleChange() {
      this.resize();
@@ -1478,6 +1684,8 @@
        this.$refs.elePriceTpl.resize();
      } else if(this.acTabs == "bmsInfo") {
        this.$refs.bmsInfo.resize();
      }else if(this.acTabs == "lithiumPack") {
        this.$refs.lithiumPack.resize();
      }else {
        this.$G.chartManage.resize(this.acTabs);
      }
@@ -1664,6 +1872,9 @@
    },
    setChart() {
      let acTabs = this.acTabs;
      if(!this.$refs[acTabs]) {
        return;
      }
      switch (acTabs) {
        case "vol":
          this.$refs.vol.setOption(vol);
@@ -1689,16 +1900,30 @@
      }
    },
    startTimer() {
      this.timer.start(() => {
        this.$axios
          .all([
      // 计时器2
      this.timer2.start(()=>{
        this.$axios.all([
            this.realTimeSearch(),
        ]).then(()=>{
          this.dataChangeFlag = Math.random(); // 数据更新
          this.timer2.open();
        }).catch(()=>{
          this.dataChangeFlag = Math.random(); // 数据更新
          this.timer2.open();
        });
      }, 3000);
      // 计时器1
      this.timer.start(() => {
        this.$axios.all([
            this.realTimeGroupss(),
            this.realTimePowerOffs(),
            this.realStateTimeData(),
            this.realTimeStateList(),
            this.loadDevAla(),
            //this.inversionInfo()
            this.getLithiumAnalog(), // 锂电池模拟量
            this.inversionData(),
            this.getLastCapacityTest(this.batt),
          ])
          .then(() => {
            this.timer.open();
@@ -1711,6 +1936,7 @@
    getBattGroupInfo(BattGroupId) {
      this.homeListShow = false;
      this.timer.name = "movingRingSysteRrealTime";
      this.timer2.name = "movingRingSysteRrealTime";
      this.$apis.dataMager.battGroupMager
        .getBattGroupInfo(BattGroupId)
        .then((res) => {
@@ -1729,12 +1955,27 @@
      this.batt = data;
      this.diagram.desc = "";
      this.realTimeAlarmss();
      this.realTimeXuHang();    // 预估续航时长
      // this.realTimeXuHang();    // 预估续航时长
      this.diagram.devType = getDevType(data.chargeType, data.buscoupleState);
      this.esVideoSn = data.videoUrl;
      this.table.headers = getTblHeader(data.FBSDeviceId);
      // 如果是61850 则查询最后一次放电数据
      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(()=>{
        this.changeTabsName();
        // 开启循环请求
        this.startTimer();
      });
@@ -1745,9 +1986,9 @@
     * 根据设备类型修改Tabs选中状态
     */
    changeTabsName() {
      if(this.isLd9) {
        this.acTabs = "vol";
      }
      // if(this.isLd9) {
      //   this.acTabs = "vol";
      // }
      this.$nextTick(()=>{
        this.resize();
@@ -1763,6 +2004,50 @@
        let rs = JSON.parse(res.data.result);
        if (rs.code == 1) {
          let list = rs.data;
        // 初始化查询参考线
        if(this.cdshStatus == "cdsh"){
          this.getGuides(rs);
        }else{
          this.setLin(rs)
        }
          // // 单体电压
          // this.setChartMarkLine(vol, "Voltage", "Batt_Alarm_Type_MonVol", list);
          // // 单体温度
          // this.setChartMarkLine(
          //   temp,
          //   "Temperature",
          //   "Batt_Alarm_Type_MonTmp",
          //   list
          // );
          // // 单体内阻
          // this.setChartMarkLine(
          //   resChart,
          //   "Resistance",
          //   "Batt_Alarm_Type_MonRes",
          //   list
          // );
          // // 单体电导
          // this.setChartMarkLine(
          //   conduct,
          //   "Conductance",
          //   "Batt_Alarm_Type_MonRes",
          //   list
          // );
          // // 漏液电压
          // this.setChartMarkLine(
          //   leakVol,
          //   "leakVol",
          //   "Batt_Alarm_Type_MonLYVol",
          //   list
          // );
        }
      });
    },
    // 设置高低线参考线
    setLin:function(res){
      if (res.code) {
          let list = res.data;
          // 单体电压
          this.setChartMarkLine(vol, "Voltage", "Batt_Alarm_Type_MonVol", list);
          // 单体温度
@@ -1795,7 +2080,6 @@
            list
          );
        }
      });
    },
    setChartMarkLine(chartData, name, alm_name, list) {
      let batt = this.batt;
@@ -1805,42 +2089,152 @@
        if (item.alm_name == alm_name) {
          let high = 0;
          let low = 0;
          let guides = 0;
          switch (name) {
            case "Voltage": // 电压告警
              //单体电压
              let std_mon_vol = batt.MonVolStd;
              high = parseFloat(std_mon_vol * item.alm_high_coe).toHold(3);
              low = parseFloat(std_mon_vol * item.alm_low_coe).toHold(3);
              if(this.cdshStatus == "cdsh"){
                guides = this.guidesData.monVol;
              }
              break;
            case "Temperature":
              //单体温度
              let std_mon_tmp = 25;
              high = parseFloat(std_mon_tmp * item.alm_high_coe).toHold(1);
              low = parseFloat(std_mon_tmp * item.alm_low_coe).toHold(1);
              if(this.cdshStatus == "cdsh"){
                guides = this.guidesData.monTemp;
              }
              break;
            case "Resistance":
              // 单体电阻
              let std_mon_res =
                (1 * (batt.MonVolStd / 2)) / (batt.MonCapStd / 100);
              high = parseFloat(std_mon_res * item.alm_high_coe).toHold(3);
              low = parseFloat(std_mon_res * item.alm_low_coe).toHold(3);
              if(this.cdshStatus == "cdsh"){
                guides = this.guidesData.monRes;
              }
              break;
            case "Conductance":
              // 单体电导
              let std_mon_ser = batt.MonSerStd;
              high = parseFloat(std_mon_ser * item.alm_high_coe).toHold(0);
              low = parseFloat(std_mon_ser * item.alm_low_coe).toHold(0);
              if(this.cdshStatus == "cdsh"){
                guides = this.guidesData.monConduct;
              }
              break;
            case "leakVol":
              // 漏液电压
              high = parseFloat(item.alm_high_coe);
              low = parseFloat(item.alm_low_coe);
              if(this.cdshStatus == "cdsh"){
                guides = this.guidesData.leakVol;
              }
              break;
          }
          // 低告警
          chartData.series[0].markLine.data[0].yAxis = low;
          // 高告警
          chartData.series[0].markLine.data[1].yAxis = high;
          if(this.cdshStatus == "cdsh"){
            //参考线
            chartData.series[0].markLine.data[2].yAxis = guides;
          }
          break;
        }
      }
    },
    // 获取电池组参考线
    getGuides:function(resdata){
      let vm = this;
      let batt = this.batt;
      let obj = {
        battGroupId:batt.BattGroupId
      }
          // debugger
          vm.$axios({
            method: "POST",
              url: "BattGroupGuidesAction!getAll",
              data:'json=' + JSON.stringify(obj)
          }).then((res)=>{
            let rs = JSON.parse(res.data.result);
                if(rs.code == 1){
                  vm.guidesData = rs.data;
                  console.log(vm.guidesData)
                  vm.setLin(resdata)
                }
            console.log(vm.guidesData);
          })
    },
    // 设置参考线弹窗
    setGuidesAlert:function(){
      let vm = this;
      let params = function(){
                      let obj = {};
                      for (const key in vm.guidesData) {
                        // if(key == 'id'){
                        //   if(vm.guidesData[key] != null){
                        //     obj[key] = vm.guidesData[key];
                        //   }
                        // }else{
                          obj[key] = vm.guidesData[key];
                        // }
                      }
                      return obj;
                    }();
          if(!params.battGroupId){
            params.battGroupId = vm.batt.BattGroupId;
          }
          if(vm.guidesVal != ""){
            switch (vm.acTabs) {
              case "vol"://电压
                params.monVol = vm.guidesVal;
                break;
              case "res"://内阻
                params.monRes = vm.guidesVal;
                break;
              case "temp"://温度
                params.monTemp = vm.guidesVal;
                break;
              case "conduct"://电导
                params.monConduct = vm.guidesVal;
                break;
              case "leakVol"://漏液电压
                params.leakVol = vm.guidesVal;
                break;
            }
            // debugger
            vm.$axios({
              method: "POST",
              url: "BattGroupGuidesAction!update",
              data:"json=" + JSON.stringify(params)
            }).then((rs)=>{
              let res = JSON.parse(rs.data.result);
              if(res.code == 1){
                  vm.$message({
                    message: "设置成功!",
                    type: 'success'
                  });
                  vm.guidesVal = "";
                  vm.guidesDialog = false;
                  vm.realTimeAlarmss();
              }else{
                vm.$message.error("设置失败!");
              }
            })
          }else{
            vm.$message({
              message: '请先填写参考线值!',
              type: 'warning'
            });
          }
    },
    /* 实时组端信息 */
    realTimeGroupss() {
@@ -1848,8 +2242,90 @@
      realTimeGroup(batt.BattGroupId).then((res) => {
        let rsa = JSON.parse(res.data.result);
        if (rsa.code == 1) {
          if(!rsa.data[0].stationId) {
            rsa.data[0].stationId=",-1,-1,-1,-1,-1";
          }
          rsa.data[0].note = Number(rsa.data[0].note);
          this.inputs = rsa.data[0];
          if(this.cdshStatus == "cdsh"){
            let data2 = rsa.data2;
             for (const key in data2) {
              this.inputs[key] = data2[key]
            }
            console.log(this.inputs)
          }
          // 多个实际容量
          let list = rsa.data[0].stationId.split(",").filter(item=>{
            return item != "";
          });
          list = list.map(item=>{
            return (Number(item)-Math.abs(rsa.data[0].batt_test_cap)).toHold(1);
          }).join(",");
          // console.log("*******");
          // console.log("标准曲线实际容量:"+rsa.data[0].stationId);
          // console.log("标准曲线剩余容量:"+list);
          // console.log("旧算法剩余容量:"+rsa.data[0].batt_rest_cap);
          // console.log("*******");
          this.inputs.list = list;
        }
      });
    },
    realStateTimeData() {
      let batt = this.batt;
      if(regEquipType(batt.FBSDeviceId, ["LD9"])) {
        this.realTimeLd9Data();
      }else {
        this.realTimePowerOffs();
      }
    },
    realTimeLd9Data() {
      let batt = this.batt;
      realTimeLd9Data({
        dev_id: batt.FBSDeviceId,
      }).then(res=>{
        let rs = JSON.parse(res.data.result);
        if(rs.code == 1) {
          let data = rs.data[0];
          // 判断是否超时
          let outTime = 2 * 60; //设备超时时间(2分钟)
          let nowTime = new Date(data.note).getTime(); //当前时间
          let record = new Date(data.record_datetime).getTime();
          if (Math.abs(nowTime - record) / 1000 > outTime) {
            this.disconnect();
          }else {
            this.diagram.desc="";
            // 0-在线监测,1-核容测试,2-测试状态状态停止,3-内阻测试
            switch(data.sys_state) {
              case 0:
                this.diagram.type = 0;
                break;
              case 1:
                let chargeMon = this.chargeMon;
                let dischargeMon = this.dischargeMon;
                // 存在放电和充电单体
                if(dischargeMon != "" && chargeMon != "") {
                  this.diagram.type = 6;
                }else if(chargeMon != "") {   // 存在充电单体
                  this.diagram.type = 2;
                }else{
                  this.diagram.type = 1;
                }
                break;
              case 2:
                this.diagram.type = 0;
                break;
              case 3:
                this.diagram.type = 3;
                this.diagram.desc="(内阻测试)";
                break;
            }
          }
        }else {
          this.disconnect();
        }
      }).catch(error=>{
        console.log(error);
        this.disconnect();
      });
    },
    /* 查询电路图开关状态和信息 */
@@ -1876,8 +2352,8 @@
          this.setEquipBase(data);
          // 判断是否超时
          var nowTime = new Date(data.note).getTime(); //当前时间
          var record = new Date(data.record_datetime).getTime();
          let nowTime = new Date(data.note).getTime(); //当前时间
          let record = new Date(data.record_datetime).getTime();
          if (Math.abs(nowTime - record) / 1000 > outTime) {
            this.disconnect();
          } else {
@@ -1888,7 +2364,7 @@
            if (regEquipType(dev_id, "equip61850")) {
              this.setEquip61850(data);
            } else if (
              regEquipType(dev_id, ["BTS", "BTS9110", "BTS9120", "lithium"])
              regEquipType(dev_id, ["BTS", "BTS9110", "BTS9120", "lithium", "LD9", "lithiumPack"])
            ) {
              this.setEquipBTS(data);
            } else if (regEquipType(dev_id, ["BTS9605", "BTS9611"])) {
@@ -1917,7 +2393,7 @@
      // 干接点
      this.setStateList("contact", "未知", "table-row-warn");
      // 核容终止原因
      this.setStateList("stopReason", "未知");
      // this.setStateList("stopReason", "未知");
      // 操作失败原因
      this.setStateList("failReason", "未知");
      // 预估续航时长
@@ -2115,15 +2591,15 @@
      let workStates = const_61850.workstates;
      this.setStateList("workState", workStates[data.dev_workstate]);
      // 核容终止原因
      let stopReasons = const_61850.stopreasons;
      if (data.dev_workstate == 2) {
        this.setStateList("stopReason", "未知");
      } else {
        this.setStateList(
          "stopReason",
          stopReasons[data.dev_last_captest_stop_type]
        );
      }
      // let stopReasons = const_61850.stopreasons;
      // if (data.dev_workstate == 2) {
      //   this.setStateList("stopReason", "未知");
      // } else {
      //   this.setStateList(
      //     "stopReason",
      //     stopReasons[data.dev_last_captest_stop_type]
      //   );
      // }
      // 操作失败原因
      let failReasons = const_61850.failreasons;
@@ -2220,18 +2696,42 @@
          state.type = type ? type : "";
        }
      }
      for (let i = 0, list = this.lastCapacityTest, j = list.length; i < j; i++) {
        let state = list[i];
        if (state.name == name) {
          state.value = value;
          state.type = type || "";
        }
      }
    },
    setTableRowClass({row}) {
      if(row.monState == 1) {
        return "red-row";
      }else if(row.monState ==2) {
        return "green-row";
      }
      return "";
    },
    /* echars图表 */
    realTimeSearch() {
      var batt = this.batt;
      let batt = this.batt;
      let type = this.inputs.batt_state;
      realTimeSearch({
        BattGroupId: batt.BattGroupId,
      }).then((res) => {
        let diagramType = this.diagram.type;
        let rs = JSON.parse(res.data.result);
        let data = [];
        let chargeMon = "";
        let dischargeMon = "";
        if (rs.code == 1 && diagramType != -1) {
          data = rs.data.map((item) => {
            if(item.monState == 1) {
              dischargeMon += (dischargeMon == ""?"#":',#')+item.mon_num;
            }else if(item.monState == 2) {
              chargeMon += (chargeMon == ""?"#":',#')+item.mon_num;
            }
            return {
              num1: "#" + item.mon_num,
              vol1: item.mon_vol,
@@ -2243,9 +2743,20 @@
              curr1: item.mon_JH_curr,
              leakVol1: item.mon_LY_vol,
              monConnRes: item.mon_conn_res,
              monCap: item.mon_cap,
              monTestCap: diagramType==1 || diagramType==2 || diagramType==6?item.monTestCap:"---",
              monResCap: diagramType==1 || diagramType==2 || diagramType==6?item.monRestCap:"---",
              monDisTimeLong: diagramType==1 || diagramType==2 || diagramType==6?Math.floor(item.monDisTimeLong/60) + "时" + (item.monDisTimeLong%60) + "分":"---",
              monState: item.monState,
            };
          });
        }
        // 添加正在测试的单体
        this.chargeMon = chargeMon;
        this.dischargeMon = dischargeMon;
        this.tdata = data;
        // 更新表格
        if (this.acTabs == "tblData") {
          this.table.datas = data;
@@ -2261,6 +2772,12 @@
            return ["#" + item.mon_num, value];
          });
        }
        // 设置电压值
        this.monVols = volTempVol.map(item=>{
          return item[1];
        });
        let volBarNum = getBarNum(volTempVol);
        vol.title.text =
          "最大值=" +
@@ -2299,6 +2816,10 @@
            return ["#" + item.mon_num, value];
          });
        }
        this.monTemps = volTempte.map(item=>{
          return item[1];
        });
        let tempBarNum = getBarNum(volTempte);
        temp.title.text =
          "最大值=" +
@@ -2384,6 +2905,12 @@
        monConnRes.series[0].data = monConnResData;
        // 更新电压图表
        this.setChart();
        this.loading = false;
      }).catch(error=>{
        // 更新电压图表
        this.setChart();
        this.loading = false;
        this.loading = false;
      });
    },
    // 向父级发送同步页面的指令
@@ -2400,6 +2927,10 @@
        batt.StationName3 +
        "&batt=" +
        batt.BattGroupId;
      let url = '#/history';
      if (regEquipType(batt.FBSDeviceId, "LD9")) {
        url = '#/history-ld9';
      }
      window.parent.postMessage(
        {
          cmd: "syncPage",
@@ -2407,7 +2938,7 @@
            pageInfo: {
              label: "历史数据",
              name: "history",
              src: "#/history" + search,
              src: url + search,
              closable: true,
            },
          },
@@ -2436,16 +2967,50 @@
              "BTS9120",
              "BTS9605",
              "lithium",
              "lithiumPack"
            ])
          ) {
            // 停止设备
            this.stopBtsTest();
          } else if (regEquipType(this.batt.FBSDeviceId, "LD9")) {
            this.stopLD9();
          } else {
            // 提示信息
            this.$layer.msg("未知设备类型,暂无法停止测试!");
          }
        }
      );
    },
    // 停止LD9测试
    stopLD9() {
      // 开启等待框
      let loading = this.$layer.loading(1);
      // 请求后台
      this.$apis.dischargeTest.ld9
        .stop({
          num: const_ld_nine.cmd.stop,
          dev_id: this.batt.FBSDeviceId,
          BattGroupNum: this.batt.GroupIndexInFBSDevice+1,
        })
        .then((res) => {
          let rs = JSON.parse(res.data.result);
          if (rs.code == 1) {
            // 提示信息
            this.$layer.msg("停止测试成功");
          } else {
            // 提示信息
            this.$layer.msg("停止测试失败!");
          }
          // 关闭等待框
          this.$layer.close(loading);
        })
        .catch((error) => {
          console.log(error);
          // 关闭等待框
          this.$layer.close(loading);
          // 提示信息
          this.$layer.msg("停止测试失败,停止测试请求异常!");
        });
    },
    // 停止bts测试
    stopBtsTest() {
@@ -2456,6 +3021,7 @@
        .stop({
          num: const_9100.cmd.stop,
          dev_id: this.batt.FBSDeviceId,
          BattGroupNum: this.batt.GroupIndexInFBSDevice+1,
        })
        .then((res) => {
          let rs = JSON.parse(res.data.result);
@@ -2486,6 +3052,7 @@
        .stop({
          num: const_61850.cmd.stop,
          dev_id: this.batt.FBSDeviceId,
          BattGroupNum: this.batt.GroupIndexInFBSDevice+1,
        })
        .then((res) => {
          let rs = JSON.parse(res.data.result);
@@ -2638,21 +3205,26 @@
     */
    getLithiumAnalog() {
      let batt = this.batt;
      let isLithium = regEquipType(batt.FBSDeviceId, ["lithium"]);
      let isLithium = regEquipType(batt.FBSDeviceId, ["lithium", "lithiumPack"]);
      if (isLithium) {
        this.$apis.dcdc
          .getDcDcAnalogParams({
        this.$apis.dcdc.getDcDcAnalogParams({
            devId: batt.FBSDeviceId,
            groupNum: batt.GroupIndexInFBSDevice
          })
          .then((res) => {
            let rs = JSON.parse(res.data.result);
            if (rs.code == 1) {
            if (rs.code == 1 && rs.data.length != 0) {
              // 剩余容量进行累加
              let restCap = 0;
              let packVols = [];
              let packCurrs = [];
              rs.data.map(item=>{
                restCap += item.restCap;
                packVols.push(item.sumVol);
                packCurrs.push(item.current);
              });
              this.packVols = packVols;
              this.packCurrs = packCurrs;
              let data = rs.data[0];
              data.restCap = restCap;
              this.lithiumParams.analog = data;
@@ -2737,29 +3309,28 @@
          console.log(error);
        });
    },
    realTimeXuHang() {
      let batt = this.batt;
      realTimeXuHang(batt.FBSDeviceId).then(res=>{
        let rs = JSON.parse(res.data.result);
        if(rs.data == -1) {
          // 预估续航时长
          this.setStateList("xuHang", "???");
        }else {
          // 预估续航时长
          this.setStateList("xuHang", formatSeconds(rs.data*60));
        }
      }).catch(error=>{
        // 预估续航时长
        this.setStateList("xuHang", "???");
      })
    },
    // realTimeXuHang() {
    //   let batt = this.batt;
    //   realTimeXuHang(batt.FBSDeviceId).then(res=>{
    //     let rs = JSON.parse(res.data.result);
    //     if(rs.data == -1) {
    //       // 预估续航时长
    //       this.setStateList("xuHang", "???");
    //     }else {
    //       // 预估续航时长
    //       this.setStateList("xuHang", formatSeconds(rs.data*60));
    //     }
    //   }).catch(error=>{
    //     // 预估续航时长
    //     this.setStateList("xuHang", "???");
    //   })
    // },
    // 逆变信息
    inversionInfo() {
      let batt = this.batt;
      inversionInfo(batt.FBSDeviceId)
        .then((res) => {
          let rs = JSON.parse(res.data.result);
          console.log(rs);
        })
        .catch((error) => {
          console.log(error);
@@ -2833,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;
@@ -2841,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(() => {
@@ -2874,6 +3449,73 @@
        }
      });
    },
    getLastCapacityTest (batt) {
      let param = {
        num: batt.FBSDeviceId,
        BattGroupId: batt.BattGroupId
      };
      getLastCapacityTest(param).then((res) => {
        res = JSON.parse(res.data.result);
        // console.log(res, 'res======');
        if (res.code) {
          let data = res.data;
          // 上次核容停止原因
          this.setStateList('stopReason', data.test_stoptype_reason);
          // 核容测试的最后一笔数据
          let datalist = data.batttestdataList;
          // 上次核容开始时间
          this.setStateList('test_starttime', data.test_starttime);
          // 上次核容测试容量
          this.setStateList('test_cap', data.test_cap.toFixed(1) + "AH");
          // 上次核容测试时长
          this.setStateList('test_timelong', formatSeconds(data.test_timelong));
          let volArr = [];
          datalist.forEach((v) => {
            volArr.push(['#' + v.mon_num, v.mon_vol]);
          });
          let batNum = getBarNum(volArr);
          let avg_curr = data.test_timelong > 0 ? data.test_cap * 3600 / data.test_timelong : data.test_curr;
          let over_cap = GetMonomerCap(batt.MonCapStd, GetHourRate(batt.MonCapStd, avg_curr),
                        data.test_cap, batNum.max, batNum.min, batt.MonVolStd, 0);
          let real_cap = GetMonomerCap(batt.MonCapStd, GetHourRate(batt.MonCapStd, avg_curr),
                        data.test_cap, batNum.max, batNum.min, batt.MonVolStd, 1);
          let xuhang = batt.Load_curr ? real_cap / batt.Load_curr : 0;
          // 剩余容量
          this.setStateList('re_cap', over_cap.toFixed(1) + 'AH');
          // 续航时长
          this.setStateList('endurance_time', xuhang ? sethoubeiTime(xuhang) : '---');
        }
      }).catch((err) => {
        console.error(err);
      });
    },
    stopOutLineCuring() {
      this.stopTime = new Date().getTime();
    },
    inversionData() {
      // 是逆变的设备
      if(regEquipType(this.batt.FBSDeviceId, 'BTS9120')) {
        inversionData(this.batt.FBSDeviceId).then(res=>{
          let rs = JSON.parse(res.data.result);
          let data = {
            commustate: -1,     // 通讯状态
            fanglei_state: -1,  // 防雷状态
            rlayworkmode: -1,   // 空开状态
          };
          if(rs.code == 1) {
            data = rs.data[0];
          }
          if(data.rlayworkmode == 1 || data.rlayworkmode == 3) {
            this.buscoupleSwitch = 0;
          }else {
            this.buscoupleSwitch = 1;
          }
        }).catch(error=>{
          this.buscoupleSwitch = 0;
        });
      }
    },
  },
  computed: {
    battFullName() {
@@ -2885,12 +3527,14 @@
    },
    backInputs() {
      let batt = this.batt;
      let isLd9 = this.isLd9;
      const obj = {
          0: "未知",
          1: "浮充",
          2: "充电",
          3: "放电",
          4: "均充",
          5: "内阻测试"
        },
        list = {
          batt_state: "未知",
@@ -2902,10 +3546,15 @@
          batt_syrl_cap: "---",
          sysc: "------",
        };
      if(this.cdshStatus == "cdsh"){
        list.MonCount = "0";
        list.MonVolStd = "0V";
      }
      if (this.diagram.type == -1) {
        return list;
      }
      let batt_state_text = this.diagram.powerCut
      let batt_state_text = this.diagram.powerCut && !isLd9
        ? "停电放电"
        : obj[this.inputs.batt_state];
      list.batt_state = batt_state_text + this.diagram.desc;
@@ -2922,13 +3571,26 @@
      list.batt_test_tlong = formatSeconds(this.inputs.batt_test_tlong);
      list.batt_test_cap = this.inputs.batt_test_cap.toFixed(1) + "AH";
      if (this.inputs.batt_state === 2) {
        list.batt_syrl_cap = "---";
      } else {
      if(this.cdshStatus == "cdsh"){
        list.MonCount = this.inputs.MonCount;
        list.MonVolStd = this.inputs.MonVolStd + "V";
      }
      if (this.inputs.batt_state === 3) {
        // 为0是不更新剩余容量
        if(this.inputs.batt_rest_cap != 0) {
          list.batt_syrl_cap = this.inputs.batt_rest_cap.toFixed(1)
        }
        // 通过标准曲线获取实际容量后计算剩余容量
        // if(this.inputs.note<=0) {
        //   list.batt_syrl_cap = "------";
        //   list.batt_syrl_cap = this.inputs.list+"AH";
        // }else {
        //   //list.batt_syrl_cap = (this.inputs.note-Math.abs(this.inputs.batt_test_cap)).toFixed(1)+"AH";
        //   list.batt_syrl_cap = this.inputs.list+"AH";
        // }
      } else {
        list.batt_syrl_cap = "---";
      }
      if (this.inputs.batt_state === 3) {
        // 为0是不更新续航时长
@@ -2943,12 +3605,11 @@
      }
      // 如果当前为锂电池
      let isLithium = regEquipType(batt.FBSDeviceId, ["lithium"]);
      let isLithium = regEquipType(batt.FBSDeviceId, ["lithium", "lithiumPack"]);
      if (isLithium) {
        list.batt_syrl_cap =
          this.lithiumParams.analog.restCap.toFixed(1) + "AH";
      }
      return list;
    },
    showStateList() {
@@ -2976,6 +3637,7 @@
          "BTS9120",
          "BTS9605",
          "lithium",
          "lithiumPack"
        ])
      ) {
        return "BTS设备放电参数设置";
@@ -2986,7 +3648,7 @@
      }
    },
    stateListState() {
      return this.stateListShow && this.showStateList.length;
      return this.stateListShow && this.showStateList.length && !this.isLd9;
    },
    historyStateListState() {
      return this.stateListShow && this.showHistoryStateList.length;
@@ -3022,6 +3684,11 @@
      let batt = this.batt;
      return regEquipType(batt.FBSDeviceId, ["lithium"]);
    },
    isLithiumPack() {
      // 锂电包
      let batt = this.batt;
      return regEquipType(batt.FBSDeviceId, ["lithiumPack"]);
    },
    isLd9() {
      // LD9BTS
      let batt = this.batt;
@@ -3035,25 +3702,52 @@
    tabsConfig() {
      let batt = this.batt;
      let isLithium = regEquipType(batt.FBSDeviceId, ["lithium"]);
      let vol = true;
      let res = !isLithium;
      let temp = true;
      let conduct = !isLithium;
      let curr = !isLithium;
      let leakVol = !isLithium;
      let dianchigaojing = !isLithium;
      let monConnRes = !isLithium;
      return {
        vol: vol,
        res: res,
        temp: temp,
        conduct: conduct,
        curr: curr,
        leakVol: leakVol,
        dianchigaojing: dianchigaojing,
        monConnRes: monConnRes,
      };
      let isLithiumPack = regEquipType(batt.FBSDeviceId, ["lithiumPack"]);
      if(isLithium) {
        return {
          vol: true,
          res: false,
          temp: true,
          conduct: false,
          curr: false,
          leakVol: false,
          dianchigaojing: false,
          monConnRes: false,
        }
      }else if(isLithiumPack) {
        return {
          vol: false,
          res: false,
          temp: false,
          conduct: false,
          curr: false,
          leakVol: false,
          dianchigaojing: false,
          monConnRes: false,
        }
      }else if(!batt.FBSDeviceId) {
        return {
          vol: false,
          res: false,
          temp: false,
          conduct: false,
          curr: false,
          leakVol: false,
          dianchigaojing: false,
          monConnRes: false,
        }
      }else {
        return {
          vol: true,
          res: true,
          temp: true,
          conduct: true,
          curr: true,
          leakVol: true,
          dianchigaojing: true,
          monConnRes: true,
        }
      }
    },
    isTestDev() {
      let batt = this.batt;
@@ -3061,6 +3755,22 @@
      //return !isFalseLoad;
      return true;
    },
    // 设备连接状态1为未连接 0正常
    isLink() {
      return this.diagram.type == -1?1:0;
    },
    dataHeaders() {
      let headers = this.table.headers;
      let tabConfig = this.pageConfig;
      let batt = this.batt;
      return headers.filter(item=>{
        let isShow = item.key1?tabConfig[item.key1]:true;
        if(item.type) {
          isShow = regEquipType(batt.FBSDeviceId, item.type);
        }
        return isShow;
      });
    }
  },
  created() {
    this.skinActive = localStorage.getItem("activeSkin");
@@ -3102,6 +3812,7 @@
  destroyed() {
    window.removeEventListener("resize", this.resize);
    this.timer.stop();
    this.timer2.stop();
  },
};
</script>
@@ -3128,7 +3839,7 @@
}
.table-row .table-cell {
  padding-top: 12px;
  padding-top: 8px;
}
.page-content {
@@ -3290,4 +4001,22 @@
.lampImg {
  height: 28px;
}
.box-header {
  font-size: 14px;
  padding: 0;
}
.wx_guides{
  height: 150px;
  text-align: center;
  background-color: #ffffff;
  padding-top: 15%;
}
.wx_guides p {
  display: inline-block;
  margin-right: 10px;
}
.wx_guides p /deep/.el-input__inner {
  color:#000;
}
</style>