2 lines
21 KiB
JavaScript
2 lines
21 KiB
JavaScript
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 r,h as i,c,j as u,d,z as v,k as g,l as m}from"./information.2f37efab.js";import"./linesGL.76a64914.js";import{_ as p,r as y,I as A,x as h,H as w,a8 as f,d as b,o as G,c as E,l as U,n as R,e as S,w as k,O as I,A as Y,m as N,V as W,W as D,k as C,J as V,f as q,N as x,q as B,s as J}from"./index.e5c8b0d6.js";import"./linkSeriesData.e74eae00.js";const M=e=>(B("data-v-24060e52"),e=e(),J(),e),Q={class:"center"},P=M((()=>U("div",{style:{width:"100%",height:"100%"},class:"cesiumContainer",id:"cesiumContainer"},null,-1))),z={class:"rightWra"},L={class:"farmlandHeader"},Z={class:"text"},K={key:0,class:"holiday"},O={class:"rightTop"},H=M((()=>U("div",{class:"title"},[U("div",{style:{width:"3px",height:"19px",opacity:"1",background:"rgba(100, 195, 164, 1)","margin-right":"12px"}}),U("span",null,"预警信息发布")],-1))),j={class:"farmlandDiv"},F={class:"radioDiv"},T={class:"radioDiv"},X={class:"selectDiv"},_={class:"selectDiv",style:{"margin-top":"10px"}},$={class:"btws"},ee=M((()=>U("img",{src:e},null,-1))),ae=M((()=>U("img",{src:a},null,-1))),le={class:"mt-4"},te={class:"tuli"},se=M((()=>U("span",null,"是否确认发送预警短信?",-1))),ne={class:"dialog-footer"},oe=p({__name:"index",setup(e){const a=y();y({name:"",value:""});let p=y(!1);y("");let B=y(!1),J=y([]),M=A({lat:"",lan:"",name:""}),oe=y([]);const re=y([]),ie=y(5e3),ce=y(),ue=y([]),de=y([]),ve=y([]),ge=y([]);let me={"无预警":{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}};const pe=y(),ye=y([]),Ae=({dayjs:e})=>ye.value.includes(e.format("YYYY-MM-DD"));function he(){Ce()}let we=window.localStorage.getItem("deptName");function fe(){ie.value=5e3,De.value="",pe.value="",Ce(),qe()}const be=[{label:"轻度干热风",flag:1},{label:"中度干热风",flag:2},{label:"重度干热风",flag:3}],Ge=e=>{const a=new Date;return a.setHours(0,0,0,0),e.getTime()>a.getTime()&&{disabled:!0,style:{color:"red",textDecoration:"line-through"}}};A({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=y(1),Ue=y(6),Re=y([]);function Se(e){Ee.value=e,ke()}function ke(){const e=(Ee.value-1)*Ue.value,a=Ee.value*Ue.value;Re.value=re.value.slice(e,a)}let Ie=y(null);let Ye=y(null);h((()=>{Ve(),a.value=(()=>{let e=new Date;return e.setDate(e.getDate()-1),e})().toJSON().substr(0,10),Ce(),Qe(),Me(),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})]}),Ye=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(Ye),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?Ye.setVisible(!0):Ye.setVisible(!1)})),Ie.on("singleclick",(function(e){y([]);const a=Ie.getEventPixel(e.originalEvent);var l=e.coordinate,i=l[0],c=l[1],u=Ie.getView();u.animate({center:[i,c],duration:1e3}),Ne.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=>{u.animate({center:[i,c],duration:1e3});const a=e.get("id"),l=e.get("type");if(Ie.addOverlay(t),"1"===l){for(const e in J.value)a===J.value[e].msName&&(M.name=a,M.lon=J.value[e].msLongitude,M.lat=J.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>${M.name}</span></div>\n <div class="line" style="margin-top: 10px"><div class="label">经度:</div><span>${M.lon}</span></div>\n <div class="line" style="margin-top: 10px"><div class="label">纬度:</div><span>${M.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&&(M.name=a,M.phone=oe.value[e].phone,M.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>${M.name}</span></div>\n <div class="line" style="margin-top: 10px"><div class="label">手机:</div><span>${M.phone}</span></div>\n <div class="line" style="margin-top: 10px"><div class="label">位置:</div><span>${M.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:r,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:r,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)}(),qe(),document.querySelector(".rightWra").style.transform="translate(101%,0)"})),w((()=>{document.querySelector(".mode").style.display="none",window.document.querySelector("#screenfull").style.display="block"})),y([]);let Ne=y([]);const We=y([]),De=y("");function Ce(){l({data:a.value,alertRange:ie.value,flag:4,msName:De.value,warning:pe.value,divisions:we}).then((e=>{re.value=e.data,ke()}))}v({divisions:we}).then((e=>{We.value=e.data}));const Ve=()=>{t().then((e=>{ce.value=Number(e.data[0].flag)}))};const qe=()=>{for(const e in de.value)Ie.removeLayer(de.value[e]);de.value=[];for(const e in ve.value)Ie.removeLayer(ve.value[e]);ve.value=[];for(const e in ge.value)Ie.removeLayer(ge.value[e]);ge.value=[],i({flag:4,data:a.value,divisions:we}).then((e=>{J.value=e.data;for(const l in J.value){const e=[parseFloat(J.value[l].msLongitude),parseFloat(J.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,ie.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:me[J.value[l].warning]&&me[J.value[l].warning].color,width:2})});de.value[l]=new ol.layer.Vector({source:new ol.source.Vector({features:[n]}),style:o}),"无灾害"!==J.value[l].warning&&Ie.addLayer(de.value[l]);const r=new ol.geom.Point(e),i=new ol.Feature({geometry:r,id:J.value[l].msName,type:J.value[l].flag});i.setStyle(new ol.style.Style({image:new ol.style.Icon({src:(a=J.value[l].warning,"轻度干热风"===a?"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAGEAAAA+CAYAAAA73nWBAAAAAXNSR0IArs4c6QAAAARzQklUCAgICHwIZIgAAAQ3SURBVHic7ZxPattAFMY/K7ZMsUtUlxYakdg9QcjG296gkEXpGbrpAUqXpQcovUUphl6hi4JKCDlAQYE60C5qGazWli2pC3nMaCyNLWv0X79VrBeHx4zem/e+mUljuly5qMmUpu0CH96/y9qPyvL6zVtITh0HmeK4gGQ7WbtRbWwHdSRkjRcJ9SRkil2no+yxHaAZlo663S7a7Xa6HglmsVhgNpttPv9RLnB38jwTX3rGNU7uvmw9r9NRDrBdQHLqdJQpjgNIttvI2o+dfH38CpZ0L2s3EsF2G8UoUZ3GUdYuJEbumjW9M4TeGW49v5h8huz82/pdQ1bTci0xctesDUwNU1ndGlwHku+ZIauYyioUa5y2i8Jx3LWAlyfOJ6PNz3pniNuuPzL6Mw0DU4NijdivFpJcN2tBEwAAt91ypCFC7tI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XzRqLMWxl7QI/RNusEXpW07NUZW3GqJ2yR8mhiJKOaPR6Bz2riZ7VxNvjV/MdtFbrwhi25mlIr3eKMRk8pOyoNXuYTVPNQJummv7N2ah9tjnb8+2QgySO3BFXytbrHexuvAtctxNb0ECR77A2kobYwX545Q021SPPMzI5uSduYSaDFfTLJsvMoB3uPKVE2Dx+orKyj8ITtzCT3A34d7EeDShA/wmzBfF1eAd/LG1lP0WGi4rqGVAmvRCbppoeW89qemznaUHm9BZmUGP5KSw89gl0NLDpxRi1PTYaOp8vEg2FhZeKGpVeaBubssIiRSp4qahR6YWOFNbGRkqhJOpFcW1UeKmoUell0UiRMS0pvJs6ZEW0TCGOihQp4N3Uodf4rBxNRwo70HQ0yDkJHFVUz69/uhVqY2EjQyqS7DGzkgKd78NstEAnDS5HKZvuC7N6Px0FUTYZSeymzqpRUAhBbll4paMyCmKQxNH4MgqWhMfReLoRU0bBCvAozKwMEcYyESITXAoz2ZQFLS3JQEctO6VbkrLwKMxkU6ap5lIqaamgnsGlqTNqhw4oq5JG2aSTKwi8VNSoAaUb976mD9NrkHEiuKqodE+ZHdCwxg57yEtGKZu7iho2oLSUDfgnQur6EOemTtBBLdYedo8gyqavH3hk8N50q9hL2DhH4xe5qLHK6TzWRu6nhZ1NzT08VdQkYXsTRUKJk472+3uprGbo9mchiZOOCj84aSHqxUGpKP/lRQCcWT4Kc5GJLMzj8Rjj8Thll5Ll8GQHhyc7WbvhJaow23YZIalQFmYByOsV2kIh6hVamVBcG4r7vl7+YXnG/AMdm706nZ3QGwAAAABJRU5ErkJggg==":"特大干热风"===a?ganhan4:"无灾害"===a?"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAGEAAAA+CAYAAAA73nWBAAAAAXNSR0IArs4c6QAAAARzQklUCAgICHwIZIgAAAQTSURBVHic7ZzPaxNBFMe/jamhEnoqaxYpFeKlEJoE/QcsEql49g/w1kOv4sGjJxE8eOjZm1cvFoLkX0gL0UIxoKDdGA8qBJuUGeMhmTC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zla25H2C24KKp+ZEQ6Q5Pyx1As8y2p5vrlOinkfWLNVtXdUkl7AjI/gMR/N8qOHndJ4oY9+nuZ1NjTvKHggWSfKMYalwtNfYD2UKVuDGn0lkbAR/g34z4YsTFhRU/7ZF1EidrGn8ofR3zGnBMzH3+330+/H+MlJk67SMrdNy1GpM4blPIER7SBjEZp+QZHROUIDYfsecJOiQYOX2zzX9g+UR8x+NJvMP5WohIwAAAABJRU5ErkJggg==":void 0),scale:.5})})),ve.value[l]=new ol.layer.Vector({source:new ol.source.Vector({features:[i]})}),Ie.addLayer(ve.value[l])}var a})),c({flag:4,alertRange:ie.value,data:a.value,divisions:we}).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})})),ge.value[a]=new ol.layer.Vector({source:new ol.source.Vector({features:[t]})}),Ie.addLayer(ge.value[a])):"1"===oe.value[a].earlyWarning&&(t.setStyle(new ol.style.Style({image:new ol.style.Icon({src:r,scale:.5})})),ge.value[a]=new ol.layer.Vector({source:new ol.source.Vector({features:[t]})}),Ie.addLayer(ge.value[a]))}}))},xe=()=>{qe(),l({data:a.value,alertRange:ie.value,flag:4,divisions:we}).then((e=>{re.value=e.data,ke()}))},Be=()=>{B.value=!1,m(ue.value).then((e=>{"200"==e.code?f({message:"预警短信已成功发送",type:"success"}):f.error("发送失败")}))},Je=e=>{ue.value=e},Me=()=>{u({flag:4,divisions:we}).then((e=>{e.data.length<1?f({message:"近1周暂无预警",type:"success"}):f({message:`近1周${e.data.length}次预警`,type:"warning"})}))},Qe=()=>{let e=[];d({flag:4,divisions:we}).then((a=>{e=[],a.data.forEach((a=>{e.push(a.dataTime)})),ye.value=e}))};return(e,t)=>{const s=b("el-date-picker"),n=b("el-radio"),o=b("el-radio-group"),r=b("el-option"),i=b("el-select"),c=b("el-button"),u=b("el-table-column"),d=b("el-table"),v=b("el-pagination"),m=b("el-icon"),y=b("el-tooltip"),A=b("el-collapse-item"),h=b("el-collapse"),w=b("el-dialog");return G(),E("div",Q,[P,U("div",z,[U("div",L,[R(" 监测日期: "),S(s,{"popper-class":"date_poper",class:"m-2",modelValue:a.value,"onUpdate:modelValue":t[0]||(t[0]=e=>a.value=e),onChange:xe,format:"YYYY 年 MM 月 DD 日","value-format":"YYYY-MM-DD",type:"date",placeholder:"选择日期",disabledDate:Ge},{default:k((e=>[U("div",{class:I(["cell",{current:e.isCurrent}])},[U("span",Z,Y(e.text),1),Ae(e)?(G(),E("span",K)):N("",!0)],2)])),_:1},8,["modelValue"])]),U("div",O,[H,U("div",j,[U("div",F,[R(" 自动发送预警短信: "),S(o,{onChange:t[1]||(t[1]=e=>{g({flag:ce.value}).then((e=>{f({message:e.msg,type:"success"})}))}),modelValue:ce.value,"onUpdate:modelValue":t[2]||(t[2]=e=>ce.value=e),class:"ml-4"},{default:k((()=>[S(n,{label:0,size:"large"},{default:k((()=>[R("是")])),_:1}),S(n,{label:1,size:"large"},{default:k((()=>[R("否")])),_:1})])),_:1},8,["modelValue"])]),U("div",T,[R(" 预警范围: "),S(o,{onChange:t[3]||(t[3]=e=>(qe(),void l({data:a.value,alertRange:ie.value,flag:4,divisions:we}).then((e=>{re.value=e.data,ke()})))),modelValue:ie.value,"onUpdate:modelValue":t[4]||(t[4]=e=>ie.value=e),class:"ml-4"},{default:k((()=>[S(n,{label:5e3,size:"large"},{default:k((()=>[R("5km")])),_:1}),S(n,{label:1e4,size:"large"},{default:k((()=>[R("10km")])),_:1})])),_:1},8,["modelValue"])]),U("div",X,[R(" 站点名称: "),S(i,{"popper-class":"select_city",style:{width:"76%"},modelValue:De.value,"onUpdate:modelValue":t[5]||(t[5]=e=>De.value=e),placeholder:"请选择",teleported:"false"},{default:k((()=>[(G(!0),E(W,null,D(We.value,(e=>(G(),C(r,{key:e.msName,label:e.msName,value:e.msName,title:e.msName},null,8,["label","value","title"])))),128))])),_:1},8,["modelValue"])]),U("div",_,[R(" 预警情况: "),S(i,{"popper-class":"select_city",style:{width:"76%"},modelValue:pe.value,"onUpdate:modelValue":t[6]||(t[6]=e=>pe.value=e),placeholder:"请选择"},{default:k((()=>[(G(),E(W,null,D(be,(e=>S(r,{key:e.flag,label:e.label,value:e.label},null,8,["label","value"]))),64))])),_:1},8,["modelValue"])]),U("div",$,[S(c,{class:"bt1",onClick:he},{default:k((()=>[R("查询")])),_:1}),S(c,{class:"bt2",onClick:fe},{default:k((()=>[R("重置")])),_:1})]),S(d,{"cell-style":{textAlign:"center"},"header-cell-style":{"text-align":"center",color:"rgba(102, 102, 102, 1)"},data:Re.value,style:{width:"100%"},onSelectionChange:Je},{default:k((()=>[S(u,{type:"selection",width:"20"}),S(u,{prop:"msName",width:"80",label:"站点名称"}),S(u,{prop:"warning",label:"预警情况"}),S(u,{prop:"name",width:"80",label:"联系人"}),S(u,{prop:"telephone",label:"联系电话"})])),_:1},8,["header-cell-style","data"]),S(v,{small:"",style:{display:"flex","justify-content":"center","margin-top":"10px"},onCurrentChange:Se,"current-page":Ee.value,"page-size":Ue.value,layout:" prev, pager, next",total:re.value.length},null,8,["current-page","page-size","total"]),S(c,{class:"but",type:"primary",disabled:ue.value.length<1||0==ce.value,onClick:t[7]||(t[7]=e=>V(B)?B.value=!0:B=!0)},{default:k((()=>[R(" 发布预警短信 ")])),_:1},8,["disabled"])])]),U("div",{class:"rightFoldDiv",onClick:t[8]||(t[8]=e=>(p.value=!p.value,void(p.value?document.querySelector(".rightWra").style.transform="translate(0,0)":document.querySelector(".rightWra").style.transform="translate(101%,0)")))},[S(y,{disabled:!q(p),"hide-after":"0","show-arrow":!1,"show-after":"200",class:"box-item",effect:"dark",content:"收起",placement:"top"},{default:k((()=>[q(p)?(G(),C(m,{key:0},{default:k((()=>[ee])),_:1})):N("",!0)])),_:1},8,["disabled"]),S(y,{disabled:q(p),"hide-after":"0","show-arrow":!1,"show-after":"200",class:"box-item",effect:"dark",content:"展开",placement:"top"},{default:k((()=>[q(p)?N("",!0):(G(),C(m,{key:0},{default:k((()=>[ae])),_:1}))])),_:1},8,["disabled"])])]),S(h,{class:"legend",accordion:""},{default:k((()=>[S(A,{name:"1"},{title:k((()=>[R("图例")])),default:k((()=>[U("div",le,[U("div",te,[(G(!0),E(W,null,D(q(me),((e,a,l)=>(G(),E("div",{key:l,style:x({backgroundColor:e.color,border:"1px solid value.color",width:"100%",height:"25px",marginTop:"5px",textAlign:"center"})},Y(a),5)))),128))])])])),_:1})])),_:1}),S(w,{modelValue:q(B),"onUpdate:modelValue":t[10]||(t[10]=e=>V(B)?B.value=e:B=e),title:"系统提示",width:"30%",center:""},{footer:k((()=>[U("span",ne,[S(c,{onClick:t[9]||(t[9]=e=>V(B)?B.value=!1:B=!1)},{default:k((()=>[R("取消")])),_:1}),S(c,{type:"primary",onClick:Be},{default:k((()=>[R("确定")])),_:1})])])),default:k((()=>[se])),_:1},8,["modelValue"])])}}},[["__scopeId","data-v-24060e52"]]);export{oe as default};
|