2 files modified
1 files added
| | |
| | | * @Author: shuishen 1109946754@qq.com |
| | | * @Date: 2022-08-18 17:00:30 |
| | | * @LastEditors: shuishen 1109946754@qq.com |
| | | * @LastEditTime: 2023-04-22 09:14:55 |
| | | * @LastEditTime: 2023-04-23 20:40:15 |
| | | * @FilePath: \srs-police-affairs\src\components\map\index.vue |
| | | * @Description: 公用地图组件 |
| | | * |
| | |
| | | |
| | | this.$EventBus.$on('layerWallAdd', (params) => { |
| | | that.layerWallAdd(params.layerName, params.positions) |
| | | }) |
| | | |
| | | this.$EventBus.$on('rowLayerWallAdd', (params) => { |
| | | that.rowLayerWallAdd(params.layerName, params.positions) |
| | | }) |
| | | |
| | | this.$EventBus.$on('getOverLayerID', (params) => { |
| | |
| | | layersObjcect[layerName].addOverlay(wall) |
| | | }, |
| | | |
| | | rowLayerWallAdd (layerName, positions) { |
| | | if (!layersObjcect[layerName] || layersObjcect[layerName] == null) { |
| | | this.mapAddLayer(layerName, 'VectorLayer') |
| | | } |
| | | |
| | | let wall = new global.DC.Wall(positions) |
| | | wall.setStyle({ |
| | | material: new global.DC.WallImageTrailMaterialProperty({ |
| | | image: '/images/jjx.png', |
| | | color: global.DC.Namespace.Cesium.Color.fromBytes(255, 255, 0, 180), |
| | | repeat: { x: 20, y: 1 }, |
| | | speed: 10 |
| | | }) |
| | | }) |
| | | layersObjcect[layerName].addOverlay(wall) |
| | | }, |
| | | |
| | | /** |
| | | * @description: 通过ID获取图层 |
| | | * @return {*} |
| | |
| | | // 加载当前活动区域 |
| | | if (params.item.activityArea && params.item.activityArea.length > 0) { |
| | | |
| | | console.log(params.item.activityArea, 36223322) |
| | | |
| | | let polyGonData = params.item.activityArea.slice(11, params.item.activityArea.length - 1) |
| | | polyGonData = polyGonData.replace(/,/g, ";") |
| | | polyGonData = polyGonData.replace(/ /g, ",") |
| | |
| | | |
| | | console.log(newPolyData, 456) |
| | | |
| | | this.$EventBus.$emit('layerWallAdd', { |
| | | this.$EventBus.$emit('rowLayerWallAdd', { |
| | | layerName: 'polygonWallLayer', |
| | | positions: newPolyData |
| | | }) |