import{S as L,w as M,L as Y,o as N,M as z,N as O}from"./element-plus.78e68aed.js";import{_ as V}from"./index.1c6e9658.js";import"./index.49b211ae.js";import{b as T,c as j,d as U,e as H}from"./system_store.09c222e2.js";import{h as g}from"./moment.40bc58bf.js";import{B as C}from"./vue-echarts.01ad0ec2.js";import{d as A,Z as _,r as E,i as I,o as h,c as D,U as t,L as s,a as o,u as l,j as P,R as X,T as Z,a9 as q,a0 as G,S as B,O as J}from"./@vue.18505fe0.js";import"./lodash-es.f52bd8b1.js";import"./async-validator.fb49d0f5.js";import"./@vueuse.fbc6a400.js";import"./@element-plus.edbd5a83.js";import"./dayjs.8ae0c638.js";import"./axios.2b8d80bd.js";import"./@ctrl.b082b0c1.js";import"./normalize-wheel-es.8aeb3683.js";import"./@popperjs.36402333.js";import"./lodash.60201f64.js";import"./vue-router.101084e3.js";import"./pinia.a969beab.js";import"./css-color-function.b82a2ce7.js";import"./color.b905eb26.js";import"./clone.e1fb2883.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.495afef3.js";import"./vue-clipboard3.cb649e18.js";import"./clipboard.4592e390.js";import"./echarts.5016c48c.js";import"./zrender.58d022a1.js";import"./tslib.60310f1a.js";import"./highlight.js.31cd7941.js";import"./@highlightjs.b0c09b66.js";import"./resize-detector.4e96b72b.js";const K={class:"workbench"},Q={class:"flex justify-between items-center"},W=o("span",{class:"text-2xl"},"\u8FD0\u8425\u6982\u51B5",-1),$={class:"flex items-center text-sm"},ee=o("span",{class:"mr-4"},"\u65F6\u95F4\u7B5B\u9009: ",-1),te={class:"flex flex-wrap box-border mt-4"},oe={class:"flex"},ae={class:"mr-2"},ue={class:"text-info"},se={class:"text-6xl"},ne=o("span",{class:"text-2xl"},"\u8425\u4E1A\u8D8B\u52BF",-1),re={class:"mt-4 flex justify-center"},le=o("span",{class:"text-2xl"},"\u4EA4\u6613\u6570\u636E",-1),ie=o("span",{class:"text-2xl"},"\u4EA4\u6613\u7C7B\u578B",-1),ce=o("span",{class:"text-2xl"},"\u95E8\u5E97\u4E1A\u7EE9",-1),pe=A({name:"statistics_store"}),Je=A({...pe,setup(me){const w=[{text:"\u8FD1\u4E00\u5468",value:()=>{const a=new Date,e=new Date;return e.setDate(e.getDate()-7),[e,a]}},{text:"\u8FD1\u4E00\u6708",value:()=>{const a=new Date,e=new Date;return e.setMonth(e.getMonth()-1),[e,a]}},{text:"\u8FD1\u4E09\u6708",value:()=>{const a=new Date,e=new Date;return e.setMonth(e.getMonth()-3),[e,a]}}],c=_({xAxis:{type:"category",data:[0],axisLabel:{rotate:45,color:"#333"}},yAxis:[{type:"value",name:"\u7528\u6237\u6570\u91CF",position:"left",axisLabel:{formatter:"{value}"}},{type:"value",name:"\u91D1\u989D",position:"right",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}]}),m=_({tooltip:{formatter:"{a}
{b}: {c} ({d}%)"},legend:{data:[]},series:[{name:"\u4EA4\u6613\u7C7B\u578B",type:"pie",radius:["35%","65%"],center:["50%","60%"],data:[],emphasis:{itemStyle:{shadowBlur:10,shadowOffsetX:0,shadowColor:"rgba(0, 0, 0, 0.5)"}}}]}),f=E([]),x=E([]),S=["#5DB1FF","#4CD384","#FFC46A","#CAA5F1","#FFC46A","#4CD384","#5DB1FF","#CAA5F1"],y=_([{name:"\u95E8\u5E97\u8BA2\u5355\u91D1\u989D",type:"store_income",icon:"RectangleCopy",num:0},{name:"\u4F59\u989D\u6D88\u8017\u91D1\u989D",type:"store_use_yue",icon:"RectangleCopy49",num:0},{name:"\u7528\u6237\u5145\u503C\u91D1\u989D",type:"recharge_price",icon:"RectangleCopy53",num:0},{name:"\u6536\u94F6\u8BA2\u5355\u91D1\u989D",type:"cashier_order_price",icon:"RectangleCopy5",num:0},{name:"\u4ED8\u8D39\u4F1A\u5458\u91D1\u989D",type:"vip_price",icon:"RectangleCopy4",num:0},{name:"\u5206\u914D\u8BA2\u5355\u91D1\u989D",type:"store_income",icon:"RectangleCopy7",num:0},{name:"\u6838\u9500\u8BA2\u5355\u91D1\u989D",type:"store_writeoff_order_price",icon:"RectangleCopy59",num:0},{name:"\u95E8\u5E97\u65B0\u589E\u7528\u6237\u6570",type:"store_user_count",icon:"RectangleCopy15",num:0},{name:"\u95E8\u5E97\u6210\u4EA4\u7528\u6237\u6570",type:"store_pay_user_count",icon:"RectangleCopy54",num:0},{name:"\u5FAE\u4FE1\u4F1A\u5458\u5361\u6FC0\u6D3B\u6570",type:"card_count",icon:"RectangleCopy7",num:0}]),i=E(["",""]),b=()=>{let a="";i.value[0]&&i.value[1]&&(a=g(i.value[0]).format("YYYY/MM/DD")+"-"+g(i.value[1]).format("YYYY/MM/DD")),T({date:a}).then(e=>{y.forEach(n=>{n.num=e[n.type]})}),j({date:a}).then(e=>{c.xAxis.data=[],c.series=[],c.legend.data=e.series.map(n=>n.name),c.xAxis.data=e.xAxis,c.series=e.series.map(n=>(n.name=="\u65B0\u589E\u7528\u6237\u6570"&&(n.yAxisIndex=0),n))}),U({date:a}).then(e=>{m.legend.data=e.bing_xdata,m.series[0].data=e.bing_data,f.value=e.order_list}),H({date:a}).then(e=>{x.value=e})};return I(()=>{b()}),(a,e)=>{const n=L,R=M,p=Y,k=V,F=N,u=z,v=O;return h(),D("div",K,[t(p,{shadow:"never",class:"!border-none"},{default:s(()=>[o("div",Q,[W,o("div",$,[ee,t(n,{modelValue:l(i),"onUpdate:modelValue":e[0]||(e[0]=r=>P(i)?i.value=r:null),type:"daterange","range-separator":"\u81F3","start-placeholder":"\u5F00\u59CB\u65E5\u671F","end-placeholder":"\u7ED3\u675F\u65E5\u671F","unlink-panels":"",shortcuts:w},null,8,["modelValue"]),t(R,{type:"primary",class:"ml-4",onClick:b},{default:s(()=>[X("\u67E5\u8BE2")]),_:1})])])]),_:1}),o("div",te,[(h(!0),D(Z,null,q(l(y),(r,d)=>(h(),D("div",{class:"box-border w-1/5",key:d},[t(p,{class:J(["!border-none ml-4 mb-4 flex",{"!ml-0":d%5===0}]),shadow:"never"},{default:s(()=>[o("div",oe,[o("div",ae,[o("div",{class:"rounded-full p-2",style:G({"background-color":S[d%8]})},[t(k,{iconName:r.icon,white:"",className:"text-6xl"},null,8,["iconName"])],4)]),o("div",null,[o("div",ue,B(r.name),1),o("div",se,B(r.num),1)])])]),_:2},1032,["class"])]))),128))]),t(p,{shadow:"never",class:"!border-none"},{default:s(()=>[ne,t(l(C),{style:{height:"400px"},option:l(c),autoresize:!0},null,8,["option"])]),_:1}),o("div",re,[t(p,{shadow:"never",class:"flex-1 !border-none"},{default:s(()=>[le,t(v,{data:l(f),class:"mt-4",height:"280"},{default:s(()=>[t(u,{prop:"avatar",label:"\u5934\u50CF","min-width":"55"},{default:s(({row:r})=>[t(F,{size:40,src:r.avatar},null,8,["src"])]),_:1}),t(u,{prop:"nickname",label:"\u7528\u6237\u540D\u79F0"}),t(u,{prop:"order_id",label:"\u8BA2\u5355\u53F7","min-width":"200"}),t(u,{prop:"pay_price",label:"\u4EA4\u6613\u91D1\u989D"}),t(u,{prop:"pay_time",label:"\u6210\u4EA4\u65F6\u95F4"})]),_:1},8,["data"])]),_:1}),t(p,{shadow:"never",class:"w-[500px] !border-none ml-4"},{default:s(()=>[ie,t(l(C),{style:{height:"300px"},option:l(m),autoresize:!0},null,8,["option"])]),_:1})]),t(p,{shadow:"never",class:"mt-4 !border-none"},{default:s(()=>[ce,t(v,{data:l(x),class:"mt-4"},{default:s(()=>[t(u,{prop:"avatar",label:"logo","min-width":"55"},{default:s(({row:r})=>[t(F,{size:40,src:r.avatar},null,8,["src"])]),_:1}),t(u,{prop:"name",label:"\u95E8\u5E97\u540D\u79F0"}),t(u,{prop:"store_price",label:"\u95E8\u5E97\u5B9E\u9645\u6536\u6B3E"}),t(u,{prop:"store_order_price",label:"\u95E8\u5E97\u5546\u54C1\u9500\u552E\u989D"}),t(u,{prop:"store_product_count",label:"\u95E8\u5E97\u5546\u54C1\u9500\u91CF"}),t(u,{prop:"store_user_count",label:"\u95E8\u5E97\u65B0\u589E\u7528\u6237\u6570"})]),_:1},8,["data"])]),_:1})])}}});export{Je as default};