zhulizhen1111 4 anni fa
parent
commit
a253b5457a

+ 2 - 0
src/utils/plugins/components.js

@@ -10,6 +10,7 @@ var system = [
                     label: "系统原理图",
                     children: [],
                     id: "GDYL",
+                    param: { tab_code: "1592" },
                 },
                 {
                     label: "变配电室内部设备清单",
@@ -21,6 +22,7 @@ var system = [
                     label: "楼层电井(间)控制商铺范围清单",
                     id: "GJSP",
                     children: [],
+                    param: { tab_code: "1592" },
                 },
                 {
                     label: "维保事项",

+ 10 - 5
src/views/equipment/eqDialog.vue

@@ -39,13 +39,13 @@
                         <tableList v-else-if='value.id.slice(0,4)=="RDQD"' :param='param' ref='list1' major='弱电'></tableList>
                         <tableList v-else-if='value.id.slice(0,4)=="NTQD"' :param='param' ref='list2' major='暖通'></tableList>
                         <!-- 维保表格 -->
-                        <wb-table v-else-if='value.id.slice(2,4)=="WB"' :smsxt='smsxt' major='维保'></wb-table>
+                        <wb-table v-else-if='value.id.slice(2,4)=="WB"' :smsxt='smsxt'></wb-table>
                         <!-- 维修的表格 -->
-                        <wx-table v-else-if='value.id.slice(2,4)=="WX"' :smsxt='smsxt' major='维修'></wx-table>
+                        <wx-table v-else-if='value.id.slice(2,4)=="WX"' :smsxt='smsxt'></wx-table>
                         <!-- 专维 -->
-                        <zw-table v-else-if='value.id.slice(2,4)=="ZW"' :smsxt='smsxt' major='专维'></zw-table>
+                        <zw-table v-else-if='value.id.slice(2,4)=="ZW"' :smsxt='smsxt' :major='dialogInfo.id'></zw-table>
                         <!-- 其他 -->
-                        <other-table v-else-if='value.id.slice(2,4)=="QT"' param major='其他'></other-table>
+                        <other-table v-else-if='value.id.slice(2,4)=="QT"' :smsxt='smsxt' :major='dialogInfo.id'></other-table>
                         <!-- 建筑立面图 -->
                         <tj-build-table v-else-if='value.id.slice(0,4)=="TJLM"'></tj-build-table>
                     </el-tab-pane>
@@ -92,7 +92,12 @@ export default {
             this.param = this.activeName
         },
         handleClick(tab) {
-            this.param = tab.name
+            if (this.param) {
+                this.param = tab.name
+            } else if (this.smsxt) {
+                this.smsxt = tab.name
+            }
+
             this.activeName = tab.name
         },
         visibalBox() {

+ 0 - 1
src/views/equipment/table/lookPageTable.vue

@@ -61,7 +61,6 @@ export default {
     methods: {
         pageChanged(page, size) {
             this.currentPage = page
-            this.size = size
             this.getList()
         },
         getList() {

+ 17 - 8
src/views/equipment/table/otherTable.vue

@@ -4,7 +4,7 @@
         <div class='eq-list-top'>
             <el-date-picker size='small' v-model='yssjwcsj' type='date' placeholder='选择处理日期:' @change='getList' style='width:180px;margin-right:12px'></el-date-picker>
             <Select width='146' tipPlace='top' caption='处置结果:' :selectdata='dataSelect2' :placeholder='"请选择"' @change='getList'></Select>
-            <el-input placeholder='按照位置和内容搜索' style='width:192px;margin-right:12px' size='small' prefix-icon='el-icon-search' v-model='input'></el-input>
+            <el-input placeholder='按照位置和内容搜索' style='width:192px;margin-right:12px' size='small' prefix-icon='el-icon-search' v-model='keyword'></el-input>
         </div>
         <el-table :data='tableData' :border='true' style='width: 100%'>
             <el-table-column type='index' label='序号' width='80'></el-table-column>
@@ -65,17 +65,17 @@ export default {
                 { id: 'test2', name: '单平米' },
                 { id: 'test3', name: '下级分项' },
                 { id: 'test4', name: '滑动平均滑动平均' }
-            ]
+            ],
+            keyword: ''
         }
     },
-    props: ['major', 'systemName'],
+    props: ['major', 'smsxt'],
     computed: {
         ...mapGetters(['floorSelect'])
     },
     methods: {
         pageChanged(page, size) {
             this.currentPage = page
-            this.size = size
             this.getList()
         },
         getList() {
@@ -94,9 +94,10 @@ export default {
             // })
             let getParams = {
                 data: {
-                    system: this.systemName,
-                    tab: this.major,
-                    plazaId: this.$store.state.plazaId,
+                    smsxt: this.smsxt,
+                    // tab: this.major,
+                    // plazaId: this.$store.state.plazaId,
+                    plazaId: '1000287',
                     page: this.currentPage,
                     size: this.size
                 }
@@ -107,8 +108,16 @@ export default {
             })
         }
     },
+    watch: {
+        smsxt(newV, oldV) {
+            if (newV !== oldV) {
+                // this.tabFind()
+                // this.getList()
+            }
+        }
+    },
     mounted() {
-        this.getList()
+        // this.getList()
     }
 }
 </script>

+ 1 - 2
src/views/equipment/table/wbTable.vue

@@ -128,9 +128,8 @@ export default {
     },
     methods: {
         onSearch() {},
-        pageChanged(page, size) {
+        pageChanged(page) {
             this.currentPage = page
-            this.size = size
             this.getList()
         },
         getList() {

+ 1 - 2
src/views/equipment/table/wxTable.vue

@@ -128,9 +128,8 @@ export default {
     props: ['smsxt', 'major'],
     methods: {
         onSearch() {},
-        pageChanged(page, size) {
+        pageChanged(page) {
             this.currentPage = page
-            this.size = size
             this.getList()
         },
         getList() {

+ 40 - 35
src/views/equipment/table/zwTable.vue

@@ -2,7 +2,7 @@
 <template>
     <div class='zw-list'>
         <div class='eq-list-top'>
-            <el-date-picker size='small' v-model='nd' type='date' placeholder='请选择年度' @change='getList' style='width:180px;margin-right:12px'></el-date-picker>
+            <el-date-picker size='small' v-model='nd' type='year' placeholder='请选择年度' @change='getList' style='width:180px;margin-right:12px'></el-date-picker>
             <Select width='146' tipPlace='top' caption='类别:' :selectdata='dataSelect2' :placeholder='"请选择"' @change='getList'></Select>
             <Select width='120' tipPlace='top' caption='项目 :' :selectdata='floorSelect' style='margin:0 12px' @change='getList'></Select>
             <Select width='180' tipPlace='top' caption='当前阶段' :selectdata='dataSelect2' :placeholder='"请选择"' @change='getList'></Select>
@@ -75,7 +75,7 @@
             <el-pagination
                 background
                 layout='prev, pager, next'
-                :total='total/size'
+                :total='total'
                 :page-size='size'
                 @prev-click='pageChanged'
                 @next-click='pageChanged'
@@ -87,6 +87,7 @@
 <script>
 import Select from '@/components/Select/Select.vue'
 import { queryZw } from '@/api/equipmentList.js'
+import { querySelect } from '@/api/public.js'
 import { mapGetters } from 'vuex'
 export default {
     components: { Select },
@@ -103,17 +104,18 @@ export default {
             currentPage: 1,
             yssjwcsj: '',
             lxsjwcsj: '',
-            size: 10
+            size: 10,
+            keyword: '',
+            nd: ''
         }
     },
     computed: {
         ...mapGetters(['floorSelect'])
     },
-    props: ['smsxt', ''],
+    props: ['smsxt', 'major'],
     methods: {
-        pageChanged(page, size) {
+        pageChanged(page) {
             this.currentPage = page
-            this.size = size
             this.getList()
         },
         //下拉框查询
@@ -127,42 +129,44 @@ export default {
                     tableName: 'glsms_asset' //视图名称
                 }
             ]
-            // let major
-            // if (this.major.slice(0, 2) == 'GD') {
-            //     major = '供电'
-            // } else if (this.major.slice(0, 2) == 'XF') {
-            //     major = '消防'
-            // } else if (this.major.slice(0, 2) == 'GPS') {
-            //     major = '给排水'
-            // } else if (this.major.slice(0, 2) == 'DT') {
-            //     major = '电梯'
-            // } else if (this.major.slice(0, 2) == 'RQ') {
-            //     major = '燃气'
-            // } else {
-            //     major = this.major
-            // }
+            let major
+            if (this.major.slice(0, 2) == 'GD') {
+                major = '供电'
+            } else if (this.major.slice(0, 2) == 'XF') {
+                major = '消防'
+            } else if (this.major.slice(0, 2) == 'GPS') {
+                major = '给排水'
+            } else if (this.major.slice(0, 2) == 'DT') {
+                major = '电梯'
+            } else if (this.major.slice(0, 2) == 'RQ') {
+                major = '燃气'
+            } else {
+                major = this.major
+            }
             let data = {
-                major: this.major,
+                major: major,
                 plazaId: this.$store.state.plazaId
             }
             querySelect({ data, postParams }).then(res => {
                 console.log(res)
-                let sb_status = res.data.data.glsms_asset.sb_status
-                let sbglgs = res.data.data.glsms_asset.sbglgs
-                this.sbglgsOption = []
-                this.statusOption = []
-                sb_status.forEach(el => {
-                    this.statusOption.push({
-                        name: el.value,
-                        id: el.key
+                if (Object.key(res.data.data).length > 0) {
+                    let sb_status = res.data.data.glsms_asset.sb_status
+                    let sbglgs = res.data.data.glsms_asset.sbglgs
+                    this.sbglgsOption = []
+                    this.statusOption = []
+                    sb_status.forEach(el => {
+                        this.statusOption.push({
+                            name: el.value,
+                            id: el.key
+                        })
                     })
-                })
-                sbglgs.forEach(el => {
-                    this.sbglgsOption.push({
-                        name: el.value,
-                        id: el.key
+                    sbglgs.forEach(el => {
+                        this.sbglgsOption.push({
+                            name: el.value,
+                            id: el.key
+                        })
                     })
-                })
+                }
             })
         },
         getList() {
@@ -185,6 +189,7 @@ export default {
     watch: {
         smsxt(newV, oldV) {
             if (newV !== oldV) {
+                // this.tabFind()
                 this.getList()
             }
         }

+ 0 - 1
src/views/legendLibrary/index.vue

@@ -233,7 +233,6 @@ export default {
         },
         pageChanged(page, size) {
             this.currentPage = page
-            // this.size = size
             this.getTableList()
         },
         getTableList() {