Sfoglia il codice sorgente

fix(工单): 优化状态显示为"正常/异常"并修复执行人信息显示逻辑

yusheng 5 mesi fa
parent
commit
edf3f71cf0

+ 2 - 2
src/views/maintenance/equipment/workOrder/details.vue

@@ -347,8 +347,8 @@
     data() {
       return {
         options: {
-          0: '正常',
-          '-1': '缺陷'
+          1: '正常',
+          '-1': '异常'
         },
         num: 1,
         infoData: {},

+ 8 - 2
src/views/maintenance/equipment/workOrder/index.vue

@@ -39,7 +39,7 @@
           <jimureportBrowse
             :businessId="row.id"
             businessCode="eommaintenance"
-            v-if="row.orderStatus==3"
+            v-if="row.orderStatus == 3"
           ></jimureportBrowse>
           <el-link
             v-if="row.orderStatus !== 3 && row.orderStatus !== 4"
@@ -156,6 +156,9 @@
             showOverflowTooltip: true,
             minWidth: 120,
             formatter: (row) => {
+              if (row.executeGroupName) {
+                return row.executeGroupName;
+              }
               if (row.executeUserType == 0) {
                 return row.executeUsers.map((i) => i.groupName).join(',');
               }
@@ -168,6 +171,9 @@
             align: 'center',
             showOverflowTooltip: true,
             formatter: (row) => {
+              if (row.executeUserName) {
+                return row.executeUserName;
+              }
               if (row.executeUserType == 0) {
                 return row.executeUsers.map((i) => i.userName).join(',');
               }
@@ -303,7 +309,7 @@
         data.deviceList = data.deviceList.map((item) => {
           return item.substance;
         });
-        console.log(3333333333333,111)
+        console.log(3333333333333, 111);
         this.$refs.edit.open(data, 'add');
       },
       goDetail({ id }) {

+ 4 - 3
src/views/maintenance/patrol/workOrder/index.vue

@@ -41,9 +41,7 @@
             报工
           </el-link>
           <el-link
-            v-if="
-              row.orderStatus !== 3 && row.orderStatus !== 4 
-            "
+            v-if="row.orderStatus !== 3 && row.orderStatus !== 4"
             type="primary"
             :underline="false"
             icon="el-icon-edit"
@@ -128,6 +126,9 @@
             showOverflowTooltip: true,
             minWidth: 120,
             formatter: (row) => {
+              if (row.executeGroupName) {
+                return row.executeGroupName;
+              }
               if (row.executeUserType == 0) {
                 return row.executeUsers.map((i) => i.groupName).join(',');
               }