Переглянути джерело

Merge branch 'dev' into pathcontrol

haojianlong 5 роки тому
батько
коміт
852783573f
55 змінених файлів з 5026 додано та 686 видалено
  1. 6 6
      config/dev.env.js
  2. 189 176
      config/index.js
  3. 3 3
      config/prod.env.js
  4. 6 6
      package.json
  5. 2 2
      src/api/scan/request.js
  6. 10 6
      src/assets/style/iconfont/iconfont.css
  7. 3 0
      src/assets/style/iconfont/iconfont.svg
  8. 4 3
      src/components/business_space/business/handsontable.vue
  9. 1 1
      src/components/business_space/lib/uploadImgsName.vue
  10. 99 58
      src/components/business_space/newGraphy/graphy.vue
  11. 17 6
      src/components/data_admin/buildTask/dialog/modelTaskDialog.vue
  12. 9 6
      src/components/ledger/cenote/elevationMap.vue
  13. 110 0
      src/components/ledger/details/detail/cruxDialog.vue
  14. 138 0
      src/components/ledger/details/detail/exhibitionBaseInformation.vue
  15. 122 0
      src/components/ledger/details/detail/exhibitionCrux.vue
  16. 58 0
      src/components/ledger/details/detail/exhibitionEnergy.vue
  17. 36 0
      src/components/ledger/details/detail/exhibitionFile.vue
  18. 52 0
      src/components/ledger/details/detail/exhibitionImage.vue
  19. 29 0
      src/components/ledger/details/detail/exhibitionMaintain.vue
  20. 51 0
      src/components/ledger/details/detail/exhibitionVideo.vue
  21. 212 0
      src/components/ledger/details/detail/lookFile.vue
  22. 298 0
      src/components/ledger/details/detail/lookImage.vue
  23. 277 0
      src/components/ledger/details/detail/lookVideo.vue
  24. 49 0
      src/components/ledger/details/detail/selectRadio.vue
  25. 16 1
      src/components/ledger/handsontables/assets.vue
  26. 19 1
      src/components/ledger/handsontables/device.vue
  27. 1 0
      src/components/ledger/lib/cenoteGraphy.vue
  28. 3 3
      src/components/model/file/floorTable.vue
  29. 1 1
      src/components/model/file/modelLog.vue
  30. 19 14
      src/components/ready/buildfloor/addBuild.vue
  31. 1 1
      src/components/ready/buildfloor/addConnectivity.vue
  32. 6 1
      src/components/ready/buildfloor/formItems.vue
  33. 230 37
      src/components/ready/buildfloor/uploadFile.vue
  34. 17 10
      src/components/relation/overview/CardList.vue
  35. 54 11
      src/components/relation/overview/Modal/RelationMaintain.vue
  36. 36 6
      src/components/relation/relationShip/Modal/addRelationShip.vue
  37. 84 55
      src/router/system.js
  38. 21 1
      src/utils/scan/tools.js
  39. 256 0
      src/views/business_space/dataUtil/topology.vue
  40. 30 10
      src/views/data_admin/buildTask/addTask/addDeviceTask.vue
  41. 255 29
      src/views/ledger/cenotelist/cenoteDetail/index.vue
  42. 3 2
      src/views/ledger/cenotelist/relatedSpace.vue
  43. 599 0
      src/views/ledger/facility/details/index.vue
  44. 3 3
      src/views/ledger/facility/index.vue
  45. 518 0
      src/views/ledger/property/details/index.vue
  46. 2 42
      src/views/ledger/spacelist/index.vue
  47. 500 36
      src/views/ledger/spacelist/spaceDetail/index.vue
  48. 432 32
      src/views/ledger/system/systemDetail/index.vue
  49. 25 51
      src/views/model/report/index.vue
  50. 1 1
      src/views/ready/buildfloor/addFloor/index.vue
  51. 2 1
      src/views/ready/buildfloor/drawGraphy/drawFloor.vue
  52. 10 4
      src/views/ready/buildfloor/index.vue
  53. 4 2
      src/views/ready/buildfloor/repetitionGraphy.vue
  54. 2 1
      src/views/ready/collectsetting/index.vue
  55. 95 57
      src/views/relation/relationShip/index.vue

+ 6 - 6
config/dev.env.js

@@ -4,12 +4,12 @@ const prodEnv = require('./prod.env')
 
 module.exports = merge(prodEnv, {
     NODE_ENV: '"development"',
-    BASE_URL: '"http://172.16.44.215"', //测试iframe地址
-    SSO_SERVER: '"http://172.16.44.235:8081"', //测试环境
+    // BASE_URL: '"http://172.16.44.215"', //测试iframe地址
+    // SSO_SERVER: '"http://172.16.44.235:8081"', //测试环境
     // BASE_URL: '"http://192.168.20.236"', //(新)测试iframe地址
     // SSO_SERVER: '"http://192.168.20.236:8086"', //(新)测试环境
-    MQTT_SERVICE: '"ws://172.16.42.210:61614/stomp/"' //MQ测试环境地址
-    // SSO_SERVER: '"http://sso.sagacloud.cn"',  //正式环境
-    // BASE_URL: '"http://mbi.sagacloud.cn"', //线上iframe地址
-    // MQTT_SERVICE: '"ws://adm.sagacloud.cn/stomp/"' //MQ正式环境地址
+    // MQTT_SERVICE: '"ws://172.16.42.210:61614/stomp/"' //MQ测试环境地址
+    SSO_SERVER: '"http://sso.sagacloud.cn"',  //正式环境
+    BASE_URL: '"http://mbi.sagacloud.cn"', //线上iframe地址
+    MQTT_SERVICE: '"ws://adm.sagacloud.cn/stomp/"' //MQ正式环境地址
 })

+ 189 - 176
config/index.js

@@ -10,184 +10,197 @@ module.exports = {
     assetsSubDirectory: 'static',
     assetsPublicPath: '/',
 
-    // proxyTable: {//正式环境
-    //   '/admin': {
-    //     target: 'http://mbi.sagacloud.cn:8080',
-    //     changeOrigin: true,
-    //     pathRewrite: {
-    //       "^/admin": "/"
-    //     }
-    //   },
-    //   '/api': {
-    //     target: 'http://mbi.sagacloud.cn:8080',
-    //     changeOrigin: true,
-    //     pathRewrite: {
-    //       "^/api": "/"
-    //     }
-    //   },
-    //   '/data-platform-3': {
-    //     // 目标 API 地址
-    //     target: 'http://api.sagacloud.cn/',
-    //     // 如果要代理 websockets
-    //     ws: true,
-    //     // 将主机标头的原点更改为目标URL
-    //     changeOrigin: false
-    //   },
-    //   '/business-space': {
-    //     // 目标 API 地址
-    //     target: 'http://api.sagacloud.cn',
-    //     changeOrigin: true,
-    //     pathRewrite: {
-    //       "^/business-space": "/dp-auxiliary/business-space/"
-    //     }
-    //   },
-    //   '/pointconfig': {
-    //     // 目标 API 地址
-    //     target: 'http://mbi.sagacloud.cn:8080/',
-    //     // 如果要代理 websockets
-    //     ws: true,
-    //     // 将主机标头的原点更改为目标URL
-    //     changeOrigin: false
-    //   },
-    //   '/venders-dp': {
-    //     // 目标 API 地址
-    //     target: 'http://api.sagacloud.cn',
-    //     changeOrigin: true,
-    //     pathRewrite: {
-    //       "^/venders-dp": "/dp-auxiliary/venders-dp/"
-    //     }
-    //   },
-    //   '/venders': {
-    //     // 目标 API 地址
-    //     target: 'http://api.sagacloud.cn',
-    //     changeOrigin: true,
-    //     pathRewrite: {
-    //       "^/venders": "/dp-auxiliary/venders/"
-    //     }
-    //   },
-    //   '/ScanBuilding': {
-    //     // 目标 API 地址
-    //     target: 'http://mbi.sagacloud.cn:8080/',
-    //     // 如果要代理 websockets
-    //     ws: true,
-    //     // 将主机标头的原点更改为目标URL
-    //     changeOrigin: false
-    //   },
-    //   '/image-service': {
-    //     // 目标 API 地址
-    //     target: 'http://api.sagacloud.cn',
-    //     changeOrigin: true,
-    //     pathRewrite: {
-    //       "^/image-service": "/dp-auxiliary/image-service/"
-    //     }
-    //   },
-    //   '/godhand': {
-    //     // 目标 API 地址
-    //     target: 'http://api.sagacloud.cn',
-    //     changeOrigin: true,
-    //     pathRewrite: {
-    //       "^/godhand": "/dp-auxiliary/godhand/"
-    //     }
-    //   },
-    //   '/modelapi': {
-    //     target: 'http://mbi.sagacloud.cn:8080',
-    //     // target: 'http://192.168.20.218:8082',//景灏
-    //     changeOrigin: true,
-    //     pathRewrite: {
-    //       "^/modelapi": "/revit-algorithm/"
-    //     }
-    //   },
-    // },
-
-    proxyTable: {
-        '/admin': {
-            target: 'http://172.16.44.235:8080',
-            changeOrigin: true,
-            pathRewrite: {
-                "^/admin": "/"
-            }
-        },
-        '/api': {
-            target: 'http://172.16.44.235:8080',
-            changeOrigin: true,
-            pathRewrite: {
-                "^/api": "/"
-            }
-        },
-        '/data-platform-3': {
-            // 目标 API 地址
-            target: 'http://172.16.42.210:8080/',
-            // 如果要代理 websockets
-            ws: true,
-            // 将主机标头的原点更改为目标URL
-            changeOrigin: false
-        },
-        '/business-space': {
-            // 目标 API 地址
-            target: 'http://172.16.42.210:8080/',
-            // 如果要代理 websockets
-            ws: true,
-            // 将主机标头的原点更改为目标URL
-            changeOrigin: false
-        },
-        '/pointconfig': {
-            // 目标 API 地址
-            target: 'http://172.16.44.235:8080/',
-            // 如果要代理 websockets
-            ws: true,
-            // 将主机标头的原点更改为目标URL
-            changeOrigin: false
-        },
-        '/venders-dp': {
-            // 目标 API 地址
-            target: 'http://172.16.42.210:8080/',
-            // 如果要代理 websockets
-            ws: true,
-            // 将主机标头的原点更改为目标URL
-            changeOrigin: false
-        },
-        '/venders': {
-            // 目标 API 地址
-            target: 'http://172.16.42.210:8080/',
-            // 如果要代理 websockets
-            ws: true,
-            // 将主机标头的原点更改为目标URL
-            changeOrigin: false
-        },
-        '/ScanBuilding': {
-            // 目标 API 地址
-            target: 'http://172.16.44.235:8080/',
-            // 如果要代理 websockets
-            ws: true,
-            // 将主机标头的原点更改为目标URL
-            changeOrigin: false
-        },
-        '/image-service': {
-            // 目标 API 地址
-            target: 'http://172.16.42.210:8080/',
-            // 如果要代理 websockets
-            ws: true,
-            // 将主机标头的原点更改为目标URL
-            changeOrigin: false
-        },
-        '/godhand': {
-            // 目标 API 地址
-            target: 'http://172.16.42.210:8080/',
-            // 如果要代理 websockets
-            ws: true,
-            // 将主机标头的原点更改为目标URL
-            changeOrigin: false
-        },
-        '/modelapi': {
-            target: 'http://172.16.43.94:8082',
-            // target: 'http://192.168.20.218:8082',//景灏
-            changeOrigin: true,
-            pathRewrite: {
-                "^/modelapi": "/"
-            }
-        },
+    proxyTable: {//正式环境
+      '/admin': {
+        target: 'http://mbi.sagacloud.cn:8080',
+        changeOrigin: true,
+        pathRewrite: {
+          "^/admin": "/"
+        }
+      },
+      '/api': {
+        target: 'http://mbi.sagacloud.cn:8080',
+        changeOrigin: true,
+        pathRewrite: {
+          "^/api": "/"
+        }
+      },
+      '/data-platform-3': {
+        // 目标 API 地址
+        target: 'http://api.sagacloud.cn/',
+        // 如果要代理 websockets
+        ws: true,
+        // 将主机标头的原点更改为目标URL
+        changeOrigin: false
+      },
+      '/business-space': {
+        // 目标 API 地址
+        target: 'http://api.sagacloud.cn',
+        changeOrigin: true,
+        pathRewrite: {
+          "^/business-space": "/dp-auxiliary/business-space/"
+        }
+      },
+      '/pointconfig': {
+        // 目标 API 地址
+        target: 'http://mbi.sagacloud.cn:8080/',
+        // 如果要代理 websockets
+        ws: true,
+        // 将主机标头的原点更改为目标URL
+        changeOrigin: false
+      },
+      '/venders-dp': {
+        // 目标 API 地址
+        target: 'http://api.sagacloud.cn',
+        changeOrigin: true,
+        pathRewrite: {
+          "^/venders-dp": "/dp-auxiliary/venders-dp/"
+        }
+      },
+      '/venders': {
+        // 目标 API 地址
+        target: 'http://api.sagacloud.cn',
+        changeOrigin: true,
+        pathRewrite: {
+          "^/venders": "/dp-auxiliary/venders/"
+        }
+      },
+      '/ScanBuilding': {
+        // 目标 API 地址
+        target: 'http://mbi.sagacloud.cn:8080/',
+        // 如果要代理 websockets
+        ws: true,
+        // 将主机标头的原点更改为目标URL
+        changeOrigin: false
+      },
+      '/image-service': {
+        // 目标 API 地址
+        target: 'http://api.sagacloud.cn',
+        changeOrigin: true,
+        pathRewrite: {
+          "^/image-service": "/dp-auxiliary/image-service/"
+        }
+      },
+      '/godhand': {
+        // 目标 API 地址
+        target: 'http://api.sagacloud.cn',
+        changeOrigin: true,
+        pathRewrite: {
+          "^/godhand": "/dp-auxiliary/godhand/"
+        }
+      },
+      '/modelapi': {
+        target: 'http://mbi.sagacloud.cn:8080',
+        changeOrigin: true,
+        pathRewrite: {
+          "^/modelapi": "/revit-algorithm/"
+        }
+      },
+      '/schedulerapi': {
+        target: 'http://mbi.sagacloud.cn:8080',
+        changeOrigin: true,
+        pathRewrite: {
+            "^/schedulerapi": "/scheduler/"
+        }
+      },
     },
 
+    // proxyTable: {
+    //     '/admin': {
+    //         target: 'http://172.16.44.235:8080',
+    //         changeOrigin: true,
+    //         pathRewrite: {
+    //             "^/admin": "/"
+    //         }
+    //     },
+    //     '/api': {
+    //         target: 'http://172.16.44.235:8080',
+    //         changeOrigin: true,
+    //         pathRewrite: {
+    //             "^/api": "/"
+    //         }
+    //     },
+    //     '/data-platform-3': {
+    //         // 目标 API 地址
+    //         target: 'http://172.16.42.210:8080/',
+    //         // 如果要代理 websockets
+    //         ws: true,
+    //         // 将主机标头的原点更改为目标URL
+    //         changeOrigin: false
+    //     },
+    //     '/business-space': {
+    //         // 目标 API 地址
+    //         target: 'http://172.16.42.210:8080/',
+    //         // 如果要代理 websockets
+    //         ws: true,
+    //         // 将主机标头的原点更改为目标URL
+    //         changeOrigin: false
+    //     },
+    //     '/pointconfig': {
+    //         // 目标 API 地址
+    //         target: 'http://172.16.44.235:8080/',
+    //         // 如果要代理 websockets
+    //         ws: true,
+    //         // 将主机标头的原点更改为目标URL
+    //         changeOrigin: false
+    //     },
+    //     '/venders-dp': {
+    //         // 目标 API 地址
+    //         target: 'http://172.16.42.210:8080/',
+    //         // 如果要代理 websockets
+    //         ws: true,
+    //         // 将主机标头的原点更改为目标URL
+    //         changeOrigin: false
+    //     },
+    //     '/venders': {
+    //         // 目标 API 地址
+    //         target: 'http://172.16.42.210:8080/',
+    //         // 如果要代理 websockets
+    //         ws: true,
+    //         // 将主机标头的原点更改为目标URL
+    //         changeOrigin: false
+    //     },
+    //     '/ScanBuilding': {
+    //         // 目标 API 地址
+    //         target: 'http://172.16.44.235:8080/',
+    //         // 如果要代理 websockets
+    //         ws: true,
+    //         // 将主机标头的原点更改为目标URL
+    //         changeOrigin: false
+    //     },
+    //     '/image-service': {
+    //         // 目标 API 地址
+    //         target: 'http://172.16.42.210:8080/',
+    //         // 如果要代理 websockets
+    //         ws: true,
+    //         // 将主机标头的原点更改为目标URL
+    //         changeOrigin: false
+    //     },
+    //     '/godhand': {
+    //         // 目标 API 地址
+    //         target: 'http://172.16.42.210:8080/',
+    //         // 如果要代理 websockets
+    //         ws: true,
+    //         // 将主机标头的原点更改为目标URL
+    //         changeOrigin: false
+    //     },
+    //     '/modelapi': {
+    //         target: 'http://172.16.42.210:8082',
+    //         // target: 'http://192.168.20.218:8082',//景灏
+    //         changeOrigin: true,
+    //         pathRewrite: {
+    //             "^/modelapi": "/"
+    //         }
+    //     },
+    //     '/schedulerapi': {
+    //       target: 'http://172.16.42.210:8081',
+    //       changeOrigin: true,
+    //       pathRewrite: {
+    //           "^/schedulerapi": "/"
+    //       }
+    //     },
+    // },
+
     // Various Dev Server settings
     host: '0.0.0.0', // can be overwritten by process.env.HOST
     port: 28080, // can be overwritten by process.env.PORT, if port is in use, a free one will be determined

+ 3 - 3
config/prod.env.js

@@ -1,11 +1,11 @@
 'use strict'
 module.exports = {
     NODE_ENV: '"production"',
-    BASE_URL: '"http://192.168.20.215"', //测试iframe地址
-    SSO_SERVER: '"http://192.168.20.235:8081"', //测试环境
+    BASE_URL: '"http://172.16.44.215"', //测试iframe地址
+    SSO_SERVER: '"http://172.16.44.235:8081"', //测试环境
     // BASE_URL: '"http://192.168.20.236"', //(新)测试iframe地址
     // SSO_SERVER: '"http://192.168.20.236:8086"', //(新)测试环境
-    MQTT_SERVICE: '"ws://192.168.20.225:61614/stomp/"' //MQ测试环境地址
+    MQTT_SERVICE: '"ws://172.16.42.210:61614/stomp/"' //MQ测试环境地址
     // BASE_URL: '"http://mbi.sagacloud.cn"', //线上iframe地址
     // SSO_SERVER: '"http://sso.sagacloud.cn"',  //正式环境
     // MQTT_SERVICE: '"ws://adm.sagacloud.cn/stomp/"' //MQ正式环境地址

+ 6 - 6
package.json

@@ -19,21 +19,21 @@
     "publish": "node publish.js"
   },
   "dependencies": {
+    "@saga-web/base": "2.1.9",
+    "@saga-web/cad-engine": "2.0.541",
+    "@saga-web/draw": "2.1.75",
+    "@saga-web/graphy": "2.1.42",
     "axios": "^0.18.0",
     "echarts": "^4.1.0",
     "el-cascader-multi": "^1.1.8",
-    "element-ui": "^2.11.0",
+    "element-ui": "^2.11.1",
     "font-awesome": "^4.7.0",
     "handsontable-pro": "^3.0.0",
     "jquery": "^3.3.1",
     "vue": "^2.5.2",
     "vue-axios": "^2.1.4",
     "vue-router": "^3.0.1",
-    "vuex": "^3.1.0",
-    "@saga-web/base": "2.1.9",
-    "@saga-web/draw": "2.1.75",
-    "@saga-web/graphy": "2.1.40",
-    "@saga-web/cad-engine": "2.0.537"
+    "vuex": "^3.1.0"
   },
   "devDependencies": {
     "ajv": "^6.9.1",

+ 2 - 2
src/api/scan/request.js

@@ -1851,8 +1851,8 @@ export function shaftSpaceTypeQuery(param, success) {
 }
 //关系-----竖井下的业务空间,竖井一对多,此方法不会覆盖以前的记录
 export function shaftZoneLink(param, success) {
-  let url = `${baseUrl}/datacenter/sh-contain-sp-base/link-shsps`;
-  http.postJson(url, param, success)
+  let url = `${baseUrl}/datacenter/sh-contain-sp-base/link-shsps?type=${param.type}`;
+  http.postJson(url, param.data, success)
 }
 //关系-----竖井下的业务空间,竖井一对多,此方法会覆盖以前的记录
 export function shaftZoneLinkReplace(param, success) {

Різницю між файлами не показано, бо вона завелика
+ 10 - 6
src/assets/style/iconfont/iconfont.css


Різницю між файлами не показано, бо вона завелика
+ 3 - 0
src/assets/style/iconfont/iconfont.svg


+ 4 - 3
src/components/business_space/business/handsontable.vue

@@ -158,8 +158,8 @@ export default {
     getData() {
       this.zoneParam = {
         ZoneType: this.zoneCode,
-        PageNumber: 1,
-        PageSize: 50,
+        PageNumber: this.page.pageNumber,
+        PageSize: this.page.pageSize,
         Orders: "createTime desc, RoomID asc"
       }
       if (this.buildFloorSelectd.length === 1) {
@@ -584,7 +584,8 @@ export default {
           }
         })
         let updateParam = {
-          Content: obj
+          Content: obj,
+          Projection: param.data.Projection
         };
         zoneUpdate(updateParam, res => {
           this.$message.success('更新成功')

+ 1 - 1
src/components/business_space/lib/uploadImgsName.vue

@@ -5,7 +5,7 @@
     @click change  承接数组发生变化时触发函数
 -->
 <template>
-  <div id="sagaUploads">
+  <div id="sagaUploads" :style="{marginLeft:(isShow && imagesArr.length>2) ? '157px':'',marginTop:(isShow && imagesArr.length>2) ? '-25px':''}">
     <div class="saga-upload-images">
       <div v-if="type != 'video'" class="point-view" v-for="(item,index) in imagesArr">
         <div class="point-image">

+ 99 - 58
src/components/business_space/newGraphy/graphy.vue

@@ -117,8 +117,8 @@
 <script>
 import canvasFun from "./canvasFun"
 import { mapGetters } from "vuex";
-import { SPoint } from "@saga-web/draw/lib";
-import { DivideFloorScene, FloorView, SpaceItem, ZoneItem } from "@saga-web/cad-engine/lib";
+import { SPoint, SColor } from "@saga-web/draw/lib";
+import { DivideFloorScene, FloorView, SpaceItem, ZoneItem, Opt } from "@saga-web/cad-engine/lib";
 import { colorArr } from "@/utils/spaceColor"
 import unRelateBSP from "./unRelateBSP";
 import createBSP from "./createBSP";
@@ -132,7 +132,8 @@ import {
   zoneCount,
   zoneCreate,
   zoneQuery,
-  zoneUpdate
+  zoneUpdate,
+  handleZoneUpdateBd
 } from "@/api/scan/request"
 
 export default {
@@ -186,7 +187,9 @@ export default {
   computed: {
     ...mapGetters('layout', ['projectId'])
   },
-  created() { },
+  created() {
+    Opt.sceneMarkColor = new SColor('#ffffff');
+  },
   mounted() {
     this.canvasWidth = this.$refs.graphy.offsetWidth - 20;
     this.canvasHeight = this.$refs.graphy.offsetHeight - 20;
@@ -359,7 +362,7 @@ export default {
         this.scene.isSpaceSelectable = false;
         // 绘制业务空间
         that.getBusinessSpace();
-        that.view.fitSceneToView();
+        that.fit();
         that.view.minScale = that.view.scale;
         if (that.$refs.canvasFun) {
           that.$refs.canvasFun.everyScale = that.view.scale;
@@ -579,7 +582,7 @@ export default {
         spaces = this.scene.getZoneDifference();
       }
       for (let key in spaces) {
-        spaces[key].map(t => {
+        spaces[key] = spaces[key].map(t => {
           let temp = t.map(item => {
             return {
               X: 1 * item.x.toFixed(2),
@@ -587,8 +590,10 @@ export default {
               Z: 0
             }
           })
-          zoneObj.Outline.push([temp]);
+          return temp;
         })
+        let newarr = this.makeMaxAreaFirst(spaces[key])
+        zoneObj.Outline.push(newarr);
         let curISP = this.sourceIdToISP[key];
         if (curISP) {
           curISP && IspaceIdList.push(curISP.RoomID);
@@ -633,66 +638,68 @@ export default {
     },
     // 根据图从未关联平面图的业务空间中选择--按钮返回关联信号
     createFromUnrelated(zoneObj) {
+      zoneObj.Outline = [];
+      zoneObj.Height = 0;
+      let spaces = {}, IspaceIdList = [];
+      if (this.scene.cutItem || this.scene.sceneMark) {
+        // 如果有划分,求交集
+        // 格式为Poly(先与业务空间求差集)
+        const obj = this.scene.getZoneDifference(true);
+        // 差集与楼层平面图或用户划分区域求交集
+        spaces = this.scene.getPloyIntersect(obj)
+      } else {
+        // 格式为SPoint[]
+        spaces = this.scene.getZoneDifference();
+      }
+      for (let key in spaces) {
+        spaces[key] = spaces[key].map(t => {
+          let temp = t.map(item => {
+            return {
+              X: 1 * item.x.toFixed(2),
+              Y: -item.y.toFixed(2),
+              Z: 0
+            }
+          })
+          return temp;
+        })
+        let newarr = this.makeMaxAreaFirst(spaces[key])
+        zoneObj.Outline.push(newarr);
+        let curISP = this.sourceIdToISP[key];
+        if (curISP) {
+          curISP && IspaceIdList.push(curISP.RoomID);
+          zoneObj.Height = zoneObj.Height == 0 ? curISP.Height : zoneObj.Height > curISP.Height ? curISP.Height : zoneObj.Height;
+        }
+      }
+
+      // 改回之前逻辑
       // zoneObj.Outline = [];
       // zoneObj.Height = 0;
       // let spaces = {}, IspaceIdList = [];
+      // let selectSpaces = this.scene.getSelectedSpaces();
+      // selectSpaces.map(t => {
+      //   zoneObj.Outline.push(t.data.OutLine);
+      //   let key = t.data.SourceId;
+      //   let curISP = this.sourceIdToISP[key];
+      //   if (curISP) {
+      //     curISP && IspaceIdList.push(curISP.RoomID);
+      //     zoneObj.Height = zoneObj.Height == 0 ? curISP.Height : zoneObj.Height > curISP.Height ? curISP.Height : zoneObj.Height;
+      //   }
+      // })
+      // // 如果有划分,求交集
       // if (this.scene.cutItem || this.scene.sceneMark) {
-      //   // 如果有划分,求交集
-      //   // 格式为Poly(先与业务空间求差集)
-      //   const obj = this.scene.getZoneDifference(true);
-      //   // 差集与楼层平面图或用户划分区域求交集
-      //   spaces = this.scene.getPloyIntersect(obj)
-      // } else {
-      //   // 格式为SPoint[]
-      //   spaces = this.scene.getZoneDifference();
-      // }
-      // for (let key in spaces) {
-      //   spaces[key].map(t => {
+      //   zoneObj.Outline = [];
+      //   let arr = this.scene.getIntersect();
+      //   arr.map(t => {
       //     let temp = t.map(item => {
       //       return {
-      //         X: 1 * item.x.toFixed(2),
-      //         Y: -item.y.toFixed(2),
+      //         X: 1 * item.x,
+      //         Y: -item.y,
       //         Z: 0
       //       }
       //     })
       //     zoneObj.Outline.push([temp]);
       //   })
-      //   let curISP = this.sourceIdToISP[key];
-      // if(curISP){
-      //   curISP && IspaceIdList.push(curISP.RoomID);
-      //   zoneObj.Height = zoneObj.Height == 0 ? curISP.Height : zoneObj.Height > curISP.Height ? curISP.Height : zoneObj.Height;
       // }
-      // }
-
-      // 改回之前逻辑
-      zoneObj.Outline = [];
-      zoneObj.Height = 0;
-      let spaces = {}, IspaceIdList = [];
-      let selectSpaces = this.scene.getSelectedSpaces();
-      selectSpaces.map(t => {
-        zoneObj.Outline.push(t.data.OutLine);
-        let key = t.data.SourceId;
-        let curISP = this.sourceIdToISP[key];
-        if (curISP) {
-          curISP && IspaceIdList.push(curISP.RoomID);
-          zoneObj.Height = zoneObj.Height == 0 ? curISP.Height : zoneObj.Height > curISP.Height ? curISP.Height : zoneObj.Height;
-        }
-      })
-      // 如果有划分,求交集
-      if (this.scene.cutItem || this.scene.sceneMark) {
-        zoneObj.Outline = [];
-        let arr = this.scene.getIntersect();
-        arr.map(t => {
-          let temp = t.map(item => {
-            return {
-              X: 1 * item.x,
-              Y: -item.y,
-              Z: 0
-            }
-          })
-          zoneObj.Outline.push([temp]);
-        })
-      }
       if (!zoneObj.Outline.length) {
         zoneObj.Outline = null;
       }
@@ -817,7 +824,7 @@ export default {
       }
       for (let key in spaces) {
         let zoneObj = { Outline: [], Height: 0 }
-        spaces[key].map(t => {
+        spaces[key] = spaces[key].map(t => {
           let temp = t.map(item => {
             return {
               X: 1 * item.x.toFixed(2),
@@ -825,8 +832,10 @@ export default {
               Z: 0
             }
           })
-          zoneObj.Outline.push([temp]);
+          return temp;
         })
+        let newarr = this.makeMaxAreaFirst(spaces[key])
+        zoneObj.Outline.push(newarr);
         if (!zoneObj.Outline.length) {
           continue
         }
@@ -1017,10 +1026,24 @@ export default {
       let ObjectType = this.tab.code == 'OtherZone' ? this.OtherValue : this.tab.code;
       zoneObj.BIMLocation = zoneObj.Outline ? this.getAverageVal(zoneObj.Outline) : null;
       zoneObj.ObjectType = ObjectType;
+      zoneObj.BuildingId = this.buildFloor[0];
+      zoneObj.FloorId = this.buildFloor[1];
       let pa = {
-        Content: [zoneObj]
+        Content: [zoneObj],
+        Projection: ['BIMLocation', 'ObjectType', 'Outline', 'Height', 'BuildingId', 'FloorId']
       }
       zoneUpdate(pa, res => {
+        this.updateZoneBF(zoneObj, IspaceIdList);
+      })
+    },
+    // 从未关联平面图的业务空间中选择时更新业务空间建筑楼层
+    updateZoneBF(zoneObj, IspaceIdList) {
+      let pa = [{
+        Type: zoneObj.ObjectType,
+        SpaceId: zoneObj.RoomID,
+        Id: zoneObj.FloorId,
+      }]
+      handleZoneUpdateBd(pa, res => {
         this.relationInBSPandISP(zoneObj.RoomID, IspaceIdList)
       })
     },
@@ -1088,6 +1111,10 @@ export default {
     },
     // 适配底图到窗口
     fit() {
+      if (this.scene.sceneMark) {
+        this.view.fitItemToView([this.scene.sceneMark])
+        return
+      }
       this.view.fitSceneToView()
     },
     // 保存为png
@@ -1122,6 +1149,20 @@ export default {
       let scale = this.view.scale;
       this.view.scaleByPoint(val / scale, this.canvasWidth / 2, this.canvasHeight / 2);
     },
+    // 给定多个轮廓线的数据,计算得到面积最大值,并把它放置数组第一项
+    // list {XYZ}[][]
+    makeMaxAreaFirst(list) {
+      let arr = [], area = 0;
+      for (let i = 0; i < list.length; i++) {
+        let temp = this.getarea(list[i])
+        if (temp > area) {
+          arr.unshift(list[i])
+        } else {
+          arr.push(list[i])
+        }
+      }
+      return arr;
+    }
   },
   filters: {
     cutString: function (str, len) {

+ 17 - 6
src/components/data_admin/buildTask/dialog/modelTaskDialog.vue

@@ -177,12 +177,23 @@ export default {
     savaRelation() {
       if (this.selections.length) {
         let list = this.selections.map((item) => {
-          return {
-            EquipId: item.EquipID,
-            FileId: item.FileId,
-            FileName: item.FileName,
-            FolderId: item.FolderId,
-            FolderName: item.FolderName
+          if (item.SchemeId) {
+            return {
+              EquipId: item.EquipID,
+              FileId: item.FileId,
+              FileName: item.FileName,
+              FolderId: item.FolderId,
+              FolderName: item.FolderName,
+              SchemeId: item.SchemeId
+            }
+          } else {
+            return {
+              EquipId: item.EquipID,
+              FileId: item.FileId,
+              FileName: item.FileName,
+              FolderId: item.FolderId,
+              FolderName: item.FolderName
+            }
           }
         })
         let params = {

+ 9 - 6
src/components/ledger/cenote/elevationMap.vue

@@ -18,10 +18,10 @@
             :class="[spaceItem.IsAI?spaceItem.checked?'saga-spaceItem-checked':'saga-spaceItem-ai':'']" 
             v-for="spaceItem in group.spaceList" 
             :key="spaceItem.RoomID"
-            :title="spaceItem.RoomLocalName"
+            :title="spaceItem.RoomLocalName?spaceItem.RoomLocalName:spaceItem.RoomName"
             @click="handleClickCheck(spaceItem)"
             >
-            {{spaceItem.RoomLocalName}}
+            {{spaceItem.RoomLocalName?spaceItem.RoomLocalName:spaceItem.RoomName}}
             </div>
           </div>
         </div>
@@ -139,10 +139,13 @@
     },
     savaEdit () {// 接口保存数据和业务空间的关系
       let params = {
-        ShaftId: this.params.ShaftId,
-        SpaceIdList: this.checkedList.map(item => {
-          return item.RoomID
-        })
+        type: this.params.ObjectType,
+        data: {
+          ShaftId: this.params.ShaftId,
+          SpaceIdList: this.checkedList.map(item => {
+            return item.RoomID
+          })
+        }
       }
       console.log(params);
       shaftZoneLink(params, res =>{

+ 110 - 0
src/components/ledger/details/detail/cruxDialog.vue

@@ -0,0 +1,110 @@
+<template>
+  <el-dialog title="关键信息点" :visible.sync="dialogFormVisible" class="crux-dialog">
+    <section v-for="(val,key,i) in checkList" :key="i">
+      <h4 class="base">{{key}}</h4>
+      <el-checkbox
+        v-for="(option,index) in val"
+        :key="option+index"
+        :label="option.InfoPointName"
+        v-model="option.KeyWord"
+      />
+    </section>
+    <div slot="footer" class="dialog-footer">
+      <el-button @click="dialogFormVisible = false">取 消</el-button>
+      <el-button type="primary" @click="save">保 存</el-button>
+    </div>
+  </el-dialog>
+</template>
+
+<script>
+  import {setDataDictionary} from "@/api/scan/request";
+
+  export default {
+    name: "cruxDialog",
+    props: ['crux', 'type'],
+    data() {
+      return {
+        dialogFormVisible: false,
+        checkList: {},
+        checkboxGroup: []
+      }
+    },
+    computed: {
+      allChecks() {
+        const tmp = [];
+        for (const key in this.checkList) {
+          if (this.checkList.hasOwnProperty(key)) {
+            const element = this.checkList[key];
+            tmp.push(...element);
+          }
+        }
+        return tmp;
+      }
+    },
+
+    watch: {
+      crux() {
+        this.changeList()
+      }
+    },
+    methods: {
+      changeList() {
+        const tmp = {};
+        for (let key in this.crux) {
+          if (this.crux.hasOwnProperty(key)) {
+            const element = this.crux[key];
+            tmp[key] = [
+              ...element.paths.map(i => ({
+                InfoPointCode: i.InfoPointCode,
+                KeyWord: i.KeyWord,
+                Type: this.type,
+                InfoPointName: i.InfoPointName
+              }))
+            ]
+          }
+        }
+        this.checkList = tmp;
+      },
+      dialogOpen() {
+        this.dialogFormVisible = true
+      },
+      save() {
+        let arrLenght = this.allChecks.filter(i => i.KeyWord)
+        if (arrLenght.length > 6) {
+          this.$message.info('不可超过6个')
+          return false
+        } else {
+          let param = this.allChecks.map(i => {
+            if (i.InfoPointName) {
+              delete i.InfoPointName
+            }
+            return {...i}
+          })
+
+          setDataDictionary(param, res => {
+            this.dialogFormVisible = false
+            this.$emit('cruxSuccess')
+            this.$message('保存成功')
+
+          });
+
+        }
+
+
+      }
+    }
+  }
+</script>
+
+<style scoped lang="less">
+  .crux-dialog {
+    .el-checkbox{
+      display: inline-block;
+      width: 20%;
+    }
+    /deep/ .el-dialog__body {
+      height: 420px;
+      overflow: auto;
+    }
+  }
+</style>

+ 138 - 0
src/components/ledger/details/detail/exhibitionBaseInformation.vue

@@ -0,0 +1,138 @@
+<template>
+<div class="exhibition-baseInformation">
+  <section v-for="(val,key,i) in exhibitionBaseInformation.information">
+    <h4 class="base">{{key || '信息'}}</h4>
+    <div class="infoPoint-item" v-for="(value,keys,index) in val.paths">
+      <span> {{value.InfoPointName}}:</span>
+      <el-popover
+        v-if="value.Path == 'EquipQRCode' || value.Path == 'RoomQRCode' || value.Path == 'ShaftQRCode'"
+        placement="right"
+        width="360"
+        trigger="hover">
+        <p style="border-bottom: 1px solid #eee;padding:2px 0 4px 0;'">{{value.InfoPointName}}</p>
+        <div style="overflow:hidden;">
+          <div style="float:left;width: 60%" v-if="value.Value">
+            <img
+              style="width:200px;height:200px;"
+              :src="'/image-service/common/file_get/'+ value.Value +'?systemId=dataPlatform'"
+              alt="二维码"
+            >
+          </div>
+          <div v-else style="width: 100%;text-align: center;padding-top: 10px">数据暂无</div>
+          <div style="float:right;width: 40%;margin-top: 30px">
+            <span>{{value.Value}}</span>
+          </div>
+        </div>
+        <div style="text-align: center; margin: 0">
+          <el-button
+            type="text"
+            size="mini"
+            v-if="value.Value &&value.InputMode != 'F2'&& value.InputMode!='N2' "
+            @click="handleCopy(value.Value)">复制
+          </el-button>
+        </div>
+        <el-button slot="reference" type="text">{{value.Value ? '有' :'-'}}</el-button>
+      </el-popover>
+      <el-popover
+        v-else-if="Array.isArray(value.Value) && value.InputMode== 'F2'"
+        placement="right"
+        width="250"
+        trigger="hover">
+        <p style="border-bottom: 1px solid #eee;padding:2px 0 4px 0;'">{{value.InfoPointName}}</p>
+        <div v-for="(pic,index) in value.Value">
+          <div>图纸名称:{{pic.Name}}
+              <el-button style="" type="text" size="mini" @click="downloadFile(pic.Key)">下载</el-button>
+          </div>
+        </div>
+        <el-button slot="reference" type="text">{{value.Value? '有':'-'}}</el-button>
+      </el-popover>
+      <el-popover
+        v-else-if="Array.isArray(value.Value) && value.InputMode=='N2'"
+        placement="right"
+        width="600"
+        trigger="hover">
+        <p style="border-bottom: 1px solid #eee;padding:2px 0 4px 0;'">{{value.InfoPointName}}</p>
+        <p style="height: 300px;overflow: auto">{{value.Value}}</p>
+        <div style="text-align: center; margin: 0">
+          <el-button type="text" size="mini" @click="handleCopy(value.Value)">复制</el-button>
+        </div>
+        <el-button slot="reference" type="text">{{value.Value ? '有' :'-'}}</el-button>
+      </el-popover>
+      <el-popover
+        v-else-if="value.Value && value.Value.length  && `${value.InfoPointName}:${value.Value}`.length>22 "
+        placement="right"
+        width="160"
+        trigger="hover">
+        <p style="border-bottom: 1px solid #eee;padding:2px 0 4px 0;'">{{value.InfoPointName}}</p>
+        <p>{{value.Value}}</p>
+        <div style="text-align: center; margin: 0">
+          <el-button type="text" size="mini" @click="handleCopy(value.Value)">复制</el-button>
+        </div>
+        <el-button slot="reference" type="text">{{handleName(value.InfoPointName, value.Value)}}</el-button>
+      </el-popover>
+      <span v-else>{{value.Value}}</span>
+    </div>
+  </section>
+</div>
+</template>
+
+<script>
+  export default {
+    name: "exhibition-baseInformation",
+    props: ['exhibitionBaseInformation'],
+    data() {
+      return {}
+    },
+    methods: {
+      downloadFile(key) {
+        window.open("/image-service/common/file_get/" + key + "?systemId=dataPlatform")
+
+      },
+      handleCopy(data) {
+        let oInput = document.createElement('input')
+        oInput.value = data
+        document.body.appendChild(oInput)
+        oInput.select()
+        document.execCommand('Copy')
+        this.$message.success('复制成功')
+        oInput.remove()
+      },
+      handleName(infoPoint, val) {
+        let text = `${infoPoint}:${val}`
+        return text.length > 22 ? val.substring(0, 22-`${infoPoint}:`.length) + '...' : val
+      }
+    }
+  }
+</script>
+
+<style scoped lang="less">
+  .exhibition-baseInformation {
+    section {
+      /*border: 1px solid #eeeeee;*/
+      /*margin: 10px;*/
+
+      .base {
+        margin: 10px;
+        font-weight: 600;
+        text-indent: 10px;
+        border-bottom: 1px dashed #eee;
+      }
+
+      /deep/ .el-button--text {
+        color: #555 !important;
+        font-size: 14px;
+      }
+    }
+
+    .ml-10 {
+      margin-left: 10px;
+      text-indent: 10px;
+    }
+
+    .infoPoint-item {
+      width: 335px;
+      display: inline-block;
+      margin-left: 20px;
+    }
+  }
+</style>

+ 122 - 0
src/components/ledger/details/detail/exhibitionCrux.vue

@@ -0,0 +1,122 @@
+<template>
+  <section class="exhibition-crux">
+    <p class="title">
+      <span class="iconfont icon-juxing"></span>
+      {{exhibitionCrux.title}}
+      <span class="icon-shezhi iconfont setting" @click="setting"></span></p>
+    <div>
+      <div v-if="exhibitionCrux.cruxArray.length">
+        <div class="crux-list" v-for="(item,index) in exhibitionCrux.cruxArray" :key="index">{{item.InfoPointName}}:
+
+        <el-popover
+          v-if="item.value && item.value.length && item.value.length>12 && item.Path=='EquipQRCode'"
+          placement="top"
+          width="360"
+          trigger="hover">
+          <p style="border-bottom: 1px solid #eee;padding:2px 0 4px 0;'">{{item.InfoPointName}}</p>
+          <div style="overflow:hidden;">
+            <div style="float:left;width: 60%">
+              <img
+                style="width:200px;height:200px;"
+                :src="'/image-service/common/file_get/'+ item.value +'?systemId=dataPlatform'"
+                alt="二维码"
+              >
+            </div>
+            <div style="float:right;width: 40%;margin-top: 30px">
+              <span>{{item.value}}</span>
+            </div>
+          </div>
+
+          <div style="text-align: center; margin: 0">
+            <el-button type="text" size="mini" @click="handleCopy(item.value)">复制</el-button>
+          </div>
+          <el-button slot="reference" type="text">{{item.value ? '有' :'-'}}</el-button>
+        </el-popover>
+        <el-popover
+          v-else-if="item.value && item.value.length && item.value.length>12"
+          placement="top"
+          width="160"
+          trigger="hover">
+          <p style="border-bottom: 1px solid #eee;padding:2px 0 4px 0;'">{{item.InfoPointName}}</p>
+          <p>{{item.value}}</p>
+          <div style="text-align: center; margin: 0">
+            <el-button type="text" size="mini" @click="handleCopy(item.value)">复制</el-button>
+          </div>
+          <el-button slot="reference" type="text">{{handleName(item.value)}}</el-button>
+        </el-popover>
+        <span v-else>{{item.value}}</span>
+        </div>
+      </div>
+      <div style="text-align: center" v-else>暂无数据</div>
+    </div>
+    <cruxDialog
+      ref="setting"
+      :crux="exhibitionCrux.allMessage"
+      :type="type"
+      @cruxSuccess="cruxSuccess"
+
+    />
+  </section>
+</template>
+
+<script>
+  import cruxDialog from "./cruxDialog";
+
+  export default {
+    name: "exhibition-crux",
+    props: ['exhibitionCrux','type'],
+    components: {cruxDialog},
+    data() {
+      return {
+        list: []
+      }
+    },
+    methods: {
+      setting() {
+        this.$refs.setting.dialogOpen()
+      },
+      cruxSuccess() {
+        this.$emit('cruxSuccess')
+      },
+      handleCopy(data) {
+        let oInput = document.createElement('input')
+        oInput.value = data
+        document.body.appendChild(oInput)
+        oInput.select()
+        document.execCommand('Copy')
+        this.$message.success('复制成功')
+        oInput.remove()
+      },
+      handleName(val) {
+        return val.length > 10 ? val.substring(0, 10) + '...' : val
+      }
+    }
+  }
+</script>
+
+<style lang="less" scoped>
+  .exhibition-crux {
+    /deep/ .el-button--text {
+      color: #555 !important;
+      font-size: 14px;
+    }
+    .title {
+      /*border-left: 8px solid black;*/
+      margin: 10px 40px 0 10px;
+      font-weight: 600;
+      text-indent: 10px;
+      display: block;
+      overflow: hidden;
+
+      .setting {
+        float: right;
+      }
+
+    }
+      .crux-list {
+        display: inline-block;
+        width: 25%;
+        margin-left: 28px;
+      }
+  }
+</style>

+ 58 - 0
src/components/ledger/details/detail/exhibitionEnergy.vue

@@ -0,0 +1,58 @@
+<template>
+  <div class="exhibition-energy">
+    <div class="title">
+      <section>
+        <h4 class="base" v-show="exhibitionEnergy.firstName">{{exhibitionEnergy.firstName}}</h4>
+        <div v-if="exhibitionEnergy.dynamic.length">
+          <div v-for="(item,index) in exhibitionEnergy.dynamic" :key="index" class="table-dynamic">
+            <div class="table-title">{{item.InfoPointName}}:</div>
+            <div>
+              <p>表号功能号 {{item.value}}</p>
+              <p>{{item.data ? item.data :item.error}} {{item.Unit}}</p>
+              <p>{{formatDate(item.receivetime)}}</p>
+            </div>
+          </div>
+        </div>
+        <div v-else style="text-align: center;margin-top: 200px">暂无数据</div>
+      </section>
+    </div>
+  </div>
+</template>
+
+<script>
+  export default {
+    name: "exhibitionEnergy",
+    props: ['exhibitionEnergy'],
+    methods:{
+      formatDate(str) {
+        return str ? str.substr(0,4)+"-"+str.substr(4,2)+"-"+str.substr(6,2)+" "+str.substr(8,2) + ":" +str.substr(10,2) + ":"+str.substr(12,2) :'--'
+      }
+    }
+  }
+</script>
+
+<style scoped lang="less">
+  .exhibition-energy {
+    .base {
+      margin: 10px;
+      font-weight: 600;
+      text-indent: 10px;
+      border-bottom: 1px dashed #eee;
+    }
+
+    .table-dynamic {
+      height: 85px;
+      width: 100%;
+      margin: 5px 0;
+      padding-left: 20px;
+      box-sizing: border-box;
+    }
+
+    .table-title {
+      float: left;
+      max-width: 200px;
+      width: 100px;
+      height: 85px;
+    }
+  }
+</style>

+ 36 - 0
src/components/ledger/details/detail/exhibitionFile.vue

@@ -0,0 +1,36 @@
+<template>
+  <div class="exhibition-file">
+    <p class="title">
+      <span class=" iconfont icon-fujian"></span>
+      {{exhibitionFile.title}}</p>
+    <div>
+      <lookFile :exhibitionFile="exhibitionFile"/>
+    </div>
+
+  </div>
+</template>
+
+<script>
+  import lookFile from "./lookFile";
+    export default {
+      name: "exhibition-file",
+      props: ['exhibitionFile'],
+      data() {return{}},
+      components:{lookFile}
+    }
+</script>
+
+<style scoped lang="less">
+  .exhibition-file {
+    border: 1px solid #eeeeee;
+    background: #FFFFFF;
+    margin-bottom: 10px;
+
+    .title {
+      border-bottom: 1px solid #eee;
+      padding: 10px 0;
+      font-weight: 600;
+      text-indent: 10px;
+    }
+  }
+</style>

+ 52 - 0
src/components/ledger/details/detail/exhibitionImage.vue

@@ -0,0 +1,52 @@
+<template>
+  <div class="exhibition-image">
+    <p class="title">
+      <span class=" icon-floorplan iconfont"></span>
+      <span>{{exhibitionImage.title}}</span>
+    </p>
+    <div class="image">
+      <lookImage  :exhibitionImage="exhibitionImage"/>
+    </div>
+
+  </div>
+</template>
+
+<script>
+  import lookImage from "./lookImage";
+  export default {
+    name: "exhibition-image",
+    props: ['exhibitionImage'],
+    components:{lookImage},
+    data() {
+      return {
+
+      }
+    },
+    methods:{
+      deepcopy(obj) {
+        return JSON.parse(JSON.stringify(obj));
+      },
+    }
+  }
+</script>
+
+<style lang="less" scoped>
+  .exhibition-image {
+    border: 1px solid #eeeeee;
+    background: #fff;
+    margin-bottom: 10px;
+    .title {
+      border-bottom: 1px solid #eee;
+      padding: 10px 0;
+      font-weight: 600;
+      text-indent: 10px;
+    }
+
+    .image {
+      margin: 10px;
+      /*text-align: center;*/
+    }
+
+  }
+
+</style>

+ 29 - 0
src/components/ledger/details/detail/exhibitionMaintain.vue

@@ -0,0 +1,29 @@
+<template>
+  <div class="exhibition-maintain">
+    <p class="title disable">
+      <span class=" iconfont icon-weixiubeijing "></span>
+      {{exhibitionMaintain.title}}
+      <span class="iconfont icon-right " style="float: right;margin-right: 20px"></span></p>
+  </div>
+</template>
+
+<script>
+  export default {
+    name: "exhibitionMaintain",
+    props: ['exhibitionMaintain']
+  }
+</script>
+
+<style scoped lang="less">
+  .exhibition-maintain {
+
+    .title {
+      margin-left: 10px;
+      font-weight: 600;
+      text-indent: 10px;
+    }
+    .disable{
+      color:#ccc;
+    }
+  }
+</style>

+ 51 - 0
src/components/ledger/details/detail/exhibitionVideo.vue

@@ -0,0 +1,51 @@
+<template>
+  <div class="exhibition-video">
+    <p class="title">
+      <span class=" icon-shipin-tianchong iconfont"></span>
+      {{exhibitionVideo.title}}</p>
+    <div class="image">
+      <lookVideo  :exhibitionVideo="exhibitionVideo"/>
+    </div>
+
+  </div>
+</template>
+
+<script>
+  import lookVideo from "./lookVideo";
+  export default {
+    name: "exhibition-video",
+    props: ['exhibitionVideo'],
+    components:{lookVideo},
+    data() {
+      return {
+
+      }
+    },
+    methods:{
+      deepcopy(obj) {
+        return JSON.parse(JSON.stringify(obj));
+      },
+    }
+  }
+</script>
+
+<style lang="less" scoped>
+  .exhibition-video {
+    border: 1px solid #eeeeee;
+    background: #fff;
+    margin-bottom: 10px;
+    .title {
+      border-bottom: 1px solid #eee;
+      padding: 10px 0;
+      font-weight: 600;
+      text-indent: 10px;
+    }
+
+    .image {
+      margin: 10px;
+      /*text-align: center;*/
+    }
+
+  }
+
+</style>

+ 212 - 0
src/components/ledger/details/detail/lookFile.vue

@@ -0,0 +1,212 @@
+<template>
+  <div class="exhibition-file">
+    <div v-if="Object.keys(exhibitionFile.list).length">
+      <div v-for="(val,key,i) in exhibitionFile.list" :key="i">
+        <div class="" v-for="(j,index) in val">
+          <p class="title">
+            <span class="iconfont icon-juxing"></span>
+            {{key}}
+          </p>
+          <div v-if="j.fileList !=undefined && j.fileList.length">
+            <div v-for="(item,index) in j.fileList" class="content">
+              <!--          图标-->
+              <div class="file-box" >
+                <div class="file-box-left ">
+                  <div class="file-box-left-content ">
+                    <span class="iconfont icon-Excel excel fs20"></span>
+                  </div>
+                </div>
+                <div class="file-box-center">
+                  <p style="margin-top: 20px"> {{delFile(item.Name)}}</p>
+                  <p> {{delFile(item.CreateTime)}}</p>
+                </div>
+                <div class="file-box-right ">
+                  <span
+                    style="height: 88px;"
+                    class="iconfont icon-download1 df fs20"
+                    @click="download(item.Key)"/>
+                </div>
+              </div>
+
+            </div>
+
+          </div>
+          <div v-else style="text-align: center;margin: 10px auto">暂无数据</div>
+        </div>
+      </div>
+    </div>
+    <div v-else style="text-align: center;margin: 10px auto">暂无数据</div>
+  </div>
+</template>
+
+<script>
+
+  export default {
+    props: ['exhibitionFile'],
+    data() {
+      return {};
+    },
+    created() {
+    },
+    methods: {
+
+      //处理地址
+      delFile(name) {
+        return name && name.length > 20 ? name.substring(0, 20) + "..." : name
+      },
+      //点击下载
+      download(key) {
+        console.log(key)
+        window.open("/image-service/common/file_get/" + key + "?systemId=dataPlatform")
+      },
+
+      //删除图片
+      deleteFile(i, key) {
+        this.filesArr.splice(i, 1);
+        this.$emit("change", this.filesArr, this.defined);
+      },
+
+      //上传
+      uploadAndSubmit(item) {
+        // var form = document.forms["demoForm"];
+
+        // if (form["file"].files.length > 0) {
+        // 寻找表单域中的 <input type="file" ... /> 标签
+        // var file = form["file"].files[0];
+
+        let file = item.file;
+        // try sending
+        let reader = new FileReader();
+
+        let vm = this;
+
+        let fileType = file.name.split(".");
+        let type = fileType[fileType.length - 1];
+        let key = "&key=" + fileType[0] + file.uid + "." + type
+        let CreateTime = tools.formatDate(new Date(file.lastModified))
+        reader.onloadstart = function () {
+          // 这个事件在读取开始时触发
+        };
+        reader.onprogress = function (p) {
+          // 这个事件在读取进行中定时触发
+        };
+
+        reader.onload = function () {
+          // 这个事件在读取成功结束后触发
+        };
+        reader.onloadend = function () {
+          // 这个事件在读取结束后,无论成功或者失败都会触发
+          if (reader.error) {
+          } else {
+            // document.getElementById("bytesRead").textContent = file.size;
+            // 构造 XMLHttpRequest 对象,发送文件 Binary 数据
+            var xhr = new XMLHttpRequest();
+            xhr.open(
+              /* method */
+              "POST",
+              /* target url */
+              "/image-service/common/file_upload?systemId=dataPlatform&secret=9e0891a7a8c8e885&overwrite=true" + key
+              /*, async, default to true */
+            );
+            //xhr.overrideMimeType("application/octet-stream");
+            xhr.send(reader.result);
+            xhr.onreadystatechange = function () {
+              if (xhr.readyState == 4) {
+                console.log(xhr)
+                if (xhr.status == 200) {
+                  let fileObject = {
+                    Key: key.split("=")[1],
+                    Type: type,
+                    Name: file.name,
+                    CreateTime,
+                    SystemId: 'dataPlatform'
+                  }
+                  vm.filesArr.push(fileObject);
+                  vm.$emit("change", vm.filesArr, vm.defined);
+                } else {
+                  this.$message.error(res.data.ResultMsg)
+                }
+              }
+            };
+          }
+        };
+        reader.readAsArrayBuffer(file);
+      }
+    },
+
+  };
+</script>
+
+<style lang="less" scoped>
+  .exhibition-file {
+    .title {
+      /*border-left: 8px solid black;*/
+      margin: 10px;
+      font-weight: 600;
+      text-indent: 10px;
+      display: block;
+      overflow: hidden;
+    }
+
+    .df {
+      display: flex;
+      justify-content: center;
+      align-items: center;
+    }
+
+    .file-box {
+      border: 1px solid #eee;
+      margin: 10px;
+      height: 88px;
+
+      .file-box-left {
+        display: inline-block;
+        width: 20%;
+        height: 100%;
+        overflow: hidden;
+        text-align: center;
+
+        .file-box-left-content {
+          background: #eeeeee;
+          width: 50px;
+          height: 50px;
+          margin: 20px 14px;
+          .excel{
+            display: block;
+            padding-top: 5px;
+          }
+        }
+      }
+
+      .file-box-center {
+        display: inline-block;
+        width: 58%;
+        height: 100%;
+        overflow: hidden;
+        text-align: center;
+      }
+
+      .file-box-right {
+        display: inline-block;
+        width: 19%;
+        height: 100%;
+        overflow: hidden;
+      }
+    }
+
+
+    .df {
+      display: flex;
+      justify-content: center;
+      align-items: center;
+    }
+
+    .fs20 {
+      font-size: 20px;
+    }
+
+    .list-name {
+      text-align: center;
+    }
+  }
+</style>

+ 298 - 0
src/components/ledger/details/detail/lookImage.vue

@@ -0,0 +1,298 @@
+<template>
+  <div id="sagaUploads-look-image">
+    <div class="saga-upload-images">
+      <div v-if="Object.keys(exhibitionImage.list).length">
+        <div v-for="(val,key,i) in exhibitionImage.list" :key="i">
+          <div class="" v-for="(j,index) in val">
+            <p class="title">
+              <span class="iconfont icon-juxing"></span>
+              {{key}}
+            </p>
+            <div v-if="j.PicList !=undefined && j.PicList.length >0">
+              <template v-for="item in j.PicList">
+                <div class="point-look-image">
+                  <img @click="lookImg" :src="imageGetUrl + '&key=' +item.Key" alt v-load style="margin-bottom: 5px">
+                  <p class="pic-name">{{handleName(item.Name)}}</p>
+                </div>
+              </template>
+            </div>
+            <div v-else style="text-align: center;margin: 10px auto">暂无数据</div>
+          </div>
+        </div>
+      </div>
+      <div style="text-align: center" v-else>暂无数据</div>
+    </div>
+    <details-dialog :title="'图片'" :iframeSrc="iframeSrc" :dialog="dialog" :setData="imagesArr"></details-dialog>
+  </div>
+</template>
+<script>
+  import detailsDialog from "@/components/business_space/lib/detailsDia"
+
+  export default {
+    components: {
+      detailsDialog
+    },
+    props: ['exhibitionImage'],
+    data() {
+      return {
+        baseUrl: "",
+        imageGetUrl: "/image-service/common/image_get?systemId=dataPlatform",
+        imageUploadUrl: "/image-service/common/image_upload?systemId=dataPlatform&secret=9e0891a7a8c8e885&overwrite=true",
+        imagesArr: [],
+        iframeSrc: "",
+        dialog: {
+          details: false
+        }
+      };
+    },
+    methods: {
+      handleName(val) {
+        return val && val.length > 10 ? val.substring(1, 10) + '...' : val
+      },
+      //查看图片
+      lookImg() {
+        this.dialog.details = true
+        this.iframeSrc = process.env.BASE_URL + ":8890/photo-View.html"
+      },
+
+      //上传
+      uploadAndSubmit(item, key) {
+        // var form = document.forms["demoForm"];
+
+        // if (form["file"].files.length > 0) {
+        // 寻找表单域中的 <input type="file" ... /> 标签
+        // var file = form["file"].files[0];
+
+        console.log("lalala", item)
+        let file = item.file;
+        // try sending
+        let reader = new FileReader();
+
+        let vm = this;
+
+        let fileType = file.name.split(".");
+        let type = fileType[fileType.length - 1];
+        let CreateTime = tools.formatDate(new Date(file.lastModified))
+
+        let uploadKey = file.uid
+        if (!!key) {
+          uploadKey = key
+        }
+
+        reader.onloadstart = function () {
+          // 这个事件在读取开始时触发
+        };
+        reader.onprogress = function (p) {
+          // 这个事件在读取进行中定时触发
+        };
+
+        reader.onload = function () {
+          // 这个事件在读取成功结束后触发
+        };
+        reader.onloadend = function () {
+          // 这个事件在读取结束后,无论成功或者失败都会触发
+          if (reader.error) {
+          } else {
+            // document.getElementById("bytesRead").textContent = file.size;
+            // 构造 XMLHttpRequest 对象,发送文件 Binary 数据
+            var xhr = new XMLHttpRequest();
+            xhr.open(
+              /* method */
+              "POST",
+              /* target url */
+              vm.imageUploadUrl + "&key=" + uploadKey + "." + type
+              /*, async, default to true */
+            );
+            //xhr.overrideMimeType("application/octet-stream");
+            xhr.send(reader.result);
+            xhr.onreadystatechange = function () {
+              if (xhr.readyState == 4) {
+                if (xhr.status == 200) {
+                  if (vm.type == 'image') {
+                    vm.imagesArr.push({
+                      Name: uploadKey + '',
+                      Key: uploadKey + "." + type,
+                      SystemId: "dataPlatform",
+                      Type: "image",
+                      CreateTime
+                    });
+                  }
+                  if (type == 'mp4') {
+                    vm.imagesArr.push({
+                      Name: uploadKey + '',
+                      Key: uploadKey + "." + type,
+                      SystemId: "dataPlatform",
+                      Type: "video",
+                      CreateTime
+                    });
+                    vm.creatImg(vm.imageGetUrl + "&key=" + uploadKey + "." + type, uploadKey)
+                  }
+                  if (vm.type == "video" && type == "png") {
+                    vm.videoPicArr.push({
+                      Name: uploadKey + '',
+                      Key: uploadKey + "." + type,
+                      SystemId: "dataPlatform",
+                      Type: "image_video",
+                      CreateTime
+                    })
+                  }
+                  vm.$emit("change", vm.imagesArr, vm.defined, vm.videoPicArr);
+                }
+              }
+            };
+          }
+        };
+        reader.readAsArrayBuffer(file);
+      },
+      dataURLtoBlob(dataURI, type) {
+        var binary = atob(dataURI.split(',')[1]);
+        var array = [];
+        for (var i = 0; i < binary.length; i++) {
+          array.push(binary.charCodeAt(i));
+        }
+        return new Blob([new Uint8Array(array)], { type: type });
+      },
+
+      creatImg(reader, key) {
+        var videoDom = document.getElementById('video');
+        videoDom.src = reader;
+        let vm = this
+        videoDom.onloadeddata = function () {
+          // 这里可以打印视频时长
+          // 这里取得视频封面
+          var canvas = document.createElement('canvas');
+          canvas.width = 300;
+          canvas.height = 300 * this.videoHeight / this.videoWidth;
+          canvas.getContext('2d').drawImage(this, 0, 0, canvas.width, canvas.height);
+          //将canvas的base64位图片转换成图片png的file
+          var blob = vm.dataURLtoBlob(canvas.toDataURL('image/png'), "image/png")
+          //将其转换成file对象
+          var file = new File([blob], "video_image.png", { type: "image/png", lastModified: Date.now() })//blob转file
+          vm.uploadAndSubmit({ file: file }, key)
+        }
+      },
+    },
+    watch: {
+      keysArr: function (val) {
+        this.imageFalg();
+      }
+    },
+    //自定义指令
+    directives: {
+      load: function (el) {
+        let imgDom = document.createElement("img");
+        imgDom.style.position = "absolute";
+        imgDom.style.top = "-999px";
+        imgDom.style.opacity = 0;
+        imgDom.src = el.src;
+        el.src = "";
+        imgDom.onload = () => {
+          let width = imgDom.width;
+          let height = imgDom.height;
+          if (width > height) {
+            el.style.height = "100%";
+            el.style.width = "auto";
+            el.style.position = "absolute";
+            el.style.left = "50%";
+            el.style.top = "0";
+            el.style.transform = "translateX(-50%)";
+            el.style.webkitTransform = "translateX(-50%) translateY(0)";
+            el.style.MozTransform = "translateX(-50%) translateY(0)";
+            el.style.msTransform = "translateX(-50%) translateY(0)";
+            el.style.OTransform = "translateX(-50%) translateY(0)";
+          } else if (width < height) {
+            el.src = imgDom.src;
+            el.style.width = "100%";
+            el.style.height = "auto";
+            el.style.position = "absolute";
+            el.style.top = "50%";
+            el.style.left = "0";
+            el.style.transform = "translateY(-50%) translateX(0)";
+            el.style.webkitTransform = "translateY(-50%) translateX(0)";
+            el.style.MozTransform = "translateY(-50%) translateX(0)";
+            el.style.msTransform = "translateY(-50%) translateX(0)";
+            el.style.OTransform = "translateY(-50%) translateX(0)";
+          } else {
+            el.style.width = "100%";
+            el.style.height = "100%";
+            el.style.position = "absolute";
+            el.style.top = "0";
+            el.style.left = "0";
+            el.style.transform = "translateY(0) translateX(0)";
+            el.style.webkitTransform = "translateY(0) translateX(0)";
+            el.style.MozTransform = "translateY(0) translateX(0)";
+            el.style.msTransform = "translateY(0) translateX(0)";
+            el.style.OTransform = "translateY(0) translateX(0)";
+          }
+          el.src = imgDom.src;
+        };
+      }
+    }
+  };
+</script>
+<style lang="less">
+  #sagaUploads-look-image {
+    overflow: hidden;
+
+    .title {
+      /*border-left: 8px solid black;*/
+      margin: 10px 10px 10px 0;
+      font-weight: 600;
+      text-indent: 10px;
+      display: block;
+      overflow: hidden;
+    }
+
+    .avatar-uploader {
+      height: 180px;
+      width: 180px;
+      overflow: hidden;
+
+      .el-upload {
+        width: 180px;
+        height: 180px;
+
+        .el-upload-dragger {
+          width: 180px;
+          height: 180px;
+          .el-icon-plus {
+            display: block;
+            width: 20px;
+            height: 20px;
+            font-size: 20px;
+            margin: 80px;
+          }
+        }
+      }
+    }
+      .pic-name {
+        position: absolute;
+        right: 72px;
+        display: inline-block;
+        background: #fff;
+        color: #000;
+        padding: 3px;
+        z-index: 99;
+        border-radius: 8px;
+        bottom: 5px;
+      }
+    .point-look-image {
+      height: 180px;
+      margin-bottom: 10px;
+      position: relative;
+      overflow: hidden;
+      img {
+        z-index: 11;
+      }
+      i {
+        position: absolute;
+        bottom: 10px;
+        right: 10px;
+        background-color: #fff;
+        padding: 5px;
+        cursor: pointer;
+        z-index: 66;
+      }
+    }
+  }
+</style>

+ 277 - 0
src/components/ledger/details/detail/lookVideo.vue

@@ -0,0 +1,277 @@
+<template>
+  <div id="sagaUploads-look-video">
+    <div class="saga-upload-images">
+      <div v-if="exhibitionVideo.list.length">
+        <template v-for="(item,index) in exhibitionVideo.list">
+          <div class="point-look-video">
+            <video
+              width="100%"
+              height="100%;"
+              :src="imageGetUrl + '&key=' +item.Key"
+              controls="controls"
+            >您的浏览器不支持 video 标签。</video>
+          </div>
+        </template>
+      </div>
+      <div v-else style="text-align: center;margin: 10px auto">暂无数据</div>
+    </div>
+  </div>
+</template>
+<script>
+
+  export default {
+    props: ['exhibitionVideo'],
+    data() {
+      return {
+        baseUrl: "",
+        imageGetUrl: "/image-service/common/image_get?systemId=dataPlatform",
+        imageUploadUrl: "/image-service/common/image_upload?systemId=dataPlatform&secret=9e0891a7a8c8e885&overwrite=true",
+        imagesArr: [],
+        iframeSrc: "",
+        dialog: {
+          details: false
+        }
+      };
+    },
+    methods: {
+      //上传
+      uploadAndSubmit(item, key) {
+        // var form = document.forms["demoForm"];
+
+        // if (form["file"].files.length > 0) {
+        // 寻找表单域中的 <input type="file" ... /> 标签
+        // var file = form["file"].files[0];
+
+        console.log("lalala", item)
+        let file = item.file;
+        // try sending
+        let reader = new FileReader();
+
+        let vm = this;
+
+        let fileType = file.name.split(".");
+        let type = fileType[fileType.length - 1];
+        let CreateTime = tools.formatDate(new Date(file.lastModified))
+
+        let uploadKey = file.uid
+        if (!!key) {
+          uploadKey = key
+        }
+
+        reader.onloadstart = function () {
+          // 这个事件在读取开始时触发
+        };
+        reader.onprogress = function (p) {
+          // 这个事件在读取进行中定时触发
+        };
+
+        reader.onload = function () {
+          // 这个事件在读取成功结束后触发
+        };
+        reader.onloadend = function () {
+          // 这个事件在读取结束后,无论成功或者失败都会触发
+          if (reader.error) {
+          } else {
+            // document.getElementById("bytesRead").textContent = file.size;
+            // 构造 XMLHttpRequest 对象,发送文件 Binary 数据
+            var xhr = new XMLHttpRequest();
+            xhr.open(
+              /* method */
+              "POST",
+              /* target url */
+              vm.imageUploadUrl + "&key=" + uploadKey + "." + type
+              /*, async, default to true */
+            );
+            //xhr.overrideMimeType("application/octet-stream");
+            xhr.send(reader.result);
+            xhr.onreadystatechange = function () {
+              if (xhr.readyState == 4) {
+                if (xhr.status == 200) {
+                  if (vm.type == 'image') {
+                    vm.imagesArr.push({
+                      Name: uploadKey + '',
+                      Key: uploadKey + "." + type,
+                      SystemId: "dataPlatform",
+                      Type: "image",
+                      CreateTime
+                    });
+                  }
+                  if (type == 'mp4') {
+                    vm.imagesArr.push({
+                      Name: uploadKey + '',
+                      Key: uploadKey + "." + type,
+                      SystemId: "dataPlatform",
+                      Type: "video",
+                      CreateTime
+                    });
+                    vm.creatImg(vm.imageGetUrl + "&key=" + uploadKey + "." + type, uploadKey)
+                  }
+                  if (vm.type == "video" && type == "png") {
+                    vm.videoPicArr.push({
+                      Name: uploadKey + '',
+                      Key: uploadKey + "." + type,
+                      SystemId: "dataPlatform",
+                      Type: "image_video",
+                      CreateTime
+                    })
+                  }
+                  vm.$emit("change", vm.imagesArr, vm.defined, vm.videoPicArr);
+                }
+              }
+            };
+          }
+        };
+        reader.readAsArrayBuffer(file);
+      },
+      dataURLtoBlob(dataURI, type) {
+        var binary = atob(dataURI.split(',')[1]);
+        var array = [];
+        for (var i = 0; i < binary.length; i++) {
+          array.push(binary.charCodeAt(i));
+        }
+        return new Blob([new Uint8Array(array)], { type: type });
+      },
+
+      creatImg(reader, key) {
+        var videoDom = document.getElementById('video');
+        videoDom.src = reader;
+        let vm = this
+        videoDom.onloadeddata = function () {
+          // 这里可以打印视频时长
+          // 这里取得视频封面
+          var canvas = document.createElement('canvas');
+          canvas.width = 300;
+          canvas.height = 300 * this.videoHeight / this.videoWidth;
+          canvas.getContext('2d').drawImage(this, 0, 0, canvas.width, canvas.height);
+          //将canvas的base64位图片转换成图片png的file
+          var blob = vm.dataURLtoBlob(canvas.toDataURL('image/png'), "image/png")
+          //将其转换成file对象
+          var file = new File([blob], "video_image.png", { type: "image/png", lastModified: Date.now() })//blob转file
+          vm.uploadAndSubmit({ file: file }, key)
+        }
+      },
+    },
+    watch: {
+      keysArr: function (val) {
+        this.imageFalg();
+      }
+    },
+    //自定义指令
+    directives: {
+      load: function (el) {
+        let imgDom = document.createElement("img");
+        imgDom.style.position = "absolute";
+        imgDom.style.top = "-999px";
+        imgDom.style.opacity = 0;
+        imgDom.src = el.src;
+        el.src = "";
+        imgDom.onload = () => {
+          let width = imgDom.width;
+          let height = imgDom.height;
+          if (width > height) {
+            el.style.height = "100%";
+            el.style.width = "auto";
+            el.style.position = "absolute";
+            el.style.left = "50%";
+            el.style.top = "0";
+            el.style.transform = "translateX(-50%)";
+            el.style.webkitTransform = "translateX(-50%) translateY(0)";
+            el.style.MozTransform = "translateX(-50%) translateY(0)";
+            el.style.msTransform = "translateX(-50%) translateY(0)";
+            el.style.OTransform = "translateX(-50%) translateY(0)";
+          } else if (width < height) {
+            el.src = imgDom.src;
+            el.style.width = "100%";
+            el.style.height = "auto";
+            el.style.position = "absolute";
+            el.style.top = "50%";
+            el.style.left = "0";
+            el.style.transform = "translateY(-50%) translateX(0)";
+            el.style.webkitTransform = "translateY(-50%) translateX(0)";
+            el.style.MozTransform = "translateY(-50%) translateX(0)";
+            el.style.msTransform = "translateY(-50%) translateX(0)";
+            el.style.OTransform = "translateY(-50%) translateX(0)";
+          } else {
+            el.style.width = "100%";
+            el.style.height = "100%";
+            el.style.position = "absolute";
+            el.style.top = "0";
+            el.style.left = "0";
+            el.style.transform = "translateY(0) translateX(0)";
+            el.style.webkitTransform = "translateY(0) translateX(0)";
+            el.style.MozTransform = "translateY(0) translateX(0)";
+            el.style.msTransform = "translateY(0) translateX(0)";
+            el.style.OTransform = "translateY(0) translateX(0)";
+          }
+          el.src = imgDom.src;
+        };
+      }
+    }
+  };
+</script>
+<style lang="less">
+  #sagaUploads-look-video {
+    overflow: hidden;
+
+    .title {
+      border-left: 8px solid black;
+      margin: 10px;
+      font-weight: 600;
+      text-indent: 10px;
+      display: block;
+      overflow: hidden;
+    }
+
+    .avatar-uploader {
+      height: 180px;
+      width: 180px;
+      overflow: hidden;
+
+      .el-upload {
+        width: 180px;
+        height: 180px;
+
+        .el-upload-dragger {
+          width: 180px;
+          height: 180px;
+          .el-icon-plus {
+            display: block;
+            width: 20px;
+            height: 20px;
+            font-size: 20px;
+            margin: 80px;
+          }
+        }
+      }
+    }
+      .pic-name {
+        position: absolute;
+        right: 72px;
+        display: inline-block;
+        background: #fff;
+        color: #000;
+        padding: 3px;
+        z-index: 99;
+        border-radius: 8px;
+        bottom: 5px;
+      }
+
+    .point-look-video {
+      height: 180px;
+      position: relative;
+      overflow: hidden;
+      img {
+        z-index: 11;
+      }
+      i {
+        position: absolute;
+        bottom: 10px;
+        right: 10px;
+        background-color: #fff;
+        padding: 5px;
+        cursor: pointer;
+        z-index: 66;
+      }
+    }
+  }
+</style>

+ 49 - 0
src/components/ledger/details/detail/selectRadio.vue

@@ -0,0 +1,49 @@
+<template>
+  <div class="select-radio">
+    <p class="title">
+      <span class="iconfont icon-juxing"></span>
+      {{selectRadio.information}}
+    </p>
+    <template>
+      <el-radio-group
+        style=" margin: 0 10px;"
+        v-model="selectRadio.initRadio"
+        @change="changeRadio"
+        v-for="(item,index) in selectRadio.radioList"
+        :key="index"
+      >
+        <el-radio :label="item.label">{{item.value}}</el-radio>
+      </el-radio-group>
+    </template>
+  </div>
+</template>
+
+<script>
+  export default {
+    name: "selectRadio",
+    props: ['selectRadio'],
+    data() {
+      return {
+        radio: '1'
+      };
+    },
+    methods: {
+      changeRadio(val) {
+        this.$emit('changeRadio', val)
+      }
+    }
+  }
+</script>
+
+<style scoped lang="less">
+  .select-radio {
+    .title {
+      /*border-left: 8px solid black;*/
+      margin: 10px 40px 10px 10px;
+      font-weight: 600;
+      text-indent: 10px;
+      display: inline-block;
+
+    }
+  }
+</style>

+ 16 - 1
src/components/ledger/handsontables/assets.vue

@@ -751,7 +751,22 @@
           //操作
           case 'caozuo':
             // window.open(`http://adm.sagacloud.cn:8058/spread?id=${infos.EquipID}&pid=${this.projectId}&secret=${this.secret}`,"_blank")
-            this.$message("开发中...")
+            // this.$message("开发中...")
+            this.$router.push({
+              path: "propertyDetails",
+              query: {
+                type: this.mess.deviceId,
+                equipId: infos.EquipID,
+                equipName: infos.EquipLocalName?infos.EquipLocalName:infos.EquipName?infos.EquipName:'',
+                equipCode: infos.EquipLocalID?infos.EquipLocalID:'',
+                data: this.tableData.map(item => {
+                  return {
+                    value: item.EquipID,
+                    label: item.EquipLocalName?item.EquipLocalName:item.EquipName?item.EquipName:''
+                  }
+                })
+              }
+            })
             return false
           //资产二维码图片
           case 'EquipQRCode':

+ 19 - 1
src/components/ledger/handsontables/device.vue

@@ -420,6 +420,7 @@
             if (this.tableData && this.tableData.length) {
               if (this.onlyRead) {
                 this.getBatch(this.tableData)
+
               }
               this.initTable();
             }
@@ -485,6 +486,7 @@
             criterias: []
           }
         }
+
         //一级遍历list
         this.tableHeader.map(head => {
           //如果一级标签为动态参数或者设定参数放入数据等待请求
@@ -507,6 +509,7 @@
         })
         if (param.data.criterias.length) {
           BeatchQueryParam(param, res => {
+
             if (!this.onlyRead) {
               return false
             }
@@ -940,7 +943,22 @@
                 //操作
                 case 'caozuo':
                     // window.open(`http://adm.sagacloud.cn:8058/spread?id=${infos.EquipID}&pid=${this.projectId}&secret=${this.secret}`,"_blank")
-                    this.$message("开发中...")
+                    // this.$message("开发中...")
+                    this.$router.push({
+                      path: "deviceDetails",
+                      query: {
+                        type: this.mess.deviceId,
+                        equipId: infos.EquipID,
+                        equipName: infos.EquipLocalName?infos.EquipLocalName:infos.EquipName?infos.EquipName:'',
+                        equipCode: infos.EquipLocalID?infos.EquipLocalID:'',
+                        data: this.tableData.map(item => {
+                          return {
+                            value: item.EquipID,
+                            label: item.EquipLocalName?item.EquipLocalName:item.EquipName?item.EquipName:''
+                          }
+                        })
+                      }
+                    })
                     return false
                 //设备二维码图片
                 case 'EquipQRCode':

+ 1 - 0
src/components/ledger/lib/cenoteGraphy.vue

@@ -296,6 +296,7 @@ export default {
   position: absolute;
   bottom: 20px;
   left: 50%;
+  width: 352px;
   transform: translateX(-50%);
   z-index: 999;
 }

+ 3 - 3
src/components/model/file/floorTable.vue

@@ -27,9 +27,9 @@
       <el-table-column prop="address" align="center" label="操作" width="240">
         <template slot-scope="scope">
           <div class="operate" v-show="scope.row.Status == 4">
-            <el-button type="primary" size="mini" class="iconfont icon-download" @click="downloadModel(scope.row)"></el-button>
-            <el-button type="primary" size="mini" class="iconfont icon-replace" @click="repliaceModel(scope.row)"></el-button>
-            <el-button type="primary" size="mini" class="iconfont icon-Log" @click="queryModelLog(scope.row)"></el-button>
+            <el-button title="下载模型" type="primary" size="mini" class="iconfont icon-download" @click="downloadModel(scope.row)"></el-button>
+            <el-button title="替换模型" type="primary" size="mini" class="iconfont icon-replace" @click="repliaceModel(scope.row)"></el-button>
+            <el-button title="查看版本日志" type="primary" size="mini" class="iconfont icon-Log" @click="queryModelLog(scope.row)"></el-button>
           </div>
           <div :class="['upLoad-loading']" v-show="scope.row.Status != 4">
             <div class="progress">

+ 1 - 1
src/components/model/file/modelLog.vue

@@ -17,7 +17,7 @@
               <el-table-column prop="UserName" label="上传人"></el-table-column>
               <el-table-column prop="address" label="操作">
                 <template slot-scope="scope">
-                  <el-button @click="handleClick(scope.row)" v-if="!scope.row.Removed" type='primary' size="mini" class="iconfont icon-download"></el-button>
+                  <el-button title="下载模型" @click="handleClick(scope.row)" v-if="!scope.row.Removed" type='primary' size="mini" class="iconfont icon-download"></el-button>
                   <!-- 需求:先不支持删除 -->
                   <!-- <el-button @click="deleteModel(scope.row)" v-if="!scope.row.Removed" type='danger' plain size="mini">删除</el-button> -->
                 </template>

+ 19 - 14
src/components/ready/buildfloor/addBuild.vue

@@ -3,12 +3,13 @@
     :title="buildTitle"
     :visible.sync="buildDialogVis"
     id="messageDialog"
-    width="55%"
+    width="850px"
   >
     <el-form
       :inline="true"
       :model="form"
-      label-width="125px"
+      label-width="160px"
+      :label-position="'right'"
       :rules="rules"
       ref="ruleForm"
     >
@@ -42,10 +43,10 @@
             </el-input>
             <el-select
             placeholder="请选择"
-            v-else-if="item.InputMode == 'D1' || item.InputMode == 'E2'"
+            v-else-if="item.InputMode == 'D1' || item.InputMode == 'E2' || item.InputMode == 'D1L'"
             v-model="form[item.Path]"
           >
-            <el-option :key="op.Code" :label="op.Name" :value="op.Code" v-for="op in item.options"></el-option>
+            <el-option :key="op.Name" :label="op.Name" :value="op.Code" v-for="op in item.options"></el-option>
           </el-select>
         <el-select
           placeholder="请选择"
@@ -55,7 +56,7 @@
           collapse-tags
         >
 
-            <el-option :key="op.Code" :label="op.Name" :value="op.Code" v-for="op in item.options"></el-option>
+            <el-option :key="op.Name" :label="op.Name" :value="op.Code" v-for="op in item.options"></el-option>
           </el-select>
            <el-date-picker
              v-model="form[item.Path]"
@@ -66,15 +67,15 @@
              start-placeholder="开始日期"
              end-placeholder="结束日期"
            />
-             <el-cascader
-               v-else-if="item.InputMode == 'D1L'"
-               placeholder="请选择"
-               :options="item.options"
-               v-model="form[item.Path]"
-               :props="{ checkStrictly: true ,value: 'Code',label:'Name'}"
-               clearable
-               style="width: 200px"
-             />
+<!--             <el-cascader-->
+<!--               v-else-if="item.InputMode == 'D1L'"-->
+<!--               placeholder="请选择"-->
+<!--               :options="item.options"-->
+<!--               v-model="form[item.Path]"-->
+<!--               :props="{ checkStrictly: true ,value: 'Code',label:'Name'}"-->
+<!--               clearable-->
+<!--               style="width: 200px"-->
+<!--             />-->
           <el-input
             v-else-if="item.InputMode == 'L'||item.InputMode == 'L1'||item.InputMode == 'L2'||item.InputMode == 'M'"
             v-model="form[item.Path]">
@@ -275,5 +276,9 @@
       width: 100% !important;
       display: block !important;
     }
+
+    /deep/ .el-input--small {
+      width: 200px
+    }
   }
 </style>

+ 1 - 1
src/components/ready/buildfloor/addConnectivity.vue

@@ -1,5 +1,5 @@
 <template>
-  <el-dialog title="楼层贯通关系维护" :visible.sync="connectDialogVis" width="50%" id="messageDialog">
+  <el-dialog title="楼层贯通关系维护" :visible.sync="connectDialogVis" width="730px" id="messageDialog">
     <el-row>
       <div style="line-height:32px;">添加与{{floor.FloorLocalName}}层有贯通关系的楼层 : </div>
       <div style="width:70%">

+ 6 - 1
src/components/ready/buildfloor/formItems.vue

@@ -1,6 +1,6 @@
 <template>
   <div id="inforsPoint">
-    <el-form ref="ruleForm" :model="form" label-width="150px" :rules="rules" :inline="true" :label-position="'left'">
+    <el-form ref="ruleForm" :model="form" label-width="150px" :rules="rules" :inline="true" :label-position="'right'">
       <div v-for="item in InforsList" :key="item.InfoPointCode" style="width:50%;display: inline-block">
         <el-form-item
           :label="item.InfoPointName"
@@ -120,8 +120,13 @@
       font-size: 12px;
     }
   }
+
   /deep/ .FloorTypeSelect .el-form-item__content {
     width: 200px;
   }
+
+  /deep/ .el-input--small {
+    width: 200px
+  }
 }
 </style>

+ 230 - 37
src/components/ready/buildfloor/uploadFile.vue

@@ -1,56 +1,249 @@
+<!--
+  上传组件
+  type: 类型,默认image
+  identify: key值,通过val获取
+  disabled: 是否可用
+  index: 父组件的下标
+  imageIndex: 图片下标
+  isShow: 图片的显示
+ -->
 <template>
-  <el-upload
-    :before-remove="beforeRemove"
-    :file-list="fileList"
-    :limit="3"
-    :on-exceed="handleExceed"
-    :on-preview="handlePreview"
-    :on-remove="handleRemove"
-    action="https://jsonplaceholder.typicode.com/posts/"
-    class="upload-demo"
-    multiple>
-    <p
-      class="el-form-item__label"
-      style="width: 125px"
-    >{{name}}:</p>
-    <el-button
-      size="small"
-      type="text"
-    >点击上传
-    </el-button>
-    <!--    <div slot="tip" class="el-upload__tip">只能上传jpg/png文件,且不超过500kb</div>-->
-  </el-upload>
+  <div id="saga-upload">
+    <div id="uploadFile">
+      <el-upload
+        class="upload-file"
+        action
+        :http-request="uploadAndSubmit"
+        :show-file-list="false"
+        drag
+      >
+        <el-button
+          size="small"
+          :type="isShow ===1 ? 'text':'primary'"
+          v-if="!readOnly"
+        >点击上传</el-button>
+        <span v-if="isShow !== 1 || isShow == undefined">
+          <div
+            slot="tip"
+            class="el-upload__tip"
+            v-if="!readOnly"
+          >请上传文件</div>
+        </span>
+
+      </el-upload>
+      <div
+        v-if="item && filesArr.length"
+        v-for="(item,index) in filesArr"
+      >
+        <el-button
+          type="text"
+          @click="download(item.Key)"
+        >
+          {{delFile(item.Name)}}</el-button>
+        <i
+          v-if="!readOnly"
+          class="el-icon-close delete-icon"
+          style="margin-left:10px; cursor:pointer"
+          @click="deleteFile(index,item)"
+        ></i>
+      </div>
+    </div>
+  </div>
 </template>
 
 <script>
+  import tools from "@/utils/scan/tools";
+
   export default {
-    name: "uploadFile",
-    props: ['name'],
+    props: {
+      keysArr: {
+        type: [Array, String],
+        default: function () {
+          return []
+        }
+      },
+      readOnly: {
+        type: Boolean,
+        default: false
+      },
+      max: {
+        type: [Number, String],
+        default: 6
+      },
+      isShow: {
+        type: Number
+      },
+      contextKey: {
+        type: [String, Object]
+      },
+      defined: null
+    },
     data() {
       return {
-        fileList: [
-          // {name: 'food.jpeg', url: 'https://fuss10.elemecdn.com/3/63/4e7f3a15429bfda99bce42a18cdd1jpeg.jpeg?imageMogr2/thumbnail/360x360/format/webp/quality/100'},
-          // {name: 'food2.jpeg', url: 'https://fuss10.elemecdn.com/3/63/4e7f3a15429bfda99bce42a18cdd1jpeg.jpeg?imageMogr2/thumbnail/360x360/format/webp/quality/100'}
-        ]
+        filesArr: []
       };
     },
+    created() {
+      this.fileFalg()
+    },
     methods: {
-      handleRemove(file, fileList) {
-        console.log(file, fileList);
+      //判断是否为空
+      fileFalg() {
+        let type = typeof (this.keysArr)
+        if (type == 'string') {
+          this.filesArr = [this.keysArr]
+          // this.filesArr = JSON.parse(this.keysArr)
+        } else {
+          this.filesArr = tools.deepCopy(this.keysArr)
+        }
+
+        if (!this.keysArr) {
+          this.filesArr = []
+        }
+      },
+      //处理地址
+      delFile(name) {
+        return name.length > 20 ? name.substring(0, 20) + "..." : name
       },
-      handlePreview(file) {
-        console.log(file);
+
+      resetFile() {
+        this.filesArr = []
       },
-      handleExceed(files, fileList) {
-        this.$message.warning(`当前限制选择 3 个文件,本次选择了 ${files.length} 个文件,共选择了 ${files.length + fileList.length} 个文件`);
+
+
+      //点击下载
+      download(key) {
+        console.log(key)
+        window.open("/image-service/common/file_get/" + key + "?systemId=dataPlatform")
       },
-      beforeRemove(file, fileList) {
-        return this.$confirm(`确定移除 ${file.name}?`);
+
+      //删除图片
+      deleteFile(i, key) {
+        this.filesArr.splice(i, 1);
+        this.$emit("change", this.filesArr, this.defined);
+      },
+
+      //上传
+      uploadAndSubmit(item) {
+        // var form = document.forms["demoForm"];
+
+        // if (form["file"].files.length > 0) {
+        // 寻找表单域中的 <input type="file" ... /> 标签
+        // var file = form["file"].files[0];
+
+        let file = item.file;
+        // try sending
+        let reader = new FileReader();
+
+        let vm = this;
+
+        let fileType = file.name.split(".");
+        let type = fileType[fileType.length - 1];
+        let key = "&key=" + fileType[0] + file.uid + "." + type
+        let CreateTime = tools.formatDate(new Date(file.lastModified))
+        reader.onloadstart = function () {
+          // 这个事件在读取开始时触发
+        };
+        reader.onprogress = function (p) {
+          // 这个事件在读取进行中定时触发
+
+        };
+        reader.onUploadProgress = function (progressEvent) {
+          let percent = (progressEvent.loaded / progressEvent.total * 100) | 0
+          //调用onProgress方法来显示进度条,需要传递个对象 percent为进度值
+          uploader.onProgress({percent: percent})
+        }
+        reader.onload = function () {
+          // 这个事件在读取成功结束后触发
+        };
+        reader.onloadend = function () {
+          // 这个事件在读取结束后,无论成功或者失败都会触发
+          if (reader.error) {
+          } else {
+            // document.getElementById("bytesRead").textContent = file.size;
+            // 构造 XMLHttpRequest 对象,发送文件 Binary 数据
+            var xhr = new XMLHttpRequest();
+            xhr.open(
+              /* method */
+              "POST",
+              /* target url */
+              "/image-service/common/file_upload?systemId=dataPlatform&secret=9e0891a7a8c8e885&overwrite=true" + key
+              /*, async, default to true */
+            );
+            //xhr.overrideMimeType("application/octet-stream");
+            xhr.send(reader.result);
+            xhr.onreadystatechange = function () {
+              if (xhr.readyState == 4) {
+                console.log(xhr)
+                if (xhr.status == 200) {
+                  let fileObject = {
+                    Key: key.split("=")[1],
+                    Type: type,
+                    Name: file.name,
+                    CreateTime,
+                    SystemId: 'dataPlatform'
+                  }
+                  vm.filesArr.push(fileObject);
+
+                  if(vm.isShow === 1) {
+                    let oFile = {}
+                    oFile[vm.contextKey] = vm.filesArr
+                    vm.$emit("change", oFile, vm.defined);
+                  } else {
+                    vm.$emit("change", vm.filesArr, vm.defined);
+                  }
+                } else {
+                  this.$message.error(res.data.ResultMsg)
+                }
+              }
+            };
+          }
+        };
+        reader.readAsArrayBuffer(file);
+      }
+    },
+    watch: {
+      keysArr: function (val) {
+        this.fileFalg()
       }
     }
-  }
+  };
 </script>
 
-<style scoped>
+<style lang="less">
+  #saga-upload {
+    .dill-image {
+      position: absolute;
+      right: 0;
+      top: 0;
+      font-size: 20px;
+    }
 
+    .el-upload-dragger {
+      width: 180px;
+      height: 180px;
+    }
+
+    img {
+      position: absolute;
+      top: 0;
+      bottom: 0;
+      left: 0;
+      right: 0;
+      width: 100%;
+      height: 100%;
+    }
+
+    #uploadFile {
+      .upload-file {
+        overflow: hidden;
+
+        .el-upload-dragger {
+          width: inherit;
+          height: inherit;
+          border: none;
+        }
+      }
+    }
+  }
 </style>

+ 17 - 10
src/components/relation/overview/CardList.vue

@@ -133,7 +133,7 @@
                           v-if="relation.IsSource"
                         >
                           <el-button
-                            @click="equipment"
+                            @click="equipment(relation)"
                             type="primary"
                             plain
                             circle
@@ -184,6 +184,7 @@
           cancel: '取消',
           confirm: '确定',
           back: '返回',
+          preservation:'保存',
           promptly: '立即计算',
           placeholder: '请选择',
           download: '下载模板(含数据)',
@@ -205,7 +206,8 @@
           dataFailed: '数据文件验证失败',
           allUpdateSuccess: 'xxxx全部更新成功',
           portionUpdateSuccess: ' xxxx关系部分更新成功',
-          downloadFile: ' 下载报告文件'
+          downloadFile: ' 下载报告文件',
+          equipmentSetting:''
         },
         isComputed: {}, // 当前要计算的对象
         ManualMaintenance: {},//手动编辑对象
@@ -238,7 +240,8 @@
           return false
         }
       },
-      equipment() {
+      equipment(relation) { //配置源端末端
+        this.values.equipmentSetting=`${relation.RelationTypeName} 源末端关系设置`
         this.$refs.maintain.dialogEquipment = true
       },
       manual(relation) {
@@ -253,16 +256,20 @@
           this.$refs.maintain.dialogManualTip = true
         }
         if (Manual === 3) {
+          // if (relation.RelManualType) {
           if (relation.RelationType) {
             this.values = {...this.values, optionTips, lastTime}
-            this.$refs.maintain.dialogManualOption = true //导出excel 弹窗
-            // this.$router.push({
-            //   path:"relationShip"
-            // })
+            // this.$refs.maintain.dialogManualOption = true //导出excel 弹窗
+            this.$router.push({
+              path:"relationShip"
+            })
             console.log(relation,'relation')
-          // localStorage.setItem('RelManualType',relation.RelManualType)
-          // localStorage.setItem('RelationType',relation.RelationType)
-          // localStorage.setItem('ZoneType',relation.ZoneType)
+          localStorage.setItem('RelManualType',relation.RelManualType)
+          localStorage.setItem('RelationTypeName',relation.RelationTypeName)
+          localStorage.setItem('RelationType',relation.RelationType)
+          localStorage.setItem('ZoneType',relation.ZoneType)
+          localStorage.setItem('MainObject',relation.MainObject)
+          localStorage.setItem('FromObject',relation.FromObject)
           } else {
             this.$message.warning("设计中")
             return false

+ 54 - 11
src/components/relation/overview/Modal/RelationMaintain.vue

@@ -29,9 +29,9 @@
       >
         <p class="font-big">{{values.existComputed}}</p>
         <p class="exist-title">{{values.existTitle}}</p>
-        <el-row :span="24">
+        <el-row :span="24" style="margin-top: 10px">
           <el-col :span="8">
-            <span class="demonstration">{{values.originEquipment}}</span>
+            <p class="demonstration">{{values.originEquipment}}</p>
             <el-cascader
                 :key="isResouceShow"
                 :options="list"
@@ -43,7 +43,7 @@
             />
           </el-col>
           <el-col :span="8">
-            <span class="demonstration">{{values.endEquipment}}</span>
+            <p class="demonstration">{{values.endEquipment}}</p>
 
             <el-cascader
                 :options="list"
@@ -71,19 +71,62 @@
       </div>
     </el-dialog>
     <!--设定设备对象源/末端-->
+    <!--    <el-dialog-->
+    <!--        :title="values.title"-->
+    <!--        :visible.sync="dialogEquipment"-->
+    <!--    >-->
+    <!--      <span class="font-big">{{values.underDesign}}</span>-->
+    <!--      <footer-->
+    <!--          slot="footer"-->
+    <!--          class="dialog-footer"-->
+    <!--      >-->
+    <!--        <el-button-->
+    <!--            type="primary"-->
+    <!--            @click="dialogEquipment = false"-->
+    <!--        >{{values.confirm}}-->
+    <!--        </el-button>-->
+    <!--      </footer>-->
+    <!--    </el-dialog> -->
     <el-dialog
-        :title="values.title"
-        :visible.sync="dialogEquipment"
+      :title="values.title"
+      :visible.sync="dialogEquipment"
     >
-      <span class="font-big">{{values.underDesign}}</span>
+      <h4>{{values.equipmentSetting}}</h4>
+      <el-row :span="24" style="margin-top: 15px">
+        <el-col :span="8">
+          <p class="">{{values.originEquipment}}</p>
+          <el-cascader
+            :key="isResouceShow"
+            :options="list"
+            v-model="ops"
+            :props="props"
+            collapse-tags
+            clearable
+          />
+        </el-col>
+        <el-col :span="8">
+          <p class="">{{values.endEquipment}}</p>
+          <el-cascader
+            :options="list"
+            v-model="filterOps"
+            :key="isResouceShow"
+            :props="props"
+            collapse-tags
+            clearable
+          />
+        </el-col>
+      </el-row>
+
       <footer
-          slot="footer"
-          class="dialog-footer"
+        slot="footer"
+        class="dialog-footer"
       >
+        <el-button @click="dialogEquipment = false">{{values.cancel}}</el-button>
+
         <el-button
-            type="primary"
-            @click="dialogEquipment = false"
-        >{{values.confirm}}
+          type="primary"
+          @click="dialogEquipment = false"
+        >{{values.preservation}}
         </el-button>
       </footer>
     </el-dialog>

+ 36 - 6
src/components/relation/relationShip/Modal/addRelationShip.vue

@@ -33,35 +33,39 @@
               v-for="item in optionsCode"
               :key="item.value"
               :label="item.label"
-              :value="item.value">
+              :value="item.value"
+            >
             </el-option>
           </el-select>
         </el-form-item>
         <el-row class="mb-20">
           <el-col :span="12">
             <p class="mb-20">{{values.mainObject}}
-              <span class="fw-bold color-AAA">(包括:XXXX类型,XXXX类型)限制条件</span>
+              <span class="fw-bold color-AAA">{{MainObject}}</span>
             </p>
             <el-form-item
               prop="main"
+              :error="mainError"
             >
               <el-input
                 v-model="ruleForm.main"
                 autocomplete="off"
                 :placeholder="values.pleaseEnterCode"
                 :disabled="disabled"
+
               />
             </el-form-item>
           </el-col>
           <el-col :span="12">
             <p class="mb-20">{{values.affiliatedObject}}
-              <span class="fw-bold color-AAA ">(包括:XXXX类型,XXXX类型)限制条件</span>
+              <span class="fw-bold color-AAA ">{{FromObject}}</span>
             </p>
             <el-form-item
               v-for="(item,index) in ruleForm.codeList"
               :key="index"
               :prop="`codeList.${index}.value`"
               :rules="rules.codeList"
+              :error="fromError"
             >
               <el-input
                 v-model="item.value"
@@ -107,6 +111,8 @@
 </template>
 
 <script>
+  import {relAdd} from "../../../../api/relation/api";
+
   export default {
     name: "addRelationShip",
     props: ['values'],
@@ -121,9 +127,12 @@
       }
       var codeList = (rule, value, callback) => {
         //TODO
+        console.log(value)
         callback()
       }
       return {
+        mainError:'',
+        fromError:'',
         addShipDialog: false,
         // disabled: true,
         optionsCode: [{
@@ -143,8 +152,9 @@
           label: '本地名称'
         }],
         codeValue: '',
+        MainObject: `(包括:${localStorage.getItem('MainObject')} )限制条件`,
+        FromObject: `(包括:${localStorage.getItem('FromObject')} )限制条件`,
         ruleForm: {
-          code: '',
           main: '',
           codeList: [{
             value: ''
@@ -172,8 +182,8 @@
       },
 
     },
+    watch:{},
     methods: {
-
       addCode() {
         this.ruleForm.codeList.push({
           value: '',
@@ -188,6 +198,7 @@
       },
       submitForm(formName) {
         this.$refs[formName].validate(valid => {
+          console.log(valid,'valid')
           if (valid) {
             let arr = []
             for(let item  of this.ruleForm.codeList) {
@@ -201,9 +212,28 @@
               RelType:localStorage.getItem('RelManualType'),
               Type:this.codeValue
             }
-            this.$emit('addShip',param)
             //清空添加value
+            let that = this
+            relAdd(param).then(res => {
+              if (res.data.Result === "failure") {
+                if(res.data.ErrorType == 1) {
+                  // this.mainError = res.data.Message
+                  this.$nextTick(()=>{this.mainError = res.data.Message})
+                } else if(res.data.ErrorType == 2) {
+                  this.$nextTick(()=>{this.fromError = res.data.Message})
+                } else {
+                  this.$message.error(res.data.Message);
+                }
 
+              } else if (res.data.Result === "success") {
+                this.$message.success(res.data.Message);
+                this.$emit('update')
+                that.addShipDialog = false
+                that.codeValue = ''
+                that.ruleForm.codeList = [{value:''}]
+                that.ruleForm.main = ''
+              }
+            })
 
           } else {
             console.log('error')

+ 84 - 55
src/router/system.js

@@ -1,31 +1,21 @@
 import LayoutMain from '@/framework/layout/Main'
 import MsgAllDetails from "@/framework/components/messagesever/msgAllDetails"
-
-import Login from '@/framework/layout/Login'
 import Dasboard from '@/views/dasboard'
-
-import UserList from '@/views/system/user/UserList'
-import RoleList from '@/views/system/role/RoleList'
-import ChangePwd from '@/views/system/pwd/ChangePwd'
-
 /**项目管理 */
 import projectAdm from '@/views/platfrom/project'
 import userAdm from '@/views/platfrom/user'
 import roleAdm from '@/views/platfrom/role'
-
 /**前期准备 */
 import buildFloor from '@/views/ready/buildfloor'
 import collectsetting from '@/views/ready/collectsetting'
 import buildUser from '@/views/ready/appuser'
 import repetitionGraphy from '@/views/ready/buildfloor/repetitionGraphy'
-
 /**模型管理 */
 import modelFile from '@/views/model/file'
 import pathControl from '@/views/model/file/pathcontrol'
 import modelReport from '@/views/model/report'
 import deleted from '@/views/model/report/deleted'
 import supplement from '@/views/model/report/supplement'
-
 /**系统集成 */
 import pointConfig from '@/views/point/config_point'
 import editDataSouce from '@/views/point/config_point/edit_origin'
@@ -41,7 +31,6 @@ import buildRela from '@/views/point/dynamicdata/addRelation/buildRela'
 import floorRela from '@/views/point/dynamicdata/addRelation/floorRela'
 import tenantRela from '@/views/point/dynamicdata/addRelation/tenantRela'
 import projectRela from '@/views/point/dynamicdata/addRelation/projectRela'
-
 /** 扫楼作业 */
 import buildTask from '@/views/data_admin/buildTask'
 import addDeviceTask from '@/views/data_admin/buildTask/addTask/addDeviceTask'
@@ -53,12 +42,13 @@ import buildData from '@/views/data_admin/buildData'
 import buildGraphy from '@/views/data_admin/buildGraphy'
 import updatePointZone from '@/views/data_admin/buildGraphy/updatePointZone'
 import createPointZone from '@/views/data_admin/buildGraphy/createPointZone'
-
 /**  台账管理 */
 import systemLedger from '@/views/ledger/system'
 import systemadd from '@/views/ledger/system/addsystem'
 import systemDetail from '@/views/ledger/system/systemDetail'
 import facilityLedger from '@/views/ledger/facility'
+import deviceDetails from "@/views/ledger/facility/details";
+import propertyDetails from "@/views/ledger/property/details";
 import partsLedger from '@/views/ledger/facility/parts'
 import partsmanageLedger from '@/views/ledger/facility/partsmanage'
 import partsadd from '@/views/ledger/facility/partsmanage/addparts'
@@ -79,7 +69,6 @@ import auth from '@/views/system/auth'
 import noUser from '@/views/system/nouser'
 import spaceDetail from '@/views/ledger/spacelist/spaceDetail'
 import relatedSpace from '@/views/ledger/cenotelist/relatedSpace'
-
 /**  关系维护并计算 */
 import maintain from '@/views/relation/maintain'
 import overView from '@/views/relation/overview'
@@ -87,20 +76,17 @@ import relationShip from '@/views/relation/relationShip'
 import relationDetail from '@/views/relation/overview/detail'
 import data from '@/views/relation/data'
 import datatable from '@/views/relation/datatable'
-
 /**  厂家库 */
-import supplier from '@/views/manufactor/supplier'
-
 /**  辅助屏 */
 import splitScreen from '@/views/screen/splitScreen'
 import spaceLedger from '@/views/screen/splitScreen/spaceledger'
 import equipLedger from '@/views/screen/splitScreen/equipledger'
 import integrateResults from '@/views/screen/splitScreen/integrateresults'
-
 /**  业务空间数据导入工具 */
 import dataUtil from '@/views/business_space/dataUtil/index'
 import dataUtil2 from '@/views/business_space/dataUtil/index2'
 import checkJsonUtil from '@/views/business_space/dataUtil/checkJsonUtil'
+import topology from '@/views/business_space/dataUtil/topology'
 
 /**市场及商务 */
 const OwnerManage = () =>
@@ -126,7 +112,8 @@ export default [{
         children: [
             { path: 'index', component: dataUtil },
             { path: 'index2', component: dataUtil2 },
-            { path: 'checkJsonUtil', component: checkJsonUtil }
+            { path: 'checkJsonUtil', component: checkJsonUtil },
+            { path: 'topology', component: topology },
         ]
     },
     // 辅助屏
@@ -352,48 +339,90 @@ export default [{
         name: 'LayoutMain',
         component: LayoutMain,
         children: [
-            { path: '', name: 'Dasboard', component: Dasboard },
-            {
-                path: 'facility',
-                name: 'facilityLedger',
-                component: facilityLedger,
-                meta: { keepAlive: false, breadcrumbs: [{ label: '台账管理', path: '/ledger/facility' }, { label: '设备台账' }] }
-            },
-            {
-                path: 'parts',
-                name: 'partsLedger',
-                component: partsLedger,
-                meta: { keepAlive: false, breadcrumbs: [{ label: '台账管理', path: '/ledger/facility' }, { label: '包含的部件' }] }
-            },
-            {
-                path: 'partsmanage',
-                name: 'partsmanageLedger',
-                component: partsmanageLedger,
-                meta: { keepAlive: false, breadcrumbs: [{ label: '台账管理', path: '/ledger/facility' }, { label: '管理部件' }] },
-            },
-            {
-                path: 'partsadd',
-                name: 'partsadd',
-                component: partsadd,
-                meta: { keepAlive: false, breadcrumbs: [{ label: '台账管理', path: '/ledger/facility' }, { label: '设备台账', path: '/ledger/facility' }, { label: '添加部件' }] },
-            },
-            {
-                path: 'deviceadd',
-                name: 'deviceadd',
-                component: deviceadd,
-                meta: { keepAlive: false, breadcrumbs: [{ label: '台账管理', path: '/ledger/facility' }, { label: '设备台账', path: '/ledger/facility' }, { label: '添加设备' }] }
-            },
-            {
-                path: 'batchlinkAssets',
-                name: 'batchlinkAssets',
-                component: batchlinkAssets,
-                meta: { keepAlive: false, breadcrumbs: [{ label: '台账管理', path: '/ledger/facility' }, { label: '设备台账', path: '/ledger/facility' }, { label: '批量关联资产' }] }
-            },
+          {path: '', name: 'Dasboard', component: Dasboard},
+          {
+            path: 'facility',
+            name: 'facilityLedger',
+            component: facilityLedger,
+            meta: {keepAlive: false, breadcrumbs: [{label: '台账管理', path: '/ledger/facility'}, {label: '设备台账'}]}
+          },
+          {
+            path: 'deviceDetails', 
+            name: 'deviceDetails', 
+            component: deviceDetails,
+            meta: {
+							keepAlive: false, 
+							breadcrumbs: [
+								{label: '台账管理', path: '/ledger/facility'},
+								{label: '设备台账', path: '/ledger/facility'}, 
+								{label: '台账详情'}
+							]
+            }
+          },
+          {
+            path: 'parts',
+            name: 'partsLedger',
+            component: partsLedger,
+            meta: {keepAlive: false, breadcrumbs: [{label: '台账管理', path: '/ledger/facility'}, {label: '包含的部件'}]}
+          },
+          {
+            path: 'partsmanage',
+            name: 'partsmanageLedger',
+            component: partsmanageLedger,
+            meta: {keepAlive: false, breadcrumbs: [{label: '台账管理', path: '/ledger/facility'}, {label: '管理部件'}]},
+          },
+          {
+            path: 'partsadd',
+            name: 'partsadd',
+            component: partsadd,
+            meta: {
+              keepAlive: false,
+              breadcrumbs: [{label: '台账管理', path: '/ledger/facility'}, {
+                label: '设备台账',
+                path: '/ledger/facility'
+              }, {label: '添加部件'}]
+            },
+          },
+          {
+            path: 'deviceadd',
+            name: 'deviceadd',
+            component: deviceadd,
+            meta: {keepAlive: false,
+              breadcrumbs: [{label: '台账管理', path: '/ledger/facility'}, {
+                label: '设备台账',
+                path: '/ledger/facility'
+              }, {label: '添加设备'}]
+            }
+          },
+          {
+            path: 'batchlinkAssets',
+            name: 'batchlinkAssets',
+            component: batchlinkAssets,
+            meta: {keepAlive: false,
+              breadcrumbs: [{label: '台账管理', path: '/ledger/facility'}, {
+                label: '设备台账',
+                path: '/ledger/facility'
+              }, {label: '批量关联资产'}]
+            }
+          },
             {
                 path: 'property',
                 name: 'propertyLedger',
                 component: propertyLedger,
                 meta: { keepAlive: false, breadcrumbs: [{ label: '台账管理', path: '/ledger/facility' }, { label: '资产台账' }] }
+			},
+            {
+                path: 'propertyDetails', 
+                name: 'propertyDetails', 
+                component: propertyDetails,
+                meta: {
+                    keepAlive: false, 
+                    breadcrumbs: [
+                        {label: '台账管理', path: '/ledger/facility'},
+                        {label: '资产台账', path: '/ledger/property'}, 
+                        {label: '资产详情'}
+                    ]
+                }
             },
             {
                 path: 'propertyadd',

+ 21 - 1
src/utils/scan/tools.js

@@ -553,7 +553,27 @@ tools.setDataForKey = function (data, key, value) {
     }
   }
 }
+tools.flattenKeys = function (obj) {
+  let res = {}
 
+  function isObject(val) {
+    return typeof val === 'object' && !Array.isArray(val)
+  }
+
+  function digKeys(prev, obj) {
+    Object.entries(obj).forEach(([key, value]) => {
+      const currentKey = prev ? `${prev}.${key}` : key
+      if (isObject(value)) {
+        digKeys(currentKey, value)
+      } else {
+        res[currentKey] = value
+      }
+    })
+  }
+
+  digKeys('', obj)
+  return res
+}
 function dateToDate(date) {
   var sDate = new Date();
   if (typeof date == 'object' && typeof new Date().getMonth == "function") {
@@ -567,4 +587,4 @@ function dateToDate(date) {
   return sDate;
 }
 
-export default tools
+export default tools

+ 256 - 0
src/views/business_space/dataUtil/topology.vue

@@ -0,0 +1,256 @@
+<template>
+  <!-- 拓扑图demo -->
+  <el-container>
+    <el-aside width="200px" class="el-scrollbar">
+      <div style="height: 300px;">
+        <el-input type="textarea" v-model="ModelID" placeholder='输入业务空间轮廓线,三维数组,X,Y,Z均为大写;或者模型ID' style="height: 100%;"></el-input>
+      </div>
+      <div title="上传json文件">
+        <el-button size="mini" @click="clickInputFile" icon="el-icon-upload"></el-button>
+        <input type="file" @change="filechange" ref="file">
+      </div>
+      <div title="适配底图">
+        <el-button size="mini" @click="fitClick" icon="el-icon-crop"></el-button>
+      </div>
+      <div title="切割">
+        <el-button size="mini" @click="cut" icon="el-icon-edit"></el-button>
+      </div>
+      <div title="清除">
+        <el-button size="mini" @click="clear" icon="el-icon-refresh-left"></el-button>
+      </div>
+      <div title="定位">
+        <el-button size="mini" @click="location" icon="el-icon-position"></el-button>
+      </div>
+      <div title="开启/关闭吸附">
+        <el-button size="mini" @click="absorb" icon="el-icon-price-tag"></el-button>
+      </div>
+      <div title="矩形选择">
+        <el-button size="mini" @click="rectSelection" icon="el-icon-mouse"></el-button>
+      </div>
+      <div title="通过模型ID生成平面图">
+        <el-button size="mini" icon="el-icon-s-promotion" @click="modelChange"></el-button>
+      </div>
+      <div title="通过轮廓线生成业务空间">
+        <el-button size="mini" @click="showOutline" icon="el-icon-magic-stick"></el-button>
+      </div>
+      <div title="打印">
+        <el-button size="mini" @click="console" icon="el-icon-printer"></el-button>
+      </div>
+    </el-aside>
+    <el-main>
+      <div ref="graphy" v-loading="loading" element-loading-text="拼命加载中" element-loading-spinner="el-icon-loading"
+        element-loading-background="rgba(0, 0, 0, 0.8)" style="height: 100%">
+        <canvas id="bg" :width="canvasWidth" :height="canvasHeight" ref="canvas" tabindex="0"></canvas>
+      </div>
+    </el-main>
+  </el-container>
+</template>
+<script>
+
+import { SGraphyScene } from "@saga-web/graphy/lib/";
+import { DivideFloorScene, LocationPointScene } from "@saga-web/cad-engine/lib";
+import { FloorView } from "@saga-web/cad-engine/lib/FloorView";
+export default {
+  data() {
+    return {
+      view: null,
+      scene: null,
+      flag: undefined,
+      show: true,
+      loading: false,
+      canvasWidth: 800,
+      canvasHeight: 800,
+      ModelID: "4cea832a217c11ea962ac576d98e7540"
+    }
+  },
+  mounted() {
+    this.canvasWidth = this.$refs.graphy.offsetWidth;
+    this.canvasHeight = this.$refs.graphy.offsetHeight;
+    this.createGraphy();
+    document.onkeydown = E => {
+      console.log(E)
+    }
+    window.onresize = () => {
+      this.canvasWidth = this.$refs.graphy.offsetWidth;
+      this.canvasHeight = this.$refs.graphy.offsetHeight;
+    }
+  },
+  beforeCreate() {
+    // 读取文件
+    FileReader.prototype.reading = function ({ encode } = pms) {
+      let bytes = new Uint8Array(this.result);    //无符号整型数组
+      let text = new TextDecoder(encode || 'UTF-8').decode(bytes);
+      return text;
+    };
+    /* 重写readAsBinaryString函数 */
+    FileReader.prototype.readAsBinaryString = function (f) {
+      if (!this.onload)       //如果this未重写onload函数,则创建一个公共处理方式
+        this.onload = e => {  //在this.onload函数中,完成公共处理
+          let rs = this.reading();
+          console.log(rs);
+        };
+      this.readAsArrayBuffer(f);  //内部会回调this.onload方法
+    };
+  },
+  methods: {
+    createGraphy() {
+      let that = this;
+      // this.disableRightButton()
+      this.clearGraphy()
+      that.scene = new DivideFloorScene();
+      this.loading = true;
+      that.scene.getFloorData('/modelapi/base-graph/query', { ModelId: this.ModelID }).then(res => {
+        if (res.Result == 'failure') {
+          this.$message.warning(res.Message)
+        }
+        console.log(res)
+        that.view.scene = that.scene;
+        that.view.fitSceneToView();
+        this.loading = false;
+      }).catch(err => {
+        console.log(err)
+      })
+    },
+    // 清除canvas
+    clearGraphy() {
+      if (this.view) {
+        this.view.scene = null;
+        return
+      }
+      this.view = new FloorView('bg')
+    },
+    fitClick() {
+      this.view.fitSceneToView();
+    },
+    showSpace() {
+      this.show = !this.show
+      // this.scene.isShowDoor = this.show
+      // this.scene.isShowSpace = this.show
+      this.scene.spaceList.map(t => {
+        if (!t.selected) {
+          t.visible = false;
+        }
+      })
+      this.scene.isShowColumn = this.show
+      // Opt.spaceColor = new SColor(100,100,100,100);
+    },
+    disableRightButton() {
+      this.$refs.canvas.addEventListener('contextmenu', (e) => {
+        console.log(e)
+        e.preventDefault();
+      })
+      this.scene.isShowSpace = false
+    },
+    cut() {
+      this.scene.isMarking = true;
+      console.log(this.scene)
+    },
+    console() {
+      console.log(this.scene.getSelectedSpaces())
+      this.scene.isShowColumn = false
+      this.scene.isShowWall = false
+    },
+    clear() {
+      this.scene.clearSceneMark()
+    },
+    location() {
+      // console.log(this)
+      this.view.fitSelectedToView()
+    },
+    move() {
+      this.view.isMoving = !this.view.isMoving;
+    },
+    absorb() {
+      this.scene.isAbsorbing = !this.scene.isAbsorbing;
+    },
+    rectSelection() {
+      this.scene.isRectSelection = 1;
+      console.log(this.scene)
+    },
+    showOutline() {
+      try {
+        let outline = JSON.parse(this.ModelID)
+        console.log(outline)
+        let obj = {
+          RoomLocalName: '哈哈哈哈',
+          OutLine: outline,
+          RoomID: 12312,
+          Color: "#006bd6",
+          Height: 5000,
+          HeightLightFlag: true
+        }
+        this.scene.removeAllZone()
+        this.scene.addZone(obj);
+        this.scene.zoneList[0].selected = true;
+        this.view.fitSelectedToView();
+      } catch (err) {
+        alert('格式不正确')
+      }
+    },
+    filechange(e) {
+      let file = e.target.files[0]
+      this.read(file)
+    },
+    read(f) {
+      let rd = new FileReader();
+      this.loading = true;
+      rd.onload = e => {
+        //this.readAsArrayBuffer函数内,会回调this.onload函数。在这里处理结果
+        let cont = rd.reading({ encode: 'UTF-8' });
+        let res = JSON.parse(cont);
+        this.JSON = res;
+        this.loadRes()
+      };
+      rd.readAsBinaryString(f);
+    },
+    loadRes() {
+      if (this.JSON) {
+        this.view.scene = null;
+        this.scene = new DivideFloorScene();
+        this.scene.addBaseMapItem(this.JSON.EntityList[0].Elements)
+        this.view.scene = this.scene;
+        console.log(this.scene)
+        this.view.fitSceneToView();
+      }
+      this.loading = false;
+    },
+    modelChange() {
+      console.log(this.ModelID)
+      this.createGraphy();
+    },
+    clickInputFile() {
+      this.$refs.file.click()
+    },
+  },
+}
+</script>
+<style lang="less" scoped>
+.el-container {
+  background: #fff;
+
+  /deep/ textarea.el-textarea__inner {
+    width: 100%;
+    height: 100% !important;
+  }
+
+  .el-aside {
+    padding: 10px;
+    border: 1px solid #e4e4e4;
+  }
+
+  .el-aside > div {
+    margin: 10px auto;
+    text-align: right;
+  }
+
+  .el-main {
+    padding: 10px !important;
+    border: 1px solid #e4e4e4;
+    border-left: none;
+  }
+
+  input[type="file"] {
+    display: none;
+  }
+}
+</style>

+ 30 - 10
src/views/data_admin/buildTask/addTask/addDeviceTask.vue

@@ -23,7 +23,14 @@
               </el-form>
             </template>
           </el-table-column>
-          <el-table-column label="所属建筑楼层" width="200"></el-table-column>
+          <el-table-column label="所属建筑楼层" width="200">
+            <template slot-scope="scope">
+              <div>
+                {{scope.row.Building?scope.row.Building.BuildLocalName?scope.row.Building.BuildLocalName:'':''}} -
+                {{scope.row.Floor?scope.row.Floor.FloorLocalName?scope.row.Floor.FloorLocalName:'':''}}
+              </div>
+            </template>
+          </el-table-column>
           <el-table-column prop="EquipLocalName" label="设备本地名称" show-overflow-tooltip>
              <template slot-scope="scope">
               <div>
@@ -253,16 +260,29 @@ export default {
     },
     //创建已选
     handleClickCreate() {
-      let list = this.multipleSelection.map((item) => {
-        return {EquipId: item.EquipID}
-      })
-      let param = {
-        Content: list
+      if (this.multipleSelection.length) {
+        let list = this.multipleSelection.map((item) => {
+          if (item.SchemeId) {
+            return {
+              EquipId: item.EquipID,
+              SchemeId: item.SchemeId
+            }
+          } else {
+            return {
+              EquipId: item.EquipID
+            }
+          }
+        })
+        let param = {
+          Content: list
+        }
+        createDeviceTask(param, res => {
+          this.$message.success("创建成功!")
+          this.$router.push({ name: "buildTask",query:{ newTaskTypes:this.$route.query.newTaskTypes } })
+        })
+      } else {
+        this.$message('请选择要创建的任务!')
       }
-      createDeviceTask(param, res => {
-        this.$message.success("创建成功!")
-        this.$router.push({ name: "buildTask",query:{ newTaskTypes:this.$route.query.newTaskTypes } })
-      })
     }
   }
 };

+ 255 - 29
src/views/ledger/cenotelist/cenoteDetail/index.vue

@@ -17,6 +17,26 @@
           <el-button size="small" @click="deleteCenote">删除竖井</el-button>
         </div>
       </el-row>
+      <div v-if="activeTab=='detail'"  class="content">
+        <div class="content-left">
+          <div class="content-showType">
+            <selectRadio
+              :selectRadio="selectRadio"
+              @changeRadio="changeRadio"
+            />
+          </div>
+          <div class="content-point">
+            <div class="content-point-left">
+              <el-scrollbar style="height:100%;">
+                <div>
+                  <exhibitionBaseInformation :exhibitionBaseInformation="exhibitionBaseInformation"/>
+
+                </div>
+              </el-scrollbar>
+            </div>
+          </div>
+        </div>
+      </div>
       <!-- 竖井内的设备 -->
       <device-table v-if="activeTab=='device'" :params="params" :type="activeTab"></device-table>
       <!-- 连通的其他竖井 -->
@@ -28,42 +48,215 @@
 </template>
 
 <script>
-import { mapGetters } from "vuex"
-import { deleteCenoteTableData } from '@/api/scan/request'
-import cenoteTable from '@/components/ledger/cenote/table/cenoteTable'
-import deviceTable from '@/components/ledger/cenote/table/deviceTable'
-import systemTable from '@/components/ledger/cenote/table/systemTable'
-export default {
-  data() {
-    return {
-      params: {},
-      tabsList: [
-        { Code: 'device', Name: '竖井内的设备' },
-        { Code: 'cenote', Name: '连通的其它竖井' },
-        { Code: 'system', Name: '竖井内系统' },
-      ], //tab页
-      activeTab: 'device' //当前选中的tab
-    }
-  },
-  computed: {
-    ...mapGetters("layout", ["projectId", "userId", "secret"])
-  },
-  components: {
-    cenoteTable,
-    deviceTable,
-    systemTable
-  },
-  created() {
-    this.params = this.$route.query;
+  import {mapGetters} from "vuex"
+  import {deleteCenoteTableData, getDataDictionary, queryCenoteTableData} from '@/api/scan/request'
+  import cenoteTable from '@/components/ledger/cenote/table/cenoteTable'
+  import deviceTable from '@/components/ledger/cenote/table/deviceTable'
+  import systemTable from '@/components/ledger/cenote/table/systemTable'
+  import exhibitionBaseInformation from "@/components/ledger/details/detail/exhibitionBaseInformation";
+  import selectRadio from "@/components/ledger/details/detail/selectRadio";
+  import tools from "@/utils/scan/tools"
+
+  export default {
+    data() {
+      return {
+        params: {},
+        tabsList: [
+          {Code: 'detail', Name: '竖井详情'},
+          {Code: 'device', Name: '竖井内的设备'},
+          {Code: 'cenote', Name: '连通的其它竖井'},
+          {Code: 'system', Name: '竖井内系统'},
+        ], //tab页
+        activeTab: 'detail', //当前选中的tab
+        pointData: [], //信息点数据
+        exampleData: {}, //实例数据
+        exhibitionBaseInformation: {
+          information: {}
+        },
+        selectRadio: {
+          information: '设备信息点',
+          initRadio: '1',
+          radioList: [
+            {
+              value: '显示需采集信息点',
+              label: '1'
+            },
+            {
+              value: '显示有值信息点',
+              label: '2'
+            },
+            {
+              value: '显示全部信息点',
+              label: '3'
+            }
+          ]
+        },
+      }
+    },
+    computed: {
+      ...mapGetters("layout", ["projectId", "userId", "secret"])
+    },
+    components: {
+      cenoteTable,
+      deviceTable,
+      systemTable,
+      exhibitionBaseInformation,
+      selectRadio
+    },
+    created() {
+      this.params = this.$route.query;
+      this.getData();
   },
   mounted() { },
   watch: {
     projectId() { }
   },
   methods: {
+    deepCopy(obj) {
+      return JSON.parse(JSON.stringify(obj))
+    },
     // 返回
     goBack() {
-      this.$router.push({ name: "cenotelist" })
+      this.$router.push({name: "cenotelist"});
+    },
+    getData() {
+      let params1 = {
+        data: {
+          Orders: "sort asc",
+          PageNumber: 1,
+          PageSize: 1000
+        },
+        type: 'Shaft'
+      }, params2 = {
+        Filters: `ShaftID='${this.params.ShaftID}'`
+      };
+      let promise1 = new Promise((resolve, reject) => {
+        getDataDictionary(params1, res => {
+          resolve(res)
+        })
+      })
+      let promise2 = new Promise((resolve, reject) => {
+        queryCenoteTableData(params2, res => {
+          resolve(res)
+        })
+      })
+      Promise.all([promise1, promise2]).then(values => {
+        this.pointData = values[0].Content;
+        this.exampleData = values[1].Content[0];
+        let obj = this.deepCopy(values[1].Content[0]);
+        obj = tools.flattenKeys(obj);
+        this.instance = obj;
+        this.handleRadios(1)
+      })
+    },
+    handleRadios(val) { //判断radio的值显示关键信息,基本信息,图片,文件
+      let arr = []
+      if (val == 1) { //需采集信息
+        arr = this.pointData.filter(i => i.Visible)
+      } else if (val == 2) { //有值信息点
+        let list = this.pointData
+        list.map(j => {
+          if (this.instance.hasOwnProperty(j.Path)) {
+            return {
+              ...j,
+              value: this.instance[j.Path]
+            }
+          }
+          arr = list.filter(k => k.value)
+        })
+      } else { //全部信息点
+        arr = this.pointData
+      }
+      this.displayData(arr)
+    },
+    changeRadio(val) { //1,需采集,2,有值,3,全部
+      this.handleRadios(val)
+      this.currentRadio = val
+    },
+    formatDate(str) {
+      if(str) {
+        if(str.includes('-')) {
+          return str
+        }else {
+          return  str.substr(0,4)+"-"+str.substr(4,2)+"-"+str.substr(6,2)+" "+str.substr(8,2) + ":" +str.substr(10,2) + ":"+str.substr(12,2)
+        }
+      } else {
+        return '--'
+      }
+    },
+    displayData(arr) {//对数据进行处理传给组件展示
+      const result = {}
+      arr.forEach(i => {
+        if (this.instance.hasOwnProperty(i.Path) && this.currentRadio != 2) {
+          i.value = this.instance[i.Path]
+        }
+        if (i.InputMode == 'C5') {
+          if (this.instance.hasOwnProperty(i.Path)) {
+            let time = this.instance[i.Path]
+            i.value = this.formatDate(time)
+          }
+        }
+        if (i.DataSource && i.DataSource.length) {
+          let source = JSON.parse(i.DataSource)
+          //判断输入类型
+          if (i.InputMode == 'D1L') {
+            let d1l = tools.formatDataSource(i.DataSource)
+            d1l.forEach(k => {
+              if (k.Code == this.instance[i.Path]) {
+                i.value = k.Name
+              }
+            })
+          } else if (i.InputMode == 'D2' || i.InputMode == 'C6') {
+            if (this.instance.hasOwnProperty(i.Path)) {
+              if (!Array.isArray(this.instance[i.Path])) {
+                let transArray = this.instance[i.Path].split(',')
+                i.value = source.filter(item => transArray.includes(item.Code)).map(item => item.Name).join(',')
+              }
+            }
+          }
+          source.forEach(j => {
+            if (j.Code == this.instance[i.Path]) {
+              console.log(j.Name)
+              i.value = j.Name
+            }
+          })
+        }
+        switch (i.InputMode) {
+          case "L":
+          case "L1":
+          case "L2":
+          case "M":
+            break;
+          default:
+            if (result[`${i.FirstName}${i.SecondName ? '/' + i.SecondName : ''}`]) {
+              result[`${i.FirstName}${i.SecondName ? '/' + i.SecondName : ''}`].paths.push({
+                Path: i.Path,
+                InfoPointName: i.InfoPointName,
+                InfoPointCode: i.InfoPointCode,
+                Value: i.value,
+                Visible: i.Visible,
+                KeyWord: i.KeyWord,
+                InputMode:i.InputMode
+              })
+            } else {
+              result[`${i.FirstName}${i.SecondName ? '/' + i.SecondName : ''}`] = {
+                paths: [{
+                  Path: i.Path,
+                  InfoPointName: i.InfoPointName,
+                  InfoPointCode: i.InfoPointCode,
+                  Value: i.value,
+                  Visible: i.Visible,
+                  KeyWord: i.KeyWord,
+                  InputMode:i.InputMode
+                }]
+              }
+            }
+
+        }
+
+
+      })
+      this.exhibitionBaseInformation.information = result
     },
     // 删除业务空间
     deleteCenote() {
@@ -92,8 +285,8 @@ export default {
     height: 100%;
     flex-direction: column;
     border: 1px solid #dfe6ec;
+    box-sizing: border-box;
     background: #fff;
-    margin-bottom: 10px;
     .header {
       padding-bottom: 10px;
       span {
@@ -120,6 +313,35 @@ export default {
         border-bottom: 1px solid #e4e7ed;
       }
     }
+
+    .content {
+      display: flex;
+      flex-direction: row;
+      box-sizing: border-box;
+      height: calc(100% - 99px);
+      .content-left {
+        display: flex;
+        flex-direction: column;
+        flex: 1;
+        .content-showType {
+          height: 50px;
+          border: 1px solid #ccc;
+          border-bottom: none;
+          box-sizing: border-box;
+        }
+        .content-point {
+          display: flex;
+          flex-direction: row;
+          height: calc(100% - 50px);
+          border: 1px solid #ccc;
+          box-sizing: border-box;
+          .content-point-left {
+            flex: 1;
+          }
+        }
+      }
+    }
+
     .main {
       margin-top: 10px;
       height: calc(100% - 96px);
@@ -127,6 +349,10 @@ export default {
     .footer {
       margin-bottom: 10px;
     }
+
+    /deep/ .el-scrollbar__wrap {
+      overflow-x: hidden;
+    }
   }
 }
 </style>

+ 3 - 2
src/views/ledger/cenotelist/relatedSpace.vue

@@ -152,10 +152,11 @@ export default {
         });
       }
     },
-    //默认显示第一个空间
+    //默认显示默认分区,无默认分区显示第一个分区
     showDefaultSpace() {
       if (this.spaceList.length) {
         this.space = this.spaceList.find((item) => { return item.Code == "GeneralZone" }) ? ["GeneralZone"] : [this.spaceList[0].Code];
+        this.ObjectType = this.space[0];
         // if (this.spaceList.length > 1 && this.cenoteObj.onlyRead) {
         //   this.showSpaceDot = true;
         // }
@@ -242,7 +243,7 @@ export default {
     },
     //更改业务空间类型
     changeSpace(val) {
-      this.ObjectType = val[val.length - 1];
+      this.ObjectType = val[0];
       this.floor = '';
       this.buildingList = [];
       this.building = '';

+ 599 - 0
src/views/ledger/facility/details/index.vue

@@ -0,0 +1,599 @@
+<template>
+  <div class="tableDisplay">
+    <div class="header">
+      <el-button style="float:left;" size="small" type="default" icon="el-icon-back" @click="goBack"></el-button>
+      <span :title="`${name} - ${code}`" class="details-title"><b>{{name}} - {{code}}</b></span>
+    </div>
+    <div class="content">
+      <div class="content-left">
+        <div class="content-keyPoint">
+          <exhibitionCrux :exhibitionCrux="exhibitionCrux" :type="type" @cruxSuccess="cruxSuccess"/>
+        </div>
+        <div class="content-showType">
+          <selectRadio
+            :selectRadio="selectRadio"
+            @changeRadio="changeRadio"
+          />
+        </div>
+        <div class="content-point">
+          <div class="content-point-left">
+            <el-scrollbar style="height:100%;">
+              <div>
+                <exhibitionBaseInformation :exhibitionBaseInformation="exhibitionBaseInformation"/>
+              </div>
+            </el-scrollbar>
+          </div>
+          <div class="content-point-right">
+            <el-scrollbar style="height:100%;">
+              <div>
+                <exhibitionEnergy :exhibitionEnergy="exhibitionEnergy"/>
+              </div>
+            </el-scrollbar>
+          </div>
+        </div>
+      </div>
+      <div class="content-right">
+        <div class="content-repair">
+          <exhibitionMaintain :exhibitionMaintain="exhibitionMaintain"/>
+        </div>
+        <div class="content-media">
+          <el-scrollbar style="height:100%;">
+            <div>
+              <exhibitionImage :exhibitionImage="exhibitionImage" v-show="isShowImage"/>
+              <exhibitionVideo :exhibitionVideo="exhibitionVideo" v-show="isShowVideo"/>
+              <exhibitionFile :exhibitionFile="exhibitionFile" v-show="isShowFile"/>
+            </div>
+          </el-scrollbar>
+        </div>
+      </div>
+    </div>
+    <div class="footer">
+      <el-select size="mini" style="float:right;margin:7px 30px 0 0" v-model="id" @change="handleChangeExample" placeholder="请选择">
+        <el-option
+          v-for="item in list"
+          :key="item.value"
+          :label="item.label"
+          :value="item.value">
+        </el-option>
+      </el-select>
+    </div>
+  </div>
+</template>
+
+<script>
+  import exhibitionBaseInformation from "@/components/ledger/details/detail/exhibitionBaseInformation";
+  import exhibitionFile from "@/components/ledger/details/detail/exhibitionFile";
+  import exhibitionImage from "@/components/ledger/details/detail/exhibitionImage";
+  import exhibitionVideo from "@/components/ledger/details/detail/exhibitionVideo";
+  import exhibitionCrux from "@/components/ledger/details/detail/exhibitionCrux";
+  import exhibitionEnergy from "@/components/ledger/details/detail/exhibitionEnergy";
+  import exhibitionMaintain from "@/components/ledger/details/detail/exhibitionMaintain";
+  import selectRadio from "@/components/ledger/details/detail/selectRadio";
+  import tools from "@/utils/scan/tools"
+  import {BeatchQueryParam, getDataDictionary, queryEquip} from "@/api/scan/request";
+  import {mapGetters} from "vuex";
+
+  export default {
+    name: "deviceDetails",
+    components: {
+      exhibitionBaseInformation,
+      exhibitionFile,
+      exhibitionVideo,
+      exhibitionImage,
+      exhibitionMaintain,
+      selectRadio,
+      exhibitionCrux,
+      exhibitionEnergy
+    },
+    created() {
+      this.id = this.$route.query.equipId;
+      this.name = this.$route.query.equipName;
+      this.code = this.$route.query.equipCode;
+      this.type = this.$route.query.type;
+      this.list = this.$route.query.data;
+      this.getData();
+      console.log(this.$route.query)
+    },
+    computed: {
+      ...mapGetters("layout", ["projectId", "secret", "userId"])
+    },
+    data() {
+      return {
+        id: '', //当前设备id
+        name: '', //当前设备本地名称
+        code: '', //当前设备的本地编码
+        type: '', //设备类型
+        list: [], //设备列表
+        pointData: [], //信息点数据
+        exampleData: {}, //实例数据
+        currentRadio: '',//当前选中的select
+        criterias: [], //动态参数
+        selectRadio: {
+          information: '设备信息点',
+          initRadio: '1',
+          radioList: [
+            {
+              value: '显示需采集信息点',
+              label: '1'
+            },
+            {
+              value: '显示有值信息点',
+              label: '2'
+            },
+            {
+              value: '显示全部信息点',
+              label: '3'
+            }
+          ]
+        },
+        exhibitionBaseInformation: {
+          information: {}
+        },
+        exhibitionEnergy: {
+          title: '能耗信息',
+          firstName:'',
+          dynamic: [],
+        },
+        exhibitionMaintain: {
+          title: '维修/维保记录'
+        },
+        exhibitionFile: {
+          title: '文件',
+          list: {}
+        },
+        exhibitionCrux: {
+          title: '关键信息点:',
+          cruxArray: [],
+          allMessage: [],//全部信息点
+        },
+        exhibitionImage: {
+          title: '图片',
+          list: {}
+        },
+        exhibitionVideo: {
+          title: '视频',
+          list: []
+        },
+        instance: {},//实例信息处理
+        isShowImage: true,
+        isShowVideo: true,
+        isShowFile: true,
+      }
+    },
+    methods: {
+      deepCopy(obj) {
+        return JSON.parse(JSON.stringify(obj))
+      },
+      cruxSuccess(){
+        this.getData()
+      },
+      // 获取表头和实例数据(动态数据在组件中获取,在此格式化请求参数)
+      getData() {
+        let params1 = {
+          data: {
+            Orders: "sort asc",
+            PageNumber: 1,
+            PageSize: 1000
+          },
+          type: this.type
+        }, params2 = {
+          Filters: `EquipID='${this.id}'`,
+        };
+        let promise1 = new Promise((resolve, reject) => {
+          getDataDictionary(params1, res => {
+            resolve(res)
+          })
+        })
+        let promise2 = new Promise((resolve, reject) => {
+          queryEquip(params2, res => {
+            resolve(res)
+          })
+        })
+        Promise.all([promise1, promise2]).then(values => {
+          this.pointData = values[0].Content;
+          this.exampleData = values[1].Content[0];
+          this.name = this.exampleData.EquipLocalName?this.exampleData.EquipLocalName:this.exampleData.EquipName?this.exampleData.EquipName:'';
+          this.code = this.exampleData.EquipLocalID?this.exampleData.EquipLocalID:'';
+          let obj = this.deepCopy(values[1].Content[0]);
+          obj = tools.flattenKeys(obj);
+          this.instance = obj;
+          this.handleRadios(1)
+          this.handleEnclosure() //处理图片视频文件信息
+          this.pointData.forEach(item => {
+            if (item.InputMode == "L" || item.InputMode == "L1" || item.InputMode == "L2" || item.InputMode == "M") {
+              let cur = tools.dataForKey(this.exampleData, item.Path);
+              if (cur) {
+                this.criterias.push({
+                  id: this.exampleData.EquipID,
+                  code: item.InfoPointCode
+                })
+
+              }
+            }
+          })
+
+          let params = { //获取动态参数
+            secret: this.secret,
+            ProjId: this.projectId,
+            data: {
+              criterias: this.criterias
+            }
+          }
+          if (this.criterias.length) {
+            BeatchQueryParam(params, res => {
+              res.Content && res.Content.map(child => {
+                this.pointData.forEach(head => {
+                  if (head.InfoPointCode == child.code) {
+                    console.log(head.FirstName,child,'==')
+                    this.exhibitionEnergy.firstName = head.FirstName
+                    this.exhibitionEnergy.dynamic.push({
+                      FirstName:head.FirstName,
+                      InfoPointCode: head.InfoPointCode,
+                      InfoPointName: head.InfoPointName,
+                      Path: head.Path,
+                      value: child.value,
+                      data: child.data || '--',
+                      receivetime: child.receivetime || '',
+                      error: child.error || '',
+                      Unit: head.Unit || ''
+                    })
+                  }
+                })
+              });
+            })
+          }
+
+        })
+      },
+      handleEnclosure() {
+        //图片文件处理,脱离radio控制
+        let isList = this.pointData
+        let isArr = []
+        isList.map(j => {
+          if (this.instance.hasOwnProperty(j.Path)) {
+            return {
+              ...j,
+              value: this.instance[j.Path]
+            }
+          }
+        })
+        isArr = isList.filter(k => k.value)
+        this.handlePicList(isArr)
+        this.handleFileList(isArr)
+      },
+      handleRadios(val) { //判断radio的值显示关键信息,基本信息,图片,文件
+        let arr = []
+        //关键信息点
+        this.exhibitionCrux.cruxArray = this.pointData.filter(i => i.KeyWord)
+        this.exhibitionCrux.cruxArray.map(i => {
+          if (this.instance.hasOwnProperty(i.Path)) {
+            return {
+              ...i,
+              value: this.instance[i.Path]
+            }
+          }
+        })
+
+        if (val == 1) { //需采集信息
+          arr = this.pointData.filter(i => i.Visible)
+          // //  图片和的处理
+          // this.handlePicList(arr)
+          // //  文件处理
+          // this.handleFileList(arr)
+
+        } else if (val == 2) { //有值信息点
+          let list = this.pointData
+          list.map(j => {
+            if (this.instance.hasOwnProperty(j.Path)) {
+              return {
+                ...j,
+                value: this.instance[j.Path]
+              }
+            }
+          })
+          arr = list.filter(k => k.value)
+          // this.handlePicList(arr, 2)
+          // this.handleFileList(arr, 2)
+
+        } else { //全部信息点
+          arr = this.pointData
+          // this.handlePicList(arr)
+          // this.handleFileList(arr)
+        }
+        this.displayData(arr)
+      },
+      handlePicList(arr) {
+        let picObject = {}
+        //处理数据格式
+        arr.map(i => {
+          if (i.InputMode == 'F2') {
+            switch (i.Path) {
+              case 'LedgerParam.PhotoDoc.Drawing':
+              case 'LedgerParam.Siteinstall.InstallPic':
+              case 'LedgerParam.Siteinstall.InstallDrawing':
+              case 'LedgerParam.PhotoDoc.Nameplate':
+                if (this.instance.hasOwnProperty(i.Path)) {
+                  i.PicList = this.instance[i.Path]
+                }
+                if (picObject[i.InfoPointName]) {
+
+                } else {
+                  picObject[i.InfoPointName] = []
+                }
+                picObject[i.InfoPointName].push({
+                  ...i,
+                })
+                break;
+
+            }
+          }
+
+        })
+        //展示图片
+        this.exhibitionImage.list = picObject
+        let isArray = [] //获取图片数组
+        for (let i in picObject) {
+          if (Array.isArray(picObject[i])) {
+            let list = picObject[i]
+            list.forEach(i => {
+              if (i.PicList) {
+                isArray.push(...i.PicList)
+              }
+            })
+          }
+        }
+        let video = isArray.filter(i => i.Type != 'image' &&i.type != 'image' )
+        this.exhibitionVideo.list = video
+          //判断是否显示图片组件
+          this.isShowImage = isArray.length ? true : false
+          //判断是否显示video组件
+          this.isShowVideo = video.length ? true : false
+
+      },
+      handleFileList(arr) {
+        let picObject = {}
+        //处理数据格式
+        arr.map(i => {
+          if (i.InputMode == 'F2') {
+            switch (i.Path) {
+              case 'LedgerParam.InsuranceDoc.InsuranceFile':
+              case 'LedgerParam.PhotoDoc.Archive':
+              case 'LedgerParam.Siteinstall.CheckReport':
+                if (this.instance.hasOwnProperty(i.Path)) {
+                  i.fileList = this.instance[i.Path]
+                }
+                if (picObject[i.InfoPointName]) {
+
+                } else {
+                  picObject[i.InfoPointName] = []
+                }
+                picObject[i.InfoPointName].push({
+                  ...i,
+                })
+                break
+            }
+          }
+        })
+        //展示文件
+        this.exhibitionFile.list = picObject
+        let isArray = [] //获取文件数组
+        for (let i in picObject) {
+          if (Array.isArray(picObject[i])) {
+            let list = picObject[i]
+            list.forEach(i => {
+              if (i.fileList) {
+                isArray.push(...i.fileList)
+              }
+            })
+          }
+        }
+          //判断是否显示文件组件
+          this.isShowFile = isArray.length ? true : false
+
+      },
+      changeRadio(val) { //1,需采集,2,有值,3,全部
+        this.handleRadios(val)
+        this.currentRadio = val
+      },
+      formatDate(str) {
+        if(str) {
+          if(str.includes('-')) {
+            return str
+          }else {
+            return  str.substr(0,4)+"-"+str.substr(4,2)+"-"+str.substr(6,2)+" "+str.substr(8,2) + ":" +str.substr(10,2) + ":"+str.substr(12,2)
+          }
+        } else {
+          return '--'
+        }
+      },
+      displayData(arr) {//对数据进行处理传给组件展示
+        const result = {}
+        arr.forEach(i => {
+          if (this.instance.hasOwnProperty(i.Path) && this.currentRadio != 2) {
+            i.value = this.instance[i.Path]
+          }
+          if (i.InputMode == 'C5') {
+            if (this.instance.hasOwnProperty(i.Path)) {
+              let time = this.instance[i.Path]
+              i.value = this.formatDate(time)
+            }
+          }
+          if (i.DataSource && i.DataSource.length) {
+            let source = JSON.parse(i.DataSource)
+            //判断输入类型
+            if (i.InputMode == 'D1L') {
+              let d1l = tools.formatDataSource(i.DataSource)
+              d1l.forEach(k => {
+                if (k.Code == this.instance[i.Path]) {
+                  i.value = k.Name
+                }
+              })
+            } else if (i.InputMode == 'D2' || i.InputMode == 'C6') {
+              if (this.instance.hasOwnProperty(i.Path)) {
+                if (!Array.isArray(this.instance[i.Path])) {
+                  let transArray = this.instance[i.Path].split(',')
+                  i.value = source.filter(item => transArray.includes(item.Code)).map(item => item.Name).join(',')
+                }
+              }
+            }
+            source.forEach(j => {
+              if (j.Code == this.instance[i.Path]) {
+                console.log(j.Name)
+                i.value = j.Name
+              }
+            })
+          }
+          switch (i.InputMode) {
+            case "L":
+            case "L1":
+            case "L2":
+            case "M":
+              break;
+            default:
+              if (result[`${i.FirstName}${i.SecondName ? '/' + i.SecondName : ''}`]) {
+                result[`${i.FirstName}${i.SecondName ? '/' + i.SecondName : ''}`].paths.push({
+                  Path: i.Path,
+                  InfoPointName: i.InfoPointName,
+                  InfoPointCode: i.InfoPointCode,
+                  Value: i.value,
+                  Visible: i.Visible,
+                  KeyWord: i.KeyWord,
+                  InputMode:i.InputMode
+                })
+              } else {
+                result[`${i.FirstName}${i.SecondName ? '/' + i.SecondName : ''}`] = {
+                  paths: [{
+                    Path: i.Path,
+                    InfoPointName: i.InfoPointName,
+                    InfoPointCode: i.InfoPointCode,
+                    Value: i.value,
+                    Visible: i.Visible,
+                    KeyWord: i.KeyWord,
+                    InputMode:i.InputMode
+                  }]
+                }
+              }
+
+          }
+
+
+        })
+        this.exhibitionBaseInformation.information = result
+        this.exhibitionCrux.allMessage = result
+      },
+      goBack() {
+        this.$router.push({
+          name: "facilityLedger",
+          params: {
+            deviceId: this.type
+          }
+        })
+      },
+      // 切换实例
+      handleChangeExample() {
+        this.selectRadio.initRadio = '1'
+        this.getData();
+        this.exhibitionEnergy.dynamic = []
+      },
+    },
+    watch: {
+      projectId() {
+        this.$router.push({path: "/ledger/facility"})
+      }
+    }
+  }
+</script>
+
+<style scoped lang="less">
+  @bgc: #fff;
+  .tableDisplay {
+    .header {
+      padding-bottom: 10px;
+      overflow: hidden;
+      text-overflow:ellipsis;
+      white-space: nowrap;
+      .details-title {
+        color: #333;
+        font-size: 16px;
+        margin-left: 20px;
+        line-height: 32px;
+        cursor: pointer;
+      }
+    }
+
+    .content {
+      display: flex;
+      flex-direction: row;
+      box-sizing: border-box;
+      height: calc(100% - 95px);
+      .content-left {
+        display: flex;
+        flex-direction: column;
+        flex: 1;
+        .content-keyPoint {
+          border: 1px solid #ccc;
+          box-sizing: border-box;
+          height: 100px;
+          margin-bottom: 10px;
+          overflow: hidden;
+          background: @bgc;
+        }
+        .content-showType {
+          height: 50px;
+          border: 1px solid #ccc;
+          border-bottom: none;
+          box-sizing: border-box;
+          background: @bgc;
+        }
+        .content-point {
+          display: flex;
+          flex-direction: row;
+          height: calc(100% - 160px);
+          border: 1px solid #ccc;
+          box-sizing: border-box;
+          background: @bgc;
+
+          .content-point-left {
+            flex: 1;
+          }
+
+          .content-point-right {
+            width: 300px;
+            border-left: 1px solid #ccc;
+          }
+        }
+      }
+      .content-right {
+        width: 400px;
+        margin-left: 10px;
+        .content-repair {
+          height: 50px;
+          line-height: 50px;
+          margin-bottom: 10px;
+          border: 1px solid #ccc;
+          background: @bgc;
+          box-sizing: border-box;
+        }
+        .content-media {
+          height: calc(100% - 60px);
+          background: @bgc;
+          border: 1px solid #ccc;
+          box-sizing: border-box;
+        }
+      }
+    }
+
+    .footer {
+      margin-top: 5px;
+      height: 45px;
+      background-color: #fff;
+      box-sizing: border-box;
+      border: 1px solid #ccc;
+    }
+  }
+
+  /deep/ .el-scrollbar__wrap {
+    overflow-x: hidden;
+  }
+
+</style>

+ 3 - 3
src/views/ledger/facility/index.vue

@@ -1,5 +1,5 @@
 <template>
-  <div id="deviceList">
+  <div id="deviceList" >
     <router-link to="/ledger/facility/addfacility"></router-link>
     <router-view></router-view>
     <saga-title :mess="mess"></saga-title>
@@ -96,7 +96,7 @@ export default {
   methods: {
     getProjName() {
       this.projects.forEach((item) => {
-        if(item.id == this.projectId) 
+        if(item.id == this.projectId)
         this.mess.perjectName = item.name
       })
       // this.getEqCode()
@@ -209,4 +209,4 @@ export default {
     }
   }
 }
-</style>
+</style>

+ 518 - 0
src/views/ledger/property/details/index.vue

@@ -0,0 +1,518 @@
+<template>
+  <div class="tableDisplay">
+    <div class="header">
+      <el-button style="float:left;" size="small" type="default" icon="el-icon-back" @click="goBack"></el-button>
+      <span :title="`${name} - ${code}`" class="details-title"><b>{{name}} - {{code}}</b></span>
+    </div>
+    <div class="content">
+      <div class="content-left">
+        <div class="content-keyPoint">
+          <exhibitionCrux :exhibitionCrux="exhibitionCrux" :type="type" @cruxSuccess="cruxSuccess"/>
+
+        </div>
+        <div class="content-showType">
+          <selectRadio
+            :selectRadio="selectRadio"
+            @changeRadio="changeRadio"
+          />
+        </div>
+        <div class="content-point">
+          <div class="content-point-left">
+            <el-scrollbar style="height:100%;">
+              <div>
+                <exhibitionBaseInformation :exhibitionBaseInformation="exhibitionBaseInformation"/>
+              </div>
+            </el-scrollbar>
+          </div>
+        </div>
+      </div>
+      <div class="content-right">
+        <div class="content-media">
+          <el-scrollbar style="height:100%;">
+            <div>
+              <exhibitionImage :exhibitionImage="exhibitionImage" v-show="isShowImage"/>
+              <exhibitionVideo :exhibitionVideo="exhibitionVideo" v-show="isShowVideo"/>
+              <exhibitionFile :exhibitionFile="exhibitionFile" v-show="isShowFile"/>
+            </div>
+          </el-scrollbar>
+        </div>
+      </div>
+    </div>
+    <div class="footer">
+      <el-select size="mini" style="float:right;margin:7px 30px 0 0" v-model="id" @change="handleChangeExample" placeholder="请选择">
+        <el-option
+          v-for="item in list"
+          :key="item.value"
+          :label="item.label"
+          :value="item.value">
+        </el-option>
+      </el-select>
+    </div>
+  </div>
+</template>
+
+<script>
+  import exhibitionBaseInformation from "@/components/ledger/details/detail/exhibitionBaseInformation";
+  import exhibitionFile from "@/components/ledger/details/detail/exhibitionFile";
+  import exhibitionImage from "@/components/ledger/details/detail/exhibitionImage";
+  import exhibitionVideo from "@/components/ledger/details/detail/exhibitionVideo";
+  import exhibitionCrux from "@/components/ledger/details/detail/exhibitionCrux";
+  import selectRadio from "@/components/ledger/details/detail/selectRadio";
+
+  import {getDataDictionary, queryProperty} from "@/api/scan/request";
+  import {mapGetters} from "vuex";
+  import tools from "@/utils/scan/tools"
+
+
+  export default {
+    name: "propertyDetails",
+    components: {
+      exhibitionBaseInformation,
+      exhibitionFile,
+      exhibitionImage,
+      selectRadio,
+      exhibitionCrux,
+      exhibitionVideo
+    },
+    created() {
+      this.id = this.$route.query.equipId;
+      this.name = this.$route.query.equipName;
+      this.code = this.$route.query.equipCode;
+      this.type = this.$route.query.type;
+      this.list = this.$route.query.data;
+      this.getData();
+      console.log(this.$route.query)
+    },
+    computed: {
+      ...mapGetters("layout", ["projectId", "secret", "userId"])
+    },
+    data() {
+      return {
+        id: '', //当前资产id
+        name: '', //当前资产本地名称
+        code: '', //当前资产的本地编码
+        type: '', //资产类型
+        list: [], //资产列表
+        pointData: [], //信息点数据
+        currentRadio: '',//当前选中的select
+        selectRadio: {
+          information: '设备信息点',
+          initRadio: '1',
+          radioList: [
+            {
+              value: '显示需采集信息点',
+              label: '1'
+            },
+            {
+              value: '显示有值信息点',
+              label: '2'
+            },
+            {
+              value: '显示全部信息点',
+              label: '3'
+            }
+          ]
+        },
+        exhibitionBaseInformation: {
+          information: {}
+        },
+        exhibitionFile: {
+          title: '文件',
+          list: {}
+        },
+        exhibitionCrux: {
+          title: '关键信息点:',
+          cruxArray: [],
+          allMessage: [],//全部信息点
+        },
+        exhibitionImage: {
+          title: '图片',
+          list: {}
+        },
+        exhibitionVideo: {
+          title: '视频',
+          list: {}
+        },
+        instance: {},//实例信息处理
+        isShowImage: true,
+        isShowVideo: true,
+        isShowFile: true,
+      }
+    },
+    methods: {
+      deepCopy(obj) {
+        return JSON.parse(JSON.stringify(obj))
+      },
+      cruxSuccess(){
+        this.getData()
+      },
+      // 获取表头和实例数据
+      getData () {
+        let params1 = {
+          data: {
+            Orders: "sort asc",
+            PageNumber: 1,
+            PageSize: 1000
+          },
+          type: this.type
+        }, params2 = {
+          Filters: `EquipID='${this.id}'`,
+        };
+        let promise1 = new Promise((resolve, reject) => {
+          getDataDictionary(params1, res => {
+            resolve(res)
+          })
+        })
+        let promise2 = new Promise((resolve, reject) => {
+          queryProperty(params2, res => {
+            resolve(res)
+          })
+        })
+        Promise.all([promise1, promise2]).then(values => {
+          this.pointData = values[0].Content;
+          this.exampleData = values[1].Content[0];
+          this.name = this.exampleData.EquipLocalName?this.exampleData.EquipLocalName:this.exampleData.EquipName?this.exampleData.EquipName:'';
+          this.code = this.exampleData.EquipLocalID?this.exampleData.EquipLocalID:'';
+          let obj = this.deepCopy(values[1].Content[0]);
+          obj = tools.flattenKeys(obj);
+          this.instance = obj;
+          this.handleRadios(1)
+          this.handleEnclosure() //处理图片视频文件信息
+        })
+      },
+      handleEnclosure() {
+        //图片文件处理,脱离radio控制
+        let isList = this.pointData
+        let isArr = []
+        isList.map(j => {
+          if (this.instance.hasOwnProperty(j.Path)) {
+            return {
+              ...j,
+              value: this.instance[j.Path]
+            }
+          }
+        })
+        isArr = isList.filter(k => k.value)
+        this.handlePicList(isArr)
+        this.handleFileList(isArr)
+      },
+      handleRadios(val) { //判断radio的值显示关键信息,基本信息,图片,文件
+        let arr = []
+        //关键信息点
+        this.exhibitionCrux.cruxArray = this.pointData.filter(i => i.KeyWord)
+        this.exhibitionCrux.cruxArray.map(i => {
+          if (this.instance.hasOwnProperty(i.Path)) {
+            return {
+              ...i,
+              value: this.instance[i.Path]
+            }
+          }
+        })
+        if (val == 1) { //需采集信息
+          arr = this.pointData.filter(i => i.Visible)
+
+          //  图片和的处理
+          // this.handlePicList(arr)
+          // //  文件处理
+          // this.handleFileList(arr)
+
+        } else if (val == 2) { //有值信息点
+          let list = this.pointData
+          list.map(j => {
+            if (this.instance.hasOwnProperty(j.Path)) {
+              return {
+                ...j,
+                value: this.instance[j.Path]
+              }
+            }
+            arr = list.filter(k => k.value)
+            // this.handlePicList(arr)
+            // this.handleFileList(arr)
+          })
+        } else { //全部信息点
+          arr = this.pointData
+          // this.handlePicList(arr)
+          // this.handleFileList(arr)
+        }
+        this.displayData(arr)
+      },
+      handlePicList(arr) {
+        let picObject = {}
+        //处理数据格式
+        arr.map(i => {
+          if(i.InputMode == 'F2') {
+            switch (i.Path) {
+              case 'LedgerParam.PhotoDoc.Drawing':
+              case 'LedgerParam.Siteinstall.InstallPic':
+              case 'LedgerParam.Siteinstall.InstallDrawing':
+              case 'LedgerParam.PhotoDoc.Nameplate':
+                if (this.instance.hasOwnProperty(i.Path)) {
+                  i.PicList = this.instance[i.Path]
+                }
+                if (picObject[i.InfoPointName]) {
+
+                } else {
+                  picObject[i.InfoPointName] = []
+                }
+                picObject[i.InfoPointName].push({
+                  ...i,
+                })
+                break;
+
+            }
+          }
+
+        })
+        //展示图片
+        this.exhibitionImage.list = picObject
+        let isArray = [] //获取图片数组
+        for (let i in picObject) {
+          if (Array.isArray(picObject[i])) {
+            let list = picObject[i]
+            list.forEach(i => {
+              if (i.PicList) {
+                isArray.push(...i.PicList)
+              }
+            })
+          }
+        }
+        let video = isArray.filter(i => i.Type =='video' && i.type == 'video' )
+        this.exhibitionVideo.list = video
+        //判断是否显示图片组件
+        this.isShowImage = isArray.length ? true : false
+        //判断是否显示video组件
+        this.isShowVideo = video.length ? true : false
+      },
+      handleFileList(arr) {
+        let picObject = {}
+        //处理数据格式
+        arr.map(i => {
+          if (i.InputMode == 'F2') {
+            switch (i.Path) {
+              case 'LedgerParam.InsuranceDoc.InsuranceFile':
+              case 'LedgerParam.PhotoDoc.Archive':
+              case 'LedgerParam.Siteinstall.CheckReport':
+                if (this.instance.hasOwnProperty(i.Path)) {
+                  i.fileList = this.instance[i.Path]
+                }
+                if (picObject[i.InfoPointName]) {
+
+                } else {
+                  picObject[i.InfoPointName] = []
+                }
+
+                picObject[i.InfoPointName].push({
+                  ...i,
+                })
+                break
+            }
+          }
+
+        })
+        //展示文件
+        this.exhibitionFile.list = picObject
+        let isArray = [] //获取文件数组
+        for (let i in picObject) {
+          if (Array.isArray(picObject[i])) {
+            let list = picObject[i]
+            list.forEach(i => {
+              if (i.fileList) {
+                isArray.push(...i.fileList)
+              }
+            })
+          }
+        }
+        //判断是否显示文件组件
+        this.isShowFile = isArray.length ? true : false
+      },
+      changeRadio(val) { //1,需采集,2,有值,3,全部
+        this.handleRadios(val)
+        this.currentRadio = val
+      },
+      formatDate(str) {
+        if(str) {
+          if(str.includes('-')) {
+            return str
+          }else {
+            return  str.substr(0,4)+"-"+str.substr(4,2)+"-"+str.substr(6,2)+" "+str.substr(8,2) + ":" +str.substr(10,2) + ":"+str.substr(12,2)
+          }
+        } else {
+          return '--'
+        }
+      },
+      displayData(arr) {//对数据进行处理传给组件展示
+        const result = {}
+        arr.forEach(i => {
+          if (this.instance.hasOwnProperty(i.Path) && this.currentRadio != 2) {
+            i.value = this.instance[i.Path]
+          }
+          if (i.InputMode == 'C5') {
+            if (this.instance.hasOwnProperty(i.Path)) {
+             let time = this.instance[i.Path]
+              i.value = this.formatDate(time)
+            }
+          }
+          if (i.DataSource && i.DataSource.length) {
+            let source = JSON.parse(i.DataSource)
+            //判断输入类型
+            if (i.InputMode == 'D1L') {
+              let d1l = tools.formatDataSource(i.DataSource)
+              d1l.forEach(k => {
+                if (k.Code == this.instance[i.Path]) {
+                  i.value = k.Name
+                }
+              })
+            } else if (i.InputMode == 'D2' || i.InputMode == 'C6') {
+              if (this.instance.hasOwnProperty(i.Path)) {
+                if (!Array.isArray(this.instance[i.Path])) {
+                  let transArray = this.instance[i.Path].split(',')
+                  i.value = source.filter(item => transArray.includes(item.Code)).map(item => item.Name).join(',')
+                }
+              }
+            }
+            source.forEach(j => {
+              if (j.Code == this.instance[i.Path]) {
+                console.log(j.Name)
+                i.value = j.Name
+              }
+            })
+          }
+          switch (i.InputMode) {
+            case "L":
+            case "L1":
+            case "L2":
+            case "M":
+              break;
+            default:
+              if (result[`${i.FirstName}${i.SecondName ? '/' + i.SecondName : ''}`]) {
+                result[`${i.FirstName}${i.SecondName ? '/' + i.SecondName : ''}`].paths.push({
+                  Path: i.Path,
+                  InfoPointName: i.InfoPointName,
+                  InfoPointCode: i.InfoPointCode,
+                  Value: i.value,
+                  Visible: i.Visible,
+                  KeyWord: i.KeyWord,
+                  InputMode:i.InputMode
+                })
+              } else {
+                result[`${i.FirstName}${i.SecondName ? '/' + i.SecondName : ''}`] = {
+                  paths: [{
+                    Path: i.Path,
+                    InfoPointName: i.InfoPointName,
+                    InfoPointCode: i.InfoPointCode,
+                    Value: i.value,
+                    Visible: i.Visible,
+                    KeyWord: i.KeyWord,
+                    InputMode:i.InputMode
+                  }]
+                }
+              }
+
+          }
+
+
+        })
+        this.exhibitionBaseInformation.information = result
+        this.exhibitionCrux.allMessage = result
+      },
+      goBack () {
+        this.$router.push({
+          name: 'propertyLedger',
+          params: {
+            Family: this.type
+          }
+        })
+      },
+      // 切换实例
+      handleChangeExample() {
+        this.selectRadio.initRadio = '1'
+        this.getData();
+      },
+    },
+    watch: {
+      projectId() {
+        this.$router.push({path: "/ledger/property"})
+      }
+    }
+  }
+</script>
+
+<style scoped lang="less">
+  @bgc: #fff;
+  .tableDisplay {
+    .header {
+      padding-bottom: 10px;
+      overflow: hidden;
+      text-overflow:ellipsis;
+      white-space: nowrap;
+      .details-title {
+        color: #333;
+        font-size: 16px;
+        margin-left: 20px;
+        line-height: 32px;
+        cursor: pointer;
+      }
+    }
+
+    .content {
+      display: flex;
+      flex-direction: row;
+      box-sizing: border-box;
+      height: calc(100% - 95px);
+      .content-left {
+        display: flex;
+        flex-direction: column;
+        flex: 1;
+        .content-keyPoint {
+          border: 1px solid #ccc;
+          box-sizing: border-box;
+          height: 100px;
+          margin-bottom: 10px;
+          overflow: hidden;
+          background: @bgc;
+        }
+        .content-showType {
+          height: 50px;
+          border: 1px solid #ccc;
+          border-bottom: none;
+          box-sizing: border-box;
+          background: @bgc;
+        }
+        .content-point {
+          display: flex;
+          flex-direction: row;
+          height: calc(100% - 160px);
+          border: 1px solid #ccc;
+          box-sizing: border-box;
+          background: @bgc;
+          .content-point-left {
+            flex: 1;
+          }
+        }
+      }
+      .content-right {
+        width: 400px;
+        margin-left: 10px;
+        .content-media {
+          height: 100%;
+          background: @bgc;
+          border: 1px solid #ccc;
+          box-sizing: border-box;
+        }
+      }
+    }
+
+    .footer {
+      margin-top: 5px;
+      height: 45px;
+      background-color: #fff;
+      box-sizing: border-box;
+      border: 1px solid #ccc;
+    }
+  }
+
+  /deep/ .el-scrollbar__wrap {
+    overflow-x: hidden;
+  }
+
+</style>

+ 2 - 42
src/views/ledger/spacelist/index.vue

@@ -217,7 +217,7 @@ export default {
 
           this.buildFloorSelectd = this.childBackParam.buildFloorSelectd;
           this.isMyTab = this.childBackParam.isMyTab;
-        } else {
+        } else if (this.activeName == '0') {
           this.activeName = 'GeneralZone';
         }
       })
@@ -263,8 +263,6 @@ export default {
     //修改所选建筑楼层
     changeCascader(val) {
       this.buildFloorSelectd = val;
-      // this.inquireZone()
-
       // 如果选择的是全部或者未明确
       if (val.indexOf('noKnow') > -1 || val.indexOf('all') > -1) {
         this.getTypes()
@@ -293,45 +291,9 @@ export default {
       } else {
         this.getInfected(this.buildFloorSelectd[1]);
         this.$refs.graphy.getData(this.buildFloorSelectd, this.FloorMap, this.activeTabType);
+        this.childBackParam = {}
       }
     },
-    // inquireZone() {
-    //   //查询空间信息
-    //   let params = {
-    //     ZoneType: this.activeName,
-    //     PageNumber: 1,
-    //     PageSize: 50,
-    //     Orders: "createTime desc, RoomID asc"
-    //   };
-    //   if (this.buildFloorSelectd.length === 1) {
-    //     switch (this.buildFloorSelectd[0]) {
-    //       case 'noKnow':
-    //         params.BuildingId = 'isnull';
-    //         break;
-    //       case 'all':
-    //         // params.BuildingId = '';
-    //         break
-    //     }
-    //   } else if (this.buildFloorSelectd.length === 2) {
-    //     switch (this.buildFloorSelectd[1]) {
-    //       case 'noKnow':
-    //         params.BuildingId = this.buildFloorSelectd[0];
-    //         params.FloorId = 'isnull';
-    //         break;
-    //       case 'all' :
-    //         params.BuildingId = this.buildFloorSelectd[0];
-    //         // params.FloorId = '';
-    //         break;
-    //       default:
-    //         params.BuildingId = this.buildFloorSelectd[0];
-    //         params.FloorId = this.buildFloorSelectd[1]
-    //
-    //     }
-    //   }
-    //   zoneQuery(params, res => {
-    //
-    //   })
-    // },
     // 触发获取表头-获取初始化信息点
     initMessage() {
       let params = {
@@ -342,10 +304,8 @@ export default {
         },
         type: this.activeName
       }
-
       getDataDictionary(params, res => {
         this.$refs.handsontable.getHeader(res.Content, this.buildFloorSelectd);
-
       })
     },
     checkSpace(list, build, graphyId) {

+ 500 - 36
src/views/ledger/spacelist/spaceDetail/index.vue

@@ -3,7 +3,7 @@
     <div class="condition">
       <div class="header">
         <el-button style="float:left;" size="small" type="default" icon="el-icon-back" @click="goBack"></el-button>
-        <span>{{spaceDetails.RoomLocalName||spaceDetails.RoomName||''}}</span>
+        <span>{{exampleData.RoomLocalName||exampleData.RoomName||''}}</span>
       </div>
       <el-row class="spaceTypes">
         <div class="types">
@@ -17,8 +17,47 @@
           <el-button size="small" @click="deleteSpace">删除业务空间</el-button>
         </div>
       </el-row>
-      <div v-if="activeTab=='detail'" style="height:calc(100% - 110px)">
-        <iframe height="100%" width="100%" :src="iframeSrc"></iframe>
+      <div v-if="activeTab=='detail'"  class="content">
+        <iframe v-if="params.isMyTab == 1" height="100%" width="100%" :src="iframeSrc"></iframe>
+        <div v-else class="content-left">
+          <div class="content-showType">
+            <selectRadio
+              :selectRadio="selectRadio"
+              @changeRadio="changeRadio"
+            />
+          </div>
+          <div class="content-point">
+            <div class="content-point-left">
+              <el-scrollbar style="height:100%;">
+                <div >
+                  <exhibitionBaseInformation :exhibitionBaseInformation="exhibitionBaseInformation"/>
+                </div>
+              </el-scrollbar>
+            </div>
+            <div class="content-point-right">
+              <el-scrollbar style="height:100%;">
+                <div>
+                  <exhibitionEnergy :exhibitionEnergy="exhibitionEnergy" />
+                </div>
+              </el-scrollbar>
+            </div>
+          </div>
+        </div>
+        <div class="content-right">
+          <div class="content-repair">
+            <exhibitionMaintain :exhibitionMaintain="exhibitionMaintain"/>
+
+          </div>
+          <div class="content-media">
+            <el-scrollbar style="height:100%;">
+              <div >
+                <exhibitionImage :exhibitionImage="exhibitionImage" v-show="isShowImage"/>
+                <exhibitionVideo :exhibitionVideo="exhibitionVideo" v-show="isShowVideo"/>
+                <exhibitionFile :exhibitionFile="exhibitionFile" v-show="isShowFile"/>
+              </div>
+            </el-scrollbar>
+          </div>
+        </div>
       </div>
       <!-- 空间内设备列表--服务于空间的设备 -->
       <eqToSpaceTable v-else-if="activeTab=='Equipment' || activeTab=='EquipmentFor'" :params="params" :type="activeTab"></eqToSpaceTable>
@@ -30,42 +69,116 @@
 </template>
 
 <script>
-import { mapGetters } from "vuex"
-import { zoneQuery, zoneCreate } from '@/api/scan/request'
-import eqToSpaceTable from '@/components/business_space/newTables/eqToSpaceTable'
-import syInSpaceTable from '@/components/business_space/newTables/syInSpaceTable'
-export default {
-  data() {
-    return {
-      params: {}, //参数-包含空间id 分区类型 进入方式(1-平面图 2-列表)
-      tabsList: [
-        { Code: 'detail', Name: '空间详情' },
-        { Code: 'Equipment', Name: '空间内设备' },
-        { Code: 'EquipmentFor', Name: '服务于空间的设备' },
-        { Code: 'generalSystem', Name: '空间内系统' },
-      ], //tab页
-      activeTab: 'detail', //当前选中的tab
-      spaceDetails: {}, //空间信息
-      iframeSrc: '', //空间详情iframe
-    }
+  import {mapGetters} from "vuex";
+  import tools from "@/utils/scan/tools";
+  import {zoneDelete, getDataDictionary, zoneQuery} from '@/api/scan/request';
+
+  import eqToSpaceTable from '@/components/business_space/newTables/eqToSpaceTable';
+  import syInSpaceTable from '@/components/business_space/newTables/syInSpaceTable';
+  import exhibitionBaseInformation from "@/components/ledger/details/detail/exhibitionBaseInformation";
+  import exhibitionFile from "@/components/ledger/details/detail/exhibitionFile";
+  import exhibitionImage from "@/components/ledger/details/detail/exhibitionImage";
+  import exhibitionVideo from "@/components/ledger/details/detail/exhibitionVideo";
+  import exhibitionCrux from "@/components/ledger/details/detail/exhibitionCrux";
+  import exhibitionEnergy from "@/components/ledger/details/detail/exhibitionEnergy";
+  import exhibitionMaintain from "@/components/ledger/details/detail/exhibitionMaintain";
+  import selectRadio from "@/components/ledger/details/detail/selectRadio";
+
+
+  export default {
+    data() {
+      return {
+        params: {}, //参数-包含空间id 分区类型 进入方式(1-平面图 2-列表)
+        tabsList: [
+          {Code: 'detail', Name: '空间详情'},
+          {Code: 'Equipment', Name: '空间内设备'},
+          {Code: 'EquipmentFor', Name: '服务于空间的设备'},
+          {Code: 'generalSystem', Name: '空间内系统'},
+        ], //tab页
+        activeTab: 'detail', //当前选中的tab
+        pointData: [], //信息点数据
+        exampleData: {}, //实例数据
+        criterias: [], //动态参数
+        instance: {},
+        iframeSrc: '', //空间详情iframe
+        selectRadio: {
+          information: '设备信息点',
+          initRadio: '1',
+          radioList: [
+            {
+              value: '显示需采集信息点',
+              label: '1'
+            },
+            {
+              value: '显示有值信息点',
+              label: '2'
+            },
+            {
+              value: '显示全部信息点',
+              label: '3'
+            }
+          ]
+        },
+        exhibitionBaseInformation: {
+          information: {}
+        },
+        exhibitionEnergy: {
+          title: '能耗信息',
+          dynamic: [],
+        },
+        exhibitionMaintain: {
+          title: '维修/维保记录'
+        },
+        exhibitionFile: {
+          title: '文件',
+          list: {}
+        },
+        exhibitionCrux: {
+          title: '关键信息点:',
+          cruxArray: [],
+          allMessage: [],//全部信息点
+        },
+        exhibitionImage: {
+          title: '图片',
+          list: {}
+        },
+        exhibitionVideo: {
+          title: '视频',
+          list: {}
+        },
+        isShowImage: true,
+        isShowVideo: true,
+        isShowFile: true,
+      }
   },
   computed: {
     ...mapGetters("layout", ["projectId", "userId", "secret"])
   },
   components: {
     eqToSpaceTable,
-    syInSpaceTable
+    syInSpaceTable,
+    exhibitionBaseInformation,
+    exhibitionFile,
+    exhibitionVideo,
+    exhibitionImage,
+    exhibitionMaintain,
+    selectRadio,
+    exhibitionCrux,
+    exhibitionEnergy
   },
   created() {
     this.params = this.$route.query;
-    this.getSpaceDetails();
-    this.setFrame()
+    this.getData();
+    this.setFrame();
   },
   mounted() { },
   watch: {
     projectId() { }
   },
   methods: {
+    deepCopy(obj) {
+      return JSON.parse(JSON.stringify(obj))
+    },
     // 返回
     goBack() {
       this.$router.push({
@@ -74,20 +187,317 @@ export default {
       })
     },
     // 查询空间详情
-    getSpaceDetails() {
-      let pa = {
-        Filters: `RoomID="${this.params.RoomID}"`,
+    getData() {
+      let params1 = {
+        data: {
+          Orders: "sort asc",
+          PageNumber: 1,
+          PageSize: 1000
+        },
+        type: this.params.zone
+      }, params2 = {
+        Filters: `RoomID='${this.params.RoomID}'`,
         ZoneType: this.params.zone
+      };
+      let promise1 = new Promise((resolve, reject) => {
+        getDataDictionary(params1, res => {
+          resolve(res)
+        })
+      })
+      let promise2 = new Promise((resolve, reject) => {
+        zoneQuery(params2, res => {
+          resolve(res)
+        })
+      })
+      Promise.all([promise1, promise2]).then(values => {
+        this.pointData = values[0].Content;
+        this.exampleData = values[1].Content[0];
+
+        let obj = this.deepCopy(values[1].Content[0]);
+        obj = tools.flattenKeys(obj);
+        this.instance = obj;
+        this.handleRadios(1)
+        this.handleEnclosure() //处理图片视频文件信息
+        this.pointData.forEach(item => {
+          if (item.InputMode == "L" || item.InputMode == "L1" || item.InputMode == "L2" || item.InputMode == "M") {
+            let cur = tools.dataForKey(this.exampleData, item.Path);
+            if (cur) {
+              this.criterias.push({
+                id: exampleData.EquipID,
+                code: item.InfoPointCode
+              })
+            }
+          }
+        })
+        let params = { //获取动态参数
+          secret: this.secret,
+          ProjId: this.projectId,
+          data: {
+            criterias: this.criterias
+          }
+        }
+        if (this.criterias.length) {
+          BeatchQueryParam(params, res => {
+            res.Content.map(child => {
+              this.pointData.forEach(head => {
+                if (head.InfoPointCode == child.code) {
+                  this.exhibitionEnergy.dynamic.push({
+                    InfoPointCode: head.InfoPointCode,
+                    InfoPointName: head.InfoPointName,
+                    Path: head.Path,
+                    value: child.value,
+                    data: child.data || '--',
+                    receivetime: child.receivetime || '',
+                    error: child.error || '',
+                    Unit: head.Unit || ''
+                  })
+                }
+              })
+            });
+          })
+        }
+      })
+    },
+    handleEnclosure() {
+      //图片文件处理,脱离radio控制
+      let isList = this.pointData
+      let isArr = []
+      isList.map(j => {
+        if (this.instance.hasOwnProperty(j.Path)) {
+          return {
+            ...j,
+            value: this.instance[j.Path]
+          }
+        }
+      })
+      isArr = isList.filter(k => k.value)
+      this.handlePicList(isArr)
+      this.handleFileList(isArr)
+    },
+    handleRadios(val) { //判断radio的值显示关键信息,基本信息,图片,文件
+      let arr = []
+      //关键信息点
+      this.exhibitionCrux.cruxArray = this.pointData.filter(i => i.KeyWord)
+      this.exhibitionCrux.cruxArray.map(i => {
+        if (this.instance.hasOwnProperty(i.Path)) {
+          return {
+            ...i,
+            value: this.instance[i.Path]
+          }
+        }
+      })
+      if (val == 1) { //需采集信息
+        arr = this.pointData.filter(i => i.Visible)
+        //  图片和的处理
+        // this.handlePicList(arr)
+        // //  文件处理
+        // this.handleFileList(arr)
+
+      } else if (val == 2) { //有值信息点
+        let list = this.pointData
+        list.map(j => {
+          if (this.instance.hasOwnProperty(j.Path)) {
+            return {
+              ...j,
+              value: this.instance[j.Path]
+            }
+          }
+          arr = list.filter(k => k.value)
+          // this.handlePicList(arr)
+          // this.handleFileList(arr)
+        })
+      } else { //全部信息点
+        arr = this.pointData
+        // this.handlePicList(arr)
+        // this.handleFileList(arr)
       }
-      zoneQuery(pa, res => {
-        this.spaceDetails = res.Content[0];
+      this.displayData(arr)
+    },
+    handlePicList(arr) {
+      let picObject = {}
+      //处理数据格式
+      arr.map(i => {
+        if (i.InputMode == 'F2') {
+          switch (i.Path) {
+            case 'LedgerParam.PhotoDoc.Drawing':
+            case 'LedgerParam.Siteinstall.InstallPic':
+            case 'LedgerParam.Siteinstall.InstallDrawing':
+            case 'LedgerParam.PhotoDoc.Nameplate':
+              if (this.instance.hasOwnProperty(i.Path)) {
+                i.PicList = this.instance[i.Path]
+              }
+              if (picObject[i.InfoPointName]) {
+
+              } else {
+                picObject[i.InfoPointName] = []
+              }
+              picObject[i.InfoPointName].push({
+                ...i,
+              })
+              break;
+
+          }
+        }
+
       })
+      //展示图片
+      this.exhibitionImage.list = picObject
+      let isArray = [] //获取图片数组
+      for (let i in picObject) {
+        if (Array.isArray(picObject[i])) {
+          let list = picObject[i]
+          list.forEach(i => {
+            if (i.PicList) {
+              isArray.push(...i.PicList)
+            }
+          })
+        }
+      }
+      let video = isArray.filter(i => i.Type != 'image' &&i.type != 'image' )
+      this.exhibitionVideo.list = video
+      //判断是否显示图片组件
+      this.isShowImage = isArray.length ? true : false
+      //判断是否显示video组件
+      this.isShowVideo = video.length ? true : false
+    },
+    handleFileList(arr) {
+      let picObject = {}
+      //处理数据格式
+      arr.map(i => {
+        if (i.InputMode == 'F2') {
+          switch (i.Path) {
+            case 'LedgerParam.InsuranceDoc.InsuranceFile':
+            case 'LedgerParam.PhotoDoc.Archive':
+            case 'LedgerParam.Siteinstall.CheckReport':
+              if (this.instance.hasOwnProperty(i.Path)) {
+                i.fileList = this.instance[i.Path]
+              }
+              if (picObject[i.InfoPointName]) {
+
+              } else {
+                picObject[i.InfoPointName] = []
+              }
+
+              picObject[i.InfoPointName].push({
+                ...i,
+              })
+              break
+          }
+        }
+
+      })
+      //展示文件
+      this.exhibitionFile.list = picObject
+      let isArray = [] //获取文件数组
+      for (let i in picObject) {
+        if (Array.isArray(picObject[i])) {
+          let list = picObject[i]
+          list.forEach(i => {
+            if (i.fileList) {
+              isArray.push(...i.fileList)
+            }
+          })
+        }
+      }
+      //判断是否显示文件组件
+      this.isShowFile = isArray.length ? true : false
+    },
+    changeRadio(val) { //1,需采集,2,有值,3,全部
+      this.handleRadios(val)
+      this.currentRadio = val
+    },
+    formatDate(str) {
+      if(str) {
+        if(str.includes('-')) {
+          return str
+        }else {
+          return  str.substr(0,4)+"-"+str.substr(4,2)+"-"+str.substr(6,2)+" "+str.substr(8,2) + ":" +str.substr(10,2) + ":"+str.substr(12,2)
+        }
+      } else {
+        return '--'
+      }
+    },
+    displayData(arr) {//对数据进行处理传给组件展示
+      const result = {}
+      arr.forEach(i => {
+        if (this.instance.hasOwnProperty(i.Path) && this.currentRadio != 2) {
+          i.value = this.instance[i.Path]
+        }
+        if (i.InputMode == 'C5') {
+          if (this.instance.hasOwnProperty(i.Path)) {
+            let time = this.instance[i.Path]
+            i.value = this.formatDate(time)
+          }
+        }
+        if (i.DataSource && i.DataSource.length) {
+          let source = JSON.parse(i.DataSource)
+          //判断输入类型
+          if (i.InputMode == 'D1L') {
+            let d1l = tools.formatDataSource(i.DataSource)
+            d1l.forEach(k => {
+              if (k.Code == this.instance[i.Path]) {
+                i.value = k.Name
+              }
+            })
+          } else if (i.InputMode == 'D2' || i.InputMode == 'C6') {
+            if (this.instance.hasOwnProperty(i.Path)) {
+              if (!Array.isArray(this.instance[i.Path])) {
+                let transArray = this.instance[i.Path].split(',')
+                i.value = source.filter(item => transArray.includes(item.Code)).map(item => item.Name).join(',')
+              }
+            }
+          }
+          source.forEach(j => {
+            if (j.Code == this.instance[i.Path]) {
+              console.log(j.Name, '===name===')
+              i.value = j.Name
+            }
+          })
+        }
+        switch (i.InputMode) {
+          case "L":
+          case "L1":
+          case "L2":
+          case "M":
+            break;
+          default:
+            if (result[`${i.FirstName}${i.SecondName ? '/' + i.SecondName : ''}`]) {
+              result[`${i.FirstName}${i.SecondName ? '/' + i.SecondName : ''}`].paths.push({
+                Path: i.Path,
+                InfoPointName: i.InfoPointName,
+                InfoPointCode: i.InfoPointCode,
+                Value: i.value,
+                Visible: i.Visible,
+                KeyWord: i.KeyWord,
+                InputMode:i.InputMode
+              })
+            } else {
+              result[`${i.FirstName}${i.SecondName ? '/' + i.SecondName : ''}`] = {
+                paths: [{
+                  Path: i.Path,
+                  InfoPointName: i.InfoPointName,
+                  InfoPointCode: i.InfoPointCode,
+                  Value: i.value,
+                  Visible: i.Visible,
+                  KeyWord: i.KeyWord,
+                  InputMode:i.InputMode
+                }]
+              }
+            }
+
+        }
+
+
+      })
+      this.exhibitionBaseInformation.information = result
+      this.exhibitionCrux.allMessage = result
     },
     // 设置iframe
     setFrame() {
-      this.iframeSrc = this.params.isMyTab == 2 ?
-        `${process.env.BASE_URL}:8889/#/details?perjectId=${this.projectId}&secret=${this.secret}&FmId=${this.params.RoomID}&type=0&code=${this.params.zone}`
-        : `${process.env.BASE_URL}:8889/#/changeMess?perjectId=${this.projectId}&secret=${this.secret}&id=${this.params.RoomID}&type=${this.params.zone}`;
+      this.iframeSrc = `${process.env.BASE_URL}:8889/#/changeMess?perjectId=${this.projectId}&secret=${this.secret}&id=${this.params.RoomID}&type=${this.params.zone}`;
+      // this.iframeSrc = this.params.isMyTab == 2 ?
+      //   `${process.env.BASE_URL}:8889/#/details?perjectId=${this.projectId}&secret=${this.secret}&FmId=${this.params.RoomID}&type=0&code=${this.params.zone}`
+      //   : `${process.env.BASE_URL}:8889/#/changeMess?perjectId=${this.projectId}&secret=${this.secret}&id=${this.params.RoomID}&type=${this.params.zone}`;
     },
     // 删除业务空间
     deleteSpace() {
@@ -96,8 +506,8 @@ export default {
         cancelButtonText: '取消',
         type: 'warning'
       }).then(() => {
-        let pa = [{RoomID: this.spaceDetails.RoomID}]
-        zoneCreate(pa, res => {
+        let pa = [{ RoomID: this.exampleData.RoomID }];
+        zoneDelete(pa, res => {
           this.$message.success('删除成功')
           this.goBack()
         })
@@ -105,7 +515,8 @@ export default {
         this.getData()
         this.$message("取消删除")
       })
-    }
+    },
+
   }
 };
 </script>
@@ -118,8 +529,8 @@ export default {
     height: 100%;
     flex-direction: column;
     border: 1px solid #dfe6ec;
+    box-sizing: border-box;
     background: #fff;
-    margin-bottom: 10px;
     .header {
       padding-bottom: 10px;
       span {
@@ -146,6 +557,55 @@ export default {
         border-bottom: 1px solid #e4e7ed;
       }
     }
+
+    .content {
+      display: flex;
+      flex-direction: row;
+      box-sizing: border-box;
+      height: calc(100% - 99px);
+      .content-left {
+        display: flex;
+        flex-direction: column;
+        flex: 1;
+        .content-showType {
+          height: 50px;
+          border: 1px solid #ccc;
+          border-bottom: none;
+          box-sizing: border-box;
+        }
+        .content-point {
+          display: flex;
+          flex-direction: row;
+          height: calc(100% - 50px);
+          border: 1px solid #ccc;
+          box-sizing: border-box;
+          .content-point-left {
+            flex: 1;
+          }
+          .content-point-right {
+            width: 300px;
+            border-left: 1px solid #ccc;
+          }
+        }
+      }
+      .content-right {
+        width: 400px;
+        margin-left: 10px;
+        .content-repair {
+          height: 50px;
+          line-height: 50px;
+          margin-bottom: 10px;
+          border: 1px solid #ccc;
+          box-sizing: border-box;
+        }
+        .content-media {
+          height: calc(100% - 60px);
+          border: 1px solid #ccc;
+          box-sizing: border-box;
+        }
+      }
+    }
+
     .main {
       margin-top: 10px;
       height: calc(100% - 96px);
@@ -153,6 +613,10 @@ export default {
     .footer {
       margin-bottom: 10px;
     }
+
+    /deep/ .el-scrollbar__wrap {
+      overflow-x: hidden;
+    }
   }
 }
 </style>

+ 432 - 32
src/views/ledger/system/systemDetail/index.vue

@@ -17,8 +17,38 @@
           <el-button size="small" @click="deleteSystem">删除系统</el-button>
         </div>
       </el-row>
-      <div v-if="activeTab=='detail'" style="height:calc(100% - 110px)">
-        <div>开发中...</div>
+      <div v-if="activeTab=='detail'" class="content">
+        <div class="content-left">
+          <div class="content-showType">
+            <selectRadio
+              :selectRadio="selectRadio"
+              @changeRadio="changeRadio"
+            />
+          </div>
+          <div class="content-point">
+            <div class="content-point-left">
+              <el-scrollbar style="height:100%;">
+                <div>
+                  <exhibitionBaseInformation :exhibitionBaseInformation="exhibitionBaseInformation"/>
+                </div>
+              </el-scrollbar>
+            </div>
+          </div>
+        </div>
+        <div class="content-right">
+          <div class="content-repair">
+            <exhibitionMaintain :exhibitionMaintain="exhibitionMaintain"/>
+          </div>
+          <div class="content-media">
+            <el-scrollbar style="height:100%;">
+              <div>
+                <exhibitionImage :exhibitionImage="exhibitionImage" v-show="isShowImage"/>
+                <exhibitionVideo :exhibitionVideo="exhibitionVideo" v-show="isShowVideo"/>
+                <exhibitionFile :exhibitionFile="exhibitionFile" v-show="isShowFile"/>
+              </div>
+            </el-scrollbar>
+          </div>
+        </div>
       </div>
       <!-- 系统内设备 -->
       <deviceTable v-if="activeTab=='Equipment'" :params="params" :type="activeTab"></deviceTable>
@@ -31,26 +61,93 @@
 </template>
 
 <script>
-import { mapGetters } from "vuex"
-import { queryLinkSys, deleteGeneralSys, queryDictionaryHead, buildingQuery } from '@/api/scan/request'
-import cenoteTable from '@/components/ledger/system/table/cenoteTable'
-import deviceTable from '@/components/ledger/system/table/deviceTable'
-import spaceTable from '@/components/ledger/system/table/spaceTable'
-export default {
-  data() {
-    return {
-      params: {}, //参数-包含系统id 分区类型
-      tabsList: [
-        { Code: 'detail', Name: '系统详情' },
-        { Code: 'Equipment', Name: '系统内设备' },
-        { Code: 'cenote', Name: '系统所在竖井' },
-        { Code: 'space', Name: '系统所在业务空间' },
-      ], //tab页
-      activeTab: 'detail', //当前选中的tab
-      systemDetails: {}, //系统信息,
-      spaceType: {},//空间种类
-      floorType: {}
-    }
+  import {mapGetters} from "vuex";
+  import {
+    buildingQuery,
+    deleteGeneralSys,
+    getDataDictionary,
+    queryDictionaryHead,
+    queryLinkSys
+  } from '@/api/scan/request';
+
+  import cenoteTable from '@/components/ledger/system/table/cenoteTable';
+  import deviceTable from '@/components/ledger/system/table/deviceTable';
+  import spaceTable from '@/components/ledger/system/table/spaceTable';
+  import exhibitionBaseInformation from "@/components/ledger/details/detail/exhibitionBaseInformation";
+  import exhibitionFile from "@/components/ledger/details/detail/exhibitionFile";
+  import exhibitionImage from "@/components/ledger/details/detail/exhibitionImage";
+  import selectRadio from "@/components/ledger/details/detail/selectRadio";
+  import exhibitionMaintain from "@/components/ledger/details/detail/exhibitionMaintain";
+  import exhibitionVideo from "@/components/ledger/details/detail/exhibitionVideo";
+  import tools from "@/utils/scan/tools"
+
+
+  export default {
+    data() {
+      return {
+        params: {}, //参数-包含系统id 分区类型
+        tabsList: [
+          {Code: 'detail', Name: '系统详情'},
+          {Code: 'Equipment', Name: '系统内设备'},
+          {Code: 'cenote', Name: '系统所在竖井'},
+          {Code: 'space', Name: '系统所在业务空间'},
+        ], //tab页
+        activeTab: 'detail', //当前选中的tab
+        pointData: [], //信息点数据
+        exampleData: {}, //实例数据
+        spaceType: {},//空间种类
+        floorType: {},
+        currentRadio: '',//当前选中的select
+        selectRadio: {
+          information: '设备信息点',
+          initRadio: '1',
+          radioList: [
+            {
+              value: '显示需采集信息点',
+              label: '1'
+            },
+            {
+              value: '显示有值信息点',
+              label: '2'
+            },
+            {
+              value: '显示全部信息点',
+              label: '3'
+            }
+          ]
+        },
+        exhibitionBaseInformation: {
+          information: {}
+        },
+        exhibitionEnergy: {
+          title: '能耗信息',
+          dynamic: [],
+        },
+        exhibitionMaintain: {
+          title: '维修/维保记录'
+        },
+        exhibitionFile: {
+          title: '文件',
+          list: {}
+        },
+        exhibitionCrux: {
+          title: '关键信息点:',
+          cruxArray: [],
+          allMessage: [],//全部信息点
+        },
+        exhibitionImage: {
+          title: '图片',
+          list: {}
+        },
+        exhibitionVideo: {
+          title: '视频',
+          list: {}
+        },
+        instance: {},//实例信息处理
+        isShowImage: true,
+        isShowVideo: true,
+        isShowFile: true,
+      }
   },
   computed: {
     ...mapGetters("layout", ["projectId", "userId", "secret"])
@@ -58,11 +155,17 @@ export default {
   components: {
     cenoteTable,
     deviceTable,
-    spaceTable
+    spaceTable,
+    exhibitionBaseInformation,
+    exhibitionFile,
+    exhibitionImage,
+    selectRadio,
+    exhibitionMaintain,
+    exhibitionVideo
   },
   created() {
     this.params = this.$route.query;
-    this.getSystemDetails();
+    this.getData();
 
     let pa = {
       Filters: `parentId='Space'`
@@ -94,6 +197,7 @@ export default {
         }
       });
     });
+
   },
   mounted() { },
   watch: {
@@ -107,14 +211,264 @@ export default {
         params: this.params
       })
     },
-    // 查询系统详情
-    getSystemDetails() {
-      let pa = {
-        Filters: `SysID="${this.params.SysID}"`
+    // 获取表头和实例数据
+    getData () {
+      let params1 = {
+        data: {
+          Orders: "sort asc",
+          PageNumber: 1,
+          PageSize: 1000
+        },
+        type: this.params.SysType
+      }, params2 = {
+        Filters: `SysID='${this.params.SysID}'`,
+      };
+      let promise1 = new Promise((resolve, reject) => {
+        getDataDictionary(params1, res => {
+          resolve(res)
+        })
+      })
+      let promise2 = new Promise((resolve, reject) => {
+        queryLinkSys(params2, res => {
+          resolve(res)
+        })
+      })
+      Promise.all([promise1, promise2]).then(values => {
+        this.pointData = values[0].Content;
+        this.exampleData = values[1].Content[0];
+        let obj = this.deepCopy(values[1].Content[0]);
+        obj = tools.flattenKeys(obj);
+        this.instance = obj;
+        this.handleRadios(1)
+        this.handleEnclosure() //处理图片视频文件信息
+      })
+    },
+    deepCopy(obj) {
+      return JSON.parse(JSON.stringify(obj))
+    },
+    handleEnclosure() {
+      //图片文件处理,脱离radio控制
+      let isList = this.pointData
+      let isArr = []
+      isList.map(j => {
+        if (this.instance.hasOwnProperty(j.Path)) {
+          return {
+            ...j,
+            value: this.instance[j.Path]
+          }
+        }
+      })
+      isArr = isList.filter(k => k.value)
+      this.handlePicList(isArr)
+      this.handleFileList(isArr)
+    },
+    handleRadios(val) { //判断radio的值显示关键信息,基本信息,图片,文件
+      let arr = []
+      if (val == 1) { //需采集信息
+        arr = this.pointData.filter(i => i.Visible)
+        //  图片和的处理
+        // this.handlePicList(arr)
+        // //  文件处理
+        // this.handleFileList(arr)
+
+      } else if (val == 2) { //有值信息点
+        let list = this.pointData
+        list.map(j => {
+          if (this.instance.hasOwnProperty(j.Path)) {
+            return {
+              ...j,
+              value: this.instance[j.Path]
+            }
+          }
+          arr = list.filter(k => k.value)
+          // this.handlePicList(arr)
+          // this.handleFileList(arr)
+        })
+      } else { //全部信息点
+        arr = this.pointData
+        // this.handlePicList(arr)
+        // this.handleFileList(arr)
+      }
+      this.displayData(arr)
+    },
+    handlePicList(arr) {
+      let picObject = {}
+      //处理数据格式
+      arr.map(i => {
+        if(i.InputMode == 'F2') {
+          switch (i.Path) {
+            case 'LedgerParam.PhotoDoc.Drawing':
+            case 'LedgerParam.Siteinstall.InstallPic':
+            case 'LedgerParam.Siteinstall.InstallDrawing':
+            case 'LedgerParam.PhotoDoc.Nameplate':
+              if (this.instance.hasOwnProperty(i.Path)) {
+                i.PicList = this.instance[i.Path]
+              }
+              if (picObject[i.InfoPointName]) {
+
+              } else {
+                picObject[i.InfoPointName] = []
+              }
+              picObject[i.InfoPointName].push({
+                ...i,
+              })
+              break;
+
+          }
+        }
+
+      })
+      //展示图片
+      this.exhibitionImage.list = picObject
+      let isArray = [] //获取图片数组
+      for (let i in picObject) {
+        if (Array.isArray(picObject[i])) {
+          let list = picObject[i]
+          list.forEach(i => {
+            if (i.PicList) {
+              isArray.push(...i.PicList)
+            }
+          })
+        }
+      }
+      let video = isArray.filter(i => i.Type != 'image' &&i.type != 'image' )
+      this.exhibitionVideo.list = video
+      //判断是否显示图片组件
+      this.isShowImage = isArray.length ? true : false
+      //判断是否显示video组件
+      this.isShowVideo = video.length ? true : false
+    },
+    handleFileList(arr) {
+      let picObject = {}
+      //处理数据格式
+      arr.map(i => {
+        if (i.InputMode == 'F2') {
+          switch (i.Path) {
+            case 'LedgerParam.InsuranceDoc.InsuranceFile':
+            case 'LedgerParam.PhotoDoc.Archive':
+            case 'LedgerParam.Siteinstall.CheckReport':
+              if (this.instance.hasOwnProperty(i.Path)) {
+                i.fileList = this.instance[i.Path]
+              }
+              if (picObject[i.InfoPointName]) {
+
+              } else {
+                picObject[i.InfoPointName] = []
+              }
+
+              picObject[i.InfoPointName].push({
+                ...i,
+              })
+              break
+          }
+        }
+
+      })
+      //展示文件
+      this.exhibitionFile.list = picObject
+      let isArray = [] //获取文件数组
+      for (let i in picObject) {
+        if (Array.isArray(picObject[i])) {
+          let list = picObject[i]
+          list.forEach(i => {
+            if (i.fileList) {
+              isArray.push(...i.fileList)
+            }
+          })
+        }
+      }
+      //判断是否显示文件组件
+      this.isShowFile = isArray.length ? true : false
+    },
+    changeRadio(val) { //1,需采集,2,有值,3,全部
+      this.handleRadios(val)
+      this.currentRadio = val
+    },
+    formatDate(str) {
+      if(str) {
+        if(str.includes('-')) {
+          return str
+        }else {
+          return  str.substr(0,4)+"-"+str.substr(4,2)+"-"+str.substr(6,2)+" "+str.substr(8,2) + ":" +str.substr(10,2) + ":"+str.substr(12,2)
+        }
+      } else {
+        return '--'
       }
-      queryLinkSys(pa, res => {
-        this.systemDetails = res.Content[0];
+    },
+    displayData(arr) {//对数据进行处理传给组件展示
+      const result = {}
+      arr.forEach(i => {
+        if (this.instance.hasOwnProperty(i.Path) && this.currentRadio != 2) {
+          i.value = this.instance[i.Path]
+        }
+        if (i.InputMode == 'C5') {
+          if (this.instance.hasOwnProperty(i.Path)) {
+            let time = this.instance[i.Path]
+            i.value = this.formatDate(time)
+          }
+        }
+        if (i.DataSource && i.DataSource.length) {
+          let source = JSON.parse(i.DataSource)
+          //判断输入类型
+          if (i.InputMode == 'D1L') {
+            let d1l = tools.formatDataSource(i.DataSource)
+            d1l.forEach(k => {
+              if (k.Code == this.instance[i.Path]) {
+                i.value = k.Name
+              }
+            })
+          } else if (i.InputMode == 'D2' || i.InputMode == 'C6') {
+            if (this.instance.hasOwnProperty(i.Path)) {
+              if (!Array.isArray(this.instance[i.Path])) {
+                let transArray = this.instance[i.Path].split(',')
+                i.value = source.filter(item => transArray.includes(item.Code)).map(item => item.Name).join(',')
+              }
+            }
+          }
+          source.forEach(j => {
+            if (j.Code == this.instance[i.Path]) {
+              console.log(j.Name)
+              i.value = j.Name
+            }
+          })
+        }
+        switch (i.InputMode) {
+          case "L":
+          case "L1":
+          case "L2":
+          case "M":
+            break;
+          default:
+            if (result[`${i.FirstName}${i.SecondName ? '/' + i.SecondName : ''}`]) {
+              result[`${i.FirstName}${i.SecondName ? '/' + i.SecondName : ''}`].paths.push({
+                Path: i.Path,
+                InfoPointName: i.InfoPointName,
+                InfoPointCode: i.InfoPointCode,
+                Value: i.value,
+                Visible: i.Visible,
+                KeyWord: i.KeyWord,
+                InputMode:i.InputMode
+              })
+            } else {
+              result[`${i.FirstName}${i.SecondName ? '/' + i.SecondName : ''}`] = {
+                paths: [{
+                  Path: i.Path,
+                  InfoPointName: i.InfoPointName,
+                  InfoPointCode: i.InfoPointCode,
+                  Value: i.value,
+                  Visible: i.Visible,
+                  KeyWord: i.KeyWord,
+                  InputMode:i.InputMode
+                }]
+              }
+            }
+
+        }
+
+
       })
+      this.exhibitionBaseInformation.information = result
+      this.exhibitionCrux.allMessage = result
     },
     // 删除系统
     deleteSystem() {
@@ -124,7 +478,7 @@ export default {
         type: 'warning'
       }).then(() => {
         let pa = [{
-          SysID: this.systemDetails.SysID
+          SysID: this.exampleData.SysID
         }]
         this.removeSys(pa)
       }).catch(() => {
@@ -150,7 +504,7 @@ export default {
     flex-direction: column;
     border: 1px solid #dfe6ec;
     background: #fff;
-    margin-bottom: 10px;
+    box-sizing: border-box;
     .header {
       padding-bottom: 10px;
       span {
@@ -177,6 +531,49 @@ export default {
         border-bottom: 1px solid #e4e7ed;
       }
     }
+    .content {
+      display: flex;
+      flex-direction: row;
+      box-sizing: border-box;
+      height: calc(100% - 99px);
+      .content-left {
+        display: flex;
+        flex-direction: column;
+        flex: 1;
+        .content-showType {
+          height: 50px;
+          border: 1px solid #ccc;
+          border-bottom: none;
+          box-sizing: border-box;
+        }
+        .content-point {
+          display: flex;
+          flex-direction: row;
+          height: calc(100% - 50px);
+          border: 1px solid #ccc;
+          box-sizing: border-box;
+          .content-point-left {
+            flex: 1;
+          }
+        }
+      }
+      .content-right {
+        width: 400px;
+        margin-left: 10px;
+        .content-repair {
+          height: 50px;
+          line-height: 50px;
+          margin-bottom: 10px;
+          border: 1px solid #ccc;
+          box-sizing: border-box;
+        }
+        .content-media {
+          height: calc(100% - 60px);
+          border: 1px solid #ccc;
+          box-sizing: border-box;
+        }
+      }
+    }
     .main {
       margin-top: 10px;
       height: calc(100% - 96px);
@@ -184,6 +581,9 @@ export default {
     .footer {
       margin-bottom: 10px;
     }
+    /deep/ .el-scrollbar__wrap {
+      overflow-x: hidden;
+    }
   }
 }
 </style>

+ 25 - 51
src/views/model/report/index.vue

@@ -64,84 +64,62 @@
             </el-table-column>
             <el-table-column prop="ElementRangeCheck" label='构件范围检查' width="200">
               <template slot-scope="scope">
-                <!--                <el-badge :value="scope.row.ElementRangeCheck" class="item" type='danger' v-if="scope.row.ElementRangeCheck">-->
-                <!--                </el-badge>-->
+                <el-badge :value="scope.row.ElementRangeCheck" class="item" type='danger'
+                          v-if="scope.row.ElementRangeCheck"/>
                 <i class="msg-icon el-icon-success success-color1" style="font-size:20px;"
                    v-if="scope.row.ElementRangeCheck<=0"></i>
-                <i class="msg-icon el-icon-success error-color1" style="font-size:20px;"
-                   v-if="scope.row.ElementRangeCheck"></i>
               </template>
             </el-table-column>
             <el-table-column prop="FamilyNameCheck" label='设备族编码检查' width="200">
               <template slot-scope="scope">
-                <!--                <el-badge :value="scope.row.FamilyNameCheck" class="item" type='danger' v-if="scope.row.FamilyNameCheck">-->
-                <!--                </el-badge>-->
+                <el-badge :value="scope.row.FamilyNameCheck" class="item" type='danger'
+                          v-if="scope.row.FamilyNameCheck"/>
                 <i class="msg-icon el-icon-success success-color1" style="font-size:20px;"
                    v-if="scope.row.FamilyNameCheck<=0"></i>
-                <i class="msg-icon el-icon-success error-color1" style="font-size:20px;"
-                   v-if="scope.row.FamilyNameCheck"></i>
               </template>
             </el-table-column>
             <el-table-column prop="EquipPartLocationCheck" label='部件所在位置检查' width="200">
               <template slot-scope="scope">
-                <!--                <el-badge :value="scope.row.EquipPartLocationCheck" class="item" type='danger' v-if="scope.row.EquipPartLocationCheck">-->
-                <!--                </el-badge>-->
-                <i class="msg-icon el-icon-success error-color1" style="font-size:20px;"
-                   v-if="scope.row.EquipPartLocationCheck"></i>
-
+                <el-badge :value="scope.row.EquipPartLocationCheck" class="item" type='danger'
+                          v-if="scope.row.EquipPartLocationCheck"/>
                 <i class="msg-icon el-icon-success success-color1" style="font-size:20px;"
                    v-if="scope.row.EquipPartLocationCheck<=0"></i>
               </template>
             </el-table-column>
             <el-table-column prop="ColumnCheck" label='柱边界检查' width="200">
               <template slot-scope="scope">
-                <!--                <el-badge :value="scope.row.ColumnCheck" class="item" type='danger' v-if="scope.row.ColumnCheck">-->
-                <!--                </el-badge>-->
-                <i class="msg-icon el-icon-success error-color1" style="font-size:20px;"
-                   v-if="scope.row.ColumnCheck"></i>
-
+                <el-badge :value="scope.row.ColumnCheck" class="item" type='danger' v-if="scope.row.ColumnCheck"/>
                 <i class="msg-icon el-icon-success success-color1" style="font-size:20px;"
                    v-if="scope.row.ColumnCheck<=0"></i>
               </template>
             </el-table-column>
             <el-table-column prop="ConnectorCheck" label='连接件检查' width="200">
               <template slot-scope="scope">
-                <!--                <el-badge :value="scope.row.ConnectorCheck" class="item" type='danger' v-if="scope.row.ConnectorCheck">-->
-                <!--                </el-badge>-->
-                <i class="msg-icon el-icon-success error-color1" style="font-size:20px;"
-                   v-if="scope.row.ConnectorCheck"></i>
-
+                <el-badge :value="scope.row.ConnectorCheck" class="item" type='danger' v-if="scope.row.ConnectorCheck"/>
                 <i class="msg-icon el-icon-success success-color1" style="font-size:20px;"
                    v-if="scope.row.ConnectorCheck<=0"></i>
               </template>
             </el-table-column>
             <el-table-column prop="SystemNameCheck" label='系统类型名称检查' width="200">
               <template slot-scope="scope">
-                <!--                <el-badge :value="scope.row.SystemNameCheck" class="item" type='danger' v-if="scope.row.SystemNameCheck">-->
-                <!--                </el-badge>-->
-                <i class="msg-icon el-icon-success error-color1" style="font-size:20px;"
-                   v-if="scope.row.SystemNameCheck"></i>
-
+                <el-badge :value="scope.row.SystemNameCheck" class="item" type='danger'
+                          v-if="scope.row.SystemNameCheck"/>
                 <i class="msg-icon el-icon-success success-color1" style="font-size:20px;"
                    v-if="scope.row.SystemNameCheck<=0"></i>
               </template>
             </el-table-column>
             <el-table-column prop="EquipInSpaceCheck" label='未在空间中的设备' width="200">
               <template slot-scope="scope">
-                <!--                <el-badge :value="scope.row.EquipInSpaceCheck" class="item" type='danger' v-if="scope.row.EquipInSpaceCheck">-->
-                <!--                </el-badge>-->
-                <i class="msg-icon el-icon-success error-color1" style="font-size:20px;"
-                   v-if="scope.row.EquipInSpaceCheck"></i>
-
+                <el-badge :value="scope.row.EquipInSpaceCheck" class="item" type='danger'
+                          v-if="scope.row.EquipInSpaceCheck"/>
                 <i class="msg-icon el-icon-success success-color1" style="font-size:20px;"
                    v-if="scope.row.EquipInSpaceCheck<=0"></i>
               </template>
             </el-table-column>
             <el-table-column prop="PipeCheck" label='管段检查' width="200">
               <template slot-scope="scope">
-                <!--                <el-badge :value="scope.row.PipeCheck" class="item" type='danger' v-if="scope.row.PipeCheck">-->
-                <!--                </el-badge>-->
-                <i class="msg-icon el-icon-success error-color1" style="font-size:20px;" v-if="scope.row.PipeCheck"></i>
+                <el-badge :value="scope.row.PipeCheck" class="item" type='danger' v-if="scope.row.PipeCheck"/>
+
 
                 <i class="msg-icon el-icon-success success-color1" style="font-size:20px;"
                    v-if="scope.row.PipeCheck<=0"></i>
@@ -149,22 +127,17 @@
             </el-table-column>
             <el-table-column prop="SystemReferEquipCheck" label='管网及相关设备检查' width="200">
               <template slot-scope="scope">
-                <!--                <el-badge :value="scope.row.SystemReferEquipCheck" class="item" :type='scope.row.SystemReferEquipCheck?"danger":"success"'-->
-                <!--                  v-if="scope.row.SystemReferEquipCheck">-->
-                <!--                </el-badge>-->
-                <i class="msg-icon el-icon-success error-color1" style="font-size:20px;"
-                   v-if="scope.row.SystemReferEquipCheck"></i>
-
+                <el-badge :type='scope.row.SystemReferEquipCheck?"danger":"success"' :value="scope.row.SystemReferEquipCheck"
+                          class="item"
+                          v-if="scope.row.SystemReferEquipCheck"/>
                 <i class="msg-icon el-icon-success success-color1" style="font-size:20px;"
                    v-if="scope.row.SystemReferEquipCheck<=0"></i>
               </template>
             </el-table-column>
             <el-table-column prop="ParameterIntegrityCheck" label='Revit族参数完整性检查' width="200">
               <template slot-scope="scope">
-                <!--                <el-badge :value="scope.row.ParameterIntegrityCheck" class="item" type='danger' v-if="scope.row.ParameterIntegrityCheck">-->
-                <!--                </el-badge>-->
-                <i class="msg-icon el-icon-success error-color1" style="font-size:20px;"
-                   v-if="scope.row.ParameterIntegrityCheck"></i>
+                <el-badge :value="scope.row.ParameterIntegrityCheck" class="item" type='danger'
+                          v-if="scope.row.ParameterIntegrityCheck"/>
 
                 <i class="msg-icon el-icon-success success-color1" style="font-size:20px;"
                    v-if="scope.row.ParameterIntegrityCheck<=0"></i>
@@ -172,11 +145,8 @@
             </el-table-column>
             <el-table-column prop="XyzOverlapCheck" label='xyz坐标重叠检查' width="200">
               <template slot-scope="scope">
-                <!--                <el-badge :value="scope.row.XyzOverlapCheck" class="item" type='danger' v-if="scope.row.XyzOverlapCheck">-->
-                <!--                </el-badge>-->
-                <i class="msg-icon el-icon-success error-color1" style="font-size:20px;"
-                   v-if="scope.row.XyzOverlapCheck"></i>
-
+                <el-badge :value="scope.row.XyzOverlapCheck" class="item" type='danger'
+                          v-if="scope.row.XyzOverlapCheck"/>
                 <i class="msg-icon el-icon-success success-color1" style="font-size:20px;"
                    v-if="scope.row.XyzOverlapCheck<=0"></i>
               </template>
@@ -570,6 +540,10 @@
       }
     }
 
+    /deep/ .el-badge__content--danger {
+      background-color: #F56C6C60;
+    }
+
   }
 
 </style>

+ 1 - 1
src/views/ready/buildfloor/addFloor/index.vue

@@ -1,5 +1,5 @@
 <template>
-  <el-dialog :title="title" :visible.sync="dialogVisible" width="45%" @close="handleClose" id="messageDialog">
+  <el-dialog :title="title" :visible.sync="dialogVisible" width="850px" @close="handleClose" id="messageDialog">
     <el-row>
       <formItems :type="'Floor'" ref="formItems"></formItems>
     </el-row>

+ 2 - 1
src/views/ready/buildfloor/drawGraphy/drawFloor.vue

@@ -10,7 +10,7 @@
 
 <script>
 import { SGraphyView } from "@saga-web/graphy/lib";
-import { DivideFloorScene, FloorView } from "@saga-web/cad-engine/lib"
+import { DivideFloorScene, FloorView, Opt } from "@saga-web/cad-engine/lib"
 import { SColor, SPoint } from "@saga-web/draw/lib";
 import canvasFun from "@/components/business_space/newGraphy/canvasFun"
 import { floorQuery } from "@/api/scan/request";
@@ -53,6 +53,7 @@ export default {
   },
   created() {
     this.FloorID = this.$route.query.FloorID;
+    Opt.sceneMarkColor = new SColor('#00000080');
     if (!this.dialog) {
       this.init();
     }

+ 10 - 4
src/views/ready/buildfloor/index.vue

@@ -108,7 +108,7 @@
     <!-- 添加贯通关系弹窗 -->
     <addConnectivity @refresh="refresh" ref="addConnectivity"/>
     <!-- 查看图片弹窗 -->
-    <checkGraphy :alreadyRelatedModel='alreadyRelatedModel' @refresh="refresh" ref="checkGraphy"></checkGraphy>
+    <checkGraphy :alreadyRelatedModel='alreadyRelatedModel' @refresh="bindRefresh" ref="checkGraphy"></checkGraphy>
   </div>
 
 </template>
@@ -165,6 +165,7 @@
         alreadyRelatedModel: [],
         // currentType: 'add'
         buildMessage: {},
+        selectedBuildIndex: 0
       };
     },
     computed: {
@@ -187,12 +188,13 @@
         buildingQueryAndCount(bdParam, res => {
           this.buildList = res.Content;
           if (this.buildList.length) {
-            this.changeBuild(0);
+            this.changeBuild(this.selectedBuildIndex);
           }
         });
       },
       //change build
       changeBuild(index) {
+        this.selectedBuildIndex = index;
         this.buildList.map(item => {
           item.active = false;
           return item;
@@ -216,7 +218,7 @@
           data: {
             Orders: "sort asc,InfoPointCode asc",
             PageNumber: 1,
-            PageSize: 50
+            PageSize: 1000
           },
           type: 'Building'
         };
@@ -325,6 +327,10 @@
           }).filter(t => t);
         });
       },
+      // 绑定图以后刷新
+      bindRefresh() {
+        this.init();
+      },
       // 创建楼层成功-修改关系成功
       refresh() {
         this.getFloorTableData();
@@ -336,7 +342,7 @@
           manageDeleteFloor(delParam, res => {
             this.$message.success("删除成功");
             this.delDialogVis = false;
-            this.getFloorTableData();
+            this.init();
           });
         } else {
           //todo

+ 4 - 2
src/views/ready/buildfloor/repetitionGraphy.vue

@@ -4,7 +4,7 @@
     <div class="buttons">
       <el-button icon="el-icon-back" size="mini" @click="backRouter"></el-button>
       <el-button v-if="!isEdit" size="mini" @click="changeGraphy">替换平面图</el-button>
-      <el-button v-if="!isEdit" size="mini" @click="editGraphy">编辑平面图</el-button>
+      <el-button v-if="sign&&!isEdit" size="mini" @click="editGraphy">编辑平面图</el-button>
       <el-button v-if="isEdit" size="mini" @click="cancel">取消</el-button>
       <el-button v-if="isEdit" size="mini" @click="confirm" type="primary">确认</el-button>
       <span style="float:right;" v-if="file.FolderName">当前对应的模型文件:{{file.FolderName}} - {{file.FloorName}}</span>
@@ -32,7 +32,8 @@ export default {
       modelId: "", // 
       isEdit: false, // 是否编辑模式
       file: {},
-      alreadyRelatedModel: []
+      alreadyRelatedModel: [],
+      sign: false
     };
   },
   created() {
@@ -118,6 +119,7 @@ export default {
       floorQueryAndSign(floorParam, res => {
         this.alreadyRelatedModel = res.Content.map(t => {
           if (t.FloorID != this.FloorID) return t.ModelId
+          this.sign = t.Sign > 0
         }).filter(t => t);
       });
     },

+ 2 - 1
src/views/ready/collectsetting/index.vue

@@ -697,8 +697,9 @@
           let param = {
             data: {
               Orders: "sort asc,InfoPointCode asc",
+              Distinct: true,
               PageNumber: 1,
-              PageSize: 500
+              PageSize: 1000
             },
             type: code
           };

+ 95 - 57
src/views/relation/relationShip/index.vue

@@ -23,7 +23,7 @@
       <el-row>
         <el-col :span="12">
           <p class="border-left-8">主对象
-            <span>限制条件:对象类型的范围(包括:XXXX类型,XXXX类型)</span></p>
+            <span>{{MainObject}}</span></p>
           <label>所属建筑楼层:</label>
           <el-select disabled v-model="buildValue">
             <el-option
@@ -46,6 +46,8 @@
             placeholder="请输入"
             @keyup.enter.native="queryTable(1)"
             v-model="mainValue"
+            style="margin-left: 5px"
+            class="min-margin"
           >
             <i
               slot="suffix"
@@ -56,7 +58,7 @@
         </el-col>
         <el-col :span="12">
           <p class="border-left-8">从对象
-            <span>(包括:XXXX类型,XXXX类型)</span></p>
+            <span>{{FromObject}}</span></p>
           <label>所属建筑楼层:</label>
           <el-select disabled v-model="buildValue">
             <el-option
@@ -79,6 +81,8 @@
             placeholder="请输入"
             @keyup.enter.native="queryTable(2)"
             v-model="formValue"
+            style="margin-left: 5px"
+            class="min-margin"
           >
             <i
               slot="suffix"
@@ -96,8 +100,7 @@
       <el-table
         :data="tableData"
         :span-method="objectSpanMethod"
-        border
-        :header-cell-style="{background:'#eef1f6',color:'#606266', lineHeight: '30px'}"
+        :header-cell-style="{background:'#e1e4e5',color:'#2b2b2b', lineHeight: '30px'}"
         :cell-style="cellStyle"
         class="table"
       >
@@ -105,31 +108,36 @@
           prop="Name"
           label="全局名称"
           width="180"
-          align="center"
+          align="left"
+          min-width="100"
         >
         </el-table-column>
         <el-table-column
           prop="LocalId"
           label="本地编码"
-          align="center"
+          align="left"
+          min-width="100"
         >
         </el-table-column>
         <el-table-column
           prop="LocalName"
           label="本地名称"
-          align="center"
+          align="left"
+          min-width="100"
         >
         </el-table-column>
         <el-table-column
           prop="CADID"
           label="CADID"
-          align="center"
+          align="left"
+          min-width="100"
         >
         </el-table-column>
         <el-table-column
           label="对象详情"
           prop="btn"
-          align="center"
+          align="left"
+          min-width="90"
         >
           <template slot-scope="scope">
             <el-button
@@ -140,33 +148,34 @@
           </template>
         </el-table-column>
         <el-table-column
+          class-name="td-bl"
           prop="cName"
           label="全局名称"
           width="180"
-          align="center"
+          align="left"
         >
         </el-table-column>
         <el-table-column
           prop="cLocalId"
-          align="center"
+          align="left"
           label="本地编码"
         >
         </el-table-column>
         <el-table-column
           prop="cLocalName"
           label="本地名称"
-          align="center"
+          align="left"
         >
         </el-table-column>
         <el-table-column
           prop="cCADID"
           label="CADID"
-          align="center"
+          align="left"
         >
         </el-table-column>
         <el-table-column
           label="对象详情"
-          align="center"
+          align="left"
         >
           <template slot-scope="scope">
             <el-button
@@ -178,33 +187,54 @@
         </el-table-column>
         <el-table-column
           label="操作"
-          align="center"
+          align="left"
         >
           <template slot-scope="scope">
-            <!--            <el-button-->
-            <!--              size="mini"-->
-            <!--              icon="el-icon-delete"-->
-            <!--              @click="deleteObject(scope.$index, scope.row)">-->
-            <!--            </el-button>-->
-            <el-popconfirm
-              title="确定删除吗?"
-              @onConfirm="deleteObject(scope.$index, scope.row)"
-            >
-              <el-button slot="reference" size="mini" icon="el-icon-delete"/>
-            </el-popconfirm>
+            <!--            <el-popconfirm-->
+            <!--              title="确定删除吗?"-->
+            <!--              @onConfirm="deleteObject(scope.$index, scope.row)"-->
+            <!--            >-->
+            <!--              <el-button slot="reference" size="mini" icon="el-icon-delete"/>-->
+            <!--            </el-popconfirm>-->
+            <!--          </template>-->
+
+            <!--            <el-popover-->
+            <!--              placement="button"-->
+            <!--              width="160"-->
+            <!--              v-model="visible">-->
+            <!--              <p>确定删除吗?</p>-->
+            <!--              <div style="text-align: right; margin: 0">-->
+            <!--                <el-button size="mini" type="text" @click="visible = false">取消</el-button>-->
+            <!--                <el-button type="primary" size="mini" @click="deleteObject(scope.$index, scope.row)">确定</el-button>-->
+            <!--              </div>-->
+            <!--              <el-button slot="reference" size="mini" icon="el-icon-delete"/>-->
+            <!--            </el-popover>-->
+            <el-button slot="reference" size="mini" icon="el-icon-delete"
+                       @click="deleteObject(scope.$index, scope.row)"/>
           </template>
         </el-table-column>
       </el-table>
     </section>
     <!-- 分页 -->
-<!--    <el-pagination-->
-<!--      @size-change="handleSizeChange"-->
-<!--      @current-change="handleCurrentChange"-->
-<!--      :current-page="currentPage"-->
-<!--      :page-sizes="pageSizes"-->
-<!--      :page-size="pageSize" layout="total, sizes, prev, pager, next, jumper" :total="total"-->
-<!--      style="float:right;margin-top:10px;padding:2px 5px;">-->
-<!--    </el-pagination>-->
+    <!--    <el-pagination-->
+    <!--      @size-change="handleSizeChange"-->
+    <!--      @current-change="handleCurrentChange"-->
+    <!--      :current-page="currentPage"-->
+    <!--      :page-sizes="pageSizes"-->
+    <!--      :page-size="pageSize" layout="total, sizes, prev, pager, next, jumper" :total="total"-->
+    <!--      style="float:right;margin-top:10px;padding:2px 5px;">-->
+    <!--    </el-pagination>-->
+    <el-dialog
+      title="提示"
+      :visible.sync="visible"
+      width="30%"
+    >
+      <span>确定删除吗?</span>
+      <span slot="footer" class="dialog-footer">
+    <el-button @click="visible = false">取 消</el-button>
+    <el-button type="primary" @click="confirmDelete">确 定</el-button>
+  </span>
+    </el-dialog>
     <exportExcel
       ref="export"
       :values="values"
@@ -212,7 +242,7 @@
     <addRelationShip
       ref="addShipComponent"
       :values="values"
-      @addShip="addShip"
+      @update="update"
     />
     <editRelationShip
       ref="editShipComponent"
@@ -226,19 +256,22 @@
   import exportExcel from "../../../components/relation/relationShip/Modal/exportExcel";
   import addRelationShip from "../../../components/relation/relationShip/Modal/addRelationShip";
   import editRelationShip from "../../../components/relation/relationShip/Modal/editRelationShip";
-  import {relAdd, relDelete, relQuery} from "../../../api/relation/api";
+  import {relDelete, relQuery} from "../../../api/relation/api";
 
   export default {
     name: "index",
     data() {
       return {
+        visible: false,
+        MainObject: `(限制条件:对象类型的范围(包括:${localStorage.getItem('MainObject')}类型)`,
+        FromObject: `(限制条件:对象类型的范围(包括:${localStorage.getItem('FromObject')}类型)`,
         pageSizes: [10, 20, 50, 100],
         pageSize: 50,
         currentPage: 1,
         total: 0,
         values: {
           relation_maintenance: '关系维护',
-          optionTips: '请下载最新最新 xxxx 数据进行手动维护', //请下载最新最新 xxxx 数据进行手动维护
+          optionTips: `请下载最新最新<${localStorage.getItem('RelationTypeName')}>数据进行手动维护`, //请下载最新最新 xxxx 数据进行手动维护
           currentNum: '当前关系数量:',
           download: '下载模板(含数据)',
           lastTime: '最后更新时间为', //最后更新时间为
@@ -307,8 +340,9 @@
           }]
         }],
         tableData: [],
+        delParam: {},
         loading: false,
-        needMergeArr: ['Name', 'LocalId', 'LocalName', 'CADID','btn'],
+        needMergeArr: ['Name', 'LocalId', 'LocalName', 'CADID', 'btn'],
         rowMergeArrs: {}
         // needMergeArr: ['name', 'id'], // 有合并项的列
         // rowMergeArrs: {}, // 包含需要一个或多个合并项信息的对象
@@ -324,7 +358,7 @@
         path: '/relation/overview'
       },
         {
-          label: '设备控制关系',
+          label: localStorage.getItem('RelationTypeName'),
         },
       ])
       this.init()
@@ -418,22 +452,6 @@
           console.log(res, '==object==')
         })
       },
-      addShip(index) {
-        let that = this
-        relAdd(index).then(res => {
-          if (res.data.Result === "failure") {
-            this.$message.error(res.data.Message);
-            return false
-          } else if (res.data.Result === "success") {
-            this.$message.success(res.data.Message);
-            this.init()
-            that.$refs.addShipComponent.addShipDialog = false
-            that.$refs.addShipComponent.codeValue = ''
-            that.$refs.addShipComponent.ruleForm.codeList = [{value:''}]
-            that.$refs.addShipComponent.ruleForm.main = ''
-          }
-        })
-      },
       //分页更换size
       handleSizeChange(val) {
         this.currentPage = 1;
@@ -445,19 +463,31 @@
         this.currentPage = val;
         this.init()
       },
+      update() {
+        this.init()
+      },
       lookOver(index, row) {
+
         console.log(index, row)
 
         // this.$refs.editShipComponent.editShipDialog = true
       },
       deleteObject(index, row) {
-        let param = {
+        this.visible = true
+        this.delParam = {
           "FromId": row.Id,
           "RelType": localStorage.getItem('RelManualType'),
           "ToId": row.cId
         }
-        relDelete(param, res => {
+        // relDelete(param, res => {
+        //   this.init()
+        // })
+      },
+      confirmDelete() {
+        relDelete(this.delParam, res => {
           this.init()
+          this.visible = false
+          this.$message.success('删除成功')
         })
       },
       cellStyle({row, column, rowIndex, columnIndex}) {
@@ -514,6 +544,12 @@
 
 <style scoped lang="less">
   .relation-ship {
+    @media screen and (max-width: 1500px) {
+      .min-margin{
+        margin-top: 10px;
+      }
+    }
+
     .cursor {
       cursor: pointer;
     }
@@ -525,6 +561,8 @@
     /deep/ .el-input {
       width: auto;
     }
+    /deep/.el-table__body-wrappe {
+    }
 
     .table-list {
       width: 100%;