Mars3D-screen_web/dist/assets/js/index-633f7450.js

2 lines
6.1 KiB
JavaScript
Raw Normal View History

2023-10-10 09:36:22 +08:00
import{_ as L}from"./notData-cf10628e.js";import{i as h}from"./index-7bc24893.js";import{u as b}from"./useEcharts-103b3ceb.js";import{an as W}from"./goverment-af43d804.js";import{d as N,r as d,b as P,c as v,e as y,f as S,g as t,h as e,i as r,F as T,j as D,k as I,x as j,t as m,q as V,s as q,_ as H}from"./index-ccab2584.js";const u=p=>(V("data-v-853b9bea"),p=p(),q(),p),M={class:"table-box"},O={class:"echart-all"},$={class:"statistics-echart"},z=u(()=>t("div",{class:"count-title"},"\u4EBA\u5458\u603B\u6570\u7EDF\u8BA1",-1)),G={class:"statistics-echart"},J=u(()=>t("div",{class:"count-title"},"\u5E74\u9F84\u5206\u5E03",-1)),K={class:"table"},Q={class:"statistics-echart"},U=u(()=>t("div",{class:"count-title"},"\u7537\u5973\u6BD4\u4F8B",-1)),X={class:"table-all"},Y={class:"statistics-table"},Z=u(()=>t("div",{class:"count-title"},"\u5728\u518C\u4EBA\u5458\u5DE5\u79CD\u7EDF\u8BA1",-1)),tt={class:"table"},et={class:"table-empty"},at=u(()=>t("img",{src:L,alt:"notData"},null,-1)),st=u(()=>t("div",null,"\u6682\u65E0\u6570\u636E",-1)),ot={class:"statistics-table"},lt=u(()=>t("div",{class:"count-title"},"\u5728\u518C\u4EBA\u5458\u5730\u57DF\u7EDF\u8BA1",-1)),rt={class:"table"},it={class:"statistics-table"},nt=u(()=>t("div",{class:"count-title"},"\u5728\u518C\u4EBA\u5458\u6C11\u65CF\u7EDF\u8BA1",-1)),ct={class:"table"},dt=N({name:"ProjectSupervisionRecord"}),ut=N({...dt,setup(p){const g=d(),f=d(),w=d(),_=d([{type:"\u5728\u518C"},{type:"\u5728\u804C"}]),x=d([]),k=d([]),A=d([]),F=d([]),C=async()=>{const{result:a}=await W();R(a),E(a),B(a),a&&(a.workerAge.map((i,o)=>{x.value.push(i.attribute),_.value[0]["data"+o]=i.workerNum,_.value[1]["data"+o]=i.inServiceWorkerNum}),k.value=a.workerTypes,A.value=a.workerAddresses,F.value=a.workerNations)},R=a=>{let i=[];a&&(i=[a.workerNum,a.inServiceWorkerNum]);let o=h(g.value);b(o,{tooltip:{trigger:"axis",axisPointer:{type:"cross",crossStyle:{color:"#999"}}},color:["#008BFF"],grid:{left:60,top:80,width:"80%"},legend:{right:0,top:8,data:["\u4EBA\u6570"]},xAxis:[{type:"category",data:["\u5728\u518C","\u5728\u804C"],axisPointer:{type:"shadow"}}],yAxis:[{type:"value",name:"\u5355\u4F4D(\u4EBA)",nameTextStyle:{align:"right"}}],series:[{name:"\u4EBA\u6570",type:"bar",barWidth:18,itemStyle:{borderRadius:[11,11,11,11]},tooltip:{valueFormatter:function(c){return c+" \u4EBA"}},data:i}]})},E=a=>{let i=[],o=[],s=[];a&&a.workerAge.map(n=>{i.push(n.attribute),o.push(n.workerNum),s.push(n.inServiceWorkerNum)});let c=h(f.value);b(c,{tooltip:{trigger:"axis",axisPointer:{type:"cross",crossStyle:{color:"#999"}}},color:["#008BFF","#60CE83"],grid:{left:60,top:80,width:"80%",height:"66%"},legend:{right:0,top:8,data:["\u5728\u804C","\u5728\u518C"]},xAxis:[{type:"category",data:i,axisPointer:{type:"shadow"}}],yAxis:[{type:"value",name:"\u5355\u4F4D(\u4EBA)",nameTextStyle:{align:"right"}}],series:[{name:"\u5728\u804C",type:"bar",barWidth:18,itemStyle:{borderRadius:[11,11,11,11]},tooltip:{valueFormatter:function(n){return n+" \u4EBA"}},data:o},{name:"\u5728\u518C",type:"bar",barWidth:18,itemStyle:{borderRadius:[11,11,11,11]},tooltip:{valueFormatter:function(n){return n+" \u4EBA"}},data:s}]})},B=a=>{let i=[],o=[];a&&a.workerSex.map(l=>{i.push(l.attribute),o.push({value:l.workerNum,name:l.attribute})});let s=h(w.value);b(s,{tooltip:{trigger:"item"},legend:{right:0,top:8,data:i},color:["#008BFF","#60CE83"],series:[{name:"\u4EBA\u6570",type:"pie",radius:["40%","30%"],avoidLabelOverlap:!0,label:{show:!0,position:"outside",formatter:"{b}: {d}% {c}\u4EBA"},labelLine:{show:!0,length:50},data:o}]})};return P(async()=>{await C()}),(a,i)=>{const o=v("el-card"),s=v("el-table-column"),c=v("el-table");return y(),S("div",M,[t("div",O,[t("div",$,[e(o,{shadow:"never"},{default:r(()=>[z,t("div",{ref_key:"echartsRef",ref:g,class:"card content-box"},null,512)]),_:1})]),t("div",G,[e(o,{shadow:"never"},{default:r(()=>[J,t("div",{ref_key:"echartsRef2",ref:f,class:"card2 content-box"},null,512),t("div",K,[e(c,{data:_.value,class:"el-table","header-cell-style":{backgroundColor:"#D6E7FF",textAlign:"center"},"cell-style":{textAlign:"center"}},{default:r((