Agriculture-front-end/dist/assets/index.602a2fd3.js

20 lines
21 KiB
JavaScript
Raw Normal View History

2023-09-19 14:34:21 +08:00
import{_ as Be,a as De}from"./zhankaiss.dd067ea4.js";import{m as K,g as oe,p as Fe,a as J,b as X,c as Me,d as Le,e as qe,f as _e,z as Qe,h as Ue}from"./information.3a53cfed.js";import"./linesGL.901ceb35.js";import"./moment.9709ab41.js";import{_ as Ye,r as l,D as ie,t as Te,C as Ne,Z as j,d as v,o as C,c as B,k as i,m as f,e as n,w as d,K as Ze,x as re,l as $,Q as ee,R as te,j as ae,f as q,I as ze,p as Pe,q as He}from"./index.42ab3fdc.js";import"./install.5b5161c6.js";const Oe="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAGEAAAA+CAYAAAA73nWBAAAAAXNSR0IArs4c6QAAAARzQklUCAgICHwIZIgAAAO0SURBVHic7Zs7bttAEIZ/CTJdWIBpNwbCQr6BkUbHCOAitzBygCBlkAPkGikM5AZu1Ri+gVjQZUwDIkBQ4jKFOPSIWkoUX8vHfoAh2SZHi/l3Z2eGq9H7ehNBo5RJGAG/f/1UPY7B8u37D4yFXgdKEREwDoXqYQybUECvBNVsV4IWQSmhDkfqCQUwyQpH0+kU5+fnzY6oYnzfh+d5ye//zM94/fRFyViu3Wd8ev2793cdjlpAGAFjocORUoQAxmE0Uj2OQRNGI52iqkYXay1AF2stQGl25BoWXq7u1Xx4i1BarL1c3WshoDAccccPXQgl4YhWAEcmxNPNA55uHnov0LZYa1AEmQDEUFdEoynq8mKeKQDhGhaWF/NmBtQSDjbwqmR5MYc9zefcvNf1hUb2hFMEIIYkRO0NvCICDI24gVePcS1APmrLjqoUoO+bdS3ZkWtYla8AezrvrRBh1eGozly/r0JUGo6aKLb6KERl4ajJardvQlTWwLMbdkqfhBBRfCC4DK5h4TJwcBk4eDeso62JssxWi53PNgOn1s+rmzACJkKUe9BvBk7iiCWO94fKcustjl/UIYQY6XNHqmm8la3ZR5+2aAH6tEULqCQ7KgplOU1kVG0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3tcYW3/CpwSMVqZIInz9/EX3OEbLh08fMbGSSPc4Ro2VRJggZhG0EkeYgHeCXhIWQT/sjgwgjjAtC8xHR0c4ODhQPKJ2CYIAvu9n3799/RPv3/zQMpb7xzN8//3u2c//BeathiExGfGWY4J2ODAbAAdmA4gjrph1Y7E7MgCd7sierXF+fK3ls41CZ9vi/PiahQD0ZUfixI9eiCTCxFLsjmgHiMiEuDy5wuXJ1eAFslS7I5kAxGh3hEp3tJjflgpA2LM1FvNbJeMxhiTCVEV2tJjfYnF4V+3aitcNBhXF2ksEyP5mREJ0XqzVEWB0dNnKZgEq0lUru00BBh+su2hb2LN16ztgcXg3XCHaDsxd5vpDFaLVwKyi2BqkEG25I5XV7uCEaKttoToLGpQQSZTeENwEe7aG93QK7+kU9qtfe1sTTXH9Zf6zQ6fTz+ucJMK0aRfVC51sIhbY3x9qirtZdWpfNcq7qIwEPmM2AL7lxQDYHRlAsuOG4K6hLEdFRmUylqpDHcL1l8+zm036Qj2n0QnSxB29dLKkAgh4oYObh4tcHTAK0p3w8vMEalUXJ5beixV02eSTiFRwUa3hblZwN6usDSKKffNw8cyGPVv3u3aIt/Uq5nTC7tL2QUEMmkRZNVvuclLRRDvihMtsiWcWooi9o25g9kIHrr/
2023-09-11 21:56:39 +08:00
<div class="info-window">
<div class="close-btn" ><span>\u7AD9\u70B9\u4FE1\u606F</span><img src="${oe}" 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>${p.name}</span></div>
<div class="line" style="margin-top: 10px"><div class="label">\u7ECF\u5EA6:</div><span>${p.lon}</span></div>
<div class="line" style="margin-top: 10px"><div class="label">\u7EAC\u5EA6:</div><span>${p.lat}</span></div>
</div>
</div>
`;const W=r.getElement().querySelector(".close-btn");W&&W.addEventListener("click",()=>{r.setPosition(void 0)})}else if(L==="0"){for(const u in A.value)E===A.value[u].contacts&&(p.name=E,p.phone=A.value[u].phone,p.region=A.value[u].region);r.setPosition(s.getGeometry().getCoordinates()),r.getElement().innerHTML=`
<div class="info-window" >
<div class="close-btn" ><span>\u4EBA\u5458\u4FE1\u606F</span><img src="${oe}" 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>${p.name}</span></div>
<div class="line" style="margin-top: 10px"><div class="label">\u624B\u673A:</div><span>${p.phone}</span></div>
<div class="line" style="margin-top: 10px"><div class="label">\u4F4D\u7F6E:</div><span>${p.region}</span></div>
</div>
</div>
2023-09-19 14:34:21 +08:00
`,s.setStyle(new ol.style.Style({image:new ol.style.Icon({src:Fe,scale:.5})})),o.getLayers().forEach(function(u){if(u instanceof ol.layer.Vector){let a=u.getSource().getFeatures()[0];a.get("type")==="0"&&a!==s&&(a.get("warning")==="0"?a.setStyle(new ol.style.Style({image:new ol.style.Icon({src:J,scale:.5})})):a.get("warning")==="1"&&a.setStyle(new ol.style.Style({image:new ol.style.Icon({src:X,scale:.5})})))}});const W=r.getElement().querySelector(".close-btn");W&&W.addEventListener("click",()=>{r.setPosition(void 0),o.getLayers().forEach(function(u){if(u instanceof ol.layer.Vector){let a=u.getSource().getFeatures()[0];a.get("type")==="0"&&(a.get("warning")==="0"?a.setStyle(new ol.style.Style({image:new ol.style.Icon({src:J,scale:.5})})):a.get("warning")==="1"&&a.setStyle(new ol.style.Style({image:new ol.style.Icon({src:X,scale:.5})})))}})})}})});var h=new ResizeObserver(function(c){c.forEach(function(b){var w=b.contentRect.width,y=b.contentRect.height;t.style.width=w+"px",t.style.height=y+"px",o.updateSize()})});h.observe(e)}function Ee(){if(V.value=!V.value,V.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 Ce=()=>{Z(),K({data:R.value,alertRange:S.value,flag:3,divisions:k}).then(e=>{D.value=e.data,Y()})},Z=()=>{for(const e in F.value)o.removeLayer(F.value[e]);F.value=[];for(const e in M.value)o.removeLayer(M.value[e]);M.value=[];for(const e in x.value)o.removeLayer(x.value[e]);x.value=[],Me({flag:3,data:R.value,divisions:k}).then(e=>{g.value=e.data;for(const t in g.value){const r=[parseFloat(g.value[t].msLongitude),parseFloat(g.value[t].msLatitude)],h=128,c=[];for(let I=0;I<h;I++){const s=2*Math.PI*I/h,E=ol.sphere.computeDestinationPoint(r,S.value,s);c.push(E)}const b=new ol.Feature({geometry:new ol.geom.Polygon([c])}),w=new ol.style.Style({stroke:new ol.style.Stroke({color:H[g.value[t].warning]&&H[g.value[t].warning].color,width:2})});F.value[t]=new ol.layer.Vector({source:new ol.source.Vector({features:[b]}),style:w}),g.value[t].warning!=="\u65E0\u707E\u5BB3"&&o.addLayer(F.value[t]);const y=new ol.geom.Point(r),m=new ol.Feature({geometry:y,id:g.value[t].msName,type:g.value[t].flag});m.setStyle(new ol.style.Style({image:new ol.style.Icon({src:pe(g.value[t].warning),scale:.5})})),M.value[t]=new ol.layer.Vector({source:new ol.source.Vector({features:[m]})}),o.addLayer(M.value[t])}}),Le({flag:3,alertRange:S.value,data:R.value,divisions:k}).then(e=>{A.value=e.data;for(const t in A.value){const r=[parseFloat(A.value[t].latitude),parseFloat(A.value[t].longitude)],h=new ol.geom.Point(r),c=new ol.Feature({geometry:h,id:A.value[t].contacts,type:A.value[t].flag,warning:A.value[t].earlyWarning});A.value[t].earlyWarning==="0"?(c.setStyle(new ol.style.Style({image:new ol.style.Icon({src:J,scale:.5})})),x.value[t]=new ol.layer.Vector({source:new ol.source.Vector({features:[c]})}),o.addLayer(x.value[t])):A.value[t].earlyWarning==="1"&&(c.setStyle(new ol.style.Style({image:new ol.style.Icon({src:X,scale:.5})})),x.value[t]=new ol.layer.Vector({source:new ol.source.Vector({features:[c]})}),o.addLayer(x.value[t]))}})},Re=()=>{Z(),K({data:R.value,alertRange:S.value,flag:3,divisions:k}).then(e=>{D.value=e.data,Y()})},Se=()=>{Ue(P.value).then(e=>{e.data.code=="200"&&j({message:"\u53D1\u9001\u6210\u529F",type:"success"})})},ke=e=>{P.value=e},Ie=()=>{qe({flag:3,divisions:k}).then(e=>{e.data.length<1?j({message:"\u8FD11\u5468\u6682\u65E0\u9884\u8B66",type:"success"}):j({message:`\u8FD11\u5468${e.data.length}\u6B21\u9884\u8B66`,type:"warning"})})},Ve=()=>{let e=[];_e({flag:3,divisions:k}).then(t=>{e=[],t.data.forEach(r=>{e.push(r.dataTime)}),le.value=e})};return(e,t)=>{const r=v("el-date-picker"),h=v("el-radio"),c=v("el-radio-group"),b=v("el-option"),w=v("el-select"),y=v("el-button"),m=v("el-table-column"),I=v("el-table"),s=v("el-pagination"),E=v("el-icon"),L=v("el-tooltip"),W=v("el-collapse-item"),u=v("el-collapse");return C(),B("div",je,[$e,i("div",et,[i("div",tt,[f(" \u76D1\u6D4B\u65E5\u671F:\u2003 "),n(r,{"pop