Agriculture-front-end/dist/assets/index.b0118193.js

2 lines
22 KiB
JavaScript
Raw Blame History

This file contains invisible Unicode characters

This file contains invisible Unicode characters that are indistinguishable to humans but may be processed differently by a computer. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

import{_ as e,a}from"./zhankaiss.6870329f.js";import{m as l,s as t,g as s,p as n,a as o,b as i,h as r,c,j as d,d as u,z as g,k as A,l as v}from"./information.2f37efab.js";import"./linesGL.76a64914.js";import"./moment.2cad4b18.js";import{_ as m,r as p,I as y,x as f,H as h,a8 as b,d as w,o as E,c as k,l as C,n as R,e as V,w as I,O as B,A as S,m as W,V as x,W as D,k as q,J as M,f as F,N as Q,q as U,s as Y}from"./index.e5c8b0d6.js";import"./linkSeriesData.e74eae00.js";const N=e=>(U("data-v-8a8c1fcd"),e=e(),Y(),e),Z={class:"center"},L=N((()=>C("div",{style:{width:"100%",height:"100%"},class:"cesiumContainer",id:"cesiumContainer"},null,-1))),H={class:"rightWra"},G={class:"farmlandHeader"},P={class:"text"},J={key:0,class:"holiday"},O={class:"rightTop"},z=N((()=>C("div",{class:"title"},[C("div",{style:{width:"3px",height:"19px",opacity:"1",background:"rgba(100, 195, 164, 1)","margin-right":"12px"}}),C("span",null,"预警信息发布")],-1))),K={class:"farmlandDiv"},T={class:"radioDiv"},X={class:"radioDiv"},j={class:"selectDiv"},_={class:"selectDiv",style:{"margin-top":"10px"}},$={class:"btws"},ee=N((()=>C("img",{src:e},null,-1))),ae=N((()=>C("img",{src:a},null,-1))),le={class:"mt-4"},te={class:"tuli"},se=N((()=>C("span",null," 是否确认发送预警短信? ",-1))),ne={class:"dialog-footer"},oe=m({__name:"index",setup(e){const a=p();p({name:"",value:""});let m=p(!1);p("");let U=p(!1),Y=p([]),N=y({lat:"",lan:"",name:""}),oe=p([]);const ie=p([]),re=p(5e3),ce=p(),de=p([]),ue=p([]),ge=p([]),Ae=p([]);let ve={"无预警":{color:"rgba(49, 235, 7, 1)",disabled:!1},"蓝色预警":{color:"rgba(9, 187, 222, 1)",disabled:!1},"黄色预警":{color:"rgba(255, 235, 59, 1)",disabled:!1},"橙色预警":{color:"rgba(234, 165, 93, 1)",disabled:!1},"红色预警":{color:"rgba(215, 25, 28, 1)",disabled:!1}};const me=p(),pe=p([]),ye=({dayjs:e})=>pe.value.includes(e.format("YYYY-MM-DD"));function fe(){qe()}function he(){re.value=5e3,xe.value="",me.value="",qe(),Fe()}const be=e=>{const a=new Date;return a.setHours(0,0,0,0),e.getTime()>a.getTime()&&{disabled:!0,style:{color:"red",textDecoration:"line-through"}}},we=[{label:"蓝色预警",flag:1},{label:"黄色预警",flag:2},{label:"橙色预警",flag:3},{label:"红色预警",flag:4}];y({power:[{required:!0,message:"Please select Activity zone",trigger:"change"}],count:[{required:!0,message:"Please select Activity count",trigger:"change"}],date1:[{type:"date",required:!0,message:"Please pick a date",trigger:"change"}],date2:[{type:"date",required:!0,message:"Please pick a time",trigger:"change"}],type:[{type:"array",required:!0,message:"Please select at least one activity type",trigger:"change"}],resource:[{required:!0,message:"Please select activity resource",trigger:"change"}],desc:[{required:!0,message:"Please input activity form",trigger:"blur"}]});const Ee=p(1),ke=p(6),Ce=p([]);function Re(e){Ee.value=e,Ve()}function Ve(){const e=(Ee.value-1)*ke.value,a=Ee.value*ke.value;Ce.value=ie.value.slice(e,a)}let Ie=p(null);let Be=p(null);f((()=>{Me(),a.value=(()=>{let e=new Date;return e.setDate(e.getDate()-1),e})().toJSON().substr(0,10),qe(),Ze(),Ne(),function(){var e=document.querySelector(".center"),a=document.getElementById("cesiumContainer");Ie=new ol.Map({target:"cesiumContainer",controls:[],view:new ol.View({center:[119.86763411957472,35.88435182141938],zoom:11,projection:"EPSG:4326"}),layers:[new ol.layer.Tile({source:new ol.source.XYZ({url:`${serverAPI.tiandituLayers}`,projection:serverAPI.flag?"EPSG:4326":"EPSG:3857"}),preload:20})]}),Be=new ol.layer.Tile({source:new ol.source.TileSuperMapRest({url:serverAPI.geoserverUrl+"/map-huangdaoqu_bianjie/rest/maps/CJQY3702112019WGS84%40huangdaoqu_bianjie",cacheEnabled:!1}),name:"CJQY3702112019WGS84",projection:"EPSG:4326",zIndex:9999}),Ie.addLayer(Be),l=new ol.layer.Tile({source:new ol.source.TileSuperMapRest({url:serverAPI.geoserverUrl+"/map-huangdaoqu_bianjie/rest/maps/XJQY3702112019WGS84%40huangdaoqu_bianjie",cacheEnabled:!1}),name:"XJQY3702112019WGS84",projection:"EPSG:4326",zIndex:9999}),Ie.addLayer(l);var l;const t=new ol.Overlay({element:document.createElement("div"),className:"overlay1",positioning:"bottom-center",offset:[0,-10],stopEvent:!0});Ie.on("moveend",(function(){Ie.getView().getZoom()>=13?Be.setVisible(!0):Be.setVisible(!1)})),Ie.on("singleclick",(function(e){p([]);const a=Ie.getEventPixel(e.originalEvent);var l=e.coordinate,r=l[0],c=l[1],d=Ie.getView();d.animate({center:[r,c],duration:1e3}),Se.value.forEach((a=>{layersDic[a]?QueryData(e,layersDic[a].setOf,`http://192.168.0.113:8090/iserver/services/${layersDic[a].name}/rest/maps/${layersDic[a].setOf}`,a):layersGbz[a]&&QueryData(e,layersGbz[a].setOf,`http://192.168.0.113:8090/iserver/services/${layersGbz[a].name}/rest/maps/${layersGbz[a].setOf}`,a)})),Ie.forEachFeatureAtPixel(a,(e=>{d.animate({center:[r,c],duration:1e3});const a=e.get("id"),l=e.get("type");if(Ie.addOverlay(t),"1"===l){for(const e in Y.value)a===Y.value[e].msName&&(N.name=a,N.lon=Y.value[e].msLongitude,N.lat=Y.value[e].msLatitude);t.setPosition(e.getGeometry().getCoordinates()),t.getElement().innerHTML=`\n <div class="info-window">\n <div class="close-btn" ><span>站点信息</span><img src="${s}" alt=""/> </div>\n <div class="content" style="color:white;font-size: 16px">\n <div class="line" style="margin-top: 10px"><div class="label">名称:</div><span>${N.name}</span></div>\n <div class="line" style="margin-top: 10px"><div class="label">经度:</div><span>${N.lon}</span></div>\n <div class="line" style="margin-top: 10px"><div class="label">纬度:</div><span>${N.lat}</span></div>\n </div>\n </div>\n `;const l=t.getElement().querySelector(".close-btn");l&&l.addEventListener("click",(()=>{t.setPosition(void 0)}))}else if("0"===l){for(const e in oe.value)a===oe.value[e].contacts&&(N.name=a,N.phone=oe.value[e].phone,N.region=oe.value[e].region);t.setPosition(e.getGeometry().getCoordinates()),t.getElement().innerHTML=`\n <div class="info-window" >\n <div class="close-btn" ><span>种粮大户信息</span><img src="${s}" alt=""/> </div>\n <div class="content" style="color:white;font-size: 16px">\n <div class="line" style="margin-top: 10px"><div class="label">姓名:</div><span>${N.name}</span></div>\n <div class="line" style="margin-top: 10px"><div class="label">手机:</div><span>${N.phone}</span></div>\n <div class="line" style="margin-top: 10px"><div class="label">位置:</div><span>${N.region}</span></div>\n </div>\n </div>\n `,e.setStyle(new ol.style.Style({image:new ol.style.Icon({src:n,scale:.5})})),Ie.getLayers().forEach((function(a){if(a instanceof ol.layer.Vector){let l=a.getSource().getFeatures()[0];"0"===l.get("type")&&l!==e&&("0"===l.get("warning")?l.setStyle(new ol.style.Style({image:new ol.style.Icon({src:o,scale:.5})})):"1"===l.get("warning")&&l.setStyle(new ol.style.Style({image:new ol.style.Icon({src:i,scale:.5})})))}}));const l=t.getElement().querySelector(".close-btn");l&&l.addEventListener("click",(()=>{t.setPosition(void 0),Ie.getLayers().forEach((function(e){if(e instanceof ol.layer.Vector){let a=e.getSource().getFeatures()[0];"0"===a.get("type")&&("0"===a.get("warning")?a.setStyle(new ol.style.Style({image:new ol.style.Icon({src:o,scale:.5})})):"1"===a.get("warning")&&a.setStyle(new ol.style.Style({image:new ol.style.Icon({src:i,scale:.5})})))}}))}))}}))})),new ResizeObserver((function(e){e.forEach((function(e){var l=e.contentRect.width,t=e.contentRect.height;a.style.width=l+"px",a.style.height=t+"px",Ie.updateSize()}))})).observe(e)}(),Fe(),document.querySelector(".rightWra").style.transform="translate(101%,0)"})),h((()=>{document.querySelector(".mode").style.display="none",window.document.querySelector("#screenfull").style.display="block"})),p([]);let Se=p([]);const We=p([]),xe=p("");let De=window.localStorage.getItem("deptName");function qe(){l({data:a.value,alertRange:re.value,flag:3,msName:xe.value,warning:me.value,divisions:De}).then((e=>{ie.value=e.data,Ve()}))}g({divisions:De}).then((e=>{We.value=e.data}));const Me=()=>{t().then((e=>{ce.value=Number(e.data[0].flag)}))};const Fe=()=>{for(const e in ue.value)Ie.removeLayer(ue.value[e]);ue.value=[];for(const e in ge.value)Ie.removeLayer(ge.value[e]);ge.value=[];for(const e in Ae.value)Ie.removeLayer(Ae.value[e]);Ae.value=[],r({flag:3,data:a.value,divisions:De}).then((e=>{Y.value=e.data;for(const l in Y.value){const e=[parseFloat(Y.value[l].msLongitude),parseFloat(Y.value[l].msLatitude)],t=128,s=[];for(let a=0;a<t;a++){const l=2*Math.PI*a/t,n=ol.sphere.computeDestinationPoint(e,re.value,l);s.push(n)}const n=new ol.Feature({geometry:new ol.geom.Polygon([s])}),o=new ol.style.Style({stroke:new ol.style.Stroke({color:ve[Y.value[l].warning]&&ve[Y.value[l].warning].color,width:2})});ue.value[l]=new ol.layer.Vector({source:new ol.source.Vector({features:[n]}),style:o}),"无灾害"!==Y.value[l].warning&&Ie.addLayer(ue.value[l]);const i=new ol.geom.Point(e),r=new ol.Feature({geometry:i,id:Y.value[l].msName,type:Y.value[l].flag});r.setStyle(new ol.style.Style({image:new ol.style.Icon({src:(a=Y.value[l].warning,"蓝色预警"===a?"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAGEAAAA+CAYAAAA73nWBAAAAAXNSR0IArs4c6QAAAARzQklUCAgICHwIZIgAAAO0SURBVHic7Zs7bttAEIZ/CTJdWIBpNwbCQr6BkUbHCOAitzBygCBlkAPkGikM5AZu1Ri+gVjQZUwDIkBQ4jKFOPSIWkoUX8vHfoAh2SZHi/l3Z2eGq9H7ehNBo5RJGAG/f/1UPY7B8u37D4yFXgdKEREwDoXqYQybUECvBNVsV4IWQSmhDkfqCQUwyQpH0+kU5+fnzY6oYnzfh+d5ye//zM94/fRFyViu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q4enNzbJ5yGo6erBxECDsMRd3zbhXASjmgFcExCPN7c4fHmrvECxc2aRRFMAhBtXRHKZk6YXU5SBSCWQYjZ5cTKeHwh3sCzkBNml5PMzm2dCDZywlsE4O9pC5WXqHkEaBuViiACZKOyPqFMAZqerCvJCVU4rcmrqvQ+ocpav6lCqDLDkY1mq4lClBaObHa7TROitOpobtkpTRLi4CMvWVkGIS5WfVys+ngJwqNbE0UZLcZ79+6u+pXer2q22xbFDvq7q/7OEVn2h4rCRWgCeiMH/c6Rg34PEBE8QJ7A8wC1KaE6ygslWBsVlc/sStR3lm44WoxTq5tlEGJuobryjUK7qG911iEBgLjUvZ7eNq4EPYbOG46oY006lq55N5vmfBLxZdvsUa9Bf0/bIFzs6+ntKxsvQVhr4XJ3zBesOUuKQdembvZYyOF2uMNNtvjWBRexbuQWobvqY7QY75xA3/mMJKfQbDXt9XRX/T1B0lYYd3BSyNFiXFsBgIJPW5CjyHH01WX7SMB+OKHfmWYun9lZbQ1rLgBQICdw+IylvaNkuMnisKSoAHLbqhMaCmd5TtaSYYOEoFlLM3e4fT3NYaZYz8UAsLOVtoLqvpOqykjMwP/V0D2SICme0zUnrdI6ZmsZhLie3tZWiNw5gSfmtGTKydKIZbFjslX7xFwkJyR7Au5EIF4tpllPMZ2uTTaSdgDswhy3dUywOlD4ZM2UTNOOHQ8lVN5jcCHSoO66CZT2QDAXg8/WPJWMyRa9v0lVEVFKicopMzTUPcxkRQ51PGArgvxHv0s0tJysuUbJ5x25R3KCBxzsE6IoQhRFlodULb3nAXrPA9fD2ONgn6CUrBAbyGfgeYDkBA+Qj9rxAL1ROPn4+718YLlj/gHgcPHpWCtfPgAAAABJRU5ErkJggg==":void 0),scale:.5})})),ge.value[l]=new ol.layer.Vector({source:new ol.source.Vector({features:[r]})}),Ie.addLayer(ge.value[l])}var a})),c({flag:3,alertRange:re.value,data:a.value,divisions:De}).then((e=>{oe.value=e.data;for(const a in oe.value){const e=[parseFloat(oe.value[a].latitude),parseFloat(oe.value[a].longitude)],l=new ol.geom.Point(e),t=new ol.Feature({geometry:l,id:oe.value[a].contacts,type:oe.value[a].flag,warning:oe.value[a].earlyWarning});"0"===oe.value[a].earlyWarning?(t.setStyle(new ol.style.Style({image:new ol.style.Icon({src:o,scale:.5})})),Ae.value[a]=new ol.layer.Vector({source:new ol.source.Vector({features:[t]})}),Ie.addLayer(Ae.value[a])):"1"===oe.value[a].earlyWarning&&(t.setStyle(new ol.style.Style({image:new ol.style.Icon({src:i,scale:.5})})),Ae.value[a]=new ol.layer.Vector({source:new ol.source.Vector({features:[t]})}),Ie.addLayer(Ae.value[a]))}}))},Qe=()=>{Fe(),l({data:a.value,alertRange:re.value,flag:3,divisions:De}).then((e=>{ie.value=e.data,Ve()}))},Ue=()=>{U.value=!1,v(de.value).then((e=>{"200"==e.code?b({message:"预警短信已成功发送",type:"success"}):b.error("发送失败")}))},Ye=e=>{de.value=e},Ne=()=>{d({flag:3,divisions:De}).then((e=>{e.data.length<1?b({message:"近1周暂无预警",type:"success"}):b({message:`近1周${e.data.length}次预警`,type:"warning"})}))},Ze=()=>{let e=[];u({flag:3,divisions:De}).then((a=>{e=[],a.data.forEach((a=>{e.push(a.dataTime)})),pe.value=e}))};return(e,t)=>{const s=w("el-date-picker"),n=w("el-radio"),o=w("el-radio-group"),i=w("el-option"),r=w("el-select"),c=w("el-button"),d=w("el-table-column"),u=w("el-table"),g=w("el-pagination"),v=w("el-icon"),p=w("el-tooltip"),y=w("el-collapse-item"),f=w("el-collapse"),h=w("el-dialog");return E(),k("div",Z,[L,C("div",H,[C("div",G,[R(" 监测日期: "),V(s,{"popper-class":"date_poper",class:"m-2",modelValue:a.value,"onUpdate:modelValue":t[0]||(t[0]=e=>a.value=e),onChange:Qe,format:"YYYY 年 MM 月 DD 日","value-format":"YYYY-MM-DD",type:"date",placeholder:"选择日期",disabledDate:be},{default:I((e=>[C("div",{class:B(["cell",{current:e.isCurrent}])},[C("span",P,S(e.text),1),ye(e)?(E(),k("span",J)):W("",!0)],2)])),_:1},8,["modelValue"])]),C("div",O,[z,C("div",K,[C("div",T,[R(" 自动发送预警短信: "),V(o,{onChange:t[1]||(t[1]=e=>{A({flag:ce.value}).then((e=>{b({message:e.msg,type:"success"})}))}),modelValue:ce.value,"onUpdate:modelValue":t[2]||(t[2]=e=>ce.value=e),class:"ml-4"},{default:I((()=>[V(n,{label:0,size:"large"},{default:I((()=>[R("是")])),_:1}),V(n,{label:1,size:"large"},{default:I((()=>[R("否")])),_:1})])),_:1},8,["modelValue"])]),C("div",X,[R(" 预警范围: "),V(o,{onChange:t[3]||(t[3]=e=>(Fe(),void l({data:a.value,alertRange:re.value,flag:3,divisions:De}).then((e=>{ie.value=e.data,Ve()})))),modelValue:re.value,"onUpdate:modelValue":t[4]||(t[4]=e=>re.value=e),class:"ml-4"},{default:I((()=>[V(n,{label:5e3,size:"large"},{default:I((()=>[R("5km")])),_:1}),V(n,{label:1e4,size:"large"},{default:I((()=>[R("10km")])),_:1})])),_:1},8,["modelValue"])]),C("div",j,[R(" 站点名称: "),V(r,{"popper-class":"select_city",modelValue:xe.value,"onUpdate:modelValue":t[5]||(t[5]=e=>xe.value=e),placeholder:"请选择",style:{width:"76%"},teleported:"false"},{default:I((()=>[(E(!0),k(x,null,D(We.value,(e=>(E(),q(i,{key:e.msName,label:e.msName,value:e.msName,title:e.msName},null,8,["label","value","title"])))),128))])),_:1},8,["modelValue"])]),C("div",_,[R(" 预警情况: "),V(r,{"popper-class":"select_city",modelValue:me.value,"onUpdate:modelValue":t[6]||(t[6]=e=>me.value=e),placeholder:"请选择",style:{width:"76%"}},{default:I((()=>[(E(),k(x,null,D(we,(e=>V(i,{key:e.flag,label:e.label,value:e.label},null,8,["label","value"]))),64))])),_:1},8,["modelValue"])]),C("div",$,[V(c,{class:"bt1",onClick:fe},{default:I((()=>[R("查询")])),_:1}),V(c,{class:"bt2",onClick:he},{default:I((()=>[R("重置")])),_:1})]),V(u,{"cell-style":{textAlign:"center"},"header-cell-style":{"text-align":"center",color:"rgba(102, 102, 102, 1)"},data:Ce.value,style:{width:"100%"},onSelectionChange:Ye},{default:I((()=>[V(d,{type:"selection",width:"20"}),V(d,{prop:"msName",width:"80",label:"站点名称"}),V(d,{prop:"warning",label:"预警情况"}),V(d,{prop:"name",width:"80",label:"联系人"}),V(d,{prop:"telephone",label:"联系电话"})])),_:1},8,["header-cell-style","data"]),V(g,{small:"",style:{display:"flex","justify-content":"center","margin-top":"10px"},onCurrentChange:Re,"current-page":Ee.value,"page-size":ke.value,layout:" prev, pager, next",total:ie.value.length},null,8,["current-page","page-size","total"]),V(c,{class:"but",type:"primary",disabled:de.value.length<1||0==ce.value,onClick:t[7]||(t[7]=e=>M(U)?U.value=!0:U=!0)},{default:I((()=>[R(" 发布预警短信 ")])),_:1},8,["disabled"])])]),C("div",{class:"rightFoldDiv",onClick:t[8]||(t[8]=e=>(m.value=!m.value,void(m.value?document.querySelector(".rightWra").style.transform="translate(0,0)":document.querySelector(".rightWra").style.transform="translate(101%,0)")))},[V(p,{disabled:!F(m),"hide-after":"0","show-arrow":!1,"show-after":"200",class:"box-item",effect:"dark",content:"收起",placement:"top"},{default:I((()=>[F(m)?(E(),q(v,{key:0},{default:I((()=>[ee])),_:1})):W("",!0)])),_:1},8,["disabled"]),V(p,{disabled:F(m),"hide-after":"0","show-arrow":!1,"show-after":"200",class:"box-item",effect:"dark",content:"展开",placement:"top"},{default:I((()=>[F(m)?W("",!0):(E(),q(v,{key:0},{default:I((()=>[ae])),_:1}))])),_:1},8,["disabled"])])]),V(f,{class:"legend",accordion:""},{default:I((()=>[V(y,{name:"1"},{title:I((()=>[R("图例")])),default:I((()=>[C("div",le,[C("div",te,[(E(!0),k(x,null,D(F(ve),((e,a,l)=>(E(),k("div",{key:l,style:Q({backgroundColor:e.color,border:"1px solid value.color",width:"100%",height:"25px",marginTop:"5px",textAlign:"center"})},S(a),5)))),128))])])])),_:1})])),_:1}),V(h,{modelValue:F(U),"onUpdate:modelValue":t[10]||(t[10]=e=>M(U)?U.value=e:U=e),title:"系统提示",width:"30%",center:""},{footer:I((()=>[C("span",ne,[V(c,{onClick:t[9]||(t[9]=e=>M(U)?U.value=!1:U=!1)},{default:I((()=>[R("取消")])),_:1}),V(c,{type:"primary",onClick:Ue},{default:I((()=>[R(" 确定 ")])),_:1})])])),default:I((()=>[se])),_:1},8,["modelValue"])])}}},[["__scopeId","data-v-8a8c1fcd"]]);export{oe as default};