YaolongHan 4 anni fa
parent
commit
8545deca54

+ 4 - 6
public/systemConf.js

@@ -23,12 +23,10 @@ var __systemConf = {
     // 系统编码
     systemCode: 'wandaBmGuide',
     conf: {
-        // 编辑器地址
         // TODO: 修改为对应的地址
-        // editerUrl: 'http://192.168.200.1:9910/wandaEditer/',
-        editerUrl: 'http://192.168.200.89:8080/wandaEditer/',
-        // wandaBmGuideUrl: 'http://192.168.200.89:8080/wandaBmGuide',
-        wandaBmGuideUrl: 'localhost:8090/wandaBmGuide',
+        // 开发环境地址 ip+port
+        editerUrl: 'http://192.168.200.1:8091/wandaEditer/', // 编辑器地址
+        wandaBmGuideUrl: 'http://192.168.200.1:8090/wandaBmGuide/', // 管理书地址
     },
 }
-window.__systemConf = __systemConf
+window.__systemConf = __systemConf

+ 2 - 2
src/components/Rotation/src/rotation.vue

@@ -40,8 +40,8 @@ export default {
         height: 100%;
     }
     img {
-        width: 100%;
-        height: 100%;
+        width: 90%;
+       
     }
 }
 </style>

+ 5 - 4
src/components/menuList.vue

@@ -127,10 +127,11 @@ export default {
       this.$router.push({ path: `/home/${item.route}` });
     },
 
-    dumpLegend() {
-      const { conf } = window.__systemConf,
-        { wandaBmGuideUrl } = conf;
-      window.open(`${wandaBmGuideUrl}/home/legendLibrary`, true);
+        dumpLegend() {
+            const { conf } = window.__systemConf,
+                { wandaBmGuideUrl } = conf
+            window.open(`${wandaBmGuideUrl}home/legendLibrary`, true)
+        }
     },
     //入草稿箱
     toDrafts() {

+ 1 - 1
src/lib/GraphView.ts

@@ -59,7 +59,7 @@ export class GraphView extends SCanvasView {
         canvas.clearRect(0, 0, this.width, this.height)
         canvas.pen.lineWidth = this.lineWidth;
         if (this.lineType == 'dashed') {
-            canvas.pen.lineDash = [10, 10]
+            canvas.pen.lineDash = [10, 2]
         }
         if (this.lineType == 'dotted') {
             canvas.pen.lineDash = [this.lineWidth, this.lineWidth]

+ 17 - 18
src/store/index.js

@@ -1,6 +1,6 @@
-import Vue from "vue"
-import Vuex from "vuex"
-import { login, queryFloor, queryfmapID } from "@/api/login.js"
+import Vue from 'vue'
+import Vuex from 'vuex'
+import { login, queryFloor, queryfmapID } from '@/api/login.js'
 Vue.use(Vuex)
 export default new Vuex.Store({
     state: {
@@ -8,15 +8,15 @@ export default new Vuex.Store({
         permissions: [], //权限信息 "GLSMS_VIEW":"说明书查看"、"GLSMS_SYMBOL_MANAGE": "图例库管理"、 "GLSMS_PLANARGRAPH_MANAGE":"平面图维护"
         plazas: [], //项目列表
         userInfo: {
-            employeename: "", //用户名称:艾宇;
-            orgCode: "",
-            username: "lengqiang", //账户名称
+            employeename: '', //用户名称:艾宇;
+            orgCode: '',
+            username: 'lengqiang', //账户名称
         },
-        plazaId: "1000423",
-        projectName: "", //全局项目名称
+        plazaId: '1000423',
+        projectName: '', //全局项目名称
         floorsArr: [], //楼层数组
         floorSelect: [], //楼层下拉框
-        fmapID: "",
+        fmapID: '',
     },
     getters: {
         floorsArr: (state) => state.floorsArr,
@@ -42,7 +42,6 @@ export default new Vuex.Store({
             state.floorsArr = data
             if (data.length > 0) {
                 data.forEach((e) => {
-                    console.log(e)
                     let obj = {
                         id: e.gname,
                         name: e.code,
@@ -61,19 +60,19 @@ export default new Vuex.Store({
             await login({
                 username: palyload,
             }).then((res) => {
-                if (res.result == "success") {
-                    commit("SETISREQUESTtAUTH", true)
-                    commit("SETAUTHMSG", res)
+                if (res.result == 'success') {
+                    commit('SETISREQUESTtAUTH', true)
+                    commit('SETAUTHMSG', res)
                 } else {
-                    console.log("接口报错!!")
-                    commit("SETISREQUESTtAUTH", false)
+                    console.log('接口报错!!')
+                    commit('SETISREQUESTtAUTH', false)
                 }
             })
         },
         getFloors(context) {
             queryFloor({ plazaId: context.state.plazaId }).then((res) => {
-                if (res.result == "success") {
-                    context.commit("SETFLOORS", res.data)
+                if (res.result == 'success') {
+                    context.commit('SETFLOORS', res.data)
                 }
             })
         },
@@ -81,7 +80,7 @@ export default new Vuex.Store({
             await queryfmapID({
                 mapId: context.state.plazaId,
             }).then((res) => {
-                context.commit("SETMAPID", `${context.state.plazaId}_${res.mapVersion}`)
+                context.commit('SETMAPID', `${context.state.plazaId}_${res.mapVersion}`)
             })
         },
     },

+ 15 - 14
src/utils/plugins/components.js

@@ -108,11 +108,11 @@ var system = [
                             id: "NTYL3",
                             param: { tab_code: "1502", type_code: "2013" },
                         },
-                        // {
-                        //     label: "分水器支路分布图",
-                        //     id: "NTYL4",
-                        //     param: { tab_code: "1542" },
-                        // },
+                        {
+                            label: "分水器支路分布图",
+                            id: "NTYL4",
+                            param: { tab_code: "1542", type_code: "FBT" },
+                        },
                     ],
                 },
                 {
@@ -218,10 +218,11 @@ var system = [
                             id: "XFYL4",
                             param: { tab_code: "1545", type_code: "2017" },
                         },
-                        // {
-                        //     label: "消防泵房引出管路分布图",
-                        //     id: "XFYL5",
-                        // },
+                        {
+                            label: "消防泵房引出管路分布图",
+                            id: "XFYL5",
+                            param: { type_code: "FBT" },
+                        },
                     ],
                     id: "XFYL",
                 },
@@ -627,6 +628,11 @@ var system = [
                     id: "TJYL",
                     children: [
                         {
+                            label: "北面外立面",
+                            id: "RQYL",
+                            param: { tab_code: "2343", type_code: "2029" },
+                        },
+                        {
                             label: "西面外立面",
                             id: "RQYL",
                             param: { tab_code: "2340", type_code: "2027" },
@@ -641,11 +647,6 @@ var system = [
                             id: "RQYL",
                             param: { tab_code: "2342", type_code: "2026" },
                         },
-                        {
-                            label: "北面外立面",
-                            id: "RQYL",
-                            param: { tab_code: "2343", type_code: "2029" },
-                        },
                     ],
                 },
                 {

+ 22 - 6
src/views/equipment/eqDialog.vue

@@ -15,7 +15,7 @@
             <!-- 没有tab的页面 -->
             <div v-if='Object.keys(dialogInfo).length>0 && dialogInfo.children.length==0' style='margin:16px 24px 0 24px'>
                 <!-- 原理图 -->
-                <div v-if='dialogInfo.id.slice(2,4)=="YL"' style='width:100%;height:90vh;overflow:hidden'>
+                <div v-if='dialogInfo.id.slice(2,4)=="YL"' style='width:90%;overflow:hidden'>
                     <rotation :rotationImg='rotationImg'></rotation>
                 </div>
                 <!-- 土建系统主要材料清单 -->
@@ -57,13 +57,21 @@
                                     :key='index1+index'
                                     :label='`${value.label}`'
                                     :name='`${value.param.type_code}`'
-                                    v-if='value.id.slice(2,4)=="YL" && eve.count>0'
+                                    v-if='value.id.slice(2,4)=="YL" && eve.count>0 && value.param.type_code!="FBT"'
                                 >
                                     <!-- 有tab的原理图 -->
                                     <div style='width:100%;height:600px;overflow:hidden'>
                                         <rotation :rotationImg='rotationImg'></rotation>
                                     </div>
                                 </el-tab-pane>
+                                <el-tab-pane
+                                    :key='index1+index'
+                                    :label='`${value.label}`'
+                                    :name='`${value.param.type_code}`'
+                                    v-if='value.id.slice(2,4)=="YL" && value.param.type_code=="FBT"'
+                                >
+                                    <fenbuPic></fenbuPic>
+                                </el-tab-pane>
                             </template>
                         </template>
                     </template>
@@ -86,6 +94,7 @@ import wxTable from './table/wxTable'
 import recordDialog from './table/recordDialog'
 import djspTable from './table/djspTable'
 import { queryPic, queryTab } from '@/api/public.js'
+import fenbuPic from './fenbuPic'
 export default {
     props: ['systemName', 'smsxt'],
     data() {
@@ -102,7 +111,7 @@ export default {
         }
     },
     mounted() {},
-    components: { tableList, tjTable, wbTable, zwTable, lookPage, standTable, otherTable, wxTable, recordDialog, djspTable },
+    components: { tableList, tjTable, wbTable, zwTable, lookPage, standTable, otherTable, wxTable, recordDialog, djspTable, fenbuPic },
     methods: {
         //打开弹窗
         showModal(item) {
@@ -111,16 +120,18 @@ export default {
             this.dialogInfo = item
             if (Object.keys(this.dialogInfo).length > 0 && this.dialogInfo.children.length > 0) {
                 this.activeName = this.dialogInfo.children[0].param.tab_code
-                this.typecode = this.dialogInfo.children[0].param.type_code
                 this.diff = this.dialogInfo.children[0].param.diff
                 if (this.dialogInfo.children[0].id.slice(2, 4) == 'YL') {
+                    this.typecode = this.dialogInfo.children[0].param.type_code
+                    this.activeName = this.typecode
                     this.isShowTab()
                     this.initImage(this.typecode)
                 }
             } else {
                 this.activeName = this.dialogInfo.param.tab_code
-                this.typecode = this.dialogInfo.param.type_code
                 if (this.dialogInfo.id.slice(2, 4) == 'YL') {
+                    this.typecode = this.dialogInfo.param.type_code
+                    this.activeName = this.typecode
                     this.isShowTab()
                     this.initImage(this.typecode)
                 }
@@ -191,7 +202,8 @@ export default {
                 this.rotationImg = res.data || []
             })
         },
-        //原理图没图片不显示tab
+        //原理图没图片不显示tab 因为供电和燃气系统没有tab所以分开判断
+        //这个方法是判断有tab的count>0的时候显示tab
         isShowTab() {
             let data = {
                 plazaId: this.$store.state.plazaId,
@@ -202,6 +214,7 @@ export default {
                 postParams.push({
                     params: {
                         typecode: this.dialogInfo.param.type_code,
+                        system: this.smsxt,
                         module: '1002'
                     },
                     tableName: 'glsms_proimgup'
@@ -211,6 +224,7 @@ export default {
                     postParams.push({
                         params: {
                             typecode: el.param.type_code,
+                            system: this.smsxt,
                             module: '1002'
                         },
                         tableName: 'glsms_proimgup'
@@ -224,9 +238,11 @@ export default {
                 data.forEach(el => {
                     this.tabCount.push({
                         count: el.count,
+                        system: el.params.system,
                         typecode: el.params.typecode
                     })
                 })
+                this.$emit('emitCount', this.tabCount)
             })
         }
     }

+ 127 - 0
src/views/equipment/fenbuPic.vue

@@ -0,0 +1,127 @@
+<template>
+    <div class='fenbu-box'>
+        <!-- 图例 -->
+        <div class='legend-boxs'>
+            <Legend></Legend>
+        </div>
+        <floor-list v-if='floorsArr.length>0' :floorsArr='floorsArr' :type='1' @emitFloor='emitFloor' :id='"floor"'></floor-list>
+        <!-- <div class='additional-box'>
+            <div class='additional' @click='additionalColl'>
+                <img src='../../assets/imgs/bg.png' alt />
+            </div>
+            <el-collapse-transition>
+                <div v-if='show' class='add-img'>我是放附加数据图片哒。。。</div>
+            </el-collapse-transition>
+        </div>-->
+        <floorMap ref='floorMap' :loadName='loadName' :type='"floor"'></floorMap>
+    </div>
+</template>
+<script>
+import floorMap from '@/components/floorMap/index.vue'
+import floorList from '@/components/floorList.vue'
+import { mapGetters } from 'vuex'
+
+export default {
+    components: { floorMap, floorList },
+    data() {
+        return {
+            show: false,
+            floorInfo: {
+                gname: 'f1',
+                code: 'F1'
+            },
+            loadName: '',
+            type: ''
+        }
+    },
+    computed: {
+        ...mapGetters(['floorsArr'])
+    },
+    methods: {
+        emitFloor(item) {
+            this.floorInfo = item
+            this.$refs.floorMap.init(this.floorInfo.gname)
+            this.init()
+        },
+        additionalColl() {
+            this.show = !this.show
+        },
+        init() {
+            this.loadName = `楼层功能-${this.floorInfo.code}`
+        }
+    },
+    mounted() {
+        this.init()
+        this.$refs.floorMap.init(this.floorInfo.gname)
+    }
+}
+</script>
+<style lang="less">
+.fenbu-box {
+    background: rgba(242, 245, 247, 1);
+    height: calc(100vh - 48px);
+    flex: 1;
+    .eq-title {
+        position: fixed;
+        z-index: 2;
+        top: 92px;
+        left: 242px;
+        width: 140px;
+        height: 32px;
+        background: linear-gradient(270deg, rgba(199, 217, 234, 0) 0%, rgba(199, 217, 234, 1) 100%);
+        box-shadow: -6px 2px 8px 0px rgba(31, 36, 41, 0.1);
+        color: #025baa;
+        font-size: 16px;
+        &::before {
+            width: 2px;
+            height: 16px;
+            background: rgba(2, 91, 170, 1);
+            display: inline-block;
+            content: '';
+            margin-right: 10px;
+            margin-top: 8px;
+        }
+    }
+    .legend-boxs {
+        position: fixed;
+        z-index: 9;
+        right: 32px;
+        top: 155px;
+    }
+    .additional-box {
+        position: relative;
+        .additional {
+            width: 44px;
+            height: 44px;
+            background: rgba(255, 255, 255, 1);
+            box-shadow: 0px 2px 15px 0px rgba(31, 36, 41, 0.08);
+            border-radius: 2px;
+            position: fixed;
+            right: 32px;
+            top: 420px;
+            z-index: 2;
+            display: flex;
+            justify-content: center;
+            align-items: center;
+            cursor: pointer;
+            img {
+                width: 20px;
+                height: 20px;
+            }
+        }
+        .add-img {
+            width: 560px;
+            height: 325px;
+            background: #ffffff;
+            -webkit-box-shadow: 0px 2px 8px 0px rgba(31, 36, 41, 0.06);
+            box-shadow: 0px 2px 8px 0px rgba(31, 36, 41, 0.06);
+            border-radius: 2px;
+            border: 1px solid #e4e5e7;
+            position: absolute;
+            right: 77px;
+            top: 93px;
+            z-index: 2;
+        }
+    }
+}
+</style>

+ 9 - 6
src/views/equipment/index.vue

@@ -9,12 +9,10 @@
         </div>
         <div class='eq-bottom'>
             <div class='eq-left'>
-                <ul>
+                <ul v-for='(eve,index) in everySystem' :key='"o"+index'>
                     <li
                         class='li-style'
-                        :class='{"is-active": eve.id}'
-                        v-for='(eve,index) in everySystem'
-                        :key='"o"+index'
+                        :class='{"is-active": eve.id}' 
                         @click='dialogVisible(eve)'
                     >
                         <span class='circle'></span>
@@ -47,7 +45,7 @@
                 </div>
             </div>
         </div>
-        <eq-dialog ref='dialog' :systemName='systemName' :smsxt='smsxt'></eq-dialog>
+        <eq-dialog ref='dialog' :systemName='systemName' :smsxt='smsxt' @emitCount='emitCount'></eq-dialog>
     </div>
 </template>
 
@@ -79,7 +77,8 @@ export default {
             show: false,
             fqPic: [],
             loadName: '',
-            type: ''
+            type: '',
+            objCount:[]
         }
     },
     components: { floorList, eqDialog, floorMap, editList },
@@ -97,6 +96,10 @@ export default {
             }
             this.init()
         },
+        //判断有没有原理图,如果没有则不出现系统原理图列表li
+        emitCount(objCount){
+            this.objCount = objCount
+        },
         emitFloor(item) {
             this.floorInfo = item
             this.$refs.floorMap.init(this.floorInfo.gname)

+ 9 - 11
src/views/equipment/table/eqDetaileDialog.vue

@@ -56,7 +56,7 @@
                 <template slot-scope='{row}'>{{row.assetnum || '--'}}</template>
             </el-table-column>
             <el-table-column prop='sl' label='数量' width='100'>
-                <template slot-scope='{row}'>{{row.sl || '--'}}</template>
+                <template slot-scope='{row}'>{{row.sl>=0?row.sl:'--'}}</template>
             </el-table-column>
             <el-table-column prop='sbglgs' label='管理归属' show-overflow-tooltip resizable>
                 <template slot-scope='{row}'>{{row.sbglgs || '--'}}</template>
@@ -242,11 +242,11 @@ export default {
                 delete data.keyword
             }
             let postParams = {
-                type_code: this.row.type_code
-                // manufacturer: this.row.manufacturer,
-                // sbxh: this.row.sbxh,
-                // // floor: '--',
-                // brand: '--'
+                classstructureid: this.row.classstructureid,
+                type_code: this.row.type_code,
+                manufacturer: this.row.manufacturer || '--',
+                sbxh: this.row.sbxh || '--',
+                brand: this.row.brand || '--'
             }
             //下拉筛选
             if (this.floor) {
@@ -266,12 +266,10 @@ export default {
         }
     },
     watch: {
-        'row.type_code': {
+        row: {
             handler(newV, oldV) {
-                if (newV != oldV) {
-                    this.queryTableList()
-                    this.tabFind()
-                }
+                this.queryTableList()
+                this.tabFind()
             },
             deep: true
         }

+ 1 - 1
src/views/equipment/table/eqListTable.vue

@@ -37,7 +37,7 @@
                 <template slot-scope='{row}'>{{row.type_name || '--'}}</template>
             </el-table-column>
             <el-table-column prop='sl' label='数量' width='100'>
-                <template slot-scope='{row}'>{{row.sl || '--'}}</template>
+                <template slot-scope='{row}'>{{row.sl>=0?row.sl:'--'}}</template>
             </el-table-column>
             <el-table-column prop='brand' label='品牌'>
                 <template slot-scope='{row}'>{{row.brand || '--'}}</template>

+ 1 - 1
src/views/equipment/table/otherTable.vue

@@ -50,7 +50,7 @@
                     <template slot-scope='{row}'>{{row.content || '--'}}</template>
                 </el-table-column>
                 <el-table-column prop='sl' label='数量'>
-                    <template slot-scope='{row}'>{{row.sl || '--'}}</template>
+                    <template slot-scope='{row}'>{{row.sl>=0?row.sl:'--'}}</template>
                 </el-table-column>
             </el-table-column>
             <el-table-column prop='zfje' label='金额(万元)'>

+ 2 - 2
src/views/equipment/table/standTable.vue

@@ -38,7 +38,7 @@
             </el-table-column>
             <!-- sbjc -->
             <el-table-column prop='sl' label='数量' width='100'>
-                <template slot-scope='{row}'>{{row.sl || '--'}}</template>
+                <template slot-scope='{row}'>{{row.sl>=0?row.sl:'--'}}</template>
             </el-table-column>
             <el-table-column prop='brand' label='品牌'>
                 <template slot-scope='{row}'>{{row.brand || '--'}}</template>
@@ -99,7 +99,7 @@ export default {
     },
     methods: {
         rowHandle(row) {
-            //console.log(row)
+            console.log(row)
             this.innerVisible = true
             this.row = row
         },

+ 1 - 1
src/views/equipment/table/tjTable.vue

@@ -19,7 +19,7 @@
                 <template slot-scope='{row}'>{{row.category || '--'}}</template>
             </el-table-column>
             <el-table-column prop='sl' label='数量' width='100'>
-                <template slot-scope='{row}'>{{row.sl || '--'}}</template>
+                <template slot-scope='{row}'>{{row.sl>=0?row.sl:'--'}}</template>
             </el-table-column>
             <el-table-column prop='brand' label='品牌'>
                 <template slot-scope='{row}'>{{row.brand || '--'}}</template>

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

@@ -78,13 +78,13 @@
             </el-table-column>
             <el-table-column label='更换配件信息' align='center'>
                 <el-table-column prop='ischangepj' label='是/否更换'>
-                    <template slot-scope='{row}'>{{row.ischangepj || '--'}}</template>
+                    <template slot-scope='{row}'>{{row.ismodel==1?'是':(row.ismodel==0?"否" :'--')}}</template>
                 </el-table-column>
                 <el-table-column prop='model' label='配件名称型号' width='130' show-overflow-tooltip resizable>
                     <template slot-scope='{row}'>{{row.model || '--'}}</template>
                 </el-table-column>
                 <el-table-column prop='sl' label='数量'>
-                    <template slot-scope='{row}'>{{row.sl || '--'}}</template>
+                    <template slot-scope='{row}'>{{row.sl>=0?row.sl:'--'}}</template>
                 </el-table-column>
                 <el-table-column prop='cost' label='费用(万元)'>
                     <template slot-scope='{row}'>{{row.cost || '--'}}</template>

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

@@ -86,13 +86,13 @@
             </el-table-column>
             <el-table-column label='更换配件信息' align='center'>
                 <el-table-column prop='ischangepj' label='是/否更换'>
-                    <template slot-scope='{row}'>{{row.ischangepj || '--'}}</template>
+                    <template slot-scope='{row}'>{{row.ismodel==1?'是':(row.ismodel==0?"否" :'--')}}</template>
                 </el-table-column>
                 <el-table-column prop='model' label='配件名称型号' width='130' show-overflow-tooltip resizable>
                     <template slot-scope='{row}'>{{row.model || '--'}}</template>
                 </el-table-column>
                 <el-table-column prop='sl' label='数量'>
-                    <template slot-scope='{row}'>{{row.sl || '--'}}</template>
+                    <template slot-scope='{row}'>{{row.sl>=0?row.sl:'--'}}</template>
                 </el-table-column>
                 <el-table-column prop='cost' label='费用(万元)'>
                     <template slot-scope='{row}'>{{number_format(row.cost,2) || '--'}}</template>

+ 1 - 1
src/views/equipment/table/zwTable.vue

@@ -75,7 +75,7 @@
                 <template slot-scope='{row}'>{{row.xm || '--'}}</template>
             </el-table-column>
             <el-table-column prop='sl' label='数量' show-overflow-tooltip resizable>
-                <template slot-scope='{row}'>{{row.sl || '--'}}</template>
+                <template slot-scope='{row}'>{{row.sl>=0?row.sl:'--'}}</template>
             </el-table-column>
             <el-table-column prop='ssfasm' label='实施方案说明' show-overflow-tooltip resizable>
                 <template slot-scope='{row}'>{{row.ssfasm || '--'}}</template>

+ 3 - 2
src/views/index.vue

@@ -44,16 +44,17 @@ export default {
         /**
          * @name handleRoute
          * @param newRoute 当前路由
-         * @description 路由处理函数, 当前路由为home下的legendLibrary(图例)时,隐藏 menuList组件
+         * @description 路由处理函数, 当前路由为home下的legendLibrary和legendRules(图例)时,隐藏 menuList组件
          */
         handleRoute(newRoute) {
             let path = ''
+            let ignoreRoute = ['legendRules', 'legendLibrary']
             newRoute.path && (path = newRoute.path)
             if (!path) {
                 return true
             }
             let lastPath = path.split('home/')[1]
-            if (lastPath === 'legendLibrary') {
+            if (ignoreRoute.includes(lastPath)) {
                 this.showMenu = false
             } else {
                 this.showMenu = true

+ 14 - 29
src/views/legendLibrary/addForm.vue

@@ -26,7 +26,7 @@
             </div>
             <div class='input-right' ref='graph' v-show='ruleForm.Type=="Zone" || ruleForm.Type=="Image" || ruleForm.Type =="Line"'>
                 <div v-show=' ruleForm.Type=="Image" && ruleForm.Url' class='input-right'>
-                    <img :src='`/serve/topology-wanda/Picture/query/${ruleForm.Url}`' alt />
+                    <img :key='key' :src='`/serve/topology-wanda/Picture/query/${ruleForm.Url}`' alt />
                     <!-- {{ruleForm.Url}} -->
                 </div>
                 <canvas id='canvas' :width='canvasWidth' :height='canvasHeight' v-show='!(ruleForm.Type=="Image" && ruleForm.Url)'></canvas>
@@ -87,17 +87,9 @@
         <div v-if='ruleForm.Type!="None"' class='form4'>
             <div class='form4-top'>
                 <span class='form4-span1'>专业/设备、位置类型:</span>
-                <!-- <span class='form4-span1'>对应工程信息化中的位置/设备分类</span>
-                <span class='form4-span2'>工程信息化的专业</span>-->
                 <span class='form4-span3'>铺位可视化typeid</span>
             </div>
             <div class='form3-bottom'>
-                <!-- <el-select v-model='value' placeholder='请选择' size='small' style='width:200px;margin-right:48px;'>
-                    <el-option v-for='item in options1' :key='item.value' :label='item.label' :value='item.value'></el-option>
-                </el-select>
-                <el-select v-model='value' placeholder='请选择' size='small' style='width:200px;margin-right:48px'>
-                    <el-option v-for='item in options2' :key='item.value' :label='item.label' :value='item.value'></el-option>
-                </el-select>-->
                 <span class='device-list'>
                     <TreeSelect
                         tipPlace='top'
@@ -111,19 +103,6 @@
                         :hideClear='true'
                     />
                 </span>
-
-                <!-- <TreeSelect
-                    tipPlace='top'
-                    width='200'
-                    style=' margin-right:48px;'
-                    :notNull='true'
-                    :returnParentNode='false'
-                    :isShowAllChoice='true'
-                    :choseArea='true'
-                    :data='majorList'
-                    @change='treeConfirmMajor'
-                />-->
-
                 <TreeSelect
                     tipPlace='top'
                     width='200'
@@ -169,7 +148,7 @@ export default {
             ],
             options1: [],
             options2: [],
-            options3: [],
+
             borderLineOption: [
                 {
                     id: 'solid',
@@ -215,7 +194,8 @@ export default {
             typeVisualization: [],
 
             // majorList: [], //专业
-            deviceList: []
+            deviceList: [],
+            key: 1
         }
     },
     props: ['ruleForm', 'title'],
@@ -231,6 +211,8 @@ export default {
             // //console.log(file, fileList, 'file')
         },
         getFile(file) {
+            // let imgSrc = document.querySelector('.input-right>img')
+            // console.log(imgSrc)
             this.file = file.file
             var formData = new FormData()
             formData.append('file', file.file)
@@ -240,6 +222,7 @@ export default {
             let postParams = formData
             uploadImg({ postParams }).then(res => {
                 if (res.Result == 'success') {
+                    this.key++
                     this.$set(this.ruleForm, 'Url', res.EntityList[0])
                     this.$message.success('图标上传成功!')
                 }
@@ -250,7 +233,6 @@ export default {
             let postParams = {
                 Content: [this.ruleForm]
             }
-
             createLegend({ postParams }).then(res => {
                 if (res.Result == 'success') {
                     this.$message.success('添加图例成功!')
@@ -390,10 +372,7 @@ export default {
             //console.log(data, 'data')
             this.$set(this.ruleForm, 'InfoTypeId', data)
         },
-        //专业
-        // treeConfirmMajor(id, info) {
-        //     // this.$set(this.ruleForm, 'InfoSystem', data)
-        // },
+
         //位置/设备
         treeConfirmDevice(id, info) {
             // this.$set(this.ruleForm, 'InfoLocal', data)
@@ -403,9 +382,11 @@ export default {
                 let type = info[i]
                 if (type.name.includes('/')) {
                     InfoLocal.push(type)
+                    //位置/设备
                     this.$set(this.ruleForm, 'InfoLocal', InfoLocal)
                 } else {
                     InfoSystem.push(type)
+                    //专业
                     this.$set(this.ruleForm, 'InfoSystem', InfoSystem)
                 }
             }
@@ -502,6 +483,10 @@ export default {
             display: flex;
             align-items: center;
             justify-content: center;
+            img {
+                width: 28px;
+                height: 28px;
+            }
             .model1 {
                 width: 56px;
                 height: 6px;

+ 1 - 1
src/views/legendLibrary/addLegend.vue

@@ -64,7 +64,6 @@ export default {
                 })
                 //treeSelect
                 this.modalShow4 = true
-
                 this.info = {
                     Name: '',
                     Type: 'None',
@@ -92,6 +91,7 @@ export default {
             } else if (title == '修改图例库') {
                 this.dialogVisible = true
                 this.info = row
+                console.log(this.info)
                 // 图例库规则中的transform
             } else if (title == '' && this.$refs.searchList) {
                 this.$refs.searchList.queryAll()

+ 57 - 25
src/views/legendLibrary/index.vue

@@ -6,8 +6,11 @@
             <img class='img-logo' src='@/assets/imgs/logo_tu.png' alt />
             <span style='color:#1F2329'>万达管理说明书</span>
             <span class='circular'></span>
-            <span style='color:#1F2329'>图例库管理</span>
-            <i class='el-icon-caret-bottom'></i>
+            <!-- <span style='color:#1F2329'>图例库管理</span>
+            <i class='el-icon-caret-bottom'></i>-->
+            <Dropdown v-model='selVal' :data='dataSelect'>
+                <span style=' font-size: 14px;color: #1f2329 ;'>{{selText}}</span>
+            </Dropdown>
         </div>
         <div class='legend-library-top'>
             图例库管理
@@ -48,7 +51,7 @@
                         width='280'
                         style='margin:0 12px'
                         :isShowAllChoice='true'
-                        :returnParentNode='false'
+                        :returnParentNode='true'
                         :choseArea='true'
                         :data='deviceList'
                         :hideClear='true'
@@ -94,7 +97,7 @@
                 ></Select>
                 <el-input size='small' @change='getTableList' prefix-icon='el-icon-search' v-model='keyword' style='width:192px;margin-right:12px;'></el-input>
             </div>
-            <el-table :data='tableData' :border='true' style='width: 100%'>
+            <el-table :data='tableData' :key='key' :border='true' style='width: 100%'>
                 <el-table-column prop='Name' label='图例名称'>
                     <template slot-scope='{row}'>{{row.Name || '--'}}</template>
                 </el-table-column>
@@ -108,18 +111,26 @@
                     <template slot-scope='{row}'>{{row.Unit || '--'}}</template>
                 </el-table-column>
                 <el-table-column prop='position' label='对应广场说明书的位置'>
-                    <template slot-scope='{row}'>{{row.position || '--'}}</template>
+                    <template slot-scope='{row}'>
+                        <span v-for='item in row.GraphCategorys ' :key='item.Name'>{{item.Name}}</span>
+                    </template>
                 </el-table-column>
                 <el-table-column label='对应工程信息化' align='center'>
-                    <el-table-column prop='type' label='位置/设备分类' width='240'>
-                        <template slot-scope='{row}'>{{row.InfoLocal || '--'}}</template>
+                    <el-table-column prop='type' label='位置/设备分类' width='240' :show-overflow-tooltip='true'>
+                        <template slot-scope='{row}'>
+                            <span v-for='item in row.InfoLocal ' :key='item.name'>{{item.name}}</span>
+                        </template>
                     </el-table-column>
-                    <el-table-column prop='system' label='专业'>
-                        <template slot-scope='{row}'>{{row.InfoSystem || '--'}}</template>
+                    <el-table-column prop='system' label='专业' :show-overflow-tooltip='true'>
+                        <template slot-scope='{row}'>
+                            <span v-for='(item,index) in row.InfoSystems ' :key='index'>{{item.Name}}</span>
+                        </template>
                     </el-table-column>
                 </el-table-column>
-                <el-table-column prop='typeId' resizable label='铺位可视化typeid' width='140'>
-                    <template slot-scope='{row}'>{{row.InfoSystem || '--'}}</template>
+                <el-table-column prop='typeId' resizable label='铺位可视化typeid' width='140' :show-overflow-tooltip='true'>
+                    <template slot-scope='{row}'>
+                        <span v-for='(item,index) in row.InfoTypes ' :key='index'>{{item.Name}}</span>
+                    </template>
                 </el-table-column>
                 <el-table-column label='操作' width='100' v-if='state==1'>
                     <template slot-scope='scope' v-if='state==1'>
@@ -164,6 +175,7 @@ export default {
     data() {
         return {
             tableData: [],
+            key: 1,
             dataSelect2: [
                 { id: 'test1', name: '选择项' },
                 { id: 'test2', name: '单平米' },
@@ -175,6 +187,13 @@ export default {
                 { id: '0', name: '已作废' }
             ],
             Type: 'all', //所属分类
+            selText: '图例库管理',
+            selVal: '0',
+            dataSelect: [
+                { id: '0', name: '图例库管理' },
+                { id: '1', name: '图例绘制规则' }
+            ],
+
             typeOptions: [
                 {
                     id: 'all',
@@ -217,6 +236,19 @@ export default {
             InfoTypeIds: undefined //铺位可视化typeid
         }
     },
+    watch: {
+        selVal(n, o) {
+            if (n === o) return
+            this.selText = this.dataSelect.find(d => d.id === n).name
+            console.log(n, o)
+            if (n == 0) {
+                this.$router.push({ path: 'legendLibrary' })
+            }
+            if (n == 1) {
+                this.$router.push({ path: 'legendRules' })
+            }
+        }
+    },
     methods: {
         //业下设备分类和位置分类树形结构
         initQueryDeviceAndPOsition() {
@@ -330,6 +362,7 @@ export default {
                 Type: this.Type == 'all' ? undefined : this.Type
             }
             graphElementSearch({ postParams }).then(res => {
+                this.key++
                 this.tableData = res.Content
                 this.total = res.Total
             })
@@ -353,20 +386,16 @@ export default {
         // },
         //位置/设备
         treeConfirmDevice(id, info) {
-            // console.log(id, info)
-            // var a = []
-            // var d = []
-            // for (let i = 0; i < info.length; i++) {
-            //     let type = info[i]
-            //     if (type.name.includes('/')) {
-            //         a.push(type)
-            //     } else {
-            //         d.push(type)
-            //     }
-            // }
-            // console.log('a:', a, 'd:', d)
-
-            this.InfoLocals = id
+            this.InfoSystems = []
+            this.InfoLocals = []
+            for (let i = 0; i < info.length; i++) {
+                let type = info[i]
+                if (type.name.includes('/')) {
+                    this.InfoLocals.push(type.id)
+                } else {
+                    this.InfoSystems.push(type.id)
+                }
+            }
             this.getTableList()
         },
         //说明书位置
@@ -413,6 +442,9 @@ export default {
             margin: 0 8px 3px 8px;
         }
     }
+    /deep/ .p-drop .p-drop-title .p-drop-triangle {
+        margin-top: -5px;
+    }
     .legend-library-top {
         height: 48px;
         background: rgba(247, 249, 250, 1);

+ 139 - 2
src/views/legendRules/index.vue

@@ -1,6 +1,18 @@
 <template>
     <!-- 图例库首页 -->
     <div class='legend-rules'>
+        <div class='nav'>
+            <img class='img-menu' src='@/assets/imgs/menu.png' alt />
+            <el-divider direction='vertical'></el-divider>
+            <img class='img-logo' src='@/assets/imgs/logo_tu.png' alt />
+            <span style='color:#1F2329'>万达管理说明书</span>
+            <span class='circular'></span>
+            <!-- <span style='color:#1F2329'>图例绘制规则</span>
+            <i class='el-icon-caret-bottom'></i>-->
+            <Dropdown v-model='selVal' :data='dataSelect'>
+                <span style=' font-size: 14px;color: #1f2329 ;'>{{selText}}</span>
+            </Dropdown>
+        </div>
         <div class='legend-rules-top'>
             图例绘制规则
             <el-button type='primary' class='rules-button' size='small' @click='add'>添加图例</el-button>
@@ -19,7 +31,7 @@
                 ></a-tree>
             </div>
             <div class='legend-rules-right'>
-                <el-table :data='tableData' style='width: 100%'>
+                <!-- <el-table :data='tableData' style='width: 100%'>
                     <el-table-column prop='Name' label='图例名称'>
                         <template slot-scope='{row}'>{{row.Name || '--'}}</template>
                     </el-table-column>
@@ -37,7 +49,17 @@
                             <el-button @click='deleteClick(scope.row)' type='text' size='small'>删除</el-button>
                         </template>
                     </el-table-column>
-                </el-table>
+                </el-table>-->
+                <Table
+                    :head='headList2'
+                    :source='tableData'
+                    :toolButtons='toolBtns'
+                    :selectWidth='180'
+                    height='100%'
+                    @tool-button-click='buttonClickHandle'
+                >
+                    <img slot-scope='{col, row}' v-if='col.key==="Url"' class='img' :src='`/serve/topology-wanda/Picture/query/${row.Url}`' alt />
+                </Table>
             </div>
         </div>
         <add-legend ref='addLegend' @mesg='mesg'></add-legend>
@@ -57,10 +79,101 @@ export default {
                 children: 'Category',
                 title: 'Name',
                 key: 'Id'
+            }, //test
+            // 可筛选表格表头列表
+            headList2: [
+                {
+                    title: '图例名称', // 列的名称
+                    key: 'Name', // 列的标识
+                    show: true // 是否显示该列
+                },
+                {
+                    title: '图例样式',
+                    key: 'Url',
+                    show: true
+                },
+                {
+                    title: '单位',
+                    key: 'Unit',
+                    show: true
+                }
+            ],
+            // 操作按钮组 (非必填)
+            toolBtns: [
+                {
+                    icon: 'copy',
+                    name: '上移'
+                },
+                {
+                    icon: 'print',
+                    name: '下移'
+                },
+                {
+                    icon: 'pending',
+                    name: '删除'
+                }
+            ],
+            selText: '图例绘制规则',
+            selVal: '1',
+            dataSelect: [
+                { id: '0', name: '图例库管理' },
+                { id: '1', name: '图例绘制规则' }
+            ]
+        }
+    },
+    watch: {
+        selVal(n, o) {
+            if (n === o) return
+            this.selText = this.dataSelect.find(d => d.id === n).name
+            console.log(n, o)
+            if (n == 0) {
+                this.$router.push({ path: 'legendLibrary' })
+            }
+            if (n == 1) {
+                this.$router.push({ path: 'legendRules' })
             }
         }
     },
     methods: {
+        /**
+         * 点击工具栏按钮回调方法
+         * @param {Object} Obj {tool:{icon:'icon组件名称',name:'按钮名称',type:'icon组件type'},item:当前行数据}
+         */
+        buttonClickHandle(obj) {
+            let index = Number(obj.item.index.split('-')[1])
+            let _this = this
+            switch (obj.tool.name) {
+                case '删除':
+                    this.deleteClick(obj.item)
+                    break
+                case '上移':
+                    up()
+                    break
+                case '下移':
+                    down()
+                    break
+            }
+            function up() {
+                if (index == 0) {
+                    _this.$message.error('处于顶端,不可再上移')
+                } else {
+                    let upDate = _this.tableData[index - 1]
+                    _this.tableData.splice(index - 1, 1)
+                    _this.tableData.splice(index, 0, upDate)
+                }
+            }
+
+            function down() {
+                if (index == _this.tableData.length - 1) {
+                    _this.$message.error('处于底端,不可再下移')
+                } else {
+                    let downDate = _this.tableData[index + 1]
+                    _this.tableData.splice(index + 1, 1)
+                    _this.tableData.splice(index, 0, downDate)
+                }
+            }
+        },
+
         handleNodeClick(data, e) {
             this.GraphCategoryId = [e.node.eventKey]
             this.getData()
@@ -116,6 +229,30 @@ export default {
     display: flex;
     flex-direction: column;
     color: #1f2329;
+    .nav {
+        height: 48px;
+        line-height: 48px;
+        width: 100%;
+        background: #fff;
+        margin-left: 17px;
+        .img-menu {
+            margin-right: 9px;
+        }
+        .img-logo {
+            margin: 0 9px;
+        }
+        .circular {
+            display: inline-block;
+            width: 4px;
+            height: 4px;
+            background: rgba(195, 198, 203, 1);
+            border-radius: 50%;
+            margin: 0 8px 3px 8px;
+        }
+    }
+    /deep/ .p-drop .p-drop-title .p-drop-triangle {
+        margin-top: -5px;
+    }
     .legend-rules-top {
         text-align: center;
         height: 48px;

+ 7 - 1
src/views/other/zhsxDialog.vue

@@ -8,7 +8,7 @@
                 <p>3.相关政府强制性检测的按时完成情况及检测中提出的问题</p>
                 <p>4.广场安全质量第三方检测过程中列出的整改事项</p>
                 <div class='bottom-table'>
-                    <el-table :data='tableData' height='500' style='width:100%;' :span-method='objectSpanMethod' border v-if='tableData.length>0'>
+                    <el-table :data='tableData' height='480' style='width:100%;' :span-method='objectSpanMethod' border v-if='tableData.length>0'>
                         <el-table-column label='序号' type='index' width='50'></el-table-column>
                         <el-table-column prop='jcsx' label='检测事项' :show-overflow-tooltip='true'></el-table-column>
                         <el-table-column prop='zgbm' label='主管部门' :show-overflow-tooltip='true'></el-table-column>
@@ -108,5 +108,11 @@ export default {
 </style>
 <style lang="less">
 .zhsx-log {
+    .el-dialog {
+        margin-top: 10vh !important;
+    }
+    .el-dialog__wrapper {
+        overflow: hidden;
+    }
 }
 </style>

+ 15 - 4
src/views/room/detail.vue

@@ -165,7 +165,7 @@ import { mapGetters } from 'vuex'
 import { queryHxsbDetail } from '@/api/room.js'
 
 export default {
-    props: ['type_code'],
+    props: ['row', 'floorChange'],
     data() {
         return {
             dialogFormVisible: false,
@@ -198,13 +198,13 @@ export default {
         ...mapGetters(['floorSelect', 'plazaId'])
     },
     mounted() {
-        if (this.type_code) {
+        if (this.row) {
             this.queryDetail()
             this.query()
         }
     },
     watch: {
-        type_code: {
+        row: {
             deep: true,
             handler: function(newV, oldV) {
                 if (newV != oldV) {
@@ -239,8 +239,19 @@ export default {
         queryDetail() {
             this.detailData = []
             let postParams = {
-                type_code: this.type_code //自定义分类内码 主要设备清单必传
+                manufacturer: this.row.manufacturer || '--',
+                sbxh: this.row.sbxh || '--',
+                brand: this.row.brand || '--',
+                location: '1572',
+                classstructureid: this.row.classstructureid,
+                type_code: this.row.type_code
             }
+            if (this.floorChange) {
+                postParams.gname = this.floorChange
+            }
+            // if (this.row.floorcode) {
+            //     postParams.floorcode = this.row.floorcode
+            // }
             let data = {
                 plazaId: this.plazaId,
                 page: this.pageDetail,

+ 2 - 2
src/views/room/index.vue

@@ -122,6 +122,7 @@
                             :page='page2'
                             :total='total2'
                             :size='size2'
+                            :floorChange='floorChange'
                             @Index2Emit='Index2Emit'
                         ></room-table3>
                     </el-tab-pane>
@@ -614,10 +615,9 @@ export default {
                 }
             }
             if (this.floorChange) {
-                data.gname = this.floorChange
+                postParams.gname = this.floorChange
             }
             queryHxsb({ data, postParams }).then(res => {
-                // console.log('核心设备', res)
                 this.loading2 = false
                 this.total2 = res.data.count
                 this.table3 = res.data.data ? res.data.data : []

+ 4 - 4
src/views/room/room3.vue

@@ -42,7 +42,7 @@
             ></el-pagination>
         </div>
         <el-dialog width='90%' title='设备清单' :visible.sync='innerVisible' append-to-body>
-            <detail v-if='type_code' :type_code='type_code'></detail>
+            <detail v-if='row' :row='row' :floorChange='floorChange'></detail>
         </el-dialog>
     </div>
 </template>
@@ -52,11 +52,11 @@ import Select from '@/components/Select/Select.vue'
 import Detail from './detail'
 
 export default {
-    props: ['table3', 'total', 'page', 'size', 'loading'],
+    props: ['table3', 'total', 'page', 'size', 'loading', 'floorChange'],
     data() {
         return {
             innerVisible: false,
-            type_code: ''
+            row: {}
         }
     },
 
@@ -69,7 +69,7 @@ export default {
             this.$emit('Index2Emit', page)
         },
         innerTable(row) {
-            this.type_code = row.type_code
+            this.row = row
             this.innerVisible = true
         }
     },

+ 7 - 3
src/views/room/room4.vue

@@ -23,13 +23,17 @@
                 </el-table-column>
                 <el-table-column prop label='更换配件信息' align='center' show-overflow-tooltip resizable>
                     <el-table-column prop label='是/否更换' show-overflow-tooltip resizable>
-                        <template slot-scope='{row}'>{{row.ismodel||'--'}}</template>
+                        <template slot-scope='{row}'>
+                            <div v-if='row.ismodel==0'>否</div>
+                            <div v-else-if='row.ismodel==1'>是</div>
+                            <div v-else>'--'</div>
+                        </template>
                     </el-table-column>
                     <el-table-column prop label='配件名称型号' width='130' min-width='110' show-overflow-tooltip resizable>
                         <template slot-scope='{row}'>{{row.model||'--'}}</template>
                     </el-table-column>
                     <el-table-column prop label='数量' show-overflow-tooltip resizable>
-                        <template slot-scope='{row}'>{{row.cost||'--'}}</template>
+                        <template slot-scope='{row}'>{{row.sl>=0?row.sl:'--'}}</template>
                     </el-table-column>
                     <el-table-column prop label='费用(万元)' min-width='100' show-overflow-tooltip resizable>
                         <template slot-scope='{row}'>{{row.cost||'--'}}</template>
@@ -42,7 +46,7 @@
                     <template slot-scope='{row}'>{{row.pics || '--'}}</template>
                 </el-table-column>
                 <el-table-column prop label='填报时间' show-overflow-tooltip resizable width='130'>
-                    <template slot-scope='{row}'>{{row.reportedby?formatter(row.reportedby):'--'}}</template>
+                    <template slot-scope='{row}'>{{row.reportdate?formatter(row.reportdate):'--'}}</template>
                 </el-table-column>
                 <el-table-column prop label='验收时间' show-overflow-tooltip width='130' resizable>
                     <template slot-scope='{row}'>{{row.sjjssj?formatter(row.sjjssj):'--'}}</template>