瀏覽代碼

修改bug

zhangyu 4 年之前
父節點
當前提交
95f0f7886b
共有 3 個文件被更改,包括 9 次插入73 次删除
  1. 2 0
      config/index.js
  2. 4 70
      src/views/ledger/facility/parts/index.vue
  3. 3 3
      src/views/ledger/facility/partsmanage/index.vue

+ 2 - 0
config/index.js

@@ -210,6 +210,7 @@ module.exports = {
         }
       },
       '/api': {
+        // target: 'http://192.168.64.17:28888/',
         target: 'http://192.168.64.14:28888/',
         changeOrigin: true,
         pathRewrite: {
@@ -293,6 +294,7 @@ module.exports = {
         // target: 'http://192.168.12.238:8080/',
         // target: 'http://60.205.177.43:28888',
         target: 'http://192.168.64.14:28888',
+        // target: 'http://192.168.64.17:28888',
         // 如果要代理 websockets
         ws: true,
         // 将主机标头的原点更改为目标URL

+ 4 - 70
src/views/ledger/facility/parts/index.vue

@@ -2,15 +2,11 @@
   <div id="partsList">
     <el-row>
       <el-tabs @tab-click="getTableHeader" v-model="tabVal">
-        <el-tab-pane v-for="t in partsTypeList" :key="t.Category" :name="t.Category"
-                     :label="t.CategoryName+'('+t.count+')'"></el-tab-pane>
+        <el-tab-pane v-for="t in partsTypeList" :key="t.category" :name="t.category"
+                     :label="`${t.categoryName}(${t.count?t.count:0})`"></el-tab-pane>
       </el-tabs>
     </el-row>
     <el-row class="left">
-      <!-- <div style="width:200px;display:inline-block;text-align:left;color:gray;">
-        <span>只看要采集的信息</span>
-        <el-checkbox v-model="allMess" @change="getTableHeader"></el-checkbox>
-      </div> -->
       <el-button size="small" type="default" icon="el-icon-back" @click="goback" style="margin-right:10px;"></el-button>
       <el-select v-model="showType" @change="initTable" style="width:100px;margin-right:10px;vertical-align:bottom;">
         <el-option v-for="item in showTypes" :key="item.value" :label="item.label" :value="item.value">
@@ -49,12 +45,6 @@ import tools from "@/utils/scan/tools";
 import showTools from "@/utils/handsontable/notShow";
 
 import qrcode from "@/components/ledger/lib/qrcode";
-import firm from "@/components/dialogs/list/firm";
-import supplyDialog from "@/components/dialogs/list/supplyDialog";
-import supplierDialog from "@/components/dialogs/list/supplierDialog";
-import maintainerDialog from "@/components/dialogs/list/maintainerDialog";
-import insurerDialog from "@/components/dialogs/list/insurerDialog";
-import guaranteeDialog from "@/components/dialogs/list/guaranteeDialog";
 import uploadFilesDialog from "@/components/dialogs/list/filesDialog";
 import uploadImgDialog from "@/components/dialogs/list/uploadImgDialog";
 import picDialog from "@/components/dialogs/list/picDialog";
@@ -67,12 +57,6 @@ import {mapGetters} from "vuex";
 export default {
   components: {
     qrcode, //二维码页面
-    firm, //品牌型号弹窗
-    supplyDialog,
-    supplierDialog,
-    maintainerDialog,
-    insurerDialog,
-    guaranteeDialog,
     uploadFilesDialog,
     uploadImgDialog,
     picDialog,
@@ -104,12 +88,6 @@ export default {
       partsTypeList: [], //tabs
       myDialog: {
         qrcode: false, //二维码弹窗
-        firm: false, //厂商弹窗
-        supply: false, //选择供应合同
-        supplier: false, //供应商选择
-        guarantee: false, //选择保单
-        maintainer: false, //选择维修商
-        insurer: false, //选择保险公司
         uploadFiles: false, //上传文件
         uploadImgs: false, //上传单个图片
         pic: false, //多个图片
@@ -119,6 +97,7 @@ export default {
         changeRea: false,
         lookPic: false //图片查看
       },
+      inputMap: {},
       qrcodeUrl: "", //二维码图片地址
       filesArr: [], //保存临时的文件key
       imgsArr: [], //临时保存的图片key数组
@@ -190,7 +169,7 @@ export default {
       let params = {
         pageNumber: this.page.pageNumber,
         pageSize: this.page.PageSize,
-        orders: "createTime desc, EquipLocalName desc, EquipLocalID desc, EquipID desc",
+        orders: "createTime desc, localName desc, localId desc, id desc",
         filters: `category='${this.tabVal}';parentId='${this.deviceId}'`
       };
       await getEquipPartsCon(params, res => {
@@ -326,51 +305,6 @@ export default {
         // this.systemList = this.tableData[row.row].linkSystem || [];
         this.myDialog.systemType = true;
       }
-      //品牌型号弹窗
-      if (val == "dpManufacturerId") {
-        this.myDialog.firm = true;
-      }
-      //供应商信息弹窗
-      if (val == "dpSupplierId") {
-        this.myDialog.supplier = true;
-      }
-      //维修商信息弹窗
-      if (val == "dpMaintainerId") {
-        this.myDialog.maintainer = true;
-      }
-      //保险公司信息
-      if (val == "dpInsurerId") {
-        this.myDialog.insurer = true;
-      }
-      //供应合同编号
-      if (val == "infos.supplierContractID") {
-        let falg = null;
-        let data = this.tableData[row.row].dpSupplierId;
-        if (data) {
-          falg = data.split("-")[0];
-        }
-        if (!!falg) {
-          this.id = falg;
-          this.myDialog.supply = true;
-        } else {
-          this.$message("请先选择供应商");
-        }
-      }
-      //保险单号
-      if (val == "infos.insuranceNum") {
-        //选择保单
-        let falg = null;
-        let data = this.tableData[row.row].dpInsurerId;
-        if (data) {
-          falg = data.split("-")[0];
-        }
-        if (!!falg) {
-          this.id = falg;
-          this.myDialog.guarantee = true;
-        } else {
-          this.$message("请先选择保险商");
-        }
-      }
       //保险文件--设备文档--安装质检报告
       if (
         val == "infos.insuranceFile" || //保险文件

+ 3 - 3
src/views/ledger/facility/partsmanage/index.vue

@@ -2,8 +2,8 @@
   <div id="deviceList">
     <el-row>
       <el-tabs @tab-click="tabsClick" v-model="tabVal">
-        <el-tab-pane v-for="t in partsTypeList" :key="t.id" :name="t.code"
-                     :label="t.name+'('+t.count+')'"></el-tab-pane>
+        <el-tab-pane v-for="t in partsTypeList" :key="t.code" :name="t.code"
+                     :label="`${t.name}(${t.count?t.count:0})`"></el-tab-pane>
       </el-tabs>
     </el-row>
     <el-row class="left">
@@ -338,7 +338,7 @@ export default {
         data: []
       };
       params.map(item => {
-        param.data.push({ EquipID: item.EquipID });
+        param.data.push({ id: item.id });
       });
       this.$confirm("此操作将删除部件,是否继续?", "提示", {
         confirmButtonText: "确定",