Browse Source

Merge branch 'yx' of http://124.70.43.205:3000/xieshengjie/jn_sis_zhfx into baiyanting

baiyanting 1 year ago
parent
commit
2123575db3

+ 1 - 0
.env.development

@@ -22,6 +22,7 @@ VUE_APP_DIALOG_POINT = contextmenu
 
 # 智慧检修
 # VUE_APP_NEW_WISDOM=http://10.81.3.162:8170
+# VUE_APP_NEW_WISDOM=http://192.168.1.103:8170 # 石林
 VUE_APP_NEW_WISDOM=http://10.81.3.155:8170
 # 综合报警
 VUE_APP_ALARM=http://10.81.3.154:6015

+ 10 - 2
src/api/wisdomOverhaul/health/index.js

@@ -9,7 +9,7 @@ const requestRecommen = (data) => {
 const recommen = (url, data) => {
     return request({
         baseURL: process.env.VUE_APP_NEW_WISDOM,
-        url: `${url}?rid=${data.rid}`,
+        url: `${url}?typeid=${data.typeid}`,
         method: "post",
         data: data
     });
@@ -168,7 +168,14 @@ const healthreportHealthReport = (data) => {
         method: "get",
     });
 };
-
+const getAlarmcountVoList = (params) => {
+    return request({
+        baseURL: process.env.VUE_APP_NEW_WISDOM,
+        url: `/health/getAlarmcountVoList`,
+        method: "get",
+        params
+    });
+};
 
 
 
@@ -198,4 +205,5 @@ export default {
     healthsubGetWeatherRealDay5Info,
     healthsubFindWtHisValueForBj,
     healthreportHealthReport,
+    getAlarmcountVoList
 }

+ 0 - 1
src/components/chart/pie/dual-pie-chart.vue

@@ -67,7 +67,6 @@ export default {
         tooltip: {
           trigger: "item",
           formatter: function (params) {
-            console.log(params);
             return params.marker + params.name + " " + params.value + "%";
           },
         },

+ 88 - 35
src/components/other/healthReport/index.vue

@@ -151,7 +151,34 @@
           <el-form-item>结论:健康报告达到推荐级别,推荐检修!</el-form-item>
         </el-form>
       </div>
-      
+
+      <div class="tableBox">
+        <div class="l" style="width: 100%">
+          <el-form>
+            <el-form-item class="imp fw">可靠性</el-form-item>
+          </el-form>
+          <el-table
+            empty-text="暂无数据"
+            :data="alarmcountVoList"
+            :header-cell-style="{
+              background: 'rgb(153,204,255)',
+              color: '#000',
+            }"
+            :cell-style="columnStyle"
+            border
+            stripe
+            style="width: 100%; margin: 10px 0"
+          >
+            <el-table-column prop="description" label="描述" />
+            <el-table-column prop="total" label="总次数" sortable />
+            <el-table-column prop="maxSeconds" label="最大时长" sortable />
+            <el-table-column prop="minSeconds" label="最小时长" sortable />
+            <el-table-column prop="avgSeconds" label="平均时长" sortable />
+            <el-table-column prop="totalSeconds" label="总时间" sortable />
+          </el-table>
+        </div>
+      </div>
+
       <div class="textBox">
         <el-form>
           <el-form-item class="imp fw text-indent-2"><b>性能</b></el-form-item>
@@ -268,12 +295,12 @@
       </div> -->
 
       <!-- 可靠性暂时隐藏 -->
-      <div class="textBox">
+      <div class="textBox" v-if="false">
         <el-form>
           <el-form-item class="imp fw text-indent-2"
             ><b>可靠性</b>:</el-form-item
           >
-          <!-- <el-form-item class="imp fw text-indent-2">部件隐患:</el-form-item>
+          <el-form-item class="imp fw text-indent-2">部件隐患:</el-form-item>
           <el-form-item class="text-indent-2">
             统计周期内,传动链隐患频次为{{ yhbjcount.cdlcount }}次,持续时长{{
               yhbjcount.cdltime
@@ -322,8 +349,8 @@
                 bjyhcount[5].yhmx
               }}分钟。</font
             >
-          </el-form-item> -->
-          <!-- <div class="logHead">部件隐患对比(次|分钟)</div>
+          </el-form-item>
+          <div class="logHead">部件隐患对比(次|分钟)</div>
           <el-table
             empty-text="暂无数据"
             :data="bjyhdbs"
@@ -369,7 +396,7 @@
               <el-table-column prop="tdgcount"></el-table-column>
               <el-table-column prop="tdgtimes"></el-table-column>
             </el-table-column>
-          </el-table> -->
+          </el-table>
           <div class="logHead">隐患模型对比</div>
           <el-table
             empty-text="暂无数据"
@@ -393,15 +420,13 @@
 
       <div class="textBox">
         <el-form>
-          <!-- <el-form-item class="imp fw text-indent-2">故障分类:</el-form-item>
+          <el-form-item class="imp fw text-indent-2">故障分类:</el-form-item>
           <el-form-item class="text-indent-2">
             统计周期内,机舱振动类故障频次为88次,持续时长51分钟。(只显示发生故障的,如没有发生过故障的不用文字描述)
           </el-form-item>
-          <el-form-item class="text-indent-2"> -->
           <!-- 其中以(明细故障mwData)发生频次最高,为mwData次;(明细故障mwData)次之,为mwData次;(明细故障mwData)第三,为mwData次。 -->
-          <!-- </el-form-item> -->
           <!-- <div class="logHead">故障分类统计</div> -->
-          <!-- <el-table
+          <el-table
             empty-text="暂无数据"
             :data="faultclass"
             :header-cell-style="{
@@ -441,11 +466,11 @@
                 label="同期"
               ></el-table-column>
             </el-table-column>
-          </el-table> -->
+          </el-table>
         </el-form>
       </div>
 
-      <!-- <div class="textBox">
+      <div class="textBox">
         <el-form>
           <el-form-item class="imp fw text-indent-2"
             >功率对部件温度影响</el-form-item
@@ -483,7 +508,7 @@
             <el-table-column prop="min1350" label="1350-1500"></el-table-column>
           </el-table>
         </el-form>
-      </div> -->
+      </div>
 
       <div class="textBox">
         <el-form>
@@ -549,7 +574,7 @@
         </el-form>
       </div>
 
-      <div class="textBox">
+      <div class="textBox" v-if="false">
         <el-form>
           <el-form-item class="imp fw text-indent-2"
             >震动监测:时域分析分析法</el-form-item
@@ -617,7 +642,7 @@
           </el-table>
         </el-form>
       </div>
-      <div class="textBox">
+      <div class="textBox" v-if="false">
         <el-form>
           <el-form-item class="imp fw text-indent-2"
             >震动监测:时域分析分析法</el-form-item
@@ -676,30 +701,32 @@
             <el-table-column prop="df" label="得分"></el-table-column>
           </el-table>
 
-          <el-form-item class="imp fw text-indent-2">震动监测:</el-form-item>
-          <el-form-item class="text-indent-2">时域分析分析法</el-form-item>
-          <el-form-item class="text-indent-2"
-            >有量纲参数:均值为100,方差为49,均方幅值67,峰值,260,平均幅值44,均方值120</el-form-item
-          >
-          <el-form-item class="text-indent-2"
-            >无量纲参数:峭度指标20,峰值指标50,波形指标90,脉冲指标77</el-form-item
-          >
-          <el-form-item class="text-indent-2"
-            >结合两种指标都未发现明显劣化值</el-form-item
-          >
-          <el-form-item class="text-indent-2"
-            >频域分析法:根据震动检测提供频域分析结果,现有设备运行正常</el-form-item
-          >
-          <!-- <multiple-line-chart
+          <template v-if="false">
+            <el-form-item class="imp fw text-indent-2">震动监测:</el-form-item>
+            <el-form-item class="text-indent-2">时域分析分析法</el-form-item>
+            <el-form-item class="text-indent-2"
+              >有量纲参数:均值为100,方差为49,均方幅值67,峰值,260,平均幅值44,均方值120</el-form-item
+            >
+            <el-form-item class="text-indent-2"
+              >无量纲参数:峭度指标20,峰值指标50,波形指标90,脉冲指标77</el-form-item
+            >
+            <el-form-item class="text-indent-2"
+              >结合两种指标都未发现明显劣化值</el-form-item
+            >
+            <el-form-item class="text-indent-2"
+              >频域分析法:根据震动检测提供频域分析结果,现有设备运行正常</el-form-item
+            >
+            <!-- <multiple-line-chart
             :showLegend="true"
             :hoverType="'axis'"
             :list="wttragetreportcharts.bj"
           /> -->
-          <double-line-chart :height="'250px'" :list="bjLineChartOptions" />
-          <el-form-item class="imp fw text-indent-2">统计分析:</el-form-item>
-          <el-form-item class="text-indent-2"
-            >发电机类故障,平均故障周期在12个月,上次故障距此次评价时间为5个月,发电机处于平稳运行周期。</el-form-item
-          >
+            <double-line-chart :height="'250px'" :list="bjLineChartOptions" />
+            <el-form-item class="imp fw text-indent-2">统计分析:</el-form-item>
+            <el-form-item class="text-indent-2"
+              >发电机类故障,平均故障周期在12个月,上次故障距此次评价时间为5个月,发电机处于平稳运行周期。</el-form-item
+            >
+          </template>
         </el-form>
       </div>
 
@@ -947,6 +974,7 @@ export default {
     return {
       datas: {},
       reportInfo1: {},
+      alarmcountVoList: [],
       ls1: [],
       ls2: [],
       ls3: [],
@@ -1724,6 +1752,15 @@ export default {
       // recorddate = "2023-05-18";
 
       api
+        .getAlarmcountVoList({
+          wtId: wtid,
+          recordDate: recorddate,
+        })
+        .then((res) => {
+          this.alarmcountVoList = res.data;
+        });
+
+      api
         .healthreportHealthReport({
           wtid: wtid,
           date: recorddate,
@@ -2045,5 +2082,21 @@ export default {
   .el-table td {
     color: black;
   }
+
+  .tableBox {
+    .el-table .sort-caret.ascending {
+      border-bottom-color: #000;
+    }
+    .el-table .sort-caret.descending {
+      border-top-color: #000;
+    }
+
+    .el-table .ascending .sort-caret.ascending {
+      border-bottom-color: #05bb4c;
+    }
+    .el-table .descending .sort-caret.descending {
+      border-top-color: #05bb4c;
+    }
+  }
 }
 </style>

+ 16 - 5
src/views/HealthControl/HealthTab1.vue

@@ -35,21 +35,21 @@
         <div class="actions mg-b-16">
           <button
             class="btn"
-            :class="{ active: recommenIndex == 1 }"
+            :class="recommenIndex === 1 ? 'active' : ''"
             @click="onClickRecommon(1)"
           >
             当日内推荐
           </button>
           <button
             class="btn"
-            :class="{ active: recommenIndex == 2 }"
+            :class="recommenIndex === 2 ? 'active' : ''"
             @click="onClickRecommon(2)"
           >
             三日内推荐
           </button>
           <button
             class="btn"
-            :class="{ active: recommenIndex == 3 }"
+            :class="recommenIndex === 3 ? 'active' : ''"
             @click="onClickRecommon(3)"
           >
             超三日推荐
@@ -238,14 +238,14 @@ export default {
         rid: rid,
       };
       api.recommen(url, data).then((res) => {
-        if (res.code == 200) this.onClickRecommon(that.recommenIndex);
+        if (res.code == 200) this.onClickRecommon(this.recommenIndex);
       });
     },
     // 操作推荐内容全部(提交/取消)
     requestOptionAll(url) {
       let data = { typeid: this.recommenIndex };
       api.recommen(url, data).then((res) => {
-        if (res.code == 200) this.onClickRecommon(that.recommenIndex);
+        if (res.code == 200) this.onClickRecommon(this.recommenIndex);
       });
     },
     // 损失电量分析  type:1 表示24小时健康趋势,2 表示七天健康趋势 3 表示30天健康趋势
@@ -375,6 +375,17 @@ export default {
     height: calc(100% - 350px - 15px);
     .health-report-panel {
       height: 100%;
+
+      .btn.active {
+        background: fade(@green, 20) !important;
+        border: 1px solid @green !important;
+        color: @green !important;
+        cursor: pointer !important;
+
+        i svg use {
+          fill: @green !important;
+        }
+      }
     }
     // 健康报告 按钮样式
     .actions {

+ 0 - 1
src/views/HealthControl/healthDetail/wtHealth/index.vue

@@ -780,7 +780,6 @@ export default {
   methods: {
     // 查看健康报告
     onClickReport() {
-    
       this.reportshow = true;
       // this.reportparams = {wtId: this.value2, recorddate: new Date(new Date()).formatDate("yyyy-MM-dd")}
       this.$refs.eport.getReport(

+ 6 - 4
src/views/HealthControl/healthManagement/overview/index.vue

@@ -49,20 +49,22 @@
     <row :type="'flex'" class="mg-b-16">
       <Col :span="12">
         <panel :title="'报警统计图'" :showLine="false">
-          <dual-pie-chart
+          <!-- <dual-pie-chart
             :innerData="healPieData"
             :outerData="healPieData"
             :height="'150px'"
-          />
+          /> -->
+          <dual-pie-chart :series="healPieData" :height="'150px'" />
         </panel>
       </Col>
       <Col :span="12">
         <panel :title="'故障统计图'" :showLine="false">
-          <dual-pie-chart
+          <!-- <dual-pie-chart
             :innerData="stopPieData"
             :outerData="stopPieData"
             :height="'150px'"
-          />
+          /> -->
+          <dual-pie-chart :series="stopPieData" :height="'150px'" />
         </panel>
       </Col>
       <!-- <Col :span="16">

+ 49 - 35
src/views/WindSite/pages/Info/StandAloneImg.vue

@@ -338,6 +338,7 @@
     </defs>
     <!-- 背景图片 -->
     <image
+      :style="`transform: translate(${getTransformPositionX()}px, 0)`"
       x="0"
       y="90"
       height="787"
@@ -346,6 +347,7 @@
       href="./standAloneImg-green.png"
     />
     <image
+      :style="`transform: translate(${getTransformPositionX()}px, 0)`"
       x="0"
       y="90"
       height="787"
@@ -362,37 +364,37 @@
       @click="click(3)"
     >
       <use
+        :transform="`translate(${getTransformPositionX(100)}, 190) scale(0.7)`"
         class="stand-alone-img-item"
         xlink:href="#pitch"
         x="214"
         y="110"
-        transform="translate(110, 190) scale(0.7)"
       />
       <use
         class="stand-alone-img-item-circle"
         xlink:href="#stand-alone-circle-bj"
-        x="320"
+        :x="getTransformPositionX(320)"
         y="330"
       />
       <line
         :class="{ 'stand-alone-line': line && hover == 3 }"
-        x1="320"
+        :x1="getTransformPositionX(320)"
         y1="330"
-        x2="620"
+        :x2="getTransformPositionX(620)"
         y2="50"
         stroke="#edbf03"
         stroke-width="2"
       />
       <circle
         :class="{ 'stand-alone-circle': circle && hover == 3 }"
-        cx="620"
+        :cx="getTransformPositionX(620)"
         cy="50"
         r="5"
         fill="#edbf03"
       />
       <text
         :class="{ 'stand-alone-text': text && hover == 3 }"
-        x="630"
+        :x="getTransformPositionX(630)"
         y="60"
         fill="#fcaf17"
         font-size="50"
@@ -409,6 +411,7 @@
       @click="click(6)"
     >
       <use
+        :style="`transform: translate(${getTransformPositionX()}px, 0)`"
         class="stand-alone-img-item"
         xlink:href="#engine-room"
         x="1270"
@@ -417,28 +420,28 @@
       <use
         class="stand-alone-img-item-circle"
         xlink:href="#stand-alone-circle-jc"
-        x="750"
+        :x="getTransformPositionX(750)"
         y="380"
       />
       <line
         :class="{ 'stand-alone-line': line && hover == 6 }"
-        x1="750"
+        :x1="getTransformPositionX(750)"
         y1="380"
-        x2="1050"
+        :x2="getTransformPositionX(1050)"
         y2="90"
         stroke="#edbf03"
         stroke-width="2"
       />
       <circle
         :class="{ 'stand-alone-circle': circle && hover == 6 }"
-        cx="1050"
+        :cx="getTransformPositionX(1050)"
         cy="90"
         r="5"
         fill="#edbf03"
       />
       <text
         :class="{ 'stand-alone-text': text && hover == 6 }"
-        x="1060"
+        :x="getTransformPositionX(1060)"
         y="100"
         fill="#fcaf17"
         font-size="50"
@@ -459,33 +462,33 @@
         xlink:href="#gear-box"
         x="730"
         y="335"
-        transform="translate(220, 280) scale(0.7)"
+        :transform="`translate(${getTransformPositionX(220)}, 280) scale(0.7)`"
       />
       <use
         class="stand-alone-img-item-circle"
         xlink:href="#stand-alone-circle-clx"
-        x="800"
+        :x="getTransformPositionX(800)"
         y="550"
       />
       <line
         :class="{ 'stand-alone-line': line && hover == 2 }"
-        x1="800"
+        :x1="getTransformPositionX(800)"
         y1="550"
-        x2="1100"
+        :x2="getTransformPositionX(1100)"
         y2="250"
         stroke="#edbf03"
         stroke-width="2"
       />
       <circle
         :class="{ 'stand-alone-circle': circle && hover == 2 }"
-        cx="1100"
+        :cx="getTransformPositionX(1100)"
         cy="250"
         r="5"
         fill="#edbf03"
       />
       <text
         :class="{ 'stand-alone-text': text && hover == 2 }"
-        x="1110"
+        :x="getTransformPositionX(1110)"
         y="250"
         fill="#fcaf17"
         font-size="50"
@@ -506,33 +509,33 @@
         xlink:href="#alternator"
         x="900"
         y="385"
-        transform="translate(300, 260) scale(0.7)"
+        :transform="`translate(${getTransformPositionX(300)}, 260) scale(0.7)`"
       />
       <use
         class="stand-alone-img-item-circle"
         xlink:href="#stand-alone-circle-fdj"
-        x="990"
+        :x="getTransformPositionX(990)"
         y="580"
       />
       <line
         :class="{ 'stand-alone-line': line && hover == 1 }"
-        x1="990"
+        :x1="getTransformPositionX(990)"
         y1="580"
-        x2="1290"
+        :x2="getTransformPositionX(1290)"
         y2="880"
         stroke="#edbf03"
         stroke-width="2"
       />
       <circle
         :class="{ 'stand-alone-circle': circle && hover == 1 }"
-        cx="1290"
+        :cx="getTransformPositionX(1290)"
         cy="880"
         r="5"
         fill="#edbf03"
       />
       <text
         :class="{ 'stand-alone-text': text && hover == 1 }"
-        x="1300"
+        :x="getTransformPositionX(1300)"
         y="920"
         fill="#fcaf17"
         font-size="50"
@@ -548,32 +551,37 @@
       @mouseout="mouseout"
       @click="click(4)"
     >
-      <use class="stand-alone-img-item" xlink:href="#yaw" x="675" y="645" />
+      <use
+        class="stand-alone-img-item"
+        xlink:href="#yaw"
+        :x="getTransformPositionX(675)"
+        y="645"
+      />
       <use
         class="stand-alone-img-item-circle"
         xlink:href="#stand-alone-circle-ph"
-        x="650"
+        :x="getTransformPositionX(650)"
         y="750"
       />
       <line
         :class="{ 'stand-alone-line': line && hover == 4 }"
-        x1="650"
+        :x1="getTransformPositionX(650)"
         y1="750"
-        x2="950"
+        :x2="getTransformPositionX(950)"
         y2="1050"
         stroke="#edbf03"
         stroke-width="2"
       />
       <circle
         :class="{ 'stand-alone-circle': circle && hover == 4 }"
-        cx="950"
+        :cx="getTransformPositionX(950)"
         cy="1050"
         r="5"
         fill="#edbf03"
       />
       <text
         :class="{ 'stand-alone-text': text && hover == 4 }"
-        x="960"
+        :x="getTransformPositionX(960)"
         y="1050"
         fill="#fcaf17"
         font-size="50"
@@ -594,33 +602,33 @@
         xlink:href="#hydraulic-pressure"
         x="775"
         y="455"
-        transform="translate(260, 310) scale(0.7)"
+        :transform="`translate(${getTransformPositionX(260)}, 310) scale(0.7)`"
       />
       <use
         class="stand-alone-img-item-circle"
         xlink:href="#stand-alone-circle-yy"
-        x="850"
+        :x="getTransformPositionX(850)"
         y="730"
       />
       <line
         :class="{ 'stand-alone-line': line && hover == 5 }"
-        x1="850"
+        :x1="getTransformPositionX(850)"
         y1="730"
-        x2="1150"
+        :x2="getTransformPositionX(1150)"
         y2="1030"
         stroke="#edbf03"
         stroke-width="2"
       />
       <circle
         :class="{ 'stand-alone-circle': circle && hover == 5 }"
-        cx="1150"
+        :cx="getTransformPositionX(1150)"
         cy="1030"
         r="5"
         fill="#edbf03"
       />
       <text
         :class="{ 'stand-alone-text': text && hover == 5 }"
-        x="1160"
+        :x="getTransformPositionX(1160)"
         y="1030"
         fill="#fcaf17"
         font-size="50"
@@ -650,6 +658,8 @@ export default {
       hover: 0,
       svgWidth: 0,
       svgHeight: 400,
+      // SVG 整体横向位移值,正数向左位移,负数向右位移,连同内部高亮区域与其他元素会一并位移
+      transformPositionX: 480,
     };
   },
   props: {
@@ -695,6 +705,10 @@ export default {
     click: function (index) {
       this.$emit("selectSvg", index);
     },
+
+    getTransformPositionX(posValue = 0) {
+      return posValue - this.transformPositionX;
+    },
   },
   // 生命周期钩子
   beforeCreate() {