ソースを参照

Merge branch 'develop' of http://39.106.8.246:3003/web/wanda-bm-guide into develop

haojianlong 4 年 前
コミット
298a9e7e63

+ 0 - 5
src/api/httputils.js

@@ -22,11 +22,6 @@ axiosservice.interceptors.request.use(
         config.withCredentials = true // 允许携带token ,这个是解决跨域产生的相关问题
         let token = store.getters['ssoToken']
         let isPreview = store.getters["isPreview"]
-        // if (token) {
-        //     config.headers = {
-        //         'sso-token': token,
-        //     }
-        // }
         if (config.url.indexOf('mapapp') < 0) {
             config.headers = {
                 "sso-token": token,

+ 1 - 1
src/components/404.vue

@@ -3,7 +3,7 @@
         <div class='not-img'>
             <img src='@/assets/imgs/dlsb.png' alt />
         </div>
-        <div class='not-text' v-if='!isPermissions'>
+        <div class='not-text' v-if='isPermissions'>
             <span>您的权限不足……</span>
             <span>建议您联系管理员开通管理说明书相关权限</span>
         </div>

+ 1 - 1
src/components/Legend/src/legend.vue

@@ -379,7 +379,7 @@ export default {
                 this.isShow2()
             } else {
                 this.isShow2()
-                this.queryEditNum(this.editSwitch)
+                this.queryEditNum(true)
             }
             this.show2 = true
         },

+ 78 - 8
src/components/floorMap/index.vue

@@ -12,12 +12,13 @@
 </template>
 <script>
 import { SFengParser } from '@saga-web/feng-map'
-import { SFloorParser } from '@saga-web/big'
+import { SFloorParser, ItemOrder } from '@saga-web/big'
 import { FloorView } from '@/lib/FloorView'
 import { FloorScene } from '@/lib/FloorScene'
 import RoomBox from '@/views/room/index'
 import canvasFun from '@/components/floorMap/canvasFun'
 import { readGroup, queryStatis } from '@/api/public'
+import { queryShops } from '@/api/equipmentList.js'
 import { STopologyParser } from '@/lib/parsers/STopologyParser'
 import { mapGetters, mapActions } from 'vuex'
 import { SImageItem } from '@saga-web/graph/lib'
@@ -39,7 +40,8 @@ export default {
             canvasID: 'canvas',
             floorid: '', //楼层id
             topologyParser: null, // 解析器数据
-            fParser: null // 底图解析器
+            fParser: null, // 底图解析器
+            wellMap: {} // 电井控制商铺映射
         }
     },
     props: {
@@ -198,13 +200,81 @@ export default {
             this.view = new FloorView(`canvas${this.id}`)
         },
         listChange(item, ev) {
-            let name = ev[0][0].data.Name,
-                location = ev[0][0].data.AttachObjectIds[0] ? ev[0][0].data.AttachObjectIds[0].id : ''
-            if (!location) {
-                this.$message('未添加位置类型')
+            if (ev[0].length) {
+                let selectItem1 = ev[0][0],
+                    name = selectItem1.data.Name,
+                    location = selectItem1.data.AttachObjectIds[0] ? selectItem1.data.AttachObjectIds[0].id : ''
+                if (name.slice(name.length - 2, name.length) == '机房') {
+                    if (location) {
+                        this.$refs.boxRoom.open({ name: name, type: this.type, location: location })
+                    } else {
+                        this.$message('未添加位置类型')
+                    }
+                }
+                // 选中电井设置电井关联的商铺高亮
+                this.setHightLight(ev[0])
+            } else {
+                this.clearHightLight()
             }
-            if (name.slice(name.length - 2, name.length) == '机房' && location) {
-                this.$refs.boxRoom.open({ name: name, type: this.type, location: location })
+        },
+        // 选中电井关联的商铺高亮
+        setHightLight(arr) {
+            this.clearHightLight()
+            arr.forEach(item => {
+                let location = item.data.AttachObjectIds[0] ? item.data.AttachObjectIds[0].id : ''
+                // 添加了位置类型并且选中的类型为电井类型
+                if (
+                    (item.data.GraphElementId == '100050' ||
+                        item.data.GraphElementId == '100055' ||
+                        item.data.GraphElementId == '100056' ||
+                        item.data.GraphElementId == '100057') &&
+                    location
+                ) {
+                    if (this.wellMap.hasOwnProperty(location)) {
+                        this.wellMap[location].forEach(item => {
+                            item.highLightFlag = true
+                            item.zOrder = 30
+                        })
+                    } else {
+                        let getParams = {
+                            plazaId: this.plazaId,
+                            floor: this.floorid,
+                            keyword: `${location}:wellnum;`
+                        }
+                        queryShops({ getParams }).then(res => {
+                            let shopsnumList = []
+                            let shopsnumItemList = []
+                            if (res.data && res.data.length) {
+                                for (let floor in res.data[0]) {
+                                    if (res.data[0][floor].length) {
+                                        res.data[0][floor].forEach(v => {
+                                            shopsnumList = shopsnumList.concat(v.shopsnumList.split(','))
+                                        })
+                                    }
+                                }
+                            }
+                            if (shopsnumList.length) {
+                                this.fParser.spaceList.forEach(item => {
+                                    if (shopsnumList.findIndex(name => name == item.data.Name) != -1) {
+                                        item.highLightFlag = true
+                                        item.zOrder = 30
+                                        shopsnumItemList.push(item)
+                                    }
+                                })
+                                this.wellMap[location] = shopsnumItemList
+                            }
+                        })
+                    }
+                }
+            })
+        },
+        // 清除电井关联商铺的高亮状态
+        clearHightLight() {
+            for (let key in this.wellMap) {
+                this.wellMap[key].forEach(item => {
+                    item.highLightFlag = false
+                    item.zOrder = ItemOrder.spaceOrder
+                })
             }
         },
         // 适配底图到窗口

+ 1 - 1
src/components/menuList.vue

@@ -5,7 +5,7 @@
             <div class='downright'></div>
             <div class='home-box'>
                 <img src='@/assets/imgs/logo.png' alt />
-                <span>{{plazas.length>0?formatter(plazaId,plazas):'--'}}</span>
+                <span v-if="plazas">{{plazas.length>0?formatter(plazaId,plazas):'--'}}</span>
             </div>
         </div>
         <div>

+ 1 - 0
src/lib/FloorScene.js

@@ -1,3 +1,4 @@
+import { SMouseEvent } from "@saga-web/base";
 import {
   SGraphScene
 } from "@saga-web/graph/lib"

+ 1 - 0
src/lib/items/STextMarkerItem.ts

@@ -20,6 +20,7 @@ export class STextMarkerItem extends STextItem {
      */
     constructor(parent: SGraphItem | null, data: Marker) {
         super(parent);
+        this.isTransform = false;
         this.zOrder = ItemOrder.textOrder;
         this.isTransform = false;
         this.data = data;

+ 1 - 0
src/lib/items/SZoneLegendItem.ts

@@ -5,6 +5,7 @@ import { SPainter, SColor, SFont, SPoint, SLineCapStyle } from "@saga-web/draw";
 import { STextItem } from '@saga-web/graph/lib';
 import { hexify } from "@/components/mapClass/until"
 import { SItemStatus, ItemOrder, SPolygonItem } from '@saga-web/big/lib';
+import { SMouseEvent } from "@saga-web/base/lib";
 /**
  * 图例节点Item(区域类型)
  *

+ 61 - 50
src/main.js

@@ -1,55 +1,66 @@
-var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
-    function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
-    return new (P || (P = Promise))(function (resolve, reject) {
-        function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
-        function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
-        function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
-        step((generator = generator.apply(thisArg, _arguments || [])).next());
-    });
-};
-import Vue from 'vue';
-import App from './App.vue';
-import router from './router';
-import store from './store';
-Vue.config.productionTip = false;
-import design from 'ant-design-vue';
-import 'ant-design-vue/dist/antd.css';
-Vue.use(design);
-import ElementUI from 'element-ui';
-import 'element-ui/lib/theme-chalk/index.css';
-Vue.use(ElementUI);
-import VueQuillEditor from 'vue-quill-editor';
-import 'quill/dist/quill.core.css';
-import 'quill/dist/quill.snow.css';
-import 'quill/dist/quill.bubble.css';
-Vue.use(VueQuillEditor);
-import WdEditor from '@/components/Editor';
-Vue.use(WdEditor);
-import Rotation from '@/components/Rotation';
-Vue.use(Rotation);
-import PicLarge from '@/components/PicLarge';
-Vue.use(PicLarge);
-import Legend from '@/components/Legend';
-Vue.use(Legend);
-import cookies from 'vue-cookie';
-Vue.use(cookies);
-import Pui from 'meri-design';
-import 'meri-design/dist/index.css';
-Vue.use(Pui);
-//////////模拟传入参数
-const username = 'lengqiang';
-/////////////////
-// 在跳入路由之前要请求获取权限信息
-router.beforeEach((to, from, next) => __awaiter(void 0, void 0, void 0, function* () {
-    if (!store.state.isrequestAuth) {
-        yield store.dispatch('getUserInfo', username);
-        yield store.dispatch('getFloors');
-        yield store.dispatch('getBrand');
+var __awaiter =
+    (this && this.__awaiter) ||
+    function(thisArg, _arguments, P, generator) {
+        function adopt(value) {
+            return value instanceof P
+                ? value
+                : new P(function(resolve) {
+                      resolve(value)
+                  })
+        }
+        return new (P || (P = Promise))(function(resolve, reject) {
+            function fulfilled(value) {
+                try {
+                    step(generator.next(value))
+                } catch (e) {
+                    reject(e)
+                }
+            }
+            function rejected(value) {
+                try {
+                    step(generator['throw'](value))
+                } catch (e) {
+                    reject(e)
+                }
+            }
+            function step(result) {
+                result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected)
+            }
+            step((generator = generator.apply(thisArg, _arguments || [])).next())
+        })
     }
-    next();
-}));
+import Vue from 'vue'
+import App from './App.vue'
+import router from './router'
+import store from './store'
+Vue.config.productionTip = false
+import design from 'ant-design-vue'
+import 'ant-design-vue/dist/antd.css'
+Vue.use(design)
+import ElementUI from 'element-ui'
+import 'element-ui/lib/theme-chalk/index.css'
+Vue.use(ElementUI)
+import VueQuillEditor from 'vue-quill-editor'
+import 'quill/dist/quill.core.css'
+import 'quill/dist/quill.snow.css'
+import 'quill/dist/quill.bubble.css'
+Vue.use(VueQuillEditor)
+import WdEditor from '@/components/Editor'
+Vue.use(WdEditor)
+import Rotation from '@/components/Rotation'
+Vue.use(Rotation)
+import PicLarge from '@/components/PicLarge'
+Vue.use(PicLarge)
+import Legend from '@/components/Legend'
+Vue.use(Legend)
+import cookies from 'vue-cookie'
+Vue.use(cookies)
+import Pui from 'meri-design'
+import 'meri-design/dist/index.css'
+Vue.use(Pui)
+
 new Vue({
     router,
     store,
     render: (h) => h(App),
-}).$mount('#app');
+}).$mount('#app')

+ 58 - 57
src/router/index.js

@@ -1,103 +1,104 @@
-import Vue from 'vue'
-import store from '@/store'
-import VueRouter from 'vue-router'
-import { query } from '@/utils/query'
+import Vue from "vue"
+import store from "@/store"
+import VueRouter from "vue-router"
+import { query } from "@/utils/query"
 Vue.use(VueRouter)
 
 const routes = [
     // 登陆页面
     {
-        path: '/',
-        redirect: '/home/overview',
+        path: "/",
+        redirect: "/home/overview",
     },
     {
-        path: '/404',
-        component: () => import('../components/404'),
+        path: "/404",
+        component: () => import("../components/404"),
     },
     // home
     {
-        path: '/home',
-        name: 'home',
-        component: () => import('../views/index'),
-        redirect: '/home/first',
+        path: "/home",
+        name: "home",
+        component: () => import("../views/index"),
+        redirect: "/home/first",
         children: [
             {
-                path: 'first',
-                component: () => import('../views/first'),
+                path: "first",
+                component: () => import("../views/first"),
             },
             //概览
             {
-                path: 'overview',
-                component: () => import('../views/overview'),
+                path: "overview",
+                component: () => import("../views/overview"),
             },
             // 楼层功能
             {
-                path: 'floorFunc',
-                component: () => import('../views/floorFunc'),
+                path: "floorFunc",
+                component: () => import("../views/floorFunc"),
             },
             // 设备设施
             {
-                path: 'equipment',
-                component: () => import('../views/equipment'),
+                path: "equipment",
+                component: () => import("../views/equipment"),
             },
             // 其他功能
             {
-                path: 'other',
-                component: () => import('../views/other'),
+                path: "other",
+                component: () => import("../views/other"),
             },
             // 分析
             {
-                path: 'analysis',
-                component: () => import('../views/analysis'),
+                path: "analysis",
+                component: () => import("../views/analysis"),
             },
             //图例库管理
             {
-                path: 'legendLibrary',
-                component: () => import('../views/legendLibrary'),
+                path: "legendLibrary",
+                component: () => import("../views/legendLibrary"),
             },
             //图例绘制规则
             {
-                path: 'legendRules',
-                component: () => import('../views/legendRules'),
+                path: "legendRules",
+                component: () => import("../views/legendRules"),
             },
         ],
     },
 ]
 const router = new VueRouter({
-    mode: 'history',
+    mode: "history",
     base: process.env.BASE_URL,
     routes,
 })
+const ignore = ["/404"]
 router.beforeEach(async (to, from, next) => {
-    const token = query().token
-    console.log(token)
-    const ssoToken = store.getters['ssoToken']
-    if (ssoToken) {
-        store.commit('SETSSOTOKEN', ssoToken)
-        await store.dispatch('getUserInfo')
-        await store.dispatch('getFloors')
-        await store.dispatch('getBrand')
-        next()
-    } else if (token) {
-        store.commit('SETSSOTOKEN', token)
-        console.log(store.state.ssoToken)
-        await store.dispatch('getUserInfo')
-        next()
-    } else {
-        let lastRoute = {
-            path: to.path,
-            params: to.params,
-            query: to.query,
+    if (!ignore.includes(to.path)) {
+        const token = query().token
+        const ssoToken = store.getters["ssoToken"]
+        if (ssoToken) {
+            store.commit("SETSSOTOKEN", ssoToken)
+            await store.dispatch("getUserInfo", router)
+            await store.dispatch("getFloors")
+            await store.dispatch("getBrand")
+            next()
+        } else if (token) {
+            store.commit("SETSSOTOKEN", token)
+            await store.dispatch("getUserInfo", router)
+            next()
+        } else {
+            let lastRoute = {
+                path: to.path,
+                params: to.params,
+                query: to.query,
+            }
+            store.commit("SETLASTROUTER", lastRoute)
+            let ssoServer = "http://oauth.wanda-dev.cn"
+            let systemcode = "CAD156",
+                signal = new Date().getTime(),
+                version = "1.0.0"
+            window.location.href = `${ssoServer}/login?systemcode=${systemcode}&signal=${signal}&version=${version}`
         }
-        store.commit('SETLASTROUTER', lastRoute)
-        let ssoServer = 'http://oauth.wanda-dev.cn'
-        let systemcode = 'CAD156',
-            signal = new Date().getTime(),
-            version = '1.0.0',
-            // returnurl = 'http://glsms.wanda-dev.cn/'
-            // returnurl = window.location.protocol + "//" + window.location.host + "/wandaBmGuide"
-            returnurl = 'http://localhost:8090/wandaBmGuide/home/equipment'
-        window.location.href = `${ssoServer}/login?token=${token}&systemcode=${systemcode}&signal=${signal}&version=${version}&returnurl=${returnurl}`
+    } else {
+        next()
+        return
     }
 })
 export default router

+ 40 - 25
src/store/index.js

@@ -1,34 +1,35 @@
-import Vue from 'vue'
-import Vuex from 'vuex'
-import { login, queryFloor, queryfmapID } from '@/api/login.js'
-import { queryBrand } from '@/api/public.js'
-import axios from 'axios'
+import Vue from "vue"
+import Vuex from "vuex"
+import { login, queryFloor, queryfmapID } from "@/api/login.js"
+import { queryBrand } from "@/api/public.js"
+import axios from "axios"
+import router from "../router"
 
 Vue.use(Vuex)
 export default new Vuex.Store({
     state: {
-        ssoToken: 'admin:lengqiang',
-        // ssoToken: null,
+        // ssoToken: 'admin:lengqiang',
+        ssoToken: null,
         isPreview: false,
-        lastRoute: '',
+        lastRoute: "",
         isrequestAuth: true, // 是否请求登录校验接口
         permissions: [], //权限信息 "GLSMS_VIEW":"说明书查看"、"GLSMS_SYMBOL_MANAGE": "图例库管理"、 "GLSMS_PLANARGRAPH_MANAGE":"平面图维护"
         plazas: [], //项目列表
         userInfo: {
-            employeename: '', //用户名称:艾宇;
-            orgCode: '',
-            username: 'lengqiang', //账户名称
+            employeename: "", //用户名称:艾宇;
+            orgCode: "",
+            username: "lengqiang", //账户名称
         },
-        plazaId: '1000423', //项目Id
-        projectName: '', //全局项目名称
+        plazaId: "1000423", //项目Id
+        projectName: "", //全局项目名称
         floorsArr: [], //楼层数组
         floorSelect: [], //楼层下拉框
-        fmapID: '',
+        fmapID: "",
         haveFengMap: false, //是否有蜂鸟地图的数据
         isMessage: true, //是否有发布的图
         scpzTable: [], //土建系统图例展示
         legendTable: [], //除土建系统图例展示
-        remarksText: '', //备注
+        remarksText: "", //备注
         bunkObj: {}, // 铺位名称
         currentFloor: {}, //当前选中的楼层信息
     },
@@ -111,20 +112,34 @@ export default new Vuex.Store({
     actions: {
         // 获取项目列表、userId
         async getUserInfo({ commit }, palyload) {
-            await login({ username: palyload }).then((res) => {
-                if (res.result == 'success') {
-                    commit('SETISREQUESTtAUTH', true)
-                    commit('SETAUTHMSG', res)
+            await login({}).then((res) => {
+                if (res.result == "success") {
+                    // token校验成功 拿到权限
+                    //commit("SETISREQUESTtAUTH", true)
+                    console.log("-----", palyload)
+                    if (res.permissions.length == 0) {
+                        //权限不足
+                        console.log("权限不足!!")
+                        router.push({ path: "/404", query: { result: "权限不足" } })
+                    }
+                    commit("SETAUTHMSG", res)
+                } else if (res.result == "no_auth") {
+                    //登录失败
+                    console.log("登录失败!!")
+                    commit("SETISREQUESTtAUTH", false)
+                    router.push({ path: "/404", query: { result: "登录失败" } })
                 } else {
-                    console.log('接口报错!!')
-                    commit('SETISREQUESTtAUTH', false)
+                    //访问出错 500
+                    console.log("访问出错!!")
+                    commit("SETISREQUESTtAUTH", false)
+                    router.push({ path: "/404", query: { result: "访问出错" } })
                 }
             })
         },
         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)
                 }
             })
         },
@@ -132,7 +147,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}`)
             })
         },
         async getBrand(context) {
@@ -147,7 +162,7 @@ export default new Vuex.Store({
                         obj[i.bunkdesc] = i
                     })
                 }
-                context.commit('SETBUNKOBJ', obj)
+                context.commit("SETBUNKOBJ", obj)
             })
         },
     },

+ 3 - 3
src/views/equipment/table/djspTable.vue

@@ -57,7 +57,7 @@ export default {
         }
     },
     computed: {
-        ...mapGetters(['floorSelect'])
+        ...mapGetters(['floorSelect', 'plazaId'])
     },
     props: ['param'],
     methods: {
@@ -82,8 +82,8 @@ export default {
         },
         getList() {
             let getParams = {
-                plazaId: this.$store.state.plazaId,
-                orderBy: `floor,0;welldesm,1;meterbox,1;`
+                orderBy: `floor,0;welldesm,1;meterbox,1;`,
+                plazaId: this.plazaId
             }
             if (this.floor) {
                 getParams.floor = this.floor

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

@@ -70,7 +70,9 @@
                 <template slot-scope='{row}'>{{row.sl>=0?row.sl:'--'}}</template>
             </el-table-column>
             <el-table-column prop='ssfasm' label='实施方案说明' show-overflow-tooltip resizable min-width='320'>
-                <template slot-scope='{row}'>{{row.ssfasm || '--'}}</template>
+                <template slot-scope='{row}'>
+                    <a :href="`http://10.199.204.167:7001/maximo/ui/?event=loadapp&value=GCZXWXLINE&uniqueid=${row.ssfasm}`" target='_blank'>{{row.ssfasm || '--'}}</a>
+                </template>
             </el-table-column>
             <el-table-column prop='sxjd' label='当前阶段' show-overflow-tooltip resizable width='80'>
                 <template slot-scope='{row}'>{{row.sxjd || '--'}}</template>

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

@@ -690,7 +690,7 @@ export default {
     width: 245px !important;
 }
 .p-select-area .p-transfer-right .p-transfer-selected .p-transfer-selected-item {
-    height: 25px;
+    height: 30px !important;
 }
 .p-select-area .p-transfer-right .p-transfer-selected .p-transfer-selected-item > span {
     word-break: break-all !important;

+ 19 - 12
src/views/legendLibrary/index.vue

@@ -123,24 +123,24 @@
                 </el-table-column>
                 <el-table-column prop='position' label='对应广场说明书的位置' show-overflow-tooltip>
                     <template slot-scope='{row}'>
-                        <span>{{row.GraphCategorys.map(item => item.Name).join(' ,') }}</span>
+                        <span>{{ row.GraphCategorys.length?row.GraphCategorys.map(item => item.Name).join(' ,'):'' }}</span>
                     </template>
                 </el-table-column>
-                <el-table-column label='对应工程信息化' align='center'>
-                    <el-table-column prop='type' label='位置/设备分类' show-overflow-tooltip>
-                        <template slot-scope='{row}'>
-                            <span>{{row.InfoLocal.map(item => item.name).join(' ,') }}</span>
-                        </template>
-                    </el-table-column>
-                    <el-table-column prop='system' label='专业' show-overflow-tooltip width='120'>
+
+                <el-table-column label='对应工程信息化中的专业/位置、设备分类' show-overflow-tooltip>
+                    <template slot-scope='{row}'>
+                        <span>{{row.InfoLocal.length?row.InfoLocal.map(item => item.name).join(' ,') :''}}</span>
+                    </template>
+                </el-table-column>
+                <!-- <el-table-column prop='system' label='专业' show-overflow-tooltip width='120'>
                         <template slot-scope='{row}'>
-                            <span>{{row.InfoSystem.map(item => item.Name).join(' ,') }}</span>
+                            <span>{{row.InfoSystem.length ?row.InfoSystem.map(item => item.Name).join(' ,') :''}}</span>
                         </template>
-                    </el-table-column>
-                </el-table-column>
+                </el-table-column>-->
+
                 <el-table-column prop='typeId' resizable label='铺位可视化typeid' width='140' show-overflow-tooltip>
                     <template slot-scope='{row}'>
-                        <span>{{row.InfoTypes.map(item => item.Name).join(' ,') }}</span>
+                        <span>{{row.InfoTypes.length ?row.InfoTypes.map(item => item.Name).join(' ,'):'' }}</span>
                     </template>
                 </el-table-column>
                 <el-table-column label='操作' width='100' v-if='state==1'>
@@ -660,4 +660,11 @@ export default {
     background: #fff;
     border: 1px solid #ccc;
 }
+.p-tree-node-check,
+.p-tree-node-check .p-tree-node-title {
+    vertical-align: top !important;
+}
+.p-checkbox .p-checkbox-box {
+    top: 4px !important;
+}
 </style>

+ 7 - 1
src/views/legendRules/index.vue

@@ -56,11 +56,12 @@
                     :head='headList2'
                     :source='tableData'
                     :toolButtons='toolBtns'
-                    :selectWidth='180'
+                    :selectWidth='200'
                     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 />
+                    <span slot-scope='{col, row}' v-else-if='col.key==="caozuo"' style='color:#0091FF'>删除</span>
                 </Table>
             </div>
         </div>
@@ -98,6 +99,11 @@ export default {
                     title: '单位',
                     key: 'Unit',
                     show: true
+                },
+                {
+                    title: '操作',
+                    key: 'caozuo',
+                    show: true
                 }
             ],
             // 操作按钮组 (非必填)

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

@@ -7,7 +7,7 @@
     <div class='compute-box'>
         <el-dialog :title='`${systemName}`||"机房"' :visible.sync='visible' :fullscreen='true'>
             <div class='compute-span'></div>
-            <el-tooltip class='item' effect='dark' :content='content' placement='top'>
+            <el-tooltip class='item' effect='dark' :content='content' placement='top' v-if='smsxtArr.length>0'>
                 <div class='compute-zf' @click='jumpFloor'></div>
             </el-tooltip>
 
@@ -854,13 +854,13 @@ export default {
         },
         // 机房右上角的跳转 如果是在楼层功能打开的机房则要跳转到设备设施对应的系统\楼层 反之亦然
         jumpFloor() {
-            if (this.smsxtArr.smsxt) {
-                if (location.pathname.split('/')[3] == 'equipment') {
-                    this.$router.push({ path: '/home/floorFunc' })
-                } else {
-                    this.$router.push({ path: '/home/equipment', query: { smsxt: this.smsxtArr.smsxt } })
-                }
+            // if (this.smsxtArr.smsxt) {
+            if (location.pathname.split('/')[3] == 'equipment') {
+                this.$router.push({ path: '/home/floorFunc' })
+            } else {
+                this.$router.push({ path: '/home/equipment', query: { smsxt: this.smsxtArr.smsxt } })
             }
+            // }
         }
     },
     mounted() {}