guoxiaohuan 4 лет назад
Родитель
Сommit
6460a16daf

+ 5 - 5
package.json

@@ -9,11 +9,11 @@
     },
     "dependencies": {
         "@mapbox/geojson-merge": "^1.1.1",
-        "@saga-web/base": "2.1.19",
-        "@saga-web/big": "1.0.40",
-        "@saga-web/draw": "2.1.94",
-        "@saga-web/feng-map": "1.0.11",
-        "@saga-web/graph": "2.1.82",
+        "@saga-web/base": "2.1.22",
+        "@saga-web/big": "1.0.67",
+        "@saga-web/draw": "2.1.100",
+        "@saga-web/feng-map": "1.0.19",
+        "@saga-web/graph": "2.1.102",
         "ant-design-vue": "^1.4.10",
         "axios": "^0.19.2",
         "core-js": "^3.4.4",

+ 4 - 10
src/api/coreDeviceReport.js

@@ -11,21 +11,15 @@
 import httputils from '@/api/httputils'
 
 // 系统列表
-
-export function queryEquipmentList() {
-    return httputils.getJson(`/data/v_glsms_systemcfg/querySmsxt`)
-
-    // export function queryEquipmentList() {
-    //     return httputils.getJson(`/data/v_glsms_systemcfg/querySmsxt`)
-}
-
+// export function queryEquipmentList() {
+//     return httputils.getJson(`/data/v_glsms_systemcfg/querySmsxt`)
+// }
 /**
  * 系统列表
  */
 export function querySystemList() {
-    return httputils.getJson(`/data/v_glsms_systemcfg/querySmsxt`)
+  return httputils.getJson(`/data/v_glsms_systemcfg/querySmsxt`);
 }
-
 /**
  * 系统下的设备
  * @param { 接口地址 } url

+ 4 - 1
src/api/legendLibrary.js

@@ -72,7 +72,10 @@ export function graphElementSearch({ postParams }) {
 // }
 
 // 业下设备分类和位置分类树形结构
-export function queryDeviceAndPOsition({ postParams }) {
+
+export function queryDeviceAndPOsition({
+    postParams
+}) {
     return httputils.postJson(`/data/t_system_wzfl/query`, postParams)
 }
 

BIN
src/assets/images/icons/1008.png


+ 3 - 10
src/components/Legend/src/legend.vue

@@ -264,10 +264,8 @@ export default {
         },
         // 编辑图例
         editTl() {
-            this.show2 = !this.show2
-            if (this.show2) {
-                this.show = false
-            }
+            this.show = false
+            this.show2 = true
             this.queryEditNum(true)
         },
         /**
@@ -291,11 +289,7 @@ export default {
             let seq = this.$cookie.get('currentFloorId')
             let data = `categoryId=${categoryId}&projectId=${this.plazaId}&BuildingID=1&FloorID=${FloorID}&FloorName=${floorName}&fmapID=${this.fmapID}&seq=${seq}&token=${this.ssoToken}`
             let url = editerUrl + 'editer?' + encodeURIComponent(data)
-            if (this.fmapID) {
-                window.open(url, true)
-            } else {
-                this.$message.error('请等待底图加载完成后再操作!')
-            }
+            window.open(url, true)
         },
         isShow2() {
             this.show2 = !this.show2
@@ -433,7 +427,6 @@ export default {
     },
     mounted() {
         this.init()
-        this.queryView(false)
         // 定时查询草稿箱数量
         this.getDraftNum() //首次查询
         this.timer = setInterval(() => {

+ 9 - 5
src/components/Rotation/src/rotation.vue

@@ -41,13 +41,17 @@ export default {
     align-items: center;
     .rotationCon {
         height: 100%;
-        display: flex;
+        width: 100%;
+        // display: flex;
     }
     img {
-        max-width: 100%;
-        max-height: 100%;
-        display: block;
-        margin: auto;
+        // max-width: 100%;
+        // max-height: 100%;
+        // display: block;
+        // margin: auto;
+        width: 100%;
+        height: 100%;
+        object-fit: fill;
     }
 }
 </style>

+ 2 - 6
src/components/menuList.vue

@@ -126,11 +126,7 @@ export default {
                 { editerUrl } = conf
             let data = `projectId=${this.plazaId}&fmapID=${this.fmapID}&token=${this.$store.state.ssoToken}`
             let url = editerUrl + 'drafts?' + encodeURIComponent(data)
-            if (this.fmapID) {
-                window.open(url, true)
-            } else {
-                this.$message.error('请等待底图加载完成后再操作!')
-            }
+            window.open(url, true)
         },
         currentTime() {
             this.times = moment().format('YYYY.MM.DD HH:mm')
@@ -255,7 +251,7 @@ export default {
         .is-active {
             color: #025baa;
             font-weight: bolder;
-            border-bottom: 2px solid #025baa;  
+            border-bottom: 2px solid #025baa;
             background: linear-gradient(180deg, rgba(2, 91, 170, 0) 0%, rgba(2, 91, 170, 0.2) 100%);
         }
     }

+ 31 - 33
src/router/index.js

@@ -72,39 +72,37 @@ const router = new VueRouter({
     routes,
 })
 //不需要token的路由
-const ignore = ['/404']
+const ignore = ['/404', '/legendLibrary', '/legendRules']
 router.beforeEach(async (to, from, next) => {
-    // 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',
-    //             returnUrl = window.location.protocol + '//' + window.location.host
-
-    //         window.location.href = `${ssoServer}/login?systemcode=${systemcode}&signal=${signal}&version=${version}`
-    //     }
-    // } else {
-    next()
-    //     return
-    // }
+    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}`
+        }
+    } else {
+        next()
+        return
+    }
 })
 export default router

+ 1 - 1
src/store/index.js

@@ -115,7 +115,7 @@ export default new Vuex.Store({
             await login({}).then((res) => {
                 if (res.result == 'success') {
                     // token校验成功 拿到权限
-                    //commit("SETISREQUESTtAUTH", true)
+                    commit('SETISREQUESTtAUTH', true)
                     if (res.permissions.length == 0) {
                         router.push('/404')
                     }

+ 164 - 152
src/views/homepage/index.vue

@@ -1,50 +1,58 @@
 <template>
-    <main class="homepage">
-        <section class="homepage-cards-content">
-            <div class="cards-item" v-for="(item , index) in cardsList" :key="index" :style = itemStyle(item)>
+    <main class='homepage'>
+        <section class='homepage-cards-content'>
+            <div class='cards-item' v-for='(item , index) in cardsList' :key='index' :style='itemStyle(item)'>
                 <h4>{{item.smsxtname}}</h4>
-                <div class="equipment-list">
-                    <div @click="navToInnerPage(item, equip)" class="equipment-item" v-for="equip in item.assetTypeList" >
-                        <div class="equip-name">
+                <div class='equipment-list' v-if='item.assetTypeList'>
+                    <div @click='navToInnerPage(item, equip)' class='equipment-item' v-for='equip in item.assetTypeList'>
+                        <div class='equip-name'>
                             <h5>{{equip.category_name}}</h5>
-                            <div class="exception-number" v-if="equip.is_exception_num">{{equip.is_exception_num}}</div>
+                            <div class='exception-number' v-if='equip.is_exception_num'>{{equip.is_exception_num}}</div>
                         </div>
-                        <div></div>
                         <section>
-                            <div class="equip-statis"><span class="equip-number">{{equip.asset_num}}</span><span class="equip-unit">台</span></div>
-                            <div><em v-if="false">维保中</em></div>
+                            <div class='equip-statis'>
+                                <span class='equip-number'>{{equip.asset_num}}</span>
+                                <span class='equip-unit'>台</span>
+                            </div>
+                            <div>
+                                <em v-if='false'>维保中</em>
+                            </div>
                         </section>
                     </div>
                 </div>
-                <div v-if="item.rptGlsmsStatisticsList && item.rptGlsmsStatisticsList.length" class="alert-list" @click="navToGanttPage(item, equip)">
-                    <div class="alert-item"   v-for="(option , index) in  item.rptGlsmsStatisticsList" :key="index" >
-                        <img v-if="option.level"  :src="srcList[option.type][option.level]"> 
-                        <div  class="content">
-                            <p class="line">
-                                <span >{{option.type === 1 ? '维保': option.type === 0 ? '专维' :  '第三方检测' }}</span>
-                                <span><em :style="{color:item.level == 1? '#646C73': item.level == 2 ? '#E07A04 ' :'#C13830'}">{{option.unfinished}}</em>/<em>{{option.total}}</em></span>
+                <div v-else class='empty-content' style='border-top:none; height:8rem;line-height:8rem;'>暂无数据</div>
+                <div v-if='item.rptGlsmsStatisticsList && item.rptGlsmsStatisticsList.length' class='alert-list' @click='navToGanttPage(item, equip)'>
+                    <div class='alert-item' v-for='(option , index) in  item.rptGlsmsStatisticsList' :key='index'>
+                        <img v-if='option.total' :src='srcList[option.type][option.level]' />
+                        <div class='content' v-if='option.total'>
+                            <p class='line'>
+                                <span>{{option.type === 1 ? '维保': option.type === 0 ? '专维' : '第三方检测' }}</span>
+                                <span>
+                                    <em :style='{color:item.level == 1? "#646C73": item.level == 2 ? "#E07A04 " :"#C13830"}'>{{option.unfinished}}</em>/
+                                    <em>{{option.total}}</em>
+                                </span>
                             </p>
-                            <p class="desc">当月未完成/总任务</p>
+                            <p class='desc'>当月未完成/总任务</p>
                         </div>
                     </div>
                 </div>
-                <div v-else class="empty-content">暂无数据</div>
+                <div v-else class='empty-content'>暂无数据</div>
             </div>
         </section>
-        <section class="homepage-nav-list">
+        <section class='homepage-nav-list'>
             <nav>
-                <div class="main-title">
+                <div class='main-title'>
                     <span>重点关注事项</span>
-                    <a @click="navToFocusItem">更多</a>
+                    <a @click='navToFocusItem'>更多</a>
                 </div>
-                <div class="table">
-                    <div class="row table-header">
+                <div class='table'>
+                    <div class='row table-header'>
                         <article>日期</article>
                         <article>政府部门</article>
                         <article>记录事项</article>
                     </div>
-                    <div class="table-body">
-                        <div class="row" v-for="(item , index) in itemsList" :key="index">
+                    <div class='table-body'>
+                        <div class='row' v-for='(item , index) in itemsList' :key='index'>
                             <article>{{item.createdate}}</article>
                             <article>{{item.department}}</article>
                             <article>{{item.recordsx}}</article>
@@ -53,18 +61,18 @@
                 </div>
             </nav>
             <nav>
-                <div class="main-title">
+                <div class='main-title'>
                     <span>说明书更新记录</span>
-                    <a @click="navToIntroduce">更多</a>
+                    <a @click='navToIntroduce'>更多</a>
                 </div>
-                <div class="table">
-                    <div class="row table-header">
+                <div class='table'>
+                    <div class='row table-header'>
                         <article>日期</article>
                         <article>事项类型</article>
                         <article>更新内容</article>
                     </div>
-                    <div class="table-body">
-                        <div class="row" v-for="(item , index) in changeList" :key="index">
+                    <div class='table-body'>
+                        <div class='row' v-for='(item , index) in changeList' :key='index'>
                             <article>{{item.changedate}}</article>
                             <article>{{item.type}}</article>
                             <article>{{item.content || '--'}}</article>
@@ -77,81 +85,87 @@
 </template>
 
 <script>
-import {getCardList, getQueryList, getChangeList} from "@/api/homePage"
+import { getCardList, getQueryList, getChangeList } from '@/api/homePage'
 import moment from 'moment'
 export default {
     data() {
         return {
-            cardsList:[],
-            itemsList:[],
-            changeList:[],
-            srcList:{
-                0:{ 
-                    1: require("../../assets/images/icons/edit_blue_b.png"),    //1.正常(蓝色) 2.警告(黄色) 3.严重(红色)
-                    2: require("../../assets/images/icons/edit_yellow_b.png"),
-                    3: require("../../assets/images/icons/edit_red_b.png")
+            cardsList: [],
+            itemsList: [],
+            changeList: [],
+            srcList: {
+                0: {
+                    1: require('../../assets/images/icons/edit_blue_b.png'), //1.正常(蓝色) 2.警告(黄色) 3.严重(红色)
+                    2: require('../../assets/images/icons/edit_yellow_b.png'),
+                    3: require('../../assets/images/icons/edit_red_b.png')
                 },
-                1:{
-                    1: require("../../assets/images/icons/fix_blue_b.png"),    
-                    2: require("../../assets/images/icons/fix_yellow_b.png"),
-                    3: require("../../assets/images/icons/fix_red_b.png")
+                1: {
+                    1: require('../../assets/images/icons/fix_blue_b.png'),
+                    2: require('../../assets/images/icons/fix_yellow_b.png'),
+                    3: require('../../assets/images/icons/fix_red_b.png')
                 },
-                2:{
-                    1: require("../../assets/images/icons/search_blue_b.png"),    
-                    2: require( "../../assets/images/icons/search_yellow_b.png"),
-                    3: require("../../assets/images/icons/search_red_b.png")
+                2: {
+                    1: require('../../assets/images/icons/search_blue_b.png'),
+                    2: require('../../assets/images/icons/search_yellow_b.png'),
+                    3: require('../../assets/images/icons/search_red_b.png')
                 }
             }
         }
     },
-    mounted () {
+    mounted() {
         this.testAjax()
         this.getItemsQuery()
         this.getInstructionList()
     },
-    methods:{
+    methods: {
         /**
          *  点击跳转进入综合事项管理页面
          */
-        navToFocusItem () {
-            this.$router.push({path:"./调"})
+        navToFocusItem() {
+            this.$router.push({ path: './调' })
         },
         /**
          *  点击跳转进入 分析|报表 说明书更新记录页面
          */
-        navToIntroduce () {
-            this.$router.push({path:"./analysis", query:{homepageKey:2}})
+        navToIntroduce() {
+            this.$router.push({ path: './analysis', query: { homepageKey: 2 } })
         },
-        itemStyle (option) {
+        itemStyle(option) {
             let num = 0
-            option.assetTypeList.forEach(item=>{
-                num +=  item.is_exception_num
-            })
+            if (option.assetTypeList) {
+                option.assetTypeList.forEach(item => {
+                    if (typeof item.is_exception_num === 'number') {
+                        num += item.is_exception_num
+                    }
+                })
+            }
             if (option.rptGlsmsStatisticsList) {
                 option.rptGlsmsStatisticsList.forEach(option => {
-                    num +=  option.unfinished
+                    if (typeof option.unfinished === 'number') {
+                        num += option.unfinished
+                    }
                 })
             }
             if (num > 0) {
                 return {
-                    borderLeft:"3px solid #EF6B66"
+                    borderLeft: '3px solid #EF6B66'
                 }
             }
         },
-        navToInnerPage (item, equip) {
-            this.$router.push({path:"./analysis", query:{smsxt:item.smsxt, equipId: equip.id}})
+        navToInnerPage(item, equip) {
+            this.$router.push({ path: './analysis', query: { smsxt: item.smsxt, equipId: equip.id } })
         },
         /**
          * 跳转到甘特图详情页
          */
-        navToGanttPage (item, equip) {
-            this.$router.push({path:"./analysis", query:{smsxt:item.smsxt}})
+        navToGanttPage(item, equip) {
+            this.$router.push({ path: './analysis', query: { smsxt: item.smsxt } })
         },
         //TODO plazaId目前是写死的 后期需要更换成用户对应的ID
-        testAjax () {
+        testAjax() {
             let params = {
                 getParams: {
-                    "plazaId":1000423,
+                    plazaId: 1000423
                 }
             }
             getCardList(params).then(res => {
@@ -167,51 +181,51 @@ export default {
         /**
          * 获取说明书变更记录
          */
-        getInstructionList () {
+        getInstructionList() {
             let params = {
                 getParams: {
-                    "plazaId":1000423,
-                    "page":1,
-                    "size":10,
+                    plazaId: 1000423,
+                    page: 1,
+                    size: 10
                 }
             }
- 
+
             getChangeList(params).then(res => {
                 if (res.result == 'success') {
                     let result = res.data
-                    result.forEach(item=>{
+                    result.forEach(item => {
                         item.changedate = moment.unix(item.changedate / 1000).format('YYYY.MM.DD')
                         if (item.objtype === 0) {
-                            item.type = "专维"
-                        } else if( item.objtype === 1) {
-                            item.type = "维保"
-                        } else if( item.objtype === 2) {
-                            item.type = "第三方检测"
+                            item.type = '专维'
+                        } else if (item.objtype === 1) {
+                            item.type = '维保'
+                        } else if (item.objtype === 2) {
+                            item.type = '第三方检测'
                         } else {
-                            item.type = "重点关注"
+                            item.type = '重点关注'
                         }
                     })
-                   
+
                     if (result && Array.isArray(result)) {
                         this.changeList = result
                     }
                 }
             })
         },
-        getItemsQuery () {
+        getItemsQuery() {
             let params = {
                 getParams: {
                     // department=部门 //部门
-                    "startDate":"20200208000000", //开始时间  
-                    "endDate":"20200608000000", //结束时间  
-                    "plazaId":1000423, //广场id 必填
-                    "page":1,//页数
-                    "size":10,//条数
+                    startDate: '20200208000000', //开始时间
+                    endDate: '20200608000000', //结束时间
+                    plazaId: 1000423, //广场id 必填
+                    page: 1, //页数
+                    size: 10 //条数
                     // "orderBy":字段名,1;//排序,1正序,0,倒序
                     // keyword=关键字1:字段名11,字段名12;关键字2:字段名21,字段名22;//模糊查询参数
                 }
             }
-            getQueryList(params).then(res=>{
+            getQueryList(params).then(res => {
                 moment().format('YYYY.MM.DD HH:mm')
                 if (res.result == 'success') {
                     if (res.data && Array.isArray(res.data)) {
@@ -220,10 +234,9 @@ export default {
                         })
                         this.itemsList = res.data
                     }
-                    
                 }
             })
-        },
+        }
     }
 }
 </script>
@@ -236,179 +249,179 @@ export default {
     padding: 15px;
     background: rgba(242, 245, 247, 1);
     overflow: auto;
-    .homepage-cards-content{
+    .homepage-cards-content {
         display: flex;
         flex-wrap: wrap;
         justify-content: space-between;
-        align-content:flex-start;
+        align-content: flex-start;
         width: 70%;
-        .cards-item{
+        .cards-item {
             width: calc(50% - 5px);
             height: 24%;
-            padding:0.4rem;    
+            padding: 0.4rem;
             padding-bottom: 0;
             margin-bottom: 1rem;
             background: #fff;
             box-shadow: 0 2px 10px 0 rgba(31, 36, 41, 0.06);
             h4 {
                 color: rgba(31, 36, 41, 1);
-                padding:1rem;
+                padding: 1rem;
                 font-size: 1.6rem;
                 font-weight: bold;
             }
-            .equipment-list{
+            .equipment-list {
                 display: flex;
                 padding-bottom: 2rem;
                 margin-bottom: 0.8rem;
-                padding:1rem;
+                padding: 1rem;
                 padding-top: 0;
-                .equipment-item{
+                .equipment-item {
                     width: 33.33%;
                     padding: 0.6rem;
                     box-sizing: border-box;
                     border-radius: 4px;
                     cursor: pointer;
-                    .equip-name{
+                    .equip-name {
                         position: relative;
                         display: inline-block;
-                        h5{
+                        h5 {
                             position: relative;
-                            color: #1F2429;
+                            color: #1f2429;
                             font-size: 1.4rem;
-                            em{
+                            em {
                                 margin-left: 1rem;
-                                color: #E19E51;
+                                color: #e19e51;
                                 font-size: 1.2rem;
                             }
                         }
-                        .exception-number{
+                        .exception-number {
                             position: absolute;
                             right: -20px;
-                            top:-5px;
+                            top: -5px;
                             height: 1.6rem;
                             border-radius: 8rem;
                             padding: 0.2rem 0.4rem;
                             line-height: 1.2rem;
                             text-align: center;
                             font-size: 1.2rem;
-                            color: #F54E45;
-                            background: #FFE0DF;
+                            color: #f54e45;
+                            background: #ffe0df;
                         }
                     }
-                    section{
+                    section {
                         display: flex;
                         justify-content: flex-start;
                         align-items: center;
-                        .equip-statis{
-                            .equip-number{
+                        .equip-statis {
+                            .equip-number {
                                 font-size: 1.8rem;
                                 font-weight: bold;
-                                color:rgba(31, 36, 41, 1)
+                                color: rgba(31, 36, 41, 1);
                             }
-                            .equip-unit{
+                            .equip-unit {
                                 color: #ccc;
                                 font-size: 1.2rem;
                             }
                         }
                     }
                 }
-                .equipment-item:hover{
+                .equipment-item:hover {
                     background: #f5f6f7;
                 }
             }
-            .alert-list{
+            .alert-list {
                 display: flex;
                 align-items: center;
                 justify-content: flex-start;
                 padding-top: 2rem;
-                border-top: 1px solid #F5F6F7;
+                border-top: 1px solid #f5f6f7;
                 border-radius: 4px;
                 cursor: pointer;
-                padding:2.2rem 1.4rem;
-                &:hover{
-                    background: #F5F6F7;
+                padding: 2.2rem 1.4rem;
+                &:hover {
+                    background: #f5f6f7;
                 }
-                .alert-item{
+                .alert-item {
                     display: flex;
                     width: 33.33%;
                     align-items: center;
-                    img{
+                    img {
                         width: 4rem;
                         height: 4rem;
                         margin-right: 1.4rem;
                     }
-                    .content{
-                        border-right: 1px solid #F5F6F7;
+                    .content {
+                        border-right: 1px solid #f5f6f7;
                         padding-right: 2rem;
-                        .line{
+                        .line {
                             display: flex;
                             justify-content: space-between;
                             align-items: center;
                             line-height: 1;
-                            span:first-child{
+                            span:first-child {
                                 margin-right: 1rem;
                                 font-size: 1.2rem;
-                                color: #1F2429;
+                                color: #1f2429;
                                 font-weight: bold;
                             }
-                            em{
+                            em {
                                 font-weight: normal;
                             }
-                            em:first-child{
+                            em:first-child {
                                 font-size: 1.6rem;
                                 font-weight: bold;
                             }
                         }
-                        .desc{
+                        .desc {
                             padding-top: 0.6rem;
-                            color: #8D9399;
+                            color: #8d9399;
                             font-size: 1.2rem;
                             text-align: right;
                         }
                     }
                 }
             }
-            .empty-content{
+            .empty-content {
                 height: 9rem;
                 line-height: 9rem;
-                border-top: 1px solid #F5F6F7;
-                
+                border-top: 1px solid #f5f6f7;
+
                 text-align: center;
-                color: #8D9399;
+                color: #8d9399;
             }
         }
     }
     .homepage-nav-list {
         width: calc(30% - 10px);
-        nav:first-child{
+        nav:first-child {
             height: 320px;
         }
-        nav:last-child{
+        nav:last-child {
             height: 320px;
         }
-        nav{
+        nav {
             padding: 14px 16px;
             margin-bottom: 10px;
             background: white;
             overflow: hidden;
             box-shadow: 0 2px 10px 0 rgba(31, 36, 41, 0.06);
-            .main-title{
+            .main-title {
                 display: flex;
                 justify-content: space-between;
                 margin-bottom: 12px;
-                span:first-child{
-                    color: #1F2429;
+                span:first-child {
+                    color: #1f2429;
                     font-weight: bold;
-                    font-size:1.4rem;
+                    font-size: 1.4rem;
                 }
             }
-            .table{
-                .row{
+            .table {
+                .row {
                     display: flex;
                     align-items: center;
                     padding: 6px;
-                    border-bottom: 1px solid #E4E6E7;
-                    article{
+                    border-bottom: 1px solid #e4e6e7;
+                    article {
                         margin-right: 10px;
                     }
                     article:nth-of-type(1) {
@@ -429,33 +442,32 @@ export default {
                         -webkit-box-orient: vertical;
                     }
                 }
-                .table-header{
+                .table-header {
                     height: 3.2rem;
                     padding: 6px;
                     line-height: 3.2rem;
-                    color:#646A73;
+                    color: #646a73;
                     font-weight: 600;
                     border-bottom: none;
-                    background: #F8F9FA;
+                    background: #f8f9fa;
                 }
-                .table-body{
+                .table-body {
                     overflow: auto;
                 }
             }
         }
-        nav:first-child{
+        nav:first-child {
             height: 40%;
-            .table-body{
+            .table-body {
                 height: 27vh;
             }
         }
-        nav:last-child{
+        nav:last-child {
             height: calc(60% - 12px);
-            .table-body{
+            .table-body {
                 height: 45vh;
             }
         }
     }
-
 }
 </style>

+ 8 - 6
src/views/legendLibrary/index.vue

@@ -132,10 +132,15 @@
                         <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.length ?row.InfoSystem.map(item => item.Name).join(' ,') :''}}</span>
+                        </template>
+                </el-table-column>-->
 
                 <el-table-column prop='typeId' resizable label='铺位可视化typeid' width='140' show-overflow-tooltip>
                     <template slot-scope='{row}'>
-                        <span>{{row.InfoTypes.length ?row.InfoTypes.map(item => `${item.Id}-${item.Name}`).join(' ,'):'' }}</span>
+                        <span>{{row.InfoTypes.length ?row.InfoTypes.map(item => `${item.Id }-${item.Name}`).join(' ,'):'' }}</span>
                     </template>
                 </el-table-column>
                 <el-table-column label='操作' width='100' v-if='state==1'>
@@ -615,8 +620,8 @@ export default {
     .device-position {
         /deep/ .p-select-input-caption {
             display: block !important;
-            width: 260px !important;
-            max-width: 300px !important;
+            width: 250px !important;
+            max-width: 250px !important;
         }
     }
     .instructions {
@@ -665,7 +670,4 @@ export default {
 .p-checkbox .p-checkbox-box {
     top: 4px !important;
 }
-.p-select-option-box {
-    border: none !important;
-}
 </style>

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

@@ -320,9 +320,9 @@ export default {
         }
         .legend-rules-right {
             padding: 16px;
-            flex: 1;
             background: #fff;
             color: #1f2429;
+            width: calc(100% - 290px);
             .img {
                 width: 28px;
                 height: 28px;

+ 34 - 19
src/views/statistics/index.vue

@@ -47,12 +47,13 @@
                             </div>
                             <span>{{item.smsxtname}}</span>
                         </div>
-                        <div class="system-equipments" >
+                        <div class="system-equipments" v-if="item.assetTypeList">
                             <div class="number" v-for="(equip , index) in item.assetTypeList" :key="index">
                                 <p>{{equip.category_name}}<span v-if="equip.is_exception_num">{{equip.is_exception_num}}</span></p>
                                 <p><span>{{equip.asset_num}}</span><span>台</span></p>
                             </div>
                         </div>
+                        <div v-else style="width:65%;text-align:center;">暂无数据</div>
                     </li>
                 </ul>
             </div>
@@ -481,7 +482,7 @@ export default {
         },
         // 处理集团地图
         pantGroupMap (data, sysId) {
-            this.clearAllLayers() 
+            // this.clearAllLayers() 
             let that = this
             data.children.forEach(item=>{
                 let params = {
@@ -511,22 +512,23 @@ export default {
                             })
                         }
                         let color = that.paintColorByData(num)
-                        let layer = L.geoJSON(JsonData.features, {
-                            style:function(){
-                                return {
-                                    'weight': 1,
-                                    'color':  color.border,
-                                    'fillColor':color.area
-                                }
-                            }
-                        }).addTo(maps);
-
+            
                         let center = JsonData.features[0].properties.center
-                        let marker = L.divIcon({
+
+                        // let marker3 = L.divIcon({
+                        //     center,
+                        //     html: `<div>${JsonData.features[0].properties.name}</div>`,
+                        //     iconSize:30
+                        // })
+
+                         var myIcon = L.divIcon({
                             html: JsonData.features[0].properties.name,
+                            className: 'my-leaflet-div-icon',
                             iconSize:30
-                        })
-                        // let marker = L.circle(center, {radius: 2000}).addTo(maps).bindPopup(contentHtml);
+                        });
+                        L.marker(center, { icon: myIcon }).addTo(maps);
+                        let marker2 = L.circle(center, 100000, { color:'transparent', fillColor:'blue', fillOpacity:0.4}).addTo(maps);
+                        let marker = L.circle(center, 50000, { color:'transparent', fillColor:'red', fillOpacity:1}).addTo(maps);
 
                         if (res.data) {
                             popup = L.popup().setLatLng(center).setContent(contentHtml)
@@ -821,6 +823,17 @@ export default {
                 contextmenu: true,
                 contextmenuWidth: 140,
             })
+            let JsonData = require("../../assets/geoData/china.json")
+             let layer = L.geoJSON(JsonData.features, {
+                style:function(){
+                    return {
+                        'weight': 1,
+                        'color': '#B3D2FF',
+                        'fillColor':'#DEECFF' 
+                    }
+                }
+            }).addTo(maps);
+            return
             if(this.currentLevel === 1) {   //1集团 3区域 0广场
                 this.pantGroupMap(this.currentDistrictData[0],"1001")
             } else if (this.currentLevel === 2) {  // 2中心 
@@ -834,13 +847,13 @@ export default {
             maps.eachLayer(function(layer){
                 maps.removeLayer(layer)
             })
-            let data = require(`../../assets/geoData/ChinaBorder.json`)
+            let data = require(`../../assets/geoData/china.json`)
             L.geoJSON(data.features, {
                 style:function(){
                     return {
                         'weight': 1,
                         'color': 'black',
-                        'fillColor':'#f1f1f1'
+                        'fillColor':'#e0ebff'
                     }
                 }
             }).addTo(maps);
@@ -964,7 +977,9 @@ export default {
                     let result = res.data
                     if (result && Array.isArray(result)) {
                         result.forEach(item => {
-                            item.assetTypeList = item.assetTypeList.splice(0,3)
+                            if (item.assetTypeList) {
+                                item.assetTypeList = item.assetTypeList.splice(0,3)
+                            }
                         })
                         res.data.forEach(item => {
                             item.selected = false
@@ -1150,7 +1165,7 @@ export default {
                 ul{
                     li.system-item{
                         display: flex;
-                        justify-content: space-around;
+                        justify-content: flex-start;
                         align-items: center;
                         width: calc(100% - 3.2rem);
                         margin-left: 1.6rem;