Browse Source

Merge branch 'master' of http://49.4.49.126:3000/GYEE_R.D/neic

lining 3 years ago
parent
commit
db7bf89df5

+ 3 - 3
src/assets/style/main.css

@@ -56,12 +56,12 @@ body,
   border-color: black !important;
 } 
 .el-tabs__item:hover{
-  background-color: rgb(29,106,235) !important;
-}
-.el-tabs__item.is-active{
   background-color: rgb(36,36,36) !important;
   border-color: black !important;
 }
+.el-tabs__item.is-active{
+  background-color: rgb(29,106,235) !important;
+}
 
 
 .el-table--border:after,.el-table--group:after,.el-table:before {

+ 17 - 15
src/components/area/AlarmArea.vue

@@ -18,6 +18,7 @@
                 'border-bottom':'solid 1px black'
               }"
       :cell-style="{ background: '#1e1e1e', color: 'rgb(220,220,220)',padding:'3px',fontSize:'12px'}"
+      @row-dblclick="itemDblclick"
       >
       <el-table-column
         prop="lastUpdateTime"
@@ -39,34 +40,30 @@
       </el-table-column>
     </el-table>
     </div>
-<!--     <div>
-      <table class="table-main">
-        <tr>
-          <td width="150px">时间</td>
-          <td idth="400px">描述</td>
-          <td width="50px">确认</td>
-        </tr>
-        <tr v-for="v in values" :key="v">
-          <td width="150px">{{ v.lastUpdateTime }}</td>
-          <td width="400px">{{ v.alertText }}</td>
-          <td width="50px"><input type="checkbox" disabled="disabled" /></td>
-        </tr>
-      </table>
-    </div> -->
   </gy-card>
+  <WindturbineDetailPages
+    v-model="dialogVisible"
+    :windturbine="currentWindturbine"
+  ></WindturbineDetailPages>
 </template>
 
 <script>
 import MessageBridge from "../../assets/script/MessageBridge";
+import WindturbineDetailPages from '../area/windturbine/WindturbineDetailPages.vue'
 export default {
   name: "AlarmArea",
+  components:{
+    WindturbineDetailPages,
+  },
   created: function () {
     this.initData();
   },
   props: {},
   data() {
     return {
-      values: ['-','-','-','-','-','-']
+      values: ['-','-','-','-','-','-'],
+      dialogVisible:false,
+      currentWindturbine: {},
     };
   },
   methods: {
@@ -87,6 +84,11 @@ export default {
       }
       console.log(val);
     },
+    itemDblclick(row){
+      if(row.category1!='FJ')return;
+      this.dialogVisible = true;
+      this.currentWindturbine=row;
+    },
   },
 };
 </script>

+ 4 - 1
src/components/area/windturbine/BasicInformationDetail.vue

@@ -57,6 +57,9 @@ import BackgroundData from "../../../assets/script/BackgroundData";
 
 export default {
   name: "BasicInformationDetail",
+  props:{
+    alarms:Object,
+  },
   data() {
     return {
       BasicInfo: {},
@@ -120,7 +123,7 @@ export default {
 
 <style scoped>
 .firstdiv {
-  height: 49vh;
+  height: 50vh;
 }
 .onediv {
   float: right;

+ 15 - 34
src/components/area/windturbine/WindturbineDetailPages.vue

@@ -9,27 +9,6 @@
     <div style="margin-top:-10px;">风机详情</div>
   </template>
     <div style="background-color: black;margin-top:-30px;margin-left:-10px;margin-right:-10px;margin-bottom:-30px;">
-      <!-- <div class="titeldiv">
-      <div class="chunkdiv" width="15%">
-        <img src="../../../assets/img/WindturbineDetailPages/pic_01.png"/>
-        <div>MA B401</div>
-      </div>
-      <div class="chunkdiv" width="15%">
-        <div>所属线路&emsp;</div>
-        <div>某某某1线</div>
-      </div>
-      <div class="chunkdiv" width="15%">
-        <div>机型&emsp;</div>
-        <div>GW1000</div>
-      </div>
-      <div class="chunkdiv" width="15%">
-        <div>告警时间:</div>
-        <div>2021年5月10日&emsp;12:23:31</div>
-      </div>
-      <div class="chunkdiv" width="15%">
-        <div>告警内容:</div>
-        <div>通讯中断</div>
-      </div> -->
       <table width="99.8%">
         <tr>
           <td>
@@ -75,37 +54,37 @@
       </div>
       <el-tabs type="border-card" tab-position="bottom" stretch="true">
         <el-tab-pane label="基本信息">
-          <BasicInformationDetail ref="BasicInfo"></BasicInformationDetail>
+          <BasicInformationDetail ref="BasicInfo" :alarms="alarms"></BasicInformationDetail>
         </el-tab-pane>
-        <!-- <el-tab-pane label="机舱信息">
+        <el-tab-pane label="机舱信息" disabled>
           <BasicInformationDetail></BasicInformationDetail>
         </el-tab-pane>
-        <el-tab-pane label="故障信息">
+        <el-tab-pane label="故障信息" disabled>
           <BasicInformationDetail></BasicInformationDetail>
         </el-tab-pane>
-        <el-tab-pane label="齿轮箱" >
+        <el-tab-pane label="齿轮箱" disabled>
           <BasicInformationDetail></BasicInformationDetail>
         </el-tab-pane>
-        <el-tab-pane label="变桨">
+        <el-tab-pane label="变桨" disabled>
           <BasicInformationDetail></BasicInformationDetail>
         </el-tab-pane>
-        <el-tab-pane label="偏航">
+        <el-tab-pane label="偏航" disabled>
           <YawDetail></YawDetail>
         </el-tab-pane>
-        <el-tab-pane label="液压">
+        <el-tab-pane label="液压" disabled>
           <BasicInformationDetail></BasicInformationDetail>
         </el-tab-pane>
-        <el-tab-pane label="发电机">
+        <el-tab-pane label="发电机" disabled>
           <BasicInformationDetail></BasicInformationDetail>
-        </el-tab-pane> -->
+        </el-tab-pane>
       </el-tabs>
     </div>
   </el-dialog>
 </template>
 
 <script>
-/* import YawDetail from "./YawDetail.vue";
- */import BasicInformationDetail from "./BasicInformationDetail.vue";
+import YawDetail from "./YawDetail.vue";
+import BasicInformationDetail from "./BasicInformationDetail.vue";
 import UniformCodes from "../../../assets/script/UniformCodes";
 import {config} from '../../../config';
 import axios from 'axios';
@@ -113,7 +92,7 @@ import BackgroundData from "../../../assets/script/BackgroundData";
 import Worning from "./warning.vue"
 export default {
   components: {
-    /* YawDetail, */
+    YawDetail, 
     BasicInformationDetail,
     Worning,
   },
@@ -126,6 +105,7 @@ export default {
       line:"",
       alarmTime:"",
       alarmContent:"",
+      alarms:{},
     };
   },
   created() {
@@ -155,12 +135,13 @@ export default {
     initData(){
       axios.get(`http://${config.calcUrl}/windturbine/line/${this.windturbine.windturbineId}`)
       .then(msg=>this.line=msg.data);
-      axios.get(`http://${config.calcUrl}/alarm/real-time-alarm?objectId=${this.windturbine.windturbineId}&pageIndex=1&pageSize=1`)
+      axios.get(`http://${config.calcUrl}/alarm/real-time-alarm?objectId=${this.windturbine.windturbineId}&pageIndex=1&pageSize=50`)
       .then(msg=>{
         var vs = msg.data;
         if(vs.length<=0)return;
         this.alarmTime = BackgroundData.getInstance().formatDate(vs[0].lastUpdateTime);
         this.alarmContent = vs[0].alertText;
+        this.alarms = msg.data;
       })
       .catch(err=>{
         console.log(err);

+ 49 - 4
src/components/area/windturbine/YawDetail.vue

@@ -1,5 +1,11 @@
 <template>
-    <img style="float:left;" src="../../../assets/img/WindturbineDetailPages/偏航.png" object-fit="fill">
+    <div class="firstdiv">
+    <img
+      style="float: left; margin-left: 40px; margin-top: 90px;width:50vh;height:25vh;"
+      src="../../../assets/img/WindturbineDetailPages/变桨.png"
+      object-fit="fill"
+    />
+    <div class="twodiv">
     <table>
         <tr>
             <th>状态信息</th>
@@ -41,14 +47,53 @@
             <td>度</td>
         </tr>
     </table>
+    </div>
+  </div>
 </template>
 <script>
-import red from './red.vue'
-import green from './green.vue'
 
 export default{
     components: {
-        red,green
+        
     }
 }
 </script>
+
+<style scoped>
+.firstdiv {
+  height: 50vh;
+}
+.onediv {
+  float: right;
+  margin-right: 30px;
+}
+.twodiv {
+  float: right;
+  margin-right: 30px;
+}
+td:nth-child(1) {
+  height: 25px;
+  width: 130px;
+  text-align: right;
+}
+td:nth-child(2) {
+  width: 78px;
+  text-align: right;
+  color: rgb(5, 176, 71);
+}
+td:nth-child(3) {
+  text-align: center;
+  width: 30px;
+}
+tr:nth-child(1) {
+  font-size: 20px;
+  width: 90px;
+  text-align: right;
+}
+th {
+  height: 40px;
+}
+table{
+  margin-top: 30px;
+}
+</style>

+ 0 - 0
src/components/area/windturbine/problem/Fault.vue