YaolongHan 4 years ago
parent
commit
e2d0305b75
2 changed files with 47 additions and 336 deletions
  1. 47 332
      src/views/room/index.vue
  2. 0 4
      vue.config.js

+ 47 - 332
src/views/room/index.vue

@@ -744,332 +744,44 @@ export default {
       this.page1 = val;
       this.Index1();
     },
-    methods: {
-        handleClick(tab) {
-            if (tab.label == '机房布置图') {
-                this.Index(this.smsxtArr.smsxt)
-            } else if (tab.label == '配电室低压柜及出线明细表') {
-                this.Index1()
-                this.$refs.roomTable2.computedHeight()
-            } else if (tab.label == '机房内核心设备') {
-                this.Index2()
-                this.$refs.roomTable3.computedHeight()
-            } else if (tab.label == '核心设备日常维修') {
-                this.Index3()
-                this.$refs.roomTable4.computedHeight()
-            } else if (tab.label == '核心设备日常维保') {
-                this.Index4()
-                this.changeSelect()
-                this.$refs.roomTable5.computedHeight()
-            }
-        },
-        // 右上角的筛选点击按钮
-        show() {
-            this.dialogFormVisible = !this.dialogFormVisible
-        },
-        Index(system) {
-            this.picFloor = this.$cookie.get('floorNow')
-            let getParams = {
-                typename: '位置布置图',
-                location: this.location,
-                module: '1002',
-                // system: system,
-                plazaId: this.plazaId,
-            }
-            if (system) {
-                getParams.system = system
-            }
-            queryPic({ getParams }).then((res) => {
-                //console.log('机房布置图', res)
-                this.tableImg = res.data ? res.data : []
-                //判断有没有图片,有图片默认显示按钮是第一个tab,没有图片显示的是第二个tab
-                if (this.tableImg.length > 0) {
-                    this.activeName = '1'
-                } else if (this.showLocationflid) {
-                    this.activeName = '2'
-                    this.Index1()
-                } else {
-                    this.activeName = '3'
-                    this.Index2()
-                }
-            })
-        },
-        // 明细表
-        Index1() {
-            let getParams = {
-                location: this.location,
-                plazaId: this.plazaId,
-                page: this.page1,
-                size: this.size1
-            }
-            if (this.floor2 && this.floor2 != '全部') {
-                getParams.floor = this.floor2
-            }
-            if (this.ctbhInput) {
-                if (getParams.keyword) {
-                    getParams.keyword = `${getParams.keyword + ';' + this.ctbhInput}:drawernum`
-                } else {
-                    getParams.keyword = `${this.ctbhInput}:drawernum`
-                }
-            }
-            if (this.cxggInput) {
-                if (getParams.keyword) {
-                    getParams.keyword = `${getParams.keyword + ';' + this.cxggInput}:outspec`
-                } else {
-                    getParams.keyword = `${this.cxggInput}:outspec`
-                }
-            }
-            if (this.djbhInput) {
-                if (getParams.keyword) {
-                    getParams.keyword = `${getParams.keyword + ';' + this.djbhInput}:wellnum`
-                } else {
-                    getParams.keyword = `${this.djbhInput}:wellnum`
-                }
-            }
-            if (this.kzhlInput) {
-                if (getParams.keyword) {
-                    getParams.keyword = `${getParams.keyword + ';' + this.kzhlInput}:control`
-                } else {
-                    getParams.keyword = `${this.kzhlInput}:control`
-                }
-            }
-            queryDygjcxline({ getParams }).then((res) => {
-                if (res.result == 'success') {
-                    this.loading1 = false
-                    this.total1 = res.count
-                    this.table2 = res.data ? res.data : []
-                    //console.log('明细表', res)
-                    if (this.table2.length == 0) {
-                    }
-                }
-            })
-        },
-        // 核心设备
-        Index2() {
-            let postParams = {
-                location: this.location,
-                system_code:this.smsxtArr.smsxt
-            }
-            let data = {
-                plazaId: this.plazaId,
-                page: this.page2,
-                size: this.size2,
-            }
-            if (this.sbjcInput) {
-                if (data.keyword) {
-                    data.keyword = `${data.keyword + ';' + this.sbjcInput}:type_name`
-                } else {
-                    data.keyword = `${this.sbjcInput}:type_name`
-                }
-            }
-            if (this.ppxhInput) {
-                if (data.keyword) {
-                    data.keyword = `${data.keyword + ';' + this.ppxhInput}:brand,sbxh`
-                } else {
-                    data.keyword = `${this.ppxhInput}:brand,sbxh`
-                }
-            }
-            if (this.sccsInput) {
-                if (data.keyword) {
-                    data.keyword = `${data.keyword + ';' + this.sccsInput}:manufacturer`
-                } else {
-                    data.keyword = `${this.sccsInput}:manufacturer`
-                }
-            }
-            // if (this.floorChange) {
-            //     postParams.gcname = this.floorChange
-            // }
-            queryHxsb({ data, postParams }).then((res) => {
-                this.loading2 = false
-                this.total2 = res.data.count
-                this.table3 = res.data.data ? res.data.data : []
-            })
-        },
-        Index1Emit(val) {
-            this.page1 = val
-            this.Index1()
-        },
-        Index2Emit(val) {
-            this.page2 = val
-            this.Index2()
-        },
-        Index3Emit(val) {
-            this.page3 = val
-            this.Index3()
-        },
-        Index4Emit(val) {
-            this.page4 = val
-            this.Index4()
-        },
-        // 机房维修记录
-        Index3() {
-            let getParams = {
-                location: this.location,
-                plazaId: this.plazaId,
-                page: this.page3,
-                size: this.size3,
-                orderBy: 'sjjssj,0;location,1',
-                smsxt:this.smsxtArr.smsxt
-            }
-            if (this.sfghSelect && this.sfghSelect != '全部') {
-                getParams.ismodel = this.sfghSelect
-            }
-            // 设备名称、编号
-            if (this.sbmcInput4) {
-                if (getParams.keyword) {
-                    getParams.keyword = `${getParams.keyword + ';' + this.sbmcInput4}:sbmc`
-                } else {
-                    getParams.keyword = `${this.sbmcInput4}:sbmc,location`
-                }
-            }
-            // 重要事项记录、描述
-            if (this.zysxInput4) {
-                if (getParams.keyword) {
-                    getParams.keyword = `${getParams.keyword + ';' + this.zysxInput4}:matters`
-                } else {
-                    getParams.keyword = `${this.zysxInput4}:matters,manufacturer`
-                }
-            }
-            // 搜索工单编号
-            if (this.gdbhInput4) {
-                if (getParams.keyword) {
-                    getParams.keyword = `${getParams.keyword + ';' + this.gdbhInput4}:wonum`
-                } else {
-                    getParams.keyword = `${this.gdbhInput4}:wonum`
-                }
-            }
-            // 填报时间
-            if (this.tbsjDate) {
-                getParams.reportedbyStartDate = this.tbsjDate[0] + '000000'
-                getParams.reportedbyEndDate = this.tbsjDate[1] + '000000'
-            }
-            // 验收时间
-            if (this.yssjDate) {
-                getParams.sjjssjStartDate = this.yssjDate[0] + '000000'
-                getParams.sjjssjEndDate = this.yssjDate[1] + '000000'
-            }
-
-            queryWxjf({ getParams }).then((res) => {
-                //console.log('维修', res)
-                if (res.result == 'success') {
-                    this.loading3 = false
-                    this.total3 = res.count
-                    this.table4 = res.data ? res.data : []
-                }
-            })
-        },
-        // 机房维保记录
-        Index4() {
-            let data = {
-                location: this.location,
-                plazaId: this.plazaId,
-                page: this.page4,
-                size: this.size4,
-                orderBy: 'wb_gzglid,0;assetnum,1;reportedby,0;',
-                smsxt:this.smsxtArr.smsxt
-            }
-            if(this.smsxtArr.smsxt != '1008'){
-                data.onlyMainAsset = true
-            }
-            // 任务开始日期
-            if (this.rwksrq) {
-                data.sjkssjStartDate = this.rwksrq[0] + '000000'
-                data.sjkssjEndDate = this.rwksrq[1] + '000000'
-            }
-            // 任务完成日期
-            if (this.rwwcrq) {
-                data.sjwcsjStartDate = this.rwwcrq[0] + '000000'
-                data.sjwcsjEndDate = this.rwwcrq[1] + '000000'
-            }
-            // 异常工单填报时间
-            if (this.ycgdtbsj) {
-                data.reportdateStartDate = this.ycgdtbsj[0] + '000000'
-                data.reportdateEndDate = this.ycgdtbsj[1] + '000000'
-            }
-            // 异常工单验收时间
-            if (this.ycgdyssj) {
-                data.sjjssjStartDate = this.ycgdyssj[0] + '000000'
-                data.sjjssjEndDate = this.ycgdyssj[1] + '000000'
-            }
-            //
-            // 是否正常
-            if (this.iszcSelect5 && this.iszcSelect5 != '全部') {
-                data.zt = this.iszcSelect5
-            }
-            // 任务状态
-            if (this.statuSelect5 && this.statuSelect5 != '全部') {
-                data.status = this.statuSelect5
-            }
-            if (this.sbmcInput5) {
-                if (data.keyword) {
-                    data.keyword = `${data.keyword + ';' + this.sbmcInput5}:sbmc,assetnum`
-                } else {
-                    data.keyword = `${this.sbmcInput5}:sbmc,assetnum`
-                }
-            }
-            if (this.wbsxjlInput5) {
-                if (data.keyword) {
-                    data.keyword = `${data.keyword + ';' + this.wbsxjlInput5}:matters`
-                } else {
-                    data.keyword = `${this.wbsxjlInput5}:matters,description`
-                }
-            }
-            if (this.rwbhInput5) {
-                if (data.keyword) {
-                    data.keyword = `${data.keyword + ';' + this.rwbhInput5}:wb_gzglid`
-                } else {
-                    data.keyword = `${this.rwbhInput5}:wb_gzglid`
-                }
-            }
-            if (this.ycgdbhInput5) {
-                if (data.keyword) {
-                    data.keyword = `${data.keyword + ';' + this.ycgdbhInput5}:wonum`
-                } else {
-                    data.keyword = `${this.ycgdbhInput5}:wonum`
-                }
-            }
-            queryWb({getParams:data}).then((res) => {
-                //console.log('维保', res)
-                this.loading4 = false
-                this.total4 = res.count
-                this.table5 = res.data ? res.data : []
-            })
-        },
-        confirm() {
-            this.Index3()
-        },
-        confirm2() {
-            this.Index4()
-        },
-        // 下拉框数据
-        changeSelect() {
-            this.department = []
-            let postParams = [
-                {
-                    columnName: { status: 'status', zt: 'zt' },
-                    tableName: 'sms_wbzy',
-                },
-            ]
-            let data = {
-                plazaId: this.plazaId,
-            }
-            querySelect({ data, postParams }).then((res) => {
-                //console.log('下拉框', res)
-                let status = [],
-                    zt = [],
-                    arr = [],
-                    arr1 = []
+    Index2Emit(val) {
+      this.page2 = val;
+      this.Index2();
+    },
+    Index3Emit(val) {
+      this.page3 = val;
+      this.Index3();
+    },
+    Index4Emit(val) {
+      this.page4 = val;
+      this.Index4();
+    },
+    // 机房维修记录
+    Index3() {
+      let getParams = {
+        data: {
+          smsxt: this.smsxtArr.smsxt,
+          // diff: this.diff,
+          plazaId: this.plazaId,
+          page: this.page3,
+          size: this.size3
+        }
+      };
+      //////////待定
+      //   if (this.assetnum) {
+      //     getParams.data.assetnum = this.assetnum;
+      //   }
 
       //下拉
-    // 监听下拉框
-    //   if (this.reportdate) {
-    //     getParams.data.schedfinishStartDate = this.reportdate[0] + "000000";
-    //     getParams.data.schedfinishEndDate = this.reportdate[1] + "000000";
-    //   }
-    //   if (this.real) {
-    //     getParams.data.wotjyssjStartDate = this.real[0] + "000000";
-    //     getParams.data.wotjyssjEndDate = this.real[1] + "000000";
-    //   }
+      // 监听下拉框
+      //   if (this.reportdate) {
+      //     getParams.data.schedfinishStartDate = this.reportdate[0] + "000000";
+      //     getParams.data.schedfinishEndDate = this.reportdate[1] + "000000";
+      //   }
+      //   if (this.real) {
+      //     getParams.data.wotjyssjStartDate = this.real[0] + "000000";
+      //     getParams.data.wotjyssjEndDate = this.real[1] + "000000";
+      //   }
       if (this.source && this.source != "全部") {
         getParams.data.bxfwlymc = this.source;
       }
@@ -1102,6 +814,9 @@ export default {
         orderBy: "wb_gzglid,0;assetnum,1;reportedby,0;",
         smsxt: this.smsxtArr.smsxt
       };
+      if (this.smsxtArr.smsxt != "1008") {
+        data.onlyMainAsset = true;
+      }
       //
       // 任务开始日期
       if (this.rwksrq) {
@@ -1136,30 +851,30 @@ export default {
         if (data.keyword) {
           data.keyword = `${data.keyword +
             ";" +
-            this.sbmcInput5}:sbmc,assetnum`;
+            this.sbmcInput5}:sbmc,assetnum;`;
         } else {
-          data.keyword = `${this.sbmcInput5}:sbmc,assetnum`;
+          data.keyword = `${this.sbmcInput5}:sbmc,assetnum;`;
         }
       }
       if (this.wbsxjlInput5) {
         if (data.keyword) {
-          data.keyword = `${data.keyword + ";" + this.wbsxjlInput5}:matters`;
+          data.keyword = `${data.keyword + ";" + this.wbsxjlInput5}:matters;`;
         } else {
-          data.keyword = `${this.wbsxjlInput5}:matters,description`;
+          data.keyword = `${this.wbsxjlInput5}:matters,description;`;
         }
       }
       if (this.rwbhInput5) {
         if (data.keyword) {
-          data.keyword = `${data.keyword + ";" + this.rwbhInput5}:wb_gzglid`;
+          data.keyword = `${data.keyword + ";" + this.rwbhInput5}:wb_gzglid;`;
         } else {
-          data.keyword = `${this.rwbhInput5}:wb_gzglid`;
+          data.keyword = `${this.rwbhInput5}:wb_gzglid;`;
         }
       }
       if (this.ycgdbhInput5) {
         if (data.keyword) {
-          data.keyword = `${data.keyword + ";" + this.ycgdbhInput5}:wonum`;
+          data.keyword = `${data.keyword + ";" + this.ycgdbhInput5}:wonum;`;
         } else {
-          data.keyword = `${this.ycgdbhInput5}:wonum`;
+          data.keyword = `${this.ycgdbhInput5}:wonum;`;
         }
       }
       queryWb({ getParams: data }).then(res => {

+ 0 - 4
vue.config.js

@@ -34,11 +34,7 @@ module.exports = {
             // 图例库服务
             "/serve": {
                 // target: 'http://192.168.200.87:8088',
-<<<<<<< HEAD
-                // target: 'http://10.199.143.129:8080',
-=======
                // target: 'http://10.199.143.129:8080',
->>>>>>> 3a6ed3b20db14fc2004f10c84ce0e9f3f6869cfb
                 target: 'http://60.205.177.43:8080',
                 changeOrigin: true,
                 pathRewrite: {