浏览代码

地图逻辑

zy 2 年之前
父节点
当前提交
544b0b15d6

+ 6 - 0
neim-biz/src/main/java/com/jiayue/biz/service/impl/HomePageServiceImpl.java

@@ -747,10 +747,13 @@ public class HomePageServiceImpl extends ServiceImpl<WindTowerDataParentTableMap
                 //循环测风塔信息
                 for (Equipment equipment : projectInfo.getEquipment()) {
                     HashMap<String, Object> map = new HashMap<>();
+                    map.put("type", "project");
                     map.put("longitude", equipment.getLongitude());
                     map.put("latitude", equipment.getLatitude());
                     map.put("towerName", equipment.getName());
+                    map.put("towerId", equipment.getId());
                     map.put("projectName", projectInfo.getProjectBasicInfo().getProjectNameEasy());
+                    map.put("projectId", projectInfo.getId());
                     towerList.add(map);
                 }
 
@@ -768,10 +771,13 @@ public class HomePageServiceImpl extends ServiceImpl<WindTowerDataParentTableMap
                 ArrayList<Map<String, Object>> arrayList = new ArrayList<>();
                 for (Equipment equipment : stationInfo.getEquipment()) {
                     HashMap<String, Object> map = new HashMap<>();
+                    map.put("type", "station");
                     map.put("longitude", equipment.getLongitude());
                     map.put("latitude", equipment.getLatitude());
                     map.put("towerName", equipment.getName());
+                    map.put("towerId", equipment.getId());
                     map.put("stationName", stationInfo.getStationBasicInfo().getStationName());
+                    map.put("stationId", stationInfo.getId());
                     arrayList.add(map);
                 }
                 towerList.addAll(arrayList);

+ 1 - 0
neim-ui/src/store/getters.js

@@ -19,5 +19,6 @@ const getters = {
   windAllInfo: state => state.equipmentInfo.windAllInfo,
   stationInfo: state => state.equipmentInfo.stationInfo,
   projectInfo: state => state.equipmentInfo.projectInfo,
+  allPointInfo: state => state.equipmentInfo.allPointInfo,
 }
 export default getters

+ 13 - 18
neim-ui/src/store/modules/equipmentInfo.js

@@ -2,15 +2,10 @@
 const state = {
   projectInfo:sessionStorage.getItem("projectInfo") || {},//项目信息
   stationInfo:sessionStorage.getItem("stationInfo") || {},//场站信息
-  emailWindTowerInfo: {
-    equipmentNo:'',
-    projectId:''
-  },
+  allPointInfo:sessionStorage.getItem("allPointInfo") || [],//场站信息
+  emailWindTowerInfo: sessionStorage.getItem("emailWindTowerInfo") || {},
   windAllInfo:[],
-  realWindTowerInfo: {
-    equipmentNo:'',
-    electricStationId:''
-  },
+  realWindTowerInfo: sessionStorage.getItem("realWindTowerInfo") || {},
 }
 
 const mutations = {
@@ -20,19 +15,16 @@ const mutations = {
   update_stationInfo:(state,value)=>{
     state.stationInfo = value
   },
+  update_allPointInfo:(state,value)=>{
+    state.allPointInfo = value
+  },
   // 修改前期塔编号
   update_emailWindTowerInfo:(state,value)=>{
-    state.emailWindTowerInfo = {
-      equipmentNo:value.equipmentNo,
-      projectId:value.projectId
-    }
+    state.emailWindTowerInfo = value
   },
   // 修改实时塔编号
   update_realWindTowerInfo:(state,value)=>{
-    state.realWindTowerInfo = {
-      equipmentNo:value.equipmentNo,
-      electricStationId:value.electricStationId
-    }
+    state.realWindTowerInfo = value
   },
   // 所有塔信息实时塔编号
   update_windAllInfo:(state,value)=>{
@@ -41,10 +33,10 @@ const mutations = {
 }
 
 const actions = {
-  update_emailWindTowerInfo({ commit },value) {
+  emailWindTowerInfo({ commit },value) {
     commit('update_emailWindTowerInfo',value)
   },
-  update_realWindTowerInfo({ commit },value) {
+  realWindTowerInfo({ commit },value) {
     commit('update_realWindTowerInfo',value)
   },
   update_windAllInfo({ commit },value) {
@@ -56,6 +48,9 @@ const actions = {
   stationInfo({ commit },value) {
     commit('update_stationInfo',value)
   },
+  allPointInfo({ commit },value) {
+    commit('update_allPointInfo',value)
+  },
 }
 
 export default {

+ 19 - 5
neim-ui/src/views/largeScreenPage/Subpage/emailResourcesInfo.vue

@@ -28,8 +28,8 @@
                       <el-option
                         v-for="(item,index) in projectOption"
                         :key="index"
-                        :label="item.projectName"
-                        :value="item.id">
+                        :label="item.label"
+                        :value="item.value">
                       </el-option>
                     </el-select>
                   </div>
@@ -214,7 +214,7 @@ export default {
     return {
       timer: null,
       time: '',
-      project: {},
+      emailWindTowerInfo: {},
       cftInfo:{equipmentNo:'006171',wdHeights:'120,80,10'},
       height: '140',
       projectId:'1',
@@ -244,7 +244,7 @@ export default {
     this.timer = null
   },
   mounted() {
-    this.project = JSON.parse(this.$store.getters.projectInfo)
+    this.emailWindTowerInfo = JSON.parse(this.$store.getters.emailWindTowerInfo)
     this.formatTime()
     this.getProjectSelect()
     this.timer = setInterval(this.formatTime, 1000 * 60)
@@ -252,7 +252,21 @@ export default {
   methods: {
     getProjectSelect(){
       projectSelect().then(res=>{
-        console.log(res.data)
+        this.projectOption = res.data
+        if(this.emailWindTowerInfo !== undefined){
+          this.projectId = this.emailWindTowerInfo.projectId
+          let project = this.projectOption.find(w=>w.value === this.projectId)
+          this.towerOption = project.equipmentDto
+          if(this.emailWindTowerInfo.equipmentNo !== null &&this.emailWindTowerInfo.equipmentNo !== undefined){
+            this.cftNo = this.emailWindTowerInfo.equipmentNo
+          }else{
+            this.cftNo = this.towerOption[0].value
+          }
+        }else{
+          this.projectId = this.projectOption[0].value
+          this.towerOption = this.projectOption[0].equipmentDto
+          this.cftNo = this.towerOption[0].value
+        }
       }).catch(err=>{
         console.log('获取项目列表失败:'+err)
       })

+ 8 - 8
neim-ui/src/views/largeScreenPage/Subpage/preProjectResources.vue

@@ -45,13 +45,13 @@
       </div>
 
       <div class="mapBtuBg">
-        <div id="mapBtuOne" class="mapBtu mapBtuBefore" @click="clickBtu('mapBtuOne')">
+        <div id="mapBtuOne" class="mapBtu mapBtuAfter" @click="clickBtu('mapBtuOne')">
           <span class="mapBtuText">地形图</span>
         </div>
         <!--        <div id="mapBtuTwo" class="mapBtu mapBtuAfter" @click="clickBtu('mapBtuTwo')">-->
         <!--          <span class="mapBtuText">风场气象图</span>-->
         <!--        </div>-->
-        <div id="mapBtuThree" class="mapBtu mapBtuAfter" @click="clickBtu('mapBtuThree')">
+        <div id="mapBtuThree" class="mapBtu mapBtuBefore" @click="clickBtu('mapBtuThree')">
           <span class="mapBtuText">风资源分布图</span>
         </div>
         <!--        <div id="mapBtuFour" class="mapBtu mapBtuAfter" @click="clickBtu('mapBtuFour')">-->
@@ -178,9 +178,9 @@ export default {
       mapMark: 'mapBtuThree',
       //地图传值
       mapValue: {
-        level: '',//地图层级
+        level: null,//地图层级
         center: [],//中心坐标
-        stationInfo: null,//场站坐标
+        allStationInfo: null,//场站坐标
         projectInfo: null,//项目坐标
       },
       projectSeat:[],// 项目位置
@@ -201,9 +201,9 @@ export default {
         this.projectSeat = res.data
         this.mapValue = {
           params: new Date(),
-          level: '',//地图层级
+          level: null,//地图层级
           center: [],//中心坐标
-          stationInfo: null,//场站坐标
+          allStationInfo: null,//场站坐标
           projectInfo: res.data
         }
       }).catch(err => {
@@ -237,9 +237,9 @@ export default {
     clickBtu(id) {
       this.mapValue = {
         params: new Date(),
-        level: '',//地图层级
+        level: null,//地图层级
         center: [],//中心坐标
-        stationInfo: null,//场站坐标
+        allStationInfo: null,//场站坐标
         projectInfo: this.projectSeat
       }
       this.mapMark = id

+ 57 - 5
neim-ui/src/views/largeScreenPage/Subpage/projectInfo.vue

@@ -70,6 +70,12 @@
         </div>
       </div>
     </div>
+    <div v-if="mapMark === 'mapBtuOne'">
+      <bige-map :mapValue="mapValue"/>
+    </div>
+    <div v-else>
+      <bige-heat-map :mapValue="mapValue"/>
+    </div>
     <div class="bottomPushBtu" @click="pushPreProjectResource()">
       <span>前期项目资源信息</span>
     </div>
@@ -77,20 +83,36 @@
 </template>
 
 <script>
-import {projectMapInfo} from "@/api/biz/dataQuery/largeScreenPage";
+import {projectMapInfo,getPointMap} from "@/api/biz/dataQuery/largeScreenPage";
+import bigeMap from "@/views/largeScreenPage/components/bigeMap";
+import bigeHeatMap from "@/views/largeScreenPage/components/bigeHeatMap";
+
 export default {
   name: "projectInfo",
+  components: {
+    bigeMap, bigeHeatMap
+  },
   data() {
     return {
       timer: null,
       time: '',
       project: {},
       projectName: '',
-      coordinates:[],//点坐标
+      coordinates:[],//中心点坐标
       // projectOverview: '依兰县位于黑龙江省中南部。 黑龙江华电哈尔滨依兰鸡冠山四期200MW风电项目中心位于黑龙江省哈尔滨市依兰县东侧15km的鸡冠砬子山上,整个场址为低山丘陵区,场区实际可利用面积约63km2。',
       projectOverview: '',
       // resourcesOverview: '根据风能资源推测120m数据分析,年平均风速为8.007m/s,平均风功率密度为567W/m²,属于3级风场。主风向为WSW,次风向为W,空气密度为1.2kg/m³。'
-      resourcesOverview: ''
+      resourcesOverview: '',
+      mapMark: 'mapBtuOne',
+      //地图传值
+      mapValue: {
+        level: null,//地图层级
+        center: [],//中心坐标
+        allStationInfo: null,//场站坐标
+        projectInfo: null,//项目坐标
+        allPointInfo:null,//所有点位信息
+      },
+      allPointInfo:[]
     }
   },
   destroyed() {
@@ -98,11 +120,28 @@ export default {
     this.timer = null
   },
   mounted() {
-    this.getInfo()
+    this.getPointMap()
     this.formatTime()
     this.timer = setInterval(this.formatTime, 1000 * 60)
   },
   methods: {
+    /*所有风机、塔、拐点坐标信息*/
+    getPointMap(){
+      if(this.$store.getters.allPointInfo.length>0){
+        this.allPointInfo = JSON.parse(this.$store.getters.allPointInfo).info
+        this.getInfo()
+      }else {
+        getPointMap().then(res=>{
+          // console.log(res.data)
+          this.allPointInfo = res.data
+          this.getInfo()
+          sessionStorage.setItem("allPointInfo", JSON.stringify({info:this.allPointInfo}))
+          this.$store.dispatch('equipmentInfo/allPointInfo', JSON.stringify({info:this.allPointInfo}))
+        }).catch(err=>{
+          console.log('所有点位坐标:'+err)
+        })
+      }
+    },
     getInfo() {
       this.project = JSON.parse(this.$store.getters.projectInfo)
       let name = this.project.projectSort
@@ -124,7 +163,15 @@ export default {
         let data = res.data
         this.projectOverview = data.projectOverview
         this.resourcesOverview = data.resourcesOverview
-        this.coordinates = data.coordinates
+        this.coordinates = [Number(data.latitude),Number(data.longitude)]
+        this.mapValue ={
+          params: new Date(),
+          level: 12,//地图层级
+          center: this.coordinates,//中心坐标
+          allStationInfo: null,//场站坐标
+          projectInfo: null,//项目坐标
+          allPointInfo:this.allPointInfo,//所有点位信息
+        }
       }).catch(err=>{
         console.log('单个项目信获取异常:'+err)
       })
@@ -136,6 +183,9 @@ export default {
       this.$router.push({path: "/homepage/projectEvolve"})
     },
     pushInfo() {
+      let project = {projectId:this.project.id,equipmentNo:null}
+      sessionStorage.setItem("emailWindTowerInfo", JSON.stringify(project))
+      this.$store.dispatch('equipmentInfo/emailWindTowerInfo', JSON.stringify(project))
       this.$router.push({path: "/homepage/emailResourcesInfo"})
     },
     back() {
@@ -265,6 +315,7 @@ export default {
   width: 20%;
   display: flex;
   flex-direction: column;
+  z-index: 100000;
 }
 
 .rightBg {
@@ -278,6 +329,7 @@ export default {
   right: 22%;
   top: 7%;
   width: 10%;
+  z-index: 100000;
 }
 
 .rightTiltleTextBg {

+ 9 - 9
neim-ui/src/views/largeScreenPage/Subpage/provincialEnergyStations.vue

@@ -135,11 +135,11 @@ export default {
       },
       //地图传值
       mapValue: {
-        level: '',//地图层级
+        level: null,//地图层级
         center: [],//中心坐标
-        stationInfo: null,//场站坐标
+        allStationInfo: null,//场站坐标
       },
-      stationSeat:[],//场站位置
+      allStationSeat:[],//场站位置
     }
   },
   destroyed() {
@@ -155,13 +155,13 @@ export default {
   methods: {
     getInfo() {
       getStationSeat().then(res=>{
-        // console.log(res.data)
-        this.stationSeat = res.data
+        console.log(res.data)
+        this.allStationSeat = res.data
         this.mapValue = {
           params:new Date(),
-          level: '',//地图层级
+          level: null,//地图层级
           center: [],//中心坐标
-          stationInfo: res.data,//场站坐标
+          allStationInfo: res.data,//场站坐标
         }
       }).catch(err=>{
         console.log('所有场站位置查询异常' + err)
@@ -188,9 +188,9 @@ export default {
     clickBtu(id) {
       this.mapValue = {
         params:new Date(),
-        level: '',//地图层级
+        level: null,//地图层级
         center: [],//中心坐标
-        stationInfo: this.stationSeat,//场站坐标
+        allStationInfo: this.allStationSeat,//场站坐标
       }
       this.mapMark = id
       let clickItem = document.getElementById(id)

+ 53 - 5
neim-ui/src/views/largeScreenPage/Subpage/stationInfo.vue

@@ -67,6 +67,12 @@
         </div>
       </div>
     </div>
+    <div v-if="mapMark === 'mapBtuOne'">
+      <bige-map :mapValue="mapValue"/>
+    </div>
+    <div v-else>
+      <bige-heat-map :mapValue="mapValue"/>
+    </div>
     <div class="bottomPushBtu" @click="pushStationResource()">
       <span>在运风光场站资源管理</span>
     </div>
@@ -75,9 +81,15 @@
 </template>
 
 <script>
-import {stationInfo} from "@/api/biz/dataQuery/largeScreenPage";
+import {getPointMap, stationInfo} from "@/api/biz/dataQuery/largeScreenPage";
+import bigeMap from "@/views/largeScreenPage/components/bigeMap";
+import bigeHeatMap from "@/views/largeScreenPage/components/bigeHeatMap";
+
 export default {
   name: "stationInfo",
+  components: {
+    bigeMap, bigeHeatMap
+  },
   data() {
     return {
       timer: null,
@@ -88,7 +100,17 @@ export default {
         // {category:'二期',fjNum:'30',model:'华锐1.5MW机型',avgWs:'4.7',power:'73125',wd:'西',hour:'1625'},
       ],
       modelT:[],
-      modelFan:[]
+      coordinates:[],
+      mapMark: 'mapBtuOne',
+      //地图传值
+      mapValue: {
+        level: null,//地图层级
+        center: [],//中心坐标
+        allStationInfo: null,//场站坐标
+        projectInfo: null,//项目坐标
+        allPointInfo:null,//所有点位信息
+      },
+      allPointInfo:[]
     }
   },
   destroyed() {
@@ -98,17 +120,41 @@ export default {
   mounted() {
     this.station = JSON.parse(this.$store.getters.stationInfo)
     this.formatTime()
-    this.getInfo()
+    this.getPointMap()
     this.timer = setInterval(this.formatTime, 1000 * 60)
   },
   methods: {
+    /*所有风机、塔、拐点坐标信息*/
+    getPointMap(){
+      if(this.$store.getters.allPointInfo.length>0){
+        this.allPointInfo = JSON.parse(this.$store.getters.allPointInfo).info
+        this.getInfo()
+      }else {
+        getPointMap().then(res=>{
+          // console.log(res.data)
+          this.allPointInfo = res.data
+          this.getInfo()
+          sessionStorage.setItem("allPointInfo", JSON.stringify({info:this.allPointInfo}))
+          this.$store.dispatch('equipmentInfo/allPointInfo', JSON.stringify({info:this.allPointInfo}))
+        }).catch(err=>{
+          console.log('所有点位坐标:'+err)
+        })
+      }
+    },
     getInfo(){
       stationInfo({stationId:this.station.id}).then(res=>{
         console.log(res.data)
         let data = res.data
         this.dataInfo = data.modelT
-        this.modelFan = data.modelFan
-        this.modelT = data.modelT
+        this.coordinates = [Number(data.latitude),Number(data.longitude)]
+        this.mapValue ={
+          params: new Date(),
+          level: 12,//地图层级
+          center: this.coordinates,//中心坐标
+          allStationInfo: null,//场站坐标
+          projectInfo: null,//项目坐标
+          allPointInfo:this.allPointInfo,//所有点位信息
+        }
       }).catch(err=>{
         console.log('场站信息获取异常:'+err)
       })
@@ -246,6 +292,7 @@ export default {
   width: 20%;
   display: flex;
   flex-direction: column;
+  z-index: 1000;
 }
 
 .rightBg {
@@ -259,6 +306,7 @@ export default {
   right: 22%;
   top: 7%;
   width: 10%;
+  z-index: 10000;
 }
 
 .rightTiltleTextBg {

+ 42 - 2
neim-ui/src/views/largeScreenPage/Subpage/stationResources.vue

@@ -78,13 +78,13 @@
       </div>
 
       <div class="mapBtuBg">
-        <div id="mapBtuOne" class="mapBtu mapBtuBefore" @click="clickBtu('mapBtuOne')">
+        <div id="mapBtuOne" class="mapBtu mapBtuAfter" @click="clickBtu('mapBtuOne')">
           <span class="mapBtuText">地形图</span>
         </div>
 <!--        <div id="mapBtuTwo" class="mapBtu mapBtuAfter" @click="clickBtu('mapBtuTwo')">-->
 <!--          <span class="mapBtuText">风场气象图</span>-->
 <!--        </div>-->
-        <div id="mapBtuThree" class="mapBtu mapBtuAfter" @click="clickBtu('mapBtuThree')">
+        <div id="mapBtuThree" class="mapBtu mapBtuBefore" @click="clickBtu('mapBtuThree')">
           <span class="mapBtuText">风资源分布图</span>
         </div>
 <!--        <div id="mapBtuFour" class="mapBtu mapBtuAfter" @click="clickBtu('mapBtuFour')">-->
@@ -95,6 +95,12 @@
         </div>
       </div>
     </div>
+    <div v-if="mapMark === 'mapBtuOne'">
+      <bige-map :mapValue="mapValue"/>
+    </div>
+    <div v-else>
+      <bige-heat-map :mapValue="mapValue"/>
+    </div>
     <div class="bottomPushBtu" @click="pushPreProjectResource()">
       <span>前期项目资源信息</span>
     </div>
@@ -127,8 +133,14 @@
 
 <script>
 import {stationTotalityInfo} from "@/api/biz/dataQuery/largeScreenPage";
+import bigeMap from "@/views/largeScreenPage/components/bigeMap";
+import bigeHeatMap from "@/views/largeScreenPage/components/bigeHeatMap";
+
 export default {
   name: "stationResources",
+  components: {
+    bigeMap, bigeHeatMap
+  },
   data() {
     return {
       timer: null,
@@ -160,6 +172,15 @@ export default {
         // {label: '安达青肯泡光伏电站', value: '12'},
         // {label: '讷河兴旺光伏电站', value: '13'}
       ],
+      mapMark: 'mapBtuThree',
+      //地图传值
+      mapValue: {
+        level: null,//地图层级
+        center: [],//中心坐标
+        allStationInfo: null,//场站坐标
+        projectInfo: null,//项目坐标
+        stationInfo: null
+      },
     }
   },
   destroyed() {
@@ -178,6 +199,14 @@ export default {
         this.fInfo = data.fInfo
         this.gInfo = data.gInfo
         this.stationOptions = data.station
+        this.mapValue = {
+          params: new Date(),
+          level: null,//地图层级
+          center: [],//中心坐标
+          allStationInfo: null,//场站坐标
+          projectInfo: null,
+          staionInfo: data.station
+        }
       }).catch(err=>{
         console.log('场站的总体信息获取异常:'+err)
       })
@@ -199,6 +228,15 @@ export default {
       this.$router.push({path: "/homepage/preProjectResources"})
     },
     clickBtu(id) {
+      this.mapValue = {
+        params: new Date(),
+        level: null,//地图层级
+        center: [],//中心坐标
+        allStationInfo: null,//场站坐标
+        projectInfo: null,
+        staionInfo:this.stationOptions
+      }
+      this.mapMark = id
       let clickItem = document.getElementById(id)
       let activeItem = document.querySelector('.mapBtuBefore')
       activeItem.classList.remove('mapBtuBefore')
@@ -319,6 +357,7 @@ export default {
   width: 20%;
   display: flex;
   flex-direction: column;
+  z-index: 10000;
 }
 
 .rightBg {
@@ -332,6 +371,7 @@ export default {
   right: 22%;
   top: 7%;
   width: 10%;
+  z-index: 100000;
 }
 
 .rightTiltleTextBg {

+ 75 - 13
neim-ui/src/views/largeScreenPage/components/bigeHeatMap.vue

@@ -132,25 +132,53 @@ export default {
           this.bindEvents(this.bMap);
 
         })
-        // 标记点位
-        if (this.mapData.stationInfo !== null) {
-          let data = this.mapData.stationInfo
-          let iconurl = 'http://' + _self.href.split("//")[1].split("/")[0] + '/largeScreenImg/station.png'
+        // 所有场站标记点位
+        if(this.mapData.allStationInfo !== null && this.mapData.allStationInfo !== undefined){
+          let data = this.mapData.allStationInfo
+          let iconurl = 'http://'+_self.href.split("//")[1].split("/")[0]+'/largeScreenImg/station.png'
+          let hfIconurl = 'http://'+_self.href.split("//")[1].split("/")[0]+'/largeScreenImg/huafuStation.png'
 
           let station_icon = window.BM.icon({
             iconUrl: iconurl,
-            iconSize: [30, 50],
-            iconAnchor: [30, 50]
+            iconSize: [25, 43],
+            iconAnchor: [25, 43]
           })
-          for (let item of data) {
-            let coordinate = [Number(item.latitude), Number(item.longitude)]
-            window.BM.marker(coordinate, {
-              icon: station_icon
+          let hf_station_icon = window.BM.icon({
+            iconUrl: hfIconurl,
+            iconSize: [35, 55],
+            iconAnchor: [35, 55]
+          })
+          for(let item of data.otherStation){
+            let coordinate = [Number(item.latitude),Number(item.longitude)]
+            let marker = window.BM.marker(coordinate,{
+              icon: station_icon,
+              riseOnHover: true
+            }).addTo(this.bMap);
+            marker.on('mouseover', function (e) {
+              marker.bindTooltip('<div>场站名称:' + item.stationName + '</div>' + '<div>经度:' + item.longitude + '</div>' + '<div>纬度:' + item.latitude + '</div>',
+                {permanent:true,className:'infoToolTip',offset:[0,-30]}).openTooltip();
+            })
+            marker.on('mouseout', function () {
+              marker.bindTooltip().closeTooltip();
+            })
+          }
+          for(let item of data.HDStation){
+            let coordinate = [Number(item.latitude),Number(item.longitude)]
+            let marker = window.BM.marker(coordinate,{
+              icon: hf_station_icon,
+              riseOnHover: true
             }).addTo(this.bMap);
+            marker.on('mouseover', function (e) {
+              marker.bindTooltip('<div>场站名称:' + item.stationName + '</div>' + '<div>经度:' + item.longitude + '</div>' + '<div>纬度:' + item.latitude + '</div>',
+                {permanent:true,className:'infoToolTip',offset:[0,-30]}).openTooltip();
+            })
+            marker.on('mouseout', function () {
+              marker.bindTooltip().closeTooltip();
+            })
           }
         }
-        // 标记点位
-        if (this.mapData.projectInfo !== null) {
+        // 项目标记点位
+        if (this.mapData.projectInfo !== null && this.mapData.projectInfo !== undefined) {
           let data = this.mapData.projectInfo
           let iconurl = 'http://' + _self.href.split("//")[1].split("/")[0] + '/largeScreenImg/project.png'
 
@@ -167,7 +195,7 @@ export default {
             }).addTo(this.bMap);
             // 悬浮动作
             marker.on('mouseover', function (e) {
-              marker.bindTooltip('<div>项目名称:' + item.projectNameEasy + '</div>' + '<div>经度:' + item.longitude + '</div>' + '<div>纬度:' + item.latitude + '</div>',
+              marker.bindTooltip('<div>场站名称:' + item.projectNameEasy + '</div>' + '<div>经度:' + item.longitude + '</div>' + '<div>纬度:' + item.latitude + '</div>',
                 {permanent:true,className:'infoToolTip',offset:[0,-30]}).openTooltip();
             })
             marker.on('mouseout', function () {
@@ -182,6 +210,40 @@ export default {
             })
           }
         }
+        // 华富场站标记点位
+        if (this.mapData.staionInfo !== null && this.mapData.staionInfo !== undefined) {
+          let data = this.mapData.staionInfo
+          let iconurl = 'http://' + _self.href.split("//")[1].split("/")[0] + '/largeScreenImg/station.png'
+
+          let station_icon = window.BM.icon({
+            iconUrl: iconurl,
+            iconSize: [30, 50],
+            iconAnchor: [30, 50],
+            className:'stationIcon',
+          })
+          for (let item of data) {
+            let coordinate = [Number(item.latitude), Number(item.longitude)]
+            let marker = window.BM.marker(coordinate, {
+              icon: station_icon,
+              riseOnHover: true
+            }).addTo(this.bMap);
+            // 悬浮动作
+            marker.on('mouseover', function (e) {
+              marker.bindTooltip('<div>项目名称:' + item.stationName + '</div>' + '<div>经度:' + item.longitude + '</div>' + '<div>纬度:' + item.latitude + '</div>',
+                {permanent:true,className:'infoToolTip',offset:[0,-30]}).openTooltip();
+            })
+            marker.on('mouseout', function () {
+              marker.bindTooltip().closeTooltip();
+            })
+            // 点击动作
+            marker.on('click', function (e) {
+              let station = {id: item.id,stationName: item.stationName}
+              sessionStorage.setItem("stationInfo",JSON.stringify(station))
+              _self.$store.dispatch('equipmentInfo/stationInfo',JSON.stringify(station))
+              _self.$router.push({path: "/homepage/stationInfo"})
+            })
+          }
+        }
         /**
          * 加载实时气象源动画效果
          fetch("/js/json/wind_data/20230403_00_atmoslev_1000_mb.json")

+ 160 - 21
neim-ui/src/views/largeScreenPage/components/bigeMap.vue

@@ -85,7 +85,7 @@ export default {
                 color: '#ffffff',
                 weight: 3,
                 fillColor: '#ffffff',
-                fillOpacity: 0.1
+                fillOpacity: 0
               };
             },
             onEachFeature: function (feature, layer) {
@@ -100,14 +100,14 @@ export default {
               color: '#ffffff',
               weight: 1,
               fillColor: 'transparent',
-              fillOpacity: 0.9
+              fillOpacity: 0
             });
           }).on('mouseout', function (e) {
             e.layer.setStyle({
               color: '#ffffff',
               weight: 3,
               fillColor: '#ffffff',
-              fillOpacity: 0.2
+              fillOpacity: 0
             });
           }).addTo(this.bMap);
           window.geo2=geo2;
@@ -130,32 +130,66 @@ export default {
           // this.setHeatMap(this.bMap);
           //绑定事件
           this.bindEvents(this.bMap);
+          if(this.mapData.level !== null){
+            this.bMap.setZoom(this.mapData.level)
+            this.bMap.panTo(this.mapData.center)
+          }
+
 
         })
-        // 标记点位
-        if(this.mapData.stationInfo !== null){
-          let data = this.mapData.stationInfo
-          let iconurl = 'http://'+_self.href.split("//")[1].split("/")[0]+'/largeScreenImg/station.png'
+        let sIconurl = 'http://'+_self.href.split("//")[1].split("/")[0]+'/largeScreenImg/station.png'
+        let hfSIconurl = 'http://'+_self.href.split("//")[1].split("/")[0]+'/largeScreenImg/huafuStation.png'
+        let pIconurl = 'http://' + _self.href.split("//")[1].split("/")[0] + '/largeScreenImg/project.png'
+        let fjIconurl = 'http://' + _self.href.split("//")[1].split("/")[0] + '/img/fengji.png'
 
+        // 所有场站标记点位
+        if(this.mapData.allStationInfo !== null && this.mapData.allStationInfo !== undefined){
+          let data = this.mapData.allStationInfo
           let station_icon = window.BM.icon({
-            iconUrl: iconurl,
-            iconSize: [30, 50],
-            iconAnchor: [30, 50]
+            iconUrl: sIconurl,
+            iconSize: [25, 43],
+            iconAnchor: [25, 43]
+          })
+          let hf_station_icon = window.BM.icon({
+            iconUrl: hfSIconurl,
+            iconSize: [35, 55],
+            iconAnchor: [35, 55]
           })
-          for(let item of data){
+          for(let item of data.otherStation){
             let coordinate = [Number(item.latitude),Number(item.longitude)]
-            window.BM.marker(coordinate,{
-              icon: station_icon
+            let marker = window.BM.marker(coordinate,{
+              icon: station_icon,
+              riseOnHover: true
             }).addTo(this.bMap);
+            marker.on('mouseover', function (e) {
+              marker.bindTooltip('<div>场站名称:' + item.stationName + '</div>' + '<div>经度:' + item.longitude + '</div>' + '<div>纬度:' + item.latitude + '</div>',
+                {permanent:true,className:'infoToolTip',offset:[0,-30]}).openTooltip();
+            })
+            marker.on('mouseout', function () {
+              marker.bindTooltip().closeTooltip();
+            })
+          }
+          for(let item of data.HDStation){
+            let coordinate = [Number(item.latitude),Number(item.longitude)]
+            let marker = window.BM.marker(coordinate,{
+              icon: hf_station_icon,
+              riseOnHover: true
+            }).addTo(this.bMap);
+            marker.on('mouseover', function (e) {
+              marker.bindTooltip('<div>场站名称:' + item.stationName + '</div>' + '<div>经度:' + item.longitude + '</div>' + '<div>纬度:' + item.latitude + '</div>',
+                {permanent:true,className:'infoToolTip',offset:[0,-30]}).openTooltip();
+            })
+            marker.on('mouseout', function () {
+              marker.bindTooltip().closeTooltip();
+            })
           }
         }
-        // 标记点位
-        if (this.mapData.projectInfo !== null) {
-          let data = this.mapData.projectInfo
-          let iconurl = 'http://' + _self.href.split("//")[1].split("/")[0] + '/largeScreenImg/project.png'
 
+        // 项目标记点位
+        if (this.mapData.projectInfo !== null && this.mapData.projectInfo !== undefined) {
+          let data = this.mapData.projectInfo
           let station_icon = window.BM.icon({
-            iconUrl: iconurl,
+            iconUrl: pIconurl,
             iconSize: [30, 50],
             iconAnchor: [30, 50]
           })
@@ -182,6 +216,110 @@ export default {
             })
           }
         }
+        // 华富场站标记点位
+        if (this.mapData.staionInfo !== null && this.mapData.staionInfo !== undefined) {
+          let data = this.mapData.staionInfo
+          let station_icon = window.BM.icon({
+            iconUrl: sIconurl,
+            iconSize: [30, 50],
+            iconAnchor: [30, 50],
+            className:'stationIcon',
+          })
+          for (let item of data) {
+            let coordinate = [Number(item.latitude), Number(item.longitude)]
+            let marker = window.BM.marker(coordinate, {
+              icon: station_icon,
+              riseOnHover: true
+            }).addTo(this.bMap);
+            // 悬浮动作
+            marker.on('mouseover', function (e) {
+              marker.bindTooltip('<div>场站名称:' + item.stationName + '</div>' + '<div>经度:' + item.longitude + '</div>' + '<div>纬度:' + item.latitude + '</div>',
+                {permanent:true,className:'infoToolTip',offset:[0,-30]}).openTooltip();
+            })
+            marker.on('mouseout', function () {
+              marker.bindTooltip().closeTooltip();
+            })
+            // 点击动作
+            marker.on('click', function (e) {
+              let station = {id: item.id,stationName: item.stationName}
+              sessionStorage.setItem("stationInfo",JSON.stringify(station))
+              this.$store.dispatch('equipmentInfo/stationInfo',JSON.stringify(station))
+              this.$router.push({path: "/homepage/stationInfo"})
+            })
+          }
+        }
+        // 所有风机、塔、拐点标记点位
+        if (this.mapData.allPointInfo !== null && this.mapData.allPointInfo !== undefined) {
+          let data = this.mapData.allPointInfo
+          let station_icon = window.BM.icon({
+            iconUrl: pIconurl,
+            iconSize: [35, 55],
+            iconAnchor: [35, 55],
+            className:'stationIcon',
+          })
+          let fj_icon = window.BM.icon({
+            iconUrl: fjIconurl,
+            iconSize: [30, 30],
+            iconAnchor: [30, 30],
+            className:'stationIcon',
+          })
+          for(let item of data.fan){
+            let coordinate = [Number(item.latitudeFan),Number(item.longitudeFan)]
+            let marker = window.BM.marker(coordinate,{
+              icon: fj_icon,
+              riseOnHover: true
+            }).addTo(this.bMap);
+          }
+          for(let item of data.coordinatesList){
+            if(item.length>0){
+              let latlngs = []
+              for (let coor of item){
+                latlngs.push([Number(coor.latitude),Number(coor.longitude)])
+                window.BM.marker([Number(coor.latitude),Number(coor.longitude)]).addTo(this.bMap);
+              }
+              var polygon = BM.polygon(latlngs).addTo(this.bMap);
+              // 让地图适配当前的线段
+              this.bMap.fitBounds(polygon.getBounds());
+            }
+          }
+          for (let item of data.towerList) {
+            let coordinate = [Number(item.latitude), Number(item.longitude)]
+            let marker = window.BM.marker(coordinate, {
+              icon: station_icon,
+              riseOnHover: true
+            }).addTo(this.bMap);
+            // 悬浮动作
+            marker.on('mouseover', function (e) {
+              console.log(item)
+              if(item.type === 'project'){
+                marker.bindTooltip('<div>项目名称:' + item.projectName + '</div>'+ '<div>测风塔名称:' + item.towerName + '</div>' + '<div>经度:' + item.longitude + '</div>' + '<div>纬度:' + item.latitude + '</div>',
+                  {permanent:true,className:'infoToolTip',offset:[0,-30]}).openTooltip();
+              }else{
+                marker.bindTooltip('<div>场站名称:' + item.stationName + '</div>'+ '<div>测风塔名称:' + item.towerName + '</div>' + '<div>经度:' + item.longitude + '</div>' + '<div>纬度:' + item.latitude + '</div>',
+                  {permanent:true,className:'infoToolTip',offset:[0,-30]}).openTooltip();
+              }
+
+            })
+            marker.on('mouseout', function () {
+              marker.bindTooltip().closeTooltip();
+            })
+            // 点击动作
+            marker.on('click', function (e) {
+              if(item.type === 'project'){
+                let project = {projectId:item.projectId,equipmentNo:item.towerId}
+                sessionStorage.setItem("emailWindTowerInfo", JSON.stringify(project))
+                _self.$store.dispatch('equipmentInfo/emailWindTowerInfo', JSON.stringify(project))
+                _self.$router.push({path: "/homepage/emailResourcesInfo"})
+              }else {
+                let station = {stationId:item.stationId,equipmentNo:item.towerId}
+                sessionStorage.setItem("realWindTowerInfo", JSON.stringify(station))
+                _self.$store.dispatch('equipmentInfo/realWindTowerInfo', JSON.stringify(station))
+                _self.$router.push({path: "/homepage/realResourcesInfo"})
+              }
+
+            })
+          }
+        }
         /**
          * 加载实时气象源动画效果
          fetch("/js/json/wind_data/20230403_00_atmoslev_1000_mb.json")
@@ -267,7 +405,7 @@ export default {
                 color: '#ffffff',
                 fillColor: 'transparent',
                 weight: 1,
-                fillOpacity: 0.9
+                fillOpacity: 1
               };
             },
           }).on('mouseover', function (e) {
@@ -302,7 +440,7 @@ export default {
               color: '#ffffff',
               fillColor: 'transparent',
               weight: 1,
-              fillOpacity: 0.9
+              fillOpacity: 1
             });
             // 点击地图区域向下钻取
             // }).on('click', (e) => {
@@ -335,6 +473,7 @@ export default {
 }
 </script>
 <style>
+
 .infoToolTip{
   color: white;
   background: rgba(0, 133, 212, 0.75);
@@ -342,7 +481,7 @@ export default {
 }
 
 .my_tooltip{
-  color: #0085d4;
+  color: white;
   background: transparent;
   border: none;
   /*font-size: 18px;*/

+ 6 - 6
neim-ui/src/views/largeScreenPage/index.vue

@@ -95,9 +95,9 @@ export default {
       resourcesOverview: '黑龙江处于高纬度地区,日照强度较大,太阳能转换率较高,为开发太阳能源提供了有理条件。特别是大兴安岭一带常年受到东亚西风带影响,具有风速大,气候干燥特点,与同维度地图相比,风资源更丰富,利于风能资源的开发与利用。',
       //地图传值
       mapValue: {
-        level: '',//地图层级
+        level: null,//地图层级
         center: [],//中心坐标
-        stationInfo: [],//场站坐标
+        allStationInfo: [],//场站坐标
       }
     }
   },
@@ -114,9 +114,9 @@ export default {
     getInfo() {
       this.mapValue = {
         params:new Date(),
-        level: '',//地图层级
+        level: null,//地图层级
         center: [],//中心坐标
-        stationInfo: null,//场站坐标
+        allStationInfo: null,//场站坐标
       }
       provincialEnergyInfo().then(res => {
         this.resourcesOverview = res.data.resourcesOverview
@@ -133,9 +133,9 @@ export default {
     clickBtu(id) {
       this.mapValue = {
         params:new Date(),
-        level: '',//地图层级
+        level: null,//地图层级
         center: [],//中心坐标
-        stationInfo: null,//场站坐标
+        allStationInfo: null,//场站坐标
       }
       this.mapMark = id
       let clickItem = document.getElementById(id)