Quellcode durchsuchen

处理设备管理页面功能

oyq28 vor 2 Jahren
Ursprung
Commit
e1470f8983

+ 8 - 4
imcs-bt-fe/imcs-bt-fe/imcs-ui/src/views/zuihou/place/Index.vue

@@ -69,19 +69,19 @@
       <el-table-column :label="$t('place.plcPid')" :show-overflow-tooltip="true" align="center" prop="plcPid"
                        width="">
         <template slot-scope="scope">
-          <span>{{ scope.row.plcPid }}</span>
+          <span>{{ scope.row.plcPid | getCodeName}}</span>
         </template>
       </el-table-column>
       <el-table-column :label="$t('place.plcCid')" :show-overflow-tooltip="true" align="center" prop="plcCid"
                        width="">
         <template slot-scope="scope">
-          <span>{{ scope.row.plcCid }}</span>
+          <span>{{ scope.row.plcCid | getCodeName}}</span>
         </template>
       </el-table-column>
       <el-table-column :label="$t('place.plcAid')" :show-overflow-tooltip="true" align="center" prop="plcAid"
                        width="">
         <template slot-scope="scope">
-          <span>{{ scope.row.plcCid }}</span>
+          <span>{{ scope.row.plcAid | getCodeName}}</span>
         </template>
       </el-table-column>
       <el-table-column :label="$t('place.plcRoad')" :show-overflow-tooltip="true" align="center" prop="plcRoad"
@@ -222,7 +222,11 @@ export default {
   name: "PlaceManage",
   directives: {elDragDialog},
   components: {Pagination, PlaceEdit, PlaceImport},
-  filters: {},
+  filters: {
+    getCodeName(code){
+        return CodeToText[code];
+    }
+  },
   data() {
     return {
 

+ 6 - 3
imcs-bt-fe/imcs-bt-fe/imcs-ui/src/views/zuihou/place/components/Edit.vue

@@ -228,9 +228,12 @@ export default {
       // this.form.aCode = this.place.selectedOptions[2]
       // console.log("省市县数据:", this.form);
 
-      this.place.plcPid = CodeToText[this.place.selectedOptions[0]];
-      this.place.plcCid = CodeToText[this.place.selectedOptions[1]];
-      this.place.plcAid = CodeToText[this.place.selectedOptions[2]];
+      //this.place.plcPid = CodeToText[this.place.selectedOptions[0]];
+      //this.place.plcCid = CodeToText[this.place.selectedOptions[1]];
+      //this.place.plcAid = CodeToText[this.place.selectedOptions[2]];
+      this.place.plcPid = this.place.selectedOptions[0];
+      this.place.plcCid = this.place.selectedOptions[1];
+      this.place.plcAid = this.place.selectedOptions[2];
       // 场地的,省市区地址
       // this.address = this.form.provinces + this.form.city + this.form.area;
       this.address = this.place.plcPid + this.place.plcCid + this.place.plcAid;

+ 11 - 4
imcs-bt-fe/imcs-bt-fe/imcs-ui/src/views/zuihou/productionresource/Index.vue

@@ -116,7 +116,7 @@
               border fit row-key="id" ref="table" style="width: 100%;margin-top:30px;" v-loading="loading">
       <el-table-column align="center" type="selection" width="40px" :reserve-selection="true"/>
       <el-table-column :label="$t('productionResource.imgUrl')" :show-overflow-tooltip="true" align="center"
-                       prop="compnayId"
+                       prop="pic"
                        width="">
         <template slot-scope="scope">
           <span><el-image :src="scope.row.pic"></el-image></span>
@@ -138,7 +138,7 @@
                        prop="areaId"
                        width="200px">
         <template slot-scope="scope">
-          <span>{{ scope.row.areaIds }}</span>
+          <span>{{ scope.row.areaIds | getCodeNames }}</span>
         </template>
       </el-table-column>
       <el-table-column :label="$t('productionResource.placeName')" :show-overflow-tooltip="true" align="center"
@@ -152,7 +152,7 @@
                        prop="code"
                        width="150px">
         <template slot-scope="scope">
-          <span>{{ scope.row.tenantDesc }}</span>
+          <span>{{ scope.row.lineDesc }}</span>
         </template>
       </el-table-column>
       <el-table-column :label="$t('productionResource.onlineStatus')" :show-overflow-tooltip="true" align="center"
@@ -264,7 +264,14 @@ export default {
   name: "ProductionresourceManage",
   directives: {elDragDialog},
   components: {Pagination, ResourceEdit, ProductMgr, MaterialMgr, OrderMgr, advertisingMgr},
-  filters: {},
+  filters: {
+    getCodeNames(code){
+       let arr = code.split(',')
+       return arr.length>1 ? arr.map(item => {
+          return CodeToText[item]
+       }).join('/') : '';
+    }
+  },
   data() {
     return {
       // 编辑