Sfoglia il codice sorgente

2024.07.08-09需求更改:
联锁+历史颜色统一,排程设置图标更改

wyh 4 mesi fa
parent
commit
b06ec99cbd

+ 2 - 2
src/views/module_interLock/baseScheduleSet/BaseScheduleSetList.vue

@@ -1,8 +1,8 @@
 <template>
   <div style="height: 100%;">
     <div class="iotmenu-content-header">
-      <a-icon type="file-text" />
-      <span>排设置</span>
+      <a-icon type="history" />
+      <span>排设置</span>
     </div>
     <a-card :bordered="false">
       <!-- 查询区域 -->

+ 65 - 6
src/views/module_interLock/interlockHistoryData/InterlockHistoryList.vue

@@ -87,6 +87,39 @@
         class="j-table-force-nowrap"
         @change="handleTableChange">
         <!-- :rowSelection="{selectedRowKeys: selectedRowKeys, onChange: onSelectChange}" -->
+
+        <!-- 表头注释 -->
+        <span slot="loopHealthLevelTitle">
+          回路健康级别
+          <a-tooltip placement="top">
+            <template slot="title">
+              <span> A代表回路健康;B代表回路有故障;C代表回路有严重故障;D代表回路失效; </span>
+            </template>
+            <a-icon type="question-circle" />
+          </a-tooltip>
+        </span>
+
+        <!-- 仪表状态 -->
+        <span slot="instrumentStatus" slot-scope="text, record">
+          <span :class="record.instrumentStatus === record.instrumentStatusNormal ? 'normal-tag':'abnormal-tag'">
+            {{ text }}
+          </span>
+          <!-- <a-tag :color="record.instrumentStatus === record.instrumentStatusNormal ? 'green':'orange'">
+            {{ text }}
+          </a-tag> -->
+        </span>
+        <!-- 控制系统状态 -->
+        <span slot="controlSystemStatus" slot-scope="text, record">
+          <span :class="record.controlSystemStatus === record.controlSystemStatusNormal ? 'normal-tag':'abnormal-tag'">
+            {{ text }}
+          </span>
+        </span>
+        <!-- 旁路状态 -->
+        <span slot="bypassStatus" slot-scope="text, record">
+          <span :class="record.bypass === record.bypassYes ? 'normal-tag':'abnormal-tag'">
+            {{ text }}
+          </span>
+        </span>
         
         <template slot="htmlSlot" slot-scope="text">
           <div v-html="text"></div>
@@ -208,32 +241,58 @@
           {
             title:'仪表状态',
             align:"center",
-            dataIndex: 'instrumentStatusName'
+            dataIndex: 'instrumentStatusName',
+            scopedSlots: { customRender: 'instrumentStatus' }
           },
           {
             title:'控制系统状态',
             align:"center",
             dataIndex: 'controlSystemStatusName',
+            scopedSlots: { customRender: 'controlSystemStatus' }
           },
           {
             title:'旁路状态',
             align:"center",
             dataIndex: 'bypassName',
+            scopedSlots: { customRender: 'bypassStatus' }
           },
           {
             title:'联锁状态',
             align:"center",
             dataIndex: 'interlockStatusName',
-            customRender:function (t,r,index) {
-              return {children: t,attrs: {rowSpan:r.rowSpan2}};
+            customRender:function (text,record,index) {
+              let classTag = {
+                class: `${record.interlockStatus === record.interlockStatusTy ? 'normal-tag':'abnormal-tag'}`
+              }
+              return {
+                children: (
+                  <span {...classTag}>{text}</span>
+                ),
+                attrs: {rowSpan:record.rowSpan2}
+              };
             },
           },
           {
-            title:'回路健康级别',
+            // title:'回路健康级别',
             align:"center",
             dataIndex: 'loopHealthLevel',
-            customRender:function (t,r,index) {
-              return {children: t,attrs: {rowSpan:r.rowSpan3}};
+            slots: { title: 'loopHealthLevelTitle' },
+            customRender:(text,record,index)=> {
+              var children
+              if(text === 'A'){
+                children = (<span style="color: #52c41a;font-weight: 600;">{text}</span>)
+                // children = (<a-tag style="color: red">{text}</a-tag>)
+              }
+              if(text === 'B'){
+                children = (<span style="color: #FFE31F;font-weight: 600;">{text}</span>)
+              }
+              if(text === 'C'){
+                children = (<span style="color: #FFA300;font-weight: 600;">{text}</span>)
+              }
+              if(text === 'D'){
+                children = (<span style="color: #FF0000;font-weight: 600;">{text}</span>)
+              }
+              return {children: children, attrs: {rowSpan:record.rowSpan3}};
             },
           },
           

+ 25 - 3
src/views/module_interLock/interlockHistoryDetail/InterlockHistoryDetailList.vue

@@ -54,6 +54,25 @@
             @change="handleTableChange">
             <!-- :rowSelection="{selectedRowKeys: selectedRowKeys, onChange: onSelectChange}" -->
 
+            <!-- 输入卡件状态 -->
+            <span slot="inputStatus" slot-scope="text, record">
+              <span :class="record.inputStatus === record.controlSystemStatusNormal ? 'normal-tag':'abnormal-tag'">
+                {{ text }}
+              </span>
+            </span>
+            <!-- 输出卡件状态 -->
+            <span slot="outputStatus" slot-scope="text, record">
+              <span :class="record.outputStatus === record.controlSystemStatusNormal ? 'normal-tag':'abnormal-tag'">
+                {{ text }}
+              </span>
+            </span>
+            <!-- MP状态 -->
+            <span slot="mpStatus" slot-scope="text, record">
+              <span :class="record.mpStatus === record.controlSystemStatusNormal ? 'normal-tag':'abnormal-tag'">
+                {{ text }}
+              </span>
+            </span>
+
             <template slot="htmlSlot" slot-scope="text">
               <div v-html="text"></div>
             </template>
@@ -198,17 +217,20 @@
           {
             title:'输入卡件状态',
             align:"center",
-            dataIndex: 'inputStatusName'
+            dataIndex: 'inputStatusName',
+            scopedSlots: { customRender: 'inputStatus' }
           },
           {
             title:'输出卡件状态',
             align:"center",
-            dataIndex: 'outputStatusName'
+            dataIndex: 'outputStatusName',
+            scopedSlots: { customRender: 'outputStatus' }
           },
           {
             title:'MP状态',
             align:"center",
-            dataIndex: 'mpStatusName'
+            dataIndex: 'mpStatusName',
+            scopedSlots: { customRender: 'mpStatus' }
           },
           // {
           //   title: '操作',

+ 26 - 3
src/views/module_interLock/interlockSummaryDetail/InterlockSummaryDetailList.vue

@@ -74,6 +74,26 @@
             class="j-table-force-nowrap"
             @change="handleTableChange">
             <!-- :rowSelection="{selectedRowKeys: selectedRowKeys, onChange: onSelectChange}" -->
+
+
+            <!-- 输入卡件状态 -->
+            <span slot="inputStatus" slot-scope="text, record">
+              <span :class="record.inputStatus === record.controlSystemStatusNormal ? 'normal-tag':'abnormal-tag'">
+                {{ text }}
+              </span>
+            </span>
+            <!-- 输出卡件状态 -->
+            <span slot="outputStatus" slot-scope="text, record">
+              <span :class="record.outputStatus === record.controlSystemStatusNormal ? 'normal-tag':'abnormal-tag'">
+                {{ text }}
+              </span>
+            </span>
+            <!-- MP状态 -->
+            <span slot="mpStatus" slot-scope="text, record">
+              <span :class="record.mpStatus === record.controlSystemStatusNormal ? 'normal-tag':'abnormal-tag'">
+                {{ text }}
+              </span>
+            </span>
     
             <template slot="htmlSlot" slot-scope="text">
               <div v-html="text"></div>
@@ -218,17 +238,20 @@
           {
             title:'输入卡件状态',
             align:"center",
-            dataIndex: 'inputStatusName'
+            dataIndex: 'inputStatusName',
+            scopedSlots: { customRender: 'inputStatus' }
           },
           {
             title:'输出卡件状态',
             align:"center",
-            dataIndex: 'outputStatusName'
+            dataIndex: 'outputStatusName',
+            scopedSlots: { customRender: 'outputStatus' }
           },
           {
             title:'MP状态',
             align:"center",
-            dataIndex: 'mpStatusName'
+            dataIndex: 'mpStatusName',
+            scopedSlots: { customRender: 'mpStatus' }
           },
           // {
           //   title: '操作',