import{U as X,L as tt,w as et,c as st,a as ot}from"./element-plus.a63a26dd.js";import{_ as at}from"./index.c76149e2.js";import{f as nt,g as lt}from"./workbench.c42ad4ca.js";import{h as V}from"./moment.40bc58bf.js";import{B as v}from"./vue-echarts.01ad0ec2.js";import{d as $,Z as D,r as f,i as it,af as ct,o as C,c as E,U as l,L as y,a as t,S as a,u as s,R as _,j as rt,T as pt,a9 as ut,a0 as dt,O as _t,bl as mt,bk as xt}from"./@vue.18505fe0.js";import{d as ht}from"./index.0a3a642f.js";import"./lodash-es.f52bd8b1.js";import"./async-validator.fb49d0f5.js";import"./@vueuse.fbc6a400.js";import"./@element-plus.edbd5a83.js";import"./dayjs.4884cfc2.js";import"./axios.932d3f8a.js";import"./@ctrl.b082b0c1.js";import"./normalize-wheel-es.8aeb3683.js";import"./@popperjs.36402333.js";import"./resize-detector.4e96b72b.js";import"./echarts.5016c48c.js";import"./zrender.58d022a1.js";import"./tslib.60310f1a.js";import"./lodash.2473fc51.js";import"./vue-router.101084e3.js";import"./pinia.a969beab.js";import"./css-color-function.9f6a56f3.js";import"./color.d1bc3784.js";import"./clone.83700f2e.js";import"./color-convert.755d189f.js";import"./color-name.e7a4e1d3.js";import"./color-string.e356f5de.js";import"./balanced-match.d2a36341.js";import"./ms.564e106c.js";import"./nprogress.fcc9be76.js";import"./vue-clipboard3.9e751565.js";import"./clipboard.dda64e67.js";import"./highlight.js.31cd7941.js";import"./@highlightjs.b0c09b66.js";const p=g=>(mt("data-v-6fc381ee"),g=g(),xt(),g),ft={class:"workbench"},yt={class:"flex"},gt={class:"flex-1 h-[270px]"},vt=p(()=>t("div",{class:"text-2xl"},"\u4ECA\u65E5\u8BA2\u5355\u91D1\u989D",-1)),Dt=p(()=>t("span",{class:"text-[12px]"},"\xA5",-1)),bt={class:"text-2xl"},wt=p(()=>t("div",{class:"w-[1px] bg-[#ccc] mr-4"},null,-1)),Ft={class:"flex-1 flex"},Ct={class:"flex-1"},Et={class:"text-1xl"},At={class:"ml-2 text-[18px]"},Bt={class:"text-[12px]"},St={class:"text-info"},kt=p(()=>t("span",{class:"text-info ml-2"},"\u65E5\u73AF\u6BD4: ",-1)),Ot={class:"text-success"},Lt={class:"text-1xl"},Rt={class:"ml-2 text-[18px]"},Nt={class:"text-[12px]"},Mt={class:"text-info"},Tt=p(()=>t("span",{class:"text-info ml-2"},"\u6708\u73AF\u6BD4: ",-1)),It={class:"text-success"},Yt={class:"flex-1"},jt={class:"text-1xl"},zt={class:"ml-2 text-[18px]"},Jt={class:"text-[12px]"},Vt={class:"text-info"},$t=p(()=>t("span",{class:"text-info ml-2"},"\u65E5\u73AF\u6BD4: ",-1)),Gt={class:"text-success"},Ut={class:"text-1xl"},Pt={class:"ml-2 text-[18px]"},Wt={class:"text-[12px]"},Zt={class:"text-info"},qt=p(()=>t("span",{class:"text-info ml-2"},"\u6708\u73AF\u6BD4: ",-1)),Ht={class:"text-success"},Kt={class:"mb-6 flex justify-between items-center"},Qt=p(()=>t("span",{class:"text-2xl"},"\u4EA4\u6613\u6982\u51B5",-1)),Xt={class:"flex items-center text-sm"},te=p(()=>t("span",{class:"mr-4"},"\u65F6\u95F4\u7B5B\u9009: ",-1)),ee={class:"flex flex-wrap"},se={class:"mr-2"},oe={class:"text-info"},ae={class:"text-6xl"},ne={class:"text-info"},le=$({name:"statistics_user"}),ie=$({...le,setup(g){const G=[{text:"\u8FD1\u4E00\u5468",value:()=>{const n=new Date,e=new Date;return e.setDate(e.getDate()-7),[e,n]}},{text:"\u672C\u6708",value:()=>{const n=new Date,e=new Date;return e.setDate(1),n.setMonth(n.getMonth()+1),n.setDate(0),[e,n]}},{text:"\u8FD1\u4E00\u6708",value:()=>{const n=new Date,e=new Date;return e.setMonth(e.getMonth()-1),[e,n]}},{text:"\u8FD1\u4E09\u6708",value:()=>{const n=new Date,e=new Date;return e.setMonth(e.getMonth()-3),[e,n]}}],u=D({xAxis:{type:"category",data:[0],axisLabel:{rotate:45,color:"#333"}},yAxis:{type:"value",name:"\u91D1\u989D",position:"left",axisLabel:{formatter:"{value}"}},grid:{left:"3%",right:"4%",bottom:"3%",containLabel:!0},legend:{data:["\u8BBF\u95EE\u91CF"]},itemStyle:{color:"red"},tooltip:{trigger:"axis"},series:[{name:"\u8BBF\u95EE\u91CF",data:[0],type:"line",smooth:!0}]}),b={tooltip:{trigger:"axis",axisPointer:{type:"cross"},formatter:n=>{let e=`
${n[0].name}\u70B9
`;return n.forEach(o=>{e+=`${o.seriesName}: ${o.value}
`}),e}},grid:{left:"3%",right:"4%",bottom:"3%",containLabel:!0},legend:{data:["\u6628\u5929","\u4ECA\u5929"],left:"3%",top:"3%"},xAxis:[{type:"category",boundaryGap:!1,axisLabel:{show:!1},axisTick:{show:!1},axisLine:{show:!1},grid:{show:!1}}],yAxis:[{type:"value",show:!1,spliteLine:{show:!1},axisLabel:{show:!1},axisTick:{show:!1},axisLine:{show:!1},grid:{show:!1}}],series:[{name:"\u6628\u5929",type:"line",smooth:!0,symbol:"none",itemStyle:{color:"#ccc"},areaStyle:{color:{type:"linear",x:0,y:0,x2:0,y2:1,colorStops:[{offset:0,color:"#ccc"},{offset:.6,color:"#fff"}],global:!1}}},{name:"\u4ECA\u5929",type:"line",smooth:!0,symbol:"none",areaStyle:{color:{type:"linear",x:0,y:0,x2:0,y2:1,colorStops:[{offset:0,color:"#5B8FF9"},{offset:.6,color:"#fff"}],global:!1}}}]},A=f({money:0,series:[]}),w=D(JSON.parse(JSON.stringify(b))),c=f([]),m=D(JSON.parse(JSON.stringify(b))),r=f([]),x=D(JSON.parse(JSON.stringify(b))),U=["#5DB1FF","#4CD384","#FFC46A","#CAA5F1","#FFC46A","#4CD384","#5DB1FF","#CAA5F1"],P=f(["RectangleCopy58","RectangleCopy48","RectangleCopy65","RectangleCopy62","RectangleCopy56","RectangleCopy55","RectangleCopy57","RectangleCopy65","RectangleCopy61","RectangleCopy52","RectangleCopy14","RectangleCopy32"]),d=f([new Date,new Date]),F=()=>{let n="";d.value[0]&&d.value[1]&&(n=V(d.value[0]).format("YYYY/MM/DD")+"-"+V(d.value[1]).format("YYYY/MM/DD")),nt({}).then(e=>{A.value={money:e.left.series[0].money,name:e.left.name},w.series[0].data=e.left.series[1].value,w.series[1].data=e.left.series[0].value,c.value=e.right.today.series,r.value=e.right.month,m.xAxis.data=e.right.today.x.map(o=>o),m.series[0].name=e.right.today.series[0].name,m.series[0].data=e.right.today.series[0].value,m.series[1].name=e.right.today.series[1].name,m.series[1].data=e.right.today.series[1].value,x.xAxis.data=Object.keys(e.right.month[0].value).map(o=>o),x.series[0].name=e.right.month[0].name,x.series[0].data=Object.values(e.right.month[0].value).map(o=>o),x.series[1].name=e.right.month[1].name,x.series[1].data=Object.values(e.right.month[1].value).map(o=>o)}),lt({date:n}).then(e=>{u.xAxis.data=[],u.series=[],console.log(e),u.legend.data=Object.values(e.series).map(o=>o.name),u.xAxis.data=e.x,u.series=Object.values(e.series).map(o=>({type:"line",smooth:!0,data:o.value,name:o.name,money:o.money,rate:o.rate,desc:o.desc}))})};return it(()=>{F()}),(n,e)=>{const o=tt,W=X,Z=et,q=at,H=ct("Warning"),K=st,Q=ot;return C(),E("div",ft,[l(o,{shadow:"never",class:"!border-none"},{default:y(()=>{var i,h,B,S,k,O,L,R,N,M,T,I,Y,j,z,J;return[t("div",yt,[t("div",gt,[vt,t("div",null,[Dt,t("span",bt,a(s(A).money||"0.00"),1)]),l(s(v),{style:{height:"200px"},option:s(w),autoresize:!0},null,8,["option"])]),wt,t("div",Ft,[t("div",Ct,[t("div",Et,[_(a((i=s(c)[0])==null?void 0:i.name),1),t("span",At,a((h=s(c)[0])==null?void 0:h.now_money),1)]),t("div",Bt,[t("span",St,"\u6628\u65E5: "+a((B=s(c)[0])==null?void 0:B.last_money),1),kt,t("span",Ot,a((S=s(c)[0])==null?void 0:S.rate)+"%",1)]),l(s(v),{style:{height:"160px","margin-bottom":"20px"},option:s(m),autoresize:!0},null,8,["option"]),t("div",Lt,[_(a((k=s(r)[0])==null?void 0:k.name),1),t("span",Rt,a((O=s(r)[0])==null?void 0:O.now_money),1)]),t("div",Nt,[t("span",Mt,"\u4E0A\u6708: "+a((L=s(r)[0])==null?void 0:L.last_money),1),Tt,t("span",It,a((R=s(r)[0])==null?void 0:R.rate)+"%",1)])]),t("div",Yt,[t("div",jt,[_(a((N=s(c)[1])==null?void 0:N.name),1),t("span",zt,a((M=s(c)[1])==null?void 0:M.now_money),1)]),t("div",Jt,[t("span",Vt,"\u6628\u65E5: "+a((T=s(c)[1])==null?void 0:T.last_money),1),$t,t("span",Gt,a((I=s(c)[1])==null?void 0:I.rate)+"%",1)]),l(s(v),{style:{height:"160px","margin-bottom":"20px"},option:s(x),autoresize:!0},null,8,["option"]),t("div",Ut,[_(a((Y=s(r)[1])==null?void 0:Y.name),1),t("span",Pt,a((j=s(r)[1])==null?void 0:j.now_money),1)]),t("div",Wt,[t("span",Zt,"\u4E0A\u6708: "+a((z=s(r)[1])==null?void 0:z.last_money),1),qt,t("span",Ht,a((J=s(r)[1])==null?void 0:J.rate)+"%",1)])])])])]}),_:1}),l(o,{shadow:"never",class:"mt-4 !border-none"},{default:y(()=>[t("div",Kt,[Qt,t("div",Xt,[te,l(W,{modelValue:s(d),"onUpdate:modelValue":e[0]||(e[0]=i=>rt(d)?d.value=i:null),type:"daterange","range-separator":"\u81F3","start-placeholder":"\u5F00\u59CB\u65E5\u671F","end-placeholder":"\u7ED3\u675F\u65E5\u671F","unlink-panels":"",shortcuts:G,onChange:F},null,8,["modelValue"]),l(Z,{type:"primary",class:"ml-4",onClick:F},{default:y(()=>[_("\u67E5\u8BE2")]),_:1})])]),t("div",ee,[(C(!0),E(pt,null,ut(s(u).series,(i,h)=>(C(),E("div",{class:"w-1/5 flex mb-6",key:h},[t("div",se,[t("div",{class:"rounded-full p-2",style:dt({"background-color":U[h%4]})},[l(q,{iconName:s(P)[h],white:"",className:"text-6xl"},null,8,["iconName"])],4)]),t("div",null,[t("div",oe,[_(a(i.name)+" ",1),l(Q,{class:"box-item",effect:"dark",content:i.desc,placement:"top-start"},{default:y(()=>[l(K,null,{default:y(()=>[l(H)]),_:1})]),_:2},1032,["content"])]),t("div",ae,a(i.money),1),t("div",ne,[_(" \u73AF\u6BD4\u589E\u957F: "),t("span",{class:_t(i.rate>0?"text-success":"text-danger")},a(i.rate)+"%",3)])])]))),128))]),t("div",null,[l(s(v),{style:{height:"400px"},option:s(u),autoresize:!0},null,8,["option"])])]),_:1})])}}});const Ge=ht(ie,[["__scopeId","data-v-6fc381ee"]]);export{Ge as default};