Merge branch 'antd-vue' of https://git.coding.net/chiangbt/superglobevue
Showing
7 changed files
with
244 additions
and
28 deletions
| ... | @@ -2410,6 +2410,14 @@ | ... | @@ -2410,6 +2410,14 @@ |
| 2410 | "integrity": "sha1-3TeelPDbgxCwgpH51kwyCXZmF/0=", | 2410 | "integrity": "sha1-3TeelPDbgxCwgpH51kwyCXZmF/0=", |
| 2411 | "dev": true | 2411 | "dev": true |
| 2412 | }, | 2412 | }, |
| 2413 | "async-validator": { | ||
| 2414 | "version": "1.8.5", | ||
| 2415 | "resolved": "https://registry.npmjs.org/async-validator/-/async-validator-1.8.5.tgz", | ||
| 2416 | "integrity": "sha512-tXBM+1m056MAX0E8TL2iCjg8WvSyXu0Zc8LNtYqrVeyoL3+esHRZ4SieE9fKQyyU09uONjnMEjrNBMqT0mbvmA==", | ||
| 2417 | "requires": { | ||
| 2418 | "babel-runtime": "6.x" | ||
| 2419 | } | ||
| 2420 | }, | ||
| 2413 | "asynckit": { | 2421 | "asynckit": { |
| 2414 | "version": "0.4.0", | 2422 | "version": "0.4.0", |
| 2415 | "resolved": "https://registry.npm.taobao.org/asynckit/download/asynckit-0.4.0.tgz", | 2423 | "resolved": "https://registry.npm.taobao.org/asynckit/download/asynckit-0.4.0.tgz", |
| ... | @@ -2536,6 +2544,11 @@ | ... | @@ -2536,6 +2544,11 @@ |
| 2536 | "resolve": "^1.12.0" | 2544 | "resolve": "^1.12.0" |
| 2537 | } | 2545 | } |
| 2538 | }, | 2546 | }, |
| 2547 | "babel-helper-vue-jsx-merge-props": { | ||
| 2548 | "version": "2.0.3", | ||
| 2549 | "resolved": "https://registry.npmjs.org/babel-helper-vue-jsx-merge-props/-/babel-helper-vue-jsx-merge-props-2.0.3.tgz", | ||
| 2550 | "integrity": "sha512-gsLiKK7Qrb7zYJNgiXKpXblxbV5ffSwR0f5whkPAaBAR4fhi6bwRZxX9wBlIc5M/v8CCkXUbXZL4N/nSE97cqg==" | ||
| 2551 | }, | ||
| 2539 | "babel-jest": { | 2552 | "babel-jest": { |
| 2540 | "version": "24.9.0", | 2553 | "version": "24.9.0", |
| 2541 | "resolved": "https://registry.npm.taobao.org/babel-jest/download/babel-jest-24.9.0.tgz?cache=0&sync_timestamp=1566444289086&other_urls=https%3A%2F%2Fregistry.npm.taobao.org%2Fbabel-jest%2Fdownload%2Fbabel-jest-24.9.0.tgz", | 2554 | "resolved": "https://registry.npm.taobao.org/babel-jest/download/babel-jest-24.9.0.tgz?cache=0&sync_timestamp=1566444289086&other_urls=https%3A%2F%2Fregistry.npm.taobao.org%2Fbabel-jest%2Fdownload%2Fbabel-jest-24.9.0.tgz", |
| ... | @@ -2638,7 +2651,6 @@ | ... | @@ -2638,7 +2651,6 @@ |
| 2638 | "version": "6.26.0", | 2651 | "version": "6.26.0", |
| 2639 | "resolved": "https://registry.npm.taobao.org/babel-runtime/download/babel-runtime-6.26.0.tgz", | 2652 | "resolved": "https://registry.npm.taobao.org/babel-runtime/download/babel-runtime-6.26.0.tgz", |
| 2640 | "integrity": "sha1-llxwWGaOgrVde/4E/yM3vItWR/4=", | 2653 | "integrity": "sha1-llxwWGaOgrVde/4E/yM3vItWR/4=", |
| 2641 | "dev": true, | ||
| 2642 | "requires": { | 2654 | "requires": { |
| 2643 | "core-js": "^2.4.0", | 2655 | "core-js": "^2.4.0", |
| 2644 | "regenerator-runtime": "^0.11.0" | 2656 | "regenerator-runtime": "^0.11.0" |
| ... | @@ -2647,14 +2659,12 @@ | ... | @@ -2647,14 +2659,12 @@ |
| 2647 | "core-js": { | 2659 | "core-js": { |
| 2648 | "version": "2.6.10", | 2660 | "version": "2.6.10", |
| 2649 | "resolved": "https://registry.npm.taobao.org/core-js/download/core-js-2.6.10.tgz?cache=0&sync_timestamp=1575309477270&other_urls=https%3A%2F%2Fregistry.npm.taobao.org%2Fcore-js%2Fdownload%2Fcore-js-2.6.10.tgz", | 2661 | "resolved": "https://registry.npm.taobao.org/core-js/download/core-js-2.6.10.tgz?cache=0&sync_timestamp=1575309477270&other_urls=https%3A%2F%2Fregistry.npm.taobao.org%2Fcore-js%2Fdownload%2Fcore-js-2.6.10.tgz", |
| 2650 | "integrity": "sha1-iluDkfjMcBPacDQRzltYVwYwDX8=", | 2662 | "integrity": "sha1-iluDkfjMcBPacDQRzltYVwYwDX8=" |
| 2651 | "dev": true | ||
| 2652 | }, | 2663 | }, |
| 2653 | "regenerator-runtime": { | 2664 | "regenerator-runtime": { |
| 2654 | "version": "0.11.1", | 2665 | "version": "0.11.1", |
| 2655 | "resolved": "https://registry.npm.taobao.org/regenerator-runtime/download/regenerator-runtime-0.11.1.tgz", | 2666 | "resolved": "https://registry.npm.taobao.org/regenerator-runtime/download/regenerator-runtime-0.11.1.tgz", |
| 2656 | "integrity": "sha1-vgWtf5v30i4Fb5cmzuUBf78Z4uk=", | 2667 | "integrity": "sha1-vgWtf5v30i4Fb5cmzuUBf78Z4uk=" |
| 2657 | "dev": true | ||
| 2658 | } | 2668 | } |
| 2659 | } | 2669 | } |
| 2660 | }, | 2670 | }, |
| ... | @@ -5016,6 +5026,26 @@ | ... | @@ -5016,6 +5026,26 @@ |
| 5016 | "integrity": "sha1-pvfhx5AlwrBYOOjjRPbonrgyE6g=", | 5026 | "integrity": "sha1-pvfhx5AlwrBYOOjjRPbonrgyE6g=", |
| 5017 | "dev": true | 5027 | "dev": true |
| 5018 | }, | 5028 | }, |
| 5029 | "element-ui": { | ||
| 5030 | "version": "2.13.0", | ||
| 5031 | "resolved": "https://registry.npmjs.org/element-ui/-/element-ui-2.13.0.tgz", | ||
| 5032 | "integrity": "sha512-KYsHWsBXYbLELS8cdfvgJTOMSUby3UEjvsPV1V1VmgJ/DdkOAS4z3MiOrPxrT9w2Cc5lZ4eVSQiGhYFR5NVChw==", | ||
| 5033 | "requires": { | ||
| 5034 | "async-validator": "~1.8.1", | ||
| 5035 | "babel-helper-vue-jsx-merge-props": "^2.0.0", | ||
| 5036 | "deepmerge": "^1.2.0", | ||
| 5037 | "normalize-wheel": "^1.0.1", | ||
| 5038 | "resize-observer-polyfill": "^1.5.0", | ||
| 5039 | "throttle-debounce": "^1.0.1" | ||
| 5040 | }, | ||
| 5041 | "dependencies": { | ||
| 5042 | "deepmerge": { | ||
| 5043 | "version": "1.5.2", | ||
| 5044 | "resolved": "https://registry.npmjs.org/deepmerge/-/deepmerge-1.5.2.tgz", | ||
| 5045 | "integrity": "sha512-95k0GDqvBjZavkuvzx/YqVLv/6YYa17fz6ILMSf7neqQITCPbnfEnQvEgMPNjH4kgobe7+WIL0yJEHku+H3qtQ==" | ||
| 5046 | } | ||
| 5047 | } | ||
| 5048 | }, | ||
| 5019 | "elliptic": { | 5049 | "elliptic": { |
| 5020 | "version": "6.5.2", | 5050 | "version": "6.5.2", |
| 5021 | "resolved": "https://registry.npm.taobao.org/elliptic/download/elliptic-6.5.2.tgz", | 5051 | "resolved": "https://registry.npm.taobao.org/elliptic/download/elliptic-6.5.2.tgz", |
| ... | @@ -9785,6 +9815,11 @@ | ... | @@ -9785,6 +9815,11 @@ |
| 9785 | "integrity": "sha1-suHE3E98bVd0PfczpPWXjRhlBVk=", | 9815 | "integrity": "sha1-suHE3E98bVd0PfczpPWXjRhlBVk=", |
| 9786 | "dev": true | 9816 | "dev": true |
| 9787 | }, | 9817 | }, |
| 9818 | "normalize-wheel": { | ||
| 9819 | "version": "1.0.1", | ||
| 9820 | "resolved": "https://registry.npmjs.org/normalize-wheel/-/normalize-wheel-1.0.1.tgz", | ||
| 9821 | "integrity": "sha1-rsiGr/2wRQcNhWRH32Ls+GFG7EU=" | ||
| 9822 | }, | ||
| 9788 | "npm-run-path": { | 9823 | "npm-run-path": { |
| 9789 | "version": "2.0.2", | 9824 | "version": "2.0.2", |
| 9790 | "resolved": "https://registry.npm.taobao.org/npm-run-path/download/npm-run-path-2.0.2.tgz?cache=0&sync_timestamp=1571055779038&other_urls=https%3A%2F%2Fregistry.npm.taobao.org%2Fnpm-run-path%2Fdownload%2Fnpm-run-path-2.0.2.tgz", | 9825 | "resolved": "https://registry.npm.taobao.org/npm-run-path/download/npm-run-path-2.0.2.tgz?cache=0&sync_timestamp=1571055779038&other_urls=https%3A%2F%2Fregistry.npm.taobao.org%2Fnpm-run-path%2Fdownload%2Fnpm-run-path-2.0.2.tgz", |
| ... | @@ -11495,6 +11530,11 @@ | ... | @@ -11495,6 +11530,11 @@ |
| 11495 | "integrity": "sha1-kl0mAdOaxIXgkc8NpcbmlNw9yv8=", | 11530 | "integrity": "sha1-kl0mAdOaxIXgkc8NpcbmlNw9yv8=", |
| 11496 | "dev": true | 11531 | "dev": true |
| 11497 | }, | 11532 | }, |
| 11533 | "resize-observer-polyfill": { | ||
| 11534 | "version": "1.5.1", | ||
| 11535 | "resolved": "https://registry.npmjs.org/resize-observer-polyfill/-/resize-observer-polyfill-1.5.1.tgz", | ||
| 11536 | "integrity": "sha512-LwZrotdHOo12nQuZlHEmtuXdqGoOD0OhaxopaNFxWzInpEgaLWoVuAMbTzixuosCx2nEG58ngzW3vxdWoxIgdg==" | ||
| 11537 | }, | ||
| 11498 | "resolve": { | 11538 | "resolve": { |
| 11499 | "version": "1.13.1", | 11539 | "version": "1.13.1", |
| 11500 | "resolved": "https://registry.npm.taobao.org/resolve/download/resolve-1.13.1.tgz", | 11540 | "resolved": "https://registry.npm.taobao.org/resolve/download/resolve-1.13.1.tgz", |
| ... | @@ -12762,6 +12802,11 @@ | ... | @@ -12762,6 +12802,11 @@ |
| 12762 | "integrity": "sha1-iQN8vJLFarGJJua6TLsgDhVnKmo=", | 12802 | "integrity": "sha1-iQN8vJLFarGJJua6TLsgDhVnKmo=", |
| 12763 | "dev": true | 12803 | "dev": true |
| 12764 | }, | 12804 | }, |
| 12805 | "throttle-debounce": { | ||
| 12806 | "version": "1.1.0", | ||
| 12807 | "resolved": "https://registry.npmjs.org/throttle-debounce/-/throttle-debounce-1.1.0.tgz", | ||
| 12808 | "integrity": "sha512-XH8UiPCQcWNuk2LYePibW/4qL97+ZQ1AN3FNXwZRBNPPowo/NRU5fAlDCSNBJIYCKbioZfuYtMhG4quqoJhVzg==" | ||
| 12809 | }, | ||
| 12765 | "through": { | 12810 | "through": { |
| 12766 | "version": "2.3.8", | 12811 | "version": "2.3.8", |
| 12767 | "resolved": "https://registry.npm.taobao.org/through/download/through-2.3.8.tgz", | 12812 | "resolved": "https://registry.npm.taobao.org/through/download/through-2.3.8.tgz", | ... | ... |
| ... | @@ -101,5 +101,16 @@ export default { | ... | @@ -101,5 +101,16 @@ export default { |
| 101 | </script> | 101 | </script> |
| 102 | 102 | ||
| 103 | <style> | 103 | <style> |
| 104 | 104 | .sm-compass { | |
| 105 | pointer-events: auto; | ||
| 106 | position: absolute; | ||
| 107 | right: 10px; | ||
| 108 | top: 70px; | ||
| 109 | width: 128px; | ||
| 110 | height: 128px; | ||
| 111 | overflow: hidden; | ||
| 112 | } | ||
| 113 | .sm-zoom { | ||
| 114 | top: 190px; | ||
| 115 | } | ||
| 105 | </style> | 116 | </style> | ... | ... |
| 1 | <!-- | 1 | <!-- |
| 2 | * @Author: jiangbotao | 2 | * @Author: jiangbotao |
| 3 | * 本例中使用了铁岭的倾斜摄影数据发布的服务 | ||
| 4 | * 1、必须同时发布为三维和Rest服务 | ||
| 5 | * 2、使用要素查询方式来选择倾斜摄影覆盖面 | ||
| 6 | * 3、使用Popup来弹出倾斜摄影覆盖面的信息 | ||
| 3 | * @Date: 2019-12-03 22:52:56 | 7 | * @Date: 2019-12-03 22:52:56 |
| 4 | * @LastEditors: jiangbotao | 8 | * @LastEditors: jiangbotao |
| 5 | * @LastEditTime: 2019-12-04 23:31:19 | 9 | * @LastEditTime: 2019-12-05 21:30:15 |
| 6 | * @FilePath: \superglobevue\src\components\viewer.vue | 10 | * @FilePath: \superglobevue\src\components\viewer.vue |
| 7 | --> | 11 | --> |
| 8 | <template> | 12 | <template> |
| ... | @@ -28,6 +32,14 @@ | ... | @@ -28,6 +32,14 @@ |
| 28 | <div class="circle4"></div> | 32 | <div class="circle4"></div> |
| 29 | </div> | 33 | </div> |
| 30 | </div> | 34 | </div> |
| 35 | <!-- 气泡HTML --> | ||
| 36 | <div id="bubble" class="bubble" style="bottom:0;left:82%;display:none;" > | ||
| 37 | <div id="tools" style="text-align : right"> | ||
| 38 | <span style="color: rgb(95, 74, 121);padding: 5px;position: absolute;left: 10px;top: 4px;">对象属性</span> | ||
| 39 | <span class="fui-cross" title="关闭" id="close" style="color: darkgrey;padding:5px"></span> | ||
| 40 | </div> | ||
| 41 | <div style="overflow-y:scroll;height:150px" id="tableContainer"><table id="tab"></table></div> | ||
| 42 | </div> | ||
| 31 | </div> | 43 | </div> |
| 32 | </template> | 44 | </template> |
| 33 | 45 | ||
| ... | @@ -52,6 +64,7 @@ export default { | ... | @@ -52,6 +64,7 @@ export default { |
| 52 | }, | 64 | }, |
| 53 | mounted: function() { | 65 | mounted: function() { |
| 54 | this.viewer = new Cesium.Viewer("cesiumContainer", { navigationInstructionsInitiallyVisible: false }); | 66 | this.viewer = new Cesium.Viewer("cesiumContainer", { navigationInstructionsInitiallyVisible: false }); |
| 67 | // 使用自定义的navigation | ||
| 55 | var options = {}; | 68 | var options = {}; |
| 56 | options.enableCompass= true; | 69 | options.enableCompass= true; |
| 57 | options.enableZoomControls= true; | 70 | options.enableZoomControls= true; |
| ... | @@ -67,21 +80,8 @@ export default { | ... | @@ -67,21 +80,8 @@ export default { |
| 67 | var scene = this.viewer.scene; | 80 | var scene = this.viewer.scene; |
| 68 | var widget = this.viewer.cesiumWidget; | 81 | var widget = this.viewer.cesiumWidget; |
| 69 | var camera = scene.camera; | 82 | var camera = scene.camera; |
| 70 | 83 | // 场景位置,用于popup定位 | |
| 71 | var handler = new Cesium.ScreenSpaceEventHandler(this.viewer.canvas); | 84 | var scenePosition = null; |
| 72 | handler.setInputAction(function(e) { | ||
| 73 | smviewer.entities.removeById('identify-area'); | ||
| 74 | var position = scene.pickPosition(e.position); | ||
| 75 | var cartographic = Cesium.Cartographic.fromCartesian(position); | ||
| 76 | var longitude = Cesium.Math.toDegrees(cartographic.longitude); | ||
| 77 | var latitude = Cesium.Math.toDegrees(cartographic.latitude); | ||
| 78 | var queryPoint = { // 查询点对象 | ||
| 79 | x: longitude, | ||
| 80 | y: latitude | ||
| 81 | }; | ||
| 82 | console.log(queryPoint); | ||
| 83 | queryByPoint(queryPoint); | ||
| 84 | }, Cesium.ScreenSpaceEventType.LEFT_CLICK); | ||
| 85 | 85 | ||
| 86 | try { | 86 | try { |
| 87 | var promise2 = scene.addS3MTilesLayerByScp("http://www.supermapol.com/realspace/services/3D-dynamicDTH/rest/realspace/datas/Config%20-%201/config", | 87 | var promise2 = scene.addS3MTilesLayerByScp("http://www.supermapol.com/realspace/services/3D-dynamicDTH/rest/realspace/datas/Config%20-%201/config", |
| ... | @@ -107,6 +107,41 @@ export default { | ... | @@ -107,6 +107,41 @@ export default { |
| 107 | var dataSourceName = '铁岭矢量面'; // 数据源名称 | 107 | var dataSourceName = '铁岭矢量面'; // 数据源名称 |
| 108 | var dataSetName = 'New_Region3D_1'; // 数据集名称 | 108 | var dataSetName = 'New_Region3D_1'; // 数据集名称 |
| 109 | var dataServiceUrl = 'http://www.supermapol.com/realspace/services/data-dynamicDTH/rest/data/featureResults.rjson?returnContent=true'; | 109 | var dataServiceUrl = 'http://www.supermapol.com/realspace/services/data-dynamicDTH/rest/data/featureResults.rjson?returnContent=true'; |
| 110 | var infoboxContainer = document.getElementById("bubble"); | ||
| 111 | var table = document.getElementById("tab"); | ||
| 112 | |||
| 113 | // 鼠标左键的触发事件,查询要素并弹出显示 | ||
| 114 | var handler = new Cesium.ScreenSpaceEventHandler(this.viewer.canvas); | ||
| 115 | handler.setInputAction(function(e) { | ||
| 116 | smviewer.entities.removeById('identify-area'); | ||
| 117 | var position = scene.pickPosition(e.position); | ||
| 118 | // 设置场景位置 | ||
| 119 | scenePosition = position; | ||
| 120 | var cartographic = Cesium.Cartographic.fromCartesian(position); | ||
| 121 | var longitude = Cesium.Math.toDegrees(cartographic.longitude); | ||
| 122 | var latitude = Cesium.Math.toDegrees(cartographic.latitude); | ||
| 123 | var queryPoint = { // 查询点对象 | ||
| 124 | x: longitude, | ||
| 125 | y: latitude | ||
| 126 | }; | ||
| 127 | // console.log(queryPoint); | ||
| 128 | queryByPoint(queryPoint); | ||
| 129 | }, Cesium.ScreenSpaceEventType.LEFT_CLICK); | ||
| 130 | |||
| 131 | $("#close").click(function(){ // 关闭气泡 | ||
| 132 | $("#bubble").hide(); | ||
| 133 | }); | ||
| 134 | // 每一帧都去计算气泡的正确位置 | ||
| 135 | scene.postRender.addEventListener(function(){ | ||
| 136 | if (scenePosition) { | ||
| 137 | var canvasHeight = scene.canvas.height; | ||
| 138 | var windowPosition = new Cesium.Cartesian2(); | ||
| 139 | Cesium.SceneTransforms.wgs84ToWindowCoordinates(scene, scenePosition, windowPosition); | ||
| 140 | infoboxContainer.style.bottom = (canvasHeight - windowPosition.y + 45) + 'px'; | ||
| 141 | infoboxContainer.style.left = (windowPosition.x - 70) + 'px'; | ||
| 142 | infoboxContainer.style.visibility = "visible"; | ||
| 143 | } | ||
| 144 | }); | ||
| 110 | 145 | ||
| 111 | // 通过点击查询用于表示单体化的面要素,添加到场景中高亮显示。 | 146 | // 通过点击查询用于表示单体化的面要素,添加到场景中高亮显示。 |
| 112 | function queryByPoint(queryPoint) { | 147 | function queryByPoint(queryPoint) { |
| ... | @@ -130,7 +165,20 @@ export default { | ... | @@ -130,7 +165,20 @@ export default { |
| 130 | success: function(result) { | 165 | success: function(result) { |
| 131 | var resultObj = JSON.parse(result); | 166 | var resultObj = JSON.parse(result); |
| 132 | if (resultObj.featureCount > 0) { | 167 | if (resultObj.featureCount > 0) { |
| 133 | addClapFeature(resultObj.features[0]); | 168 | var selectedFeature = resultObj.features[0]; |
| 169 | addClapFeature(selectedFeature); | ||
| 170 | console.log(selectedFeature); | ||
| 171 | $("#bubble").show(); | ||
| 172 | for (var i=table.rows.length-1; i>-1; i--){ | ||
| 173 | table.deleteRow(i); | ||
| 174 | } | ||
| 175 | for(var index in selectedFeature.fieldNames){ | ||
| 176 | var newRow = table.insertRow(); | ||
| 177 | var cell1 = newRow.insertCell(); | ||
| 178 | var cell2 = newRow.insertCell(); | ||
| 179 | cell1.innerHTML = selectedFeature.fieldNames[index]; | ||
| 180 | cell2.innerHTML = selectedFeature.fieldValues[index]; | ||
| 181 | } | ||
| 134 | } | 182 | } |
| 135 | }, | 183 | }, |
| 136 | error: function(msg) { | 184 | error: function(msg) { |
| ... | @@ -168,9 +216,13 @@ export default { | ... | @@ -168,9 +216,13 @@ export default { |
| 168 | 216 | ||
| 169 | <style> | 217 | <style> |
| 170 | .compass { | 218 | .compass { |
| 171 | top: 10px; | 219 | top: 60px; |
| 172 | } | 220 | } |
| 173 | .navigation-controls { | 221 | .navigation-controls { |
| 174 | top: 120px; | 222 | top: 180px; |
| 223 | } | ||
| 224 | .bubble { | ||
| 225 | padding: 10px; | ||
| 226 | border-radius: 10px; | ||
| 175 | } | 227 | } |
| 176 | </style> | 228 | </style> | ... | ... |
| ... | @@ -4,7 +4,7 @@ | ... | @@ -4,7 +4,7 @@ |
| 4 | * 2、添加了超图发布的矢量瓦片服务 | 4 | * 2、添加了超图发布的矢量瓦片服务 |
| 5 | * @Date: 2019-12-02 09:05:50 | 5 | * @Date: 2019-12-02 09:05:50 |
| 6 | * @LastEditors: jiangbotao | 6 | * @LastEditors: jiangbotao |
| 7 | * @LastEditTime: 2019-12-04 22:37:19 | 7 | * @LastEditTime: 2019-12-05 13:14:46 |
| 8 | * @FilePath: \WebGL_Webpack_Vue\components\viewer.vue | 8 | * @FilePath: \WebGL_Webpack_Vue\components\viewer.vue |
| 9 | --> | 9 | --> |
| 10 | <template> | 10 | <template> |
| ... | @@ -90,5 +90,16 @@ export default { | ... | @@ -90,5 +90,16 @@ export default { |
| 90 | </script> | 90 | </script> |
| 91 | 91 | ||
| 92 | <style> | 92 | <style> |
| 93 | 93 | .sm-compass { | |
| 94 | pointer-events: auto; | ||
| 95 | position: absolute; | ||
| 96 | right: 10px; | ||
| 97 | top: 70px; | ||
| 98 | width: 128px; | ||
| 99 | height: 128px; | ||
| 100 | overflow: hidden; | ||
| 101 | } | ||
| 102 | .sm-zoom { | ||
| 103 | top: 190px; | ||
| 104 | } | ||
| 94 | </style> | 105 | </style> |
| ... | \ No newline at end of file | ... | \ No newline at end of file | ... | ... |
| 1 | /* | ||
| 2 | * @Author: jiangbotao | ||
| 3 | * @Date: 2019-12-03 22:31:08 | ||
| 4 | * @LastEditors: jiangbotao | ||
| 5 | * @LastEditTime: 2019-12-05 11:16:09 | ||
| 6 | * @FilePath: \superglobevue\src\main.js | ||
| 7 | */ | ||
| 1 | import Vue from 'vue' | 8 | import Vue from 'vue' |
| 9 | import ElementUI from 'element-ui' | ||
| 10 | import 'element-ui/lib/theme-chalk/index.css' | ||
| 2 | import App from './App.vue' | 11 | import App from './App.vue' |
| 3 | import router from './router' | 12 | import router from './router' |
| 4 | 13 | ||
| 5 | Vue.config.productionTip = false | 14 | Vue.config.productionTip = false |
| 15 | Vue.use(ElementUI) | ||
| 6 | 16 | ||
| 7 | new Vue({ | 17 | new Vue({ |
| 8 | router, | 18 | router, | ... | ... |
| ... | @@ -2,13 +2,66 @@ | ... | @@ -2,13 +2,66 @@ |
| 2 | * @Author: jiangbotao | 2 | * @Author: jiangbotao |
| 3 | * @Date: 2019-12-03 22:31:08 | 3 | * @Date: 2019-12-03 22:31:08 |
| 4 | * @LastEditors: jiangbotao | 4 | * @LastEditors: jiangbotao |
| 5 | * @LastEditTime: 2019-12-05 10:46:13 | 5 | * @LastEditTime: 2019-12-05 21:29:53 |
| 6 | * @FilePath: \superglobevue\src\views\Home.vue | 6 | * @FilePath: \superglobevue\src\views\Home.vue |
| 7 | --> | 7 | --> |
| 8 | <template> | 8 | <template> |
| 9 | <el-container style="height: 100%; border: 1px solid #eee"> | ||
| 10 | <el-container> | ||
| 11 | <el-header style="text-align: left; font-size: 28px"> | ||
| 12 | <i class="el-icon-map-location"></i>三维 | ||
| 13 | </el-header> | ||
| 14 | <el-main> | ||
| 15 | <el-aside width="66px" style="background-color: white"> | ||
| 16 | <el-menu default-active="1-4-1" class="el-menu-vertical-demo" :collapse="isCollapse"> | ||
| 17 | <el-submenu index="1"> | ||
| 18 | <template slot="title"> | ||
| 19 | <i class="el-icon-location"></i> | ||
| 20 | <span slot="title">地图操作</span> | ||
| 21 | </template> | ||
| 22 | <el-menu-item-group> | ||
| 23 | <span slot="title">分组一</span> | ||
| 24 | <el-menu-item index="1-1">选项1</el-menu-item> | ||
| 25 | <el-menu-item index="1-2">选项2</el-menu-item> | ||
| 26 | </el-menu-item-group> | ||
| 27 | <el-menu-item-group title="分组2"> | ||
| 28 | <el-menu-item index="1-3">选项3</el-menu-item> | ||
| 29 | </el-menu-item-group> | ||
| 30 | <el-submenu index="1-4"> | ||
| 31 | <span slot="title">选项4</span> | ||
| 32 | <el-menu-item index="1-4-1">选项1</el-menu-item> | ||
| 33 | </el-submenu> | ||
| 34 | </el-submenu> | ||
| 35 | <el-menu-item index="2"> | ||
| 36 | <i class="el-icon-menu"></i> | ||
| 37 | <span slot="title">空间查询</span> | ||
| 38 | </el-menu-item> | ||
| 39 | <el-submenu index="3"> | ||
| 40 | <template slot="title"> | ||
| 41 | <i class="el-icon-location"></i> | ||
| 42 | <span slot="title">地图操作</span> | ||
| 43 | </template> | ||
| 44 | <el-menu-item-group> | ||
| 45 | <span slot="title">分组一</span> | ||
| 46 | <el-menu-item index="3-1">淹没分析</el-menu-item> | ||
| 47 | <el-menu-item index="3-2">选项2</el-menu-item> | ||
| 48 | </el-menu-item-group> | ||
| 49 | <el-menu-item-group title="分组2"> | ||
| 50 | <el-menu-item index="3-3">选项3</el-menu-item> | ||
| 51 | </el-menu-item-group> | ||
| 52 | <el-submenu index="3-4"> | ||
| 53 | <span slot="title">选项4</span> | ||
| 54 | <el-menu-item index="3-4-1">选项1</el-menu-item> | ||
| 55 | </el-submenu> | ||
| 56 | </el-submenu> | ||
| 57 | </el-menu> | ||
| 58 | </el-aside> | ||
| 9 | <div id="map"> | 59 | <div id="map"> |
| 10 | <viewer></viewer> | 60 | <viewer></viewer> |
| 11 | </div> | 61 | </div> |
| 62 | </el-main> | ||
| 63 | </el-container> | ||
| 64 | </el-container> | ||
| 12 | </template> | 65 | </template> |
| 13 | 66 | ||
| 14 | <script> | 67 | <script> |
| ... | @@ -16,8 +69,41 @@ import viewer from "@/components/viewer_s3m_single.vue"; | ... | @@ -16,8 +69,41 @@ import viewer from "@/components/viewer_s3m_single.vue"; |
| 16 | 69 | ||
| 17 | export default { | 70 | export default { |
| 18 | name: "home", | 71 | name: "home", |
| 72 | data() { | ||
| 73 | return { | ||
| 74 | isCollapse: true | ||
| 75 | }; | ||
| 76 | }, | ||
| 19 | components: { | 77 | components: { |
| 20 | viewer | 78 | viewer |
| 21 | } | 79 | } |
| 22 | }; | 80 | }; |
| 23 | </script> | 81 | </script> |
| 82 | |||
| 83 | <style scoped> | ||
| 84 | .el-header { | ||
| 85 | padding: 12px 20px; | ||
| 86 | -webkit-box-sizing: border-box; | ||
| 87 | box-sizing: border-box; | ||
| 88 | -ms-flex-negative: 0; | ||
| 89 | flex-shrink: 0; | ||
| 90 | position: absolute; | ||
| 91 | z-index: 99; | ||
| 92 | background-color: white; | ||
| 93 | width: 100%; | ||
| 94 | margin-top: -1px; | ||
| 95 | border-bottom: red; | ||
| 96 | border-bottom-style: solid; | ||
| 97 | border-bottom-width: 2px; | ||
| 98 | } | ||
| 99 | .el-aside { | ||
| 100 | width: 200px; | ||
| 101 | position: absolute; | ||
| 102 | height: 100%; | ||
| 103 | z-index: 98; | ||
| 104 | margin-top: 39px; | ||
| 105 | margin-left: -20px; | ||
| 106 | background-color: white; | ||
| 107 | /* background-color: rgb(238, 241, 246); */ | ||
| 108 | } | ||
| 109 | </style> | ... | ... |
-
Please register or sign in to post a comment