20 lines
21 KiB
JavaScript
20 lines
21 KiB
JavaScript
|
import{_ as Ne,a as xe}from"./zhankaiss.dd067ea4.js";import{m as X,g as ce,p as Le,a as j,b as $,c as Ve,d as Be,e as qe,f as Me,z as ze,h as Pe}from"./information.28c899cc.js";import"./linesGL.901ceb35.js";import{_ as Je,r as l,D as de,t as Qe,C as Te,Z as ee,d as v,o as R,c as _,k as i,m as f,e as o,w as s,K as Ze,x as ue,l as te,Q as ae,R as le,j as oe,F as ne,f as N,I as Oe,p as Fe,q as Ke}from"./index.4144b0df.js";import"./install.5b5161c6.js";const He="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAGEAAAA+CAYAAAA73nWBAAAAAXNSR0IArs4c6QAAAARzQklUCAgICHwIZIgAAAQ3SURBVHic7ZxPattAFMY/K7ZMsUtUlxYakdg9QcjG296gkEXpGbrpAUqXpQcovUUphl6hi4JKCDlAQYE60C5qGazWli2pC3nMaCyNLWv0X79VrBeHx4zem/e+mUljuly5qMmUpu0CH96/y9qPyvL6zVtITh0HmeK4gGQ7WbtRbWwHdSRkjRcJ9SRkil2no+yxHaAZlo663S7a7Xa6HglmsVhgNpttPv9RLnB38jwTX3rGNU7uvmw9r9NRDrBdQHLqdJQpjgNIttvI2o+dfH38CpZ0L2s3EsF2G8UoUZ3GUdYuJEbumjW9M4TeGW49v5h8huz82/pdQ1bTci0xctesDUwNU1ndGlwHku+ZIauYyioUa5y2i8Jx3LWAlyfOJ6PNz3pniNuuPzL6Mw0DU4NijdivFpJcN2tBEwAAt91ypCFC7tIRIWwCCDcPLlP0Jllyk44m7TMsIaOJFXoLfa/vGLKKI9iYtE4BAGfm9wQ9TA7b5cgWaWK0VPxt9SDbJnoLHdM9042NJlaSnLB3yeJFQg7WhKezb77PfVODIfNTDqmMFOtnYn6lQW7XhF30Z1rWLggjtwKeYo19pSprG5jlmQRvTchBOqLRO0MoyzEUa4xnvz5uOuiprKJvaps0pHeGpZiMtYAX74/wavYwmxHQFZPnbGk6ML3m7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WHYz9PFnNgkRhOwvTlyk9CWRbCG/5UUAeulozFkmsDF3u110u92YXYqWnd0V7OyuJO0GQ0AQLEtmSDzIxiwAMggCkJKJOcsosKAMeqr8wvKE+Q89RE9/lW/XZQAAAABJRU5ErkJggg==",je="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAGEAAAA+CAYAAAA73nWBAAAAAXNSR0IArs4c6QAAAARzQklUCAgICHwIZIgAAAQrSURBVHic7Zy/b9NAFMe/DnEq0ggKYqksGBqWDqhi8R8ASiQYkDrxLxSJiQEJ/gAGkGBh4F9gQJVYkNI/AMkIVayAow5ESHRJUZImsWMz0IvO5x9N4rN99vkzJX6J9HSX997d991F+WtNXZRkShWujdcvXmbth7Q8ef4UFcW1s/ZDahTXRgVOOQmZ4tiooIyEbHHLScieMh0JgGOjGlaYG40G1tbWUvaIL5PJBIPBYP7+9uVveLD5KRNfDk928PH3Pd/zs8I8y8ClkjnOrKwJmZOXwvzo2jNcVAbnfzCP5KUwX1DE93FlHFusHbNe70Cvd3zPP/Qf49Rt+D6rqWZariWGIlo6MkZtaLWub3ArsD3PNNWEVuuiZzXTdpE/ro2qaOlov783f63XO9DXDzx2Y9
|
||
|
<div class="info-window">
|
||
|
<div class="close-btn" ><span>\u7AD9\u70B9\u4FE1\u606F</span><img src="${ce}" alt=""/> </div>
|
||
|
<div class="content" style="color:white;font-size: 16px">
|
||
|
<div class="line" style="margin-top: 10px"><div class="label">\u540D\u79F0:</div><span>${y.name}</span></div>
|
||
|
<div class="line" style="margin-top: 10px"><div class="label">\u7ECF\u5EA6:</div><span>${y.lon}</span></div>
|
||
|
<div class="line" style="margin-top: 10px"><div class="label">\u7EAC\u5EA6:</div><span>${y.lat}</span></div>
|
||
|
</div>
|
||
|
</div>
|
||
|
`;const Y=c.getElement().querySelector(".close-btn");Y&&Y.addEventListener("click",()=>{c.setPosition(void 0)})}else if(B==="0"){for(const u in m.value)G===m.value[u].contacts&&(y.name=G,y.phone=m.value[u].phone,y.region=m.value[u].region);c.setPosition(n.getGeometry().getCoordinates()),c.getElement().innerHTML=`
|
||
|
<div class="info-window" >
|
||
|
<div class="close-btn" ><span>\u79CD\u7CAE\u5927\u6237\u4FE1\u606F</span><img src="${ce}" alt=""/> </div>
|
||
|
<div class="content" style="color:white;font-size: 16px">
|
||
|
<div class="line" style="margin-top: 10px"><div class="label">\u59D3\u540D:</div><span>${y.name}</span></div>
|
||
|
<div class="line" style="margin-top: 10px"><div class="label">\u624B\u673A:</div><span>${y.phone}</span></div>
|
||
|
<div class="line" style="margin-top: 10px"><div class="label">\u4F4D\u7F6E:</div><span>${y.region}</span></div>
|
||
|
</div>
|
||
|
</div>
|
||
|
`,n.setStyle(new ol.style.Style({image:new ol.style.Icon({src:Le,scale:.5})})),r.getLayers().forEach(function(u){if(u instanceof ol.layer.Vector){let p=u.getSource().getFeatures()[0];p.get("type")==="0"&&p!==n&&(p.get("warning")==="0"?p.setStyle(new ol.style.Style({image:new ol.style.Icon({src:j,scale:.5})})):p.get("warning")==="1"&&p.setStyle(new ol.style.Style({image:new ol.style.Icon({src:$,scale:.5})})))}});const Y=c.getElement().querySelector(".close-btn");Y&&Y.addEventListener("click",()=>{c.setPosition(void 0),r.getLayers().forEach(function(u){if(u instanceof ol.layer.Vector){let p=u.getSource().getFeatures()[0];p.get("type")==="0"&&(p.get("warning")==="0"?p.setStyle(new ol.style.Style({image:new ol.style.Icon({src:j,scale:.5})})):p.get("warning")==="1"&&p.setStyle(new ol.style.Style({image:new ol.style.Icon({src:$,scale:.5})})))}})})}})});var b=new ResizeObserver(function(d){d.forEach(function(E){var S=E.contentRect.width,A=E.contentRect.height;t.style.width=S+"px",t.style.height=A+"px",r.updateSize()})});b.observe(e)}function Re(){if(W.value=!W.value,W.value){let e=document.querySelector(".rightWra");e.style.transform="translate(0,0)"}else{let e=document.querySelector(".rightWra");e.style.transform="translate(101%,0)"}}const Ie=()=>{Z(),X({data:I.value,alertRange:U.value,flag:4,divisions:C}).then(e=>{x.value=e.data,J()})},Z=()=>{for(const e in L.value)r.removeLayer(L.value[e]);L.value=[];for(const e in V.value)r.removeLayer(V.value[e]);V.value=[];for(const e in k.value)r.removeLayer(k.value[e]);k.value=[],Ve({flag:4,data:I.value,divisions:C}).then(e=>{g.value=e.data;for(const t in g.value){const c=[parseFloat(g.value[t].msLongitude),parseFloat(g.value[t].msLatitude)],b=128,d=[];for(let D=0;D<b;D++){const n=2*Math.PI*D/b,G=ol.sphere.computeDestinationPoint(c,U.value,n);d.push(G)}const E=new ol.Feature({geometry:new ol.geom.Polygon([d])}),S=new ol.style.Style({stroke:new ol.style.Stroke({color:F[g.value[t].warning]&&F[g.value[t].warning].color,width:2})});L.value[t]=new ol.layer.Vector({source:new ol.source.Vector({features:[E]}),style:S}),g.value[t].warning!=="\u65E0\u707E\u5BB3"&&r.addLayer(L.value[t]);const A=new ol.geom.Point(c),w=new ol.Feature({geometry:A,id:g.value[t].msName,type:g.value[t].flag});w.setStyle(new ol.style.Style({image:new ol.style.Icon({src:fe(g.value[t].warning),scale:.5})})),V.value[t]=new ol.layer.Vector({source:new ol.source.Vector({features:[w]})}),r.addLayer(V.value[t])}}),Be({flag:4,alertRange:U.value,data:I.value,divisions:C}).then(e=>{m.value=e.data;for(const t in m.value){const c=[parseFloat(m.value[t].latitude),parseFloat(m.value[t].longitude)],b=new ol.geom.Point(c),d=new ol.Feature({geometry:b,id:m.value[t].contacts,type:m.value[t].flag,warning:m.value[t].earlyWarning});m.value[t].earlyWarning==="0"?(d.setStyle(new ol.style.Style({image:new ol.style.Icon({src:j,scale:.5})})),k.value[t]=new ol.layer.Vector({source:new ol.source.Vector({features:[d]})}),r.addLayer(k.value[t])):m.value[t].earlyWarning==="1"&&(d.setStyle(new ol.style.Style({image:new ol.style.Icon({src:$,scale:.5})})),k.value[t]=new ol.layer.Vector({source:new ol.source.Vector({features:[d]})}),r.addLayer(k.value[t]))}})},Ue=()=>{Z(),X({data:I.value,alertRange:U.value,flag:4,divisions:C}).then(e=>{x.value=e.data,J()})},Ce=()=>{h.value=!1,Pe(O.value).then(e=>{e.data.code=="200"&&ee({message:"\u53D1\u9001\u6210\u529F",type:"success"})})},De=e=>{O.value=e},We=()=>{qe({flag:4,divisions:C}).then(e=>{e.data.length<1?ee({message:"\u8FD11\u5468\u6682\u65E0\u9884\u8B66",type:"success"}):ee({message:`\u8FD11\u5468${e.data.length}\u6B21\u9884\u8B66`,type:"warning"})})},ke=()=>{let e=[];Me({flag:4,divisions:C}).then(t=>{e=[],t.data.forEach(c=>{e.push(c.dataTime)}),se.value=e})};return(e,t)=>{const c=v("el-date-picker"),b=v("el-radio"),d=v("el-radio-group"),E=v("el-option"),S=v("el-select"),A=v("el-button"),w=v("el-table-column"),D=v("el-table"),n=v("el-pagination"),G=v("el-icon"),B=v("el-tooltip"),Y=v("el-collapse-item"),u=v("el-collapse"),p=v("el-dialog");return R(),_("div",et,[tt,i("div",at,[i("div",lt,[f(" \u76D1\u6D4B\
|