index-fa7a14f4.js 8.6 KB

1
  1. import{R}from"./index-ecd7a86a.js";import{w as S,X as g,Y as $,c as B,a as P,o as E,W as v,$ as e,m as l,Z as a,F as w,E as i,a4 as n,u as m,a6 as _,a5 as F,a0 as I,a1 as N}from"./vue-7f5e2b1b.js";import{A as V}from"./index-61855aff.js";import{_ as Y}from"./_plugin-vue_export-helper-c27b6911.js";import"./ext-57207912.js";import"./vue-router-e2815956.js";const q=["id"],M={__name:"ringProgress",props:["percent","idname"],setup(f){const u=f;return S(()=>u.percent,(o,p)=>{new R(u.idname,{height:100,width:100,autoFit:!1,percent:u.percent,color:["#5B8FF9","#E8EDF3"]}).render()}),(o,p)=>(g(),$("div",{id:u.idname},null,8,q))}};const r=f=>(I("data-v-e85bf6c7"),f=f(),N(),f),A={class:"y-container mt-10"},C={class:"brderRight pd-10 flex"},T={style:{"font-size":"14px",color:"red"}},L={class:"info"},W=r(()=>e("small",null,"达成金额",-1)),X={class:"info"},Z=r(()=>e("small",null,"目标金额",-1)),j={class:"brderRight pd-10 flex"},G={style:{"font-size":"14px",color:"red"}},H={class:"info"},J=r(()=>e("small",null,"达成金额",-1)),K={class:"info"},O=r(()=>e("small",null,"目标金额",-1)),Q={class:"brderRight pd-10 flex"},U={style:{"font-size":"14px",color:"red"}},tt={class:"info"},et=r(()=>e("small",null,"达成金额",-1)),lt={class:"info"},at=r(()=>e("small",null,"目标金额",-1)),st={class:"y-container mt-10"},nt=r(()=>e("p",{class:"almm"},"一季度目标",-1)),ot={class:"y-container mt-10"},dt=r(()=>e("p",{class:"almm"},"二季度目标",-1)),it={class:"y-container mt-10"},ut=r(()=>e("p",{class:"almm"},"三季度目标",-1)),rt={class:"y-container"},ct=r(()=>e("p",{class:"almm"},"四季度目标",-1)),_t={__name:"index",setup(f){const u=B(()=>{var h=new Date,x=h.getMonth()+1;return x>=1&&x<=3?1:x>=4&&x<=6?2:x>=7&&x<=9?3:4}),o=P({}),p=P([]),z=async()=>{const h=await V.requested({id:"20230110151902",content:{where:{year:new Date().getFullYear()}}});p.value=h.data,h.data.length>0?o.value=h.data[0]:o.value="none"};return E(()=>{z()}),(h,x)=>{const b=v("a-statistic"),D=v("a-col"),k=v("a-row"),d=v("a-table-column"),c=v("a-table-column-group"),y=v("a-table");return g(),$(w,null,[e("div",A,[l(k,{gutter:16},{default:a(()=>[l(D,{span:8},{default:a(()=>[e("div",C,[e("div",null,[l(b,{class:"mt-10",style:{cursor:"pointer"},title:"本月目标",value:o.value[`m${new Date().getMonth()+1}pl`],"value-style":{color:"#333"}},{suffix:a(()=>[i(" % "),e("small",T,n(o.value[`m${new Date().getMonth()+1}a`]-o.value[`m${new Date().getMonth()+1}l`]),1)]),_:1},8,["value"]),e("div",null,[e("div",L,[W,i(" "),e("small",null,n(o.value[`m${new Date().getMonth()+1}a`])+"万元",1)]),e("div",X,[Z,i(" "),e("small",null,n(o.value[`m${new Date().getMonth()+1}l`])+"万元",1)])])]),l(M,{idname:"ringProgress",percent:o.value[`m${new Date().getMonth()+1}a`]/o.value[`m${new Date().getMonth()+1}l`]},null,8,["percent"])])]),_:1}),l(D,{span:8},{default:a(()=>[e("div",j,[e("div",null,[l(b,{class:"mt-10",style:{cursor:"pointer"},title:"本季目标",value:o.value[`s${m(u)}pl`],"value-style":{color:"#333"}},{suffix:a(()=>[i(" % "),e("small",G,n(o.value[`s${m(u)}a`]-o.value[`s${m(u)}l`]),1)]),_:1},8,["value"]),e("div",null,[e("div",H,[J,i(" "),e("small",null,n(o.value[`s${m(u)}a`])+"万元",1)]),e("div",K,[O,i(" "),e("small",null,n(o.value[`s${m(u)}l`])+"万元",1)])])]),l(M,{idname:"ringProgress2",percent:o.value[`s${m(u)}a`]/o.value[`s${m(u)}l`]},null,8,["percent"])])]),_:1}),l(D,{span:8},{default:a(()=>[e("div",Q,[e("div",null,[l(b,{class:"mt-10",style:{cursor:"pointer"},title:"本年目标",value:o.value.y1pl,"value-style":{color:"#333"}},{suffix:a(()=>[i(" % "),e("small",U,n(o.value.y1a-o.value.y1l),1)]),_:1},8,["value"]),e("div",null,[e("div",tt,[et,i(" "),e("small",null,n(o.value.y1a),1)]),e("div",lt,[at,i(" "),e("small",null,n(o.value.y1l),1)])])]),l(M,{idname:"ringProgress3",percent:o.value.y1a/o.value.y1l},null,8,["percent"])])]),_:1})]),_:1})]),e("div",st,[nt,l(y,{"data-source":p.value,class:"ant-table-small mt-10",size:"small",pagination:!1,"row-class-name":(t,s)=>s%2===1?"table-striped":null,bordered:""},{default:a(()=>[l(c,null,{title:a(()=>[i("1季度(万元)")]),default:a(()=>[l(d,{title:"目标","data-index":"s1l"}),l(d,{title:"实际","data-index":"s1a"},{default:a(({record:t})=>[e("span",{style:_(t.s1a>t.s1l?{color:"red"}:{color:"green"})},n(t.s1a.toFixed(2)),5)]),_:1}),l(d,{title:"达成率"},{default:a(({record:t})=>[e("span",null,n((t.s1a.toFixed(2)/t.s1l.toFixed(2)*100).toFixed(2))+" % ",1)]),_:1})]),_:1}),(g(),$(w,null,F(3,t=>l(c,{key:t},{title:a(()=>[i(n(`${t}月(万元)`),1)]),default:a(()=>[l(d,{title:"目标","data-index":`m${t}l`},null,8,["data-index"]),l(d,{title:"实际","data-index":`m${t}a`},{default:a(({record:s})=>[e("span",{style:_(s[`m${t}a`]>s[`m${t}l`]?{color:"red"}:{color:"green"})},n(s[`m${t}a`].toFixed(2)),5)]),_:2},1032,["data-index"]),l(d,{title:"达成率"},{default:a(({record:s})=>[e("span",null,n((s[`m${t}a`].toFixed(2)/s[`m${t}l`].toFixed(2)*100).toFixed(2))+" % ",1)]),_:2},1024)]),_:2},1024)),64))]),_:1},8,["data-source","row-class-name"])]),e("div",ot,[dt,l(y,{"data-source":p.value,class:"ant-table-small mt-10",size:"small",pagination:!1,"row-class-name":(t,s)=>s%2===1?"table-striped":null,bordered:""},{default:a(()=>[l(c,null,{title:a(()=>[i("2季度(万元)")]),default:a(()=>[l(d,{title:"目标","data-index":"s2l",width:"100px"}),l(d,{title:"实际","data-index":"s2a",width:"100px"},{default:a(({record:t})=>[e("span",{style:_(t.s2a>t.s2l?{color:"red"}:{color:"green"})},n(t.s2a.toFixed(2)),5)]),_:1}),l(d,{title:"达成率",width:"100px"},{default:a(({record:t})=>[e("span",null,n((t.s2a.toFixed(2)/t.s2l.toFixed(2)*100).toFixed(2))+" % ",1)]),_:1})]),_:1}),(g(),$(w,null,F(3,t=>l(c,{key:t},{title:a(()=>[i(n(`${t+3}月(万元)`),1)]),default:a(()=>[l(d,{title:"目标","data-index":`m${t+3}l`,width:"100px"},null,8,["data-index"]),l(d,{title:"实际","data-index":`m${t+3}a`,width:"100px"},{default:a(({record:s})=>[e("span",{style:_(s[`m${t+3}a`]>s[`m${t+3}l`]?{color:"red"}:{color:"green"})},n(s[`m${t+3}a`].toFixed(2)),5)]),_:2},1032,["data-index"]),l(d,{title:"达成率",width:"100px"},{default:a(({record:s})=>[e("span",null,n((s[`m${t+3}a`].toFixed(2)/s[`m${t+3}l`].toFixed(2)*100).toFixed(2))+" % ",1)]),_:2},1024)]),_:2},1024)),64))]),_:1},8,["data-source","row-class-name"])]),e("div",it,[ut,l(y,{"data-source":p.value,class:"ant-table-small mt-10",size:"small",pagination:!1,"row-class-name":(t,s)=>s%2===1?"table-striped":null,bordered:""},{default:a(()=>[l(c,null,{title:a(()=>[i("3季度(万元)")]),default:a(()=>[l(d,{title:"目标","data-index":"s3l",width:"100px"}),l(d,{title:"实际","data-index":"s3a",width:"100px"},{default:a(({record:t})=>[e("span",{style:_(t.s3a>t.s3l?{color:"red"}:{color:"green"})},n(t.s3a.toFixed(2)),5)]),_:1}),l(d,{title:"达成率",width:"100px"},{default:a(({record:t})=>[e("span",null,n((t.s3a.toFixed(2)/t.s3l.toFixed(2)*100).toFixed(2))+" % ",1)]),_:1})]),_:1}),(g(),$(w,null,F(3,t=>l(c,{key:t},{title:a(()=>[i(n(`${t+6}月(万元)`),1)]),default:a(()=>[l(d,{title:"目标","data-index":`m${t+6}l`,width:"100px"},null,8,["data-index"]),l(d,{title:"实际","data-index":`m${t+6}a`,width:"100px"},{default:a(({record:s})=>[e("span",{style:_(s[`m${t+6}a`]>s[`m${t+6}l`]?{color:"red"}:{color:"green"})},n(s[`m${t+6}a`].toFixed(2)),5)]),_:2},1032,["data-index"]),l(d,{title:"达成率",width:"100px"},{default:a(({record:s})=>[e("span",null,n((s[`m${t+6}a`].toFixed(2)/s[`m${t+6}l`].toFixed(2)*100).toFixed(2))+" % ",1)]),_:2},1024)]),_:2},1024)),64))]),_:1},8,["data-source","row-class-name"])]),e("div",rt,[ct,l(y,{"data-source":p.value,class:"ant-table-small",size:"small",pagination:!1,"row-class-name":(t,s)=>s%2===1?"table-striped":null,bordered:""},{default:a(()=>[l(c,null,{title:a(()=>[i("4季度(万元)")]),default:a(()=>[l(d,{title:"目标","data-index":"s3l",width:"100px"}),l(d,{title:"实际","data-index":"s3a",width:"100px"},{default:a(({record:t})=>[e("span",{style:_(t.s4a>t.s4l?{color:"red"}:{color:"green"})},n(t.s4a.toFixed(2)),5)]),_:1}),l(d,{title:"达成率",width:"100px"},{default:a(({record:t})=>[e("span",null,n((t.s4a.toFixed(2)/t.s4l.toFixed(2)*100).toFixed(2))+" % ",1)]),_:1})]),_:1}),(g(),$(w,null,F(3,t=>l(c,{key:t},{title:a(()=>[i(n(`${t+9}月`),1)]),default:a(()=>[l(d,{title:"目标","data-index":`m${t+9}l`,width:"100px"},null,8,["data-index"]),l(d,{title:"实际","data-index":`m${t+9}a`,width:"100px"},{default:a(({record:s})=>[e("span",{style:_(s[`m${t+9}a`]>s[`m${t+9}l`]?{color:"red"}:{color:"green"})},n(s[`m${t+9}a`].toFixed(2)),5)]),_:2},1032,["data-index"]),l(d,{title:"达成率",width:"100px"},{default:a(({record:s})=>[e("span",null,n((s[`m${t+9}a`]/s[`m${t+9}l`]*100).toFixed(2))+" % ",1)]),_:2},1024)]),_:2},1024)),64))]),_:1},8,["data-source","row-class-name"])])],64)}}},gt=Y(_t,[["__scopeId","data-v-e85bf6c7"]]);export{gt as default};