chunk-59e3a2aa.ad5ef7f6.js 4.4 KB

1
  1. (window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["chunk-59e3a2aa","chunk-2d0dd9c6"],{"3adf":function(t,n,e){"use strict";e.d(n,"b",(function(){return i})),e.d(n,"a",(function(){return o})),e.d(n,"c",(function(){return r}));var a=e("b775");function i(t){return Object(a["a"])({url:"/dataQuery/electricFieId/list",method:"get",params:t})}function o(t){return Object(a["a"])({url:"/dataQuery/electricFieId",method:"post",data:t})}function r(t){return Object(a["a"])({url:"/dataQuery/electricFieId",method:"put",data:t})}},4305:function(t,n,e){"use strict";e.d(n,"e",(function(){return i})),e.d(n,"c",(function(){return o})),e.d(n,"d",(function(){return r})),e.d(n,"a",(function(){return c})),e.d(n,"f",(function(){return u})),e.d(n,"b",(function(){return d}));var a=e("b775");function i(t){return Object(a["a"])({url:"/dataQuery/windTowerStatusInfo/list",method:"get",params:t})}function o(){return Object(a["a"])({url:"/dataQuery/windTowerStatusInfo/dashAllWindInfo",method:"get"})}function r(){return Object(a["a"])({url:"/dataQuery/windTowerStatusInfo/listAll",method:"get"})}function c(t){return Object(a["a"])({url:"/dataQuery/windTowerStatusInfo",method:"post",data:t})}function u(t){return Object(a["a"])({url:"/dataQuery/windTowerStatusInfo",method:"put",data:t})}function d(t){return Object(a["a"])({url:"/dataQuery/windTowerStatusInfo/"+t,method:"delete"})}},"4fb2":function(t,n,e){"use strict";e.r(n);var a=function(){var t=this,n=t.$createElement,e=t._self._c||n;return e("div",[e("div",{staticClass:"mapTitleBox"},[e("dv-decoration-6",{staticStyle:{width:"20%",height:"30px"}}),e("dv-border-box-12",{staticClass:"mapTitle"},[e("span",[t._v("地形图")])]),e("dv-decoration-6",{staticStyle:{width:"20%",height:"30px"}})],1),e("div",{ref:"allmap",staticClass:"map",attrs:{id:"map"}})])},i=[],o=(e("d81d"),e("d3b7"),e("159b"),e("b0c0"),e("81b9")),r=e("4305"),c=e("3adf"),u={name:"bMap",data:function(){return{map:"",windInfo:[],longitude:"131.759770",latitude:"47.051740"}},destroyed:function(){this.map=null;for(var t=setInterval(";"),n=0;n<t;n++)clearInterval(n);var e=document.querySelectorAll(".map");e.forEach((function(t){document.body.removeChild(t)}))},created:function(){},mounted:function(){var t=this;this.getAllWindInfo(),this.init(),setTimeout((function(){t.init()}),500)},methods:{getAllWindInfo:function(){var t=this;Object(r["c"])().then((function(n){t.windInfo=n.rows,t.getEleInfo()}))},getEleInfo:function(){var t=this;Object(c["b"])().then((function(n){var e=n.rows[0];void 0!=e&&(t.longitude=e.longitude,t.latitude=e.latitude)}))},init:function(){var t=this;Object(o["tMpgl"])().then((function(n){var a="http://t0.tianditu.gov.cn/img_w/wmts?SERVICE=WMTS&REQUEST=GetTile&VERSION=1.0.0&LAYER=img&STYLE=default&TILEMATRIXSET=w&FORMAT=tiles&TILEMATRIX={z}&TILEROW={y}&TILECOL={x}&tk=7cabc767dcc67e80ef97889c297f48f9",i="http://t0.tianditu.gov.cn/cia_w/wmts?SERVICE=WMTS&REQUEST=GetTile&VERSION=1.0.0&LAYER=cia&STYLE=default&TILEMATRIXSET=w&FORMAT=tiles&TILEMATRIX={z}&TILEROW={y}&TILECOL={x}&tk=7cabc767dcc67e80ef97889c297f48f9",o=new n.TileLayer(a,{minZoom:6,maxZoom:18}),r=new n.TileLayer(i,{minZoom:6,maxZoom:18}),c={layers:[o,r]};t.map=new n.Map("map",c),t.map.centerAndZoom(new n.LngLat(t.longitude,t.latitude),10);var u=new n.Control.Zoom;t.map.addControl(u);var d=new n.Icon({iconUrl:e("8376"),iconSize:new n.Point(29,27),iconAnchor:new n.Point(10,25)}),f=t.windInfo;if(f.length>0){for(var l=[],s=0;s<f.length;s++){var m="";m=new n.Marker(new n.LngLat(f[s].lon,f[s].lat),{icon:d});var p="<div>测风塔名字:"+f[s].name+"<br>经度:"+f[s].lon+"<br>纬度:"+f[s].lat+" </div>";l.push({marker:m,info:p}),t.map.addOverLay(m)}for(var w=function(t){var e=l[t].marker;e.addEventListener("click",(function(){var a=new n.InfoWindow;a.setContent(l[t].info),e.openInfoWindow(a)}))},h=0;h<l.length;h++)w(h)}}))}}},d=u,f=(e("b93e"),e("2877")),l=Object(f["a"])(d,a,i,!1,null,"5d53008e",null);n["default"]=l.exports},"81b9":function(t,n,e){"use strict";e.r(n),e.d(n,"tMpgl",(function(){return a}));e("d3b7");function a(){return new Promise((function(t,n){if("undefined"!==typeof T)return t(T),!0;window.onBMapCallback=function(){t(T)};var e=document.createElement("script");e.type="text/javascript",e.src="http://api.tianditu.gov.cn/api?v=4.0&tk=7cabc767dcc67e80ef97889c297f48f9",e.onerror=n,document.head.appendChild(e)}))}},8376:function(t,n,e){t.exports=e.p+"static/img/fengche.2a8cc8d4.png"},a61f:function(t,n,e){},b93e:function(t,n,e){"use strict";e("a61f")}}]);