import{Y as V,w as S,I as T,b as $,L as P,M as j}from"./element-plus.eb2e53ea.js";import{d as D,b as B,o as d,c as _,a as t,Q as k,a0 as b,r as w,i as z,W as e,O as s,u as i,j as Y,T as y,V as I,a7 as U,$ as O,U as p}from"./@vue.c3e77981.js";import{d as q}from"./index.33b7474b.js";import{h as m}from"./moment.40bc58bf.js";import{B as Q}from"./vue-echarts.60e3d927.js";import"./@vueuse.a48d0173.js";import"./@element-plus.12c58ce2.js";import"./lodash-es.2b5acb28.js";import"./dayjs.16ed1fda.js";import"./axios.a8078129.js";import"./async-validator.fb49d0f5.js";import"./@ctrl.b082b0c1.js";import"./@popperjs.36402333.js";import"./escape-html.e5dfadb9.js";import"./normalize-wheel-es.8aeb3683.js";import"./lodash.a2abcd4b.js";import"./vue-router.43c06794.js";import"./pinia.b5130627.js";import"./css-color-function.975e80a5.js";import"./color.d986aa86.js";import"./clone.704d8332.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.ded7f805.js";import"./vue-clipboard3.987889a8.js";import"./clipboard.af74a91f.js";import"./echarts.8535e5a6.js";import"./zrender.3eba8991.js";import"./tslib.60310f1a.js";import"./highlight.js.31cd7941.js";import"./@highlightjs.b8b719e9.js";import"./resize-detector.4e96b72b.js";const W=["xlink:href","fill"],G=D({__name:"index",props:{iconName:{type:String,required:!0},className:{type:String,default:""},color:{type:String,default:"#333"},white:{type:Boolean,default:!1}},setup(c){const l=c,f=B(()=>`#icon-${l.iconName}`),F=B(()=>l.className?`svg-icon ${l.className}`:"svg-icon");return(v,n)=>(d(),_("svg",{class:k(F.value),"aria-hidden":"true"},[t("use",{"xlink:href":f.value,fill:c.white?"#fff":c.color},null,8,W)],2))}});const H=q(G,[["__scopeId","data-v-9b161d0d"]]),J={class:"workbench"},K={class:"mb-6 flex justify-between items-center"},X=t("span",{class:"text-2xl"},"\u5546\u54C1\u6982\u51B5",-1),Z={class:"flex items-center text-sm"},ee=t("span",{class:"mr-4"},"\u65F6\u95F4\u7B5B\u9009: ",-1),te={class:"flex flex-wrap"},oe={class:"mr-2"},ne={class:"text-info"},ue={class:"text-6xl"},ae={class:"text-info"},se={class:"mb-6 flex justify-between items-center"},le=t("span",{class:"text-2xl"},"\u5546\u54C1\u6392\u884C",-1),re={class:"flex items-center text-sm"},ie=t("span",{class:"mr-4"},"\u65F6\u95F4\u7B5B\u9009: ",-1),ce=D({name:"product"}),Qe=D({...ce,setup(c){const l=[{text:"\u8FD1\u4E00\u5468",value:()=>{const r=new Date,o=new Date;return o.setDate(o.getDate()-7),[o,r]}},{text:"\u8FD1\u4E00\u6708",value:()=>{const r=new Date,o=new Date;return o.setMonth(o.getMonth()-1),[o,r]}},{text:"\u8FD1\u4E09\u6708",value:()=>{const r=new Date,o=new Date;return o.setMonth(o.getMonth()-3),[o,r]}}],f=b({xAxis:{type:"category",data:[0],axisLabel:{rotate:45,color:"#333"}},yAxis:[{type:"value",name:"\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}]}),F=["#5DB1FF","#4CD384","#FFC46A","#CAA5F1"],v=b([{name:"\u5546\u54C1\u6D4F\u89C8\u91CF",type:"browse",icon:"RectangleCopy21",num:0,percent:0},{name:"\u5546\u54C1\u8BBF\u5BA2\u6570",type:"user",icon:"RectangleCopy5",num:0,percent:0},{name:"\u52A0\u8D2D\u4EF6\u6570",type:"cart",icon:"RectangleCopy13",num:0,percent:0},{name:"\u4E0B\u5355\u4EF6\u6570",type:"order",icon:"RectangleCopy12",num:0,percent:0},{name:"\u652F\u4ED8\u4EF6\u6570",type:"pay",icon:"RectangleCopy15",num:0,percent:0},{name:"\u652F\u4ED8\u91D1\u989D",type:"payPrice",icon:"RectangleCopy14",num:0,percent:0},{name:"\u6210\u672C\u91D1\u989D",type:"cost",icon:"RectangleCopy24",num:0,percent:0},{name:"\u9000\u6B3E\u91D1\u989D",type:"refundPrice",icon:"RectangleCopy32",num:0,percent:0},{name:"\u9000\u6B3E\u4EF6\u6570",type:"refund",icon:"RectangleCopy19",num:0,percent:0},{name:"\u8BBF\u5BA2-\u652F\u4ED8\u8F6C\u5316\u7387",type:"payPercent",icon:"RectangleCopy4",num:0,percent:0}]),n=w(["",""]),h=()=>{n.value[0]&&n.value[1]&&m(n.value[0]).format("YYYY/MM/DD")+""+m(n.value[1]).format("YYYY/MM/DD")},M=w([]),N=()=>{n.value[0]&&n.value[1]&&m(n.value[0]).format("YYYY/MM/DD")+""+m(n.value[1]).format("YYYY/MM/DD")};return z(()=>{h(),N()}),(r,o)=>{const g=V,x=S,A=H,E=T,R=$,a=P,L=j;return d(),_("div",J,[e(E,{shadow:"never",class:"!border-none"},{default:s(()=>[t("div",K,[X,t("div",Z,[ee,e(g,{modelValue:i(n),"onUpdate:modelValue":o[0]||(o[0]=u=>Y(n)?n.value=u:null),type:"daterange","range-separator":"\u81F3","start-placeholder":"\u5F00\u59CB\u65E5\u671F","end-placeholder":"\u7ED3\u675F\u65E5\u671F","unlink-panels":"",shortcuts:l},null,8,["modelValue"]),e(x,{type:"primary",class:"ml-4",onClick:h},{default:s(()=>[y("\u67E5\u8BE2")]),_:1})])]),t("div",te,[(d(!0),_(I,null,U(i(v),(u,C)=>(d(),_("div",{class:"w-1/5 flex mb-6",key:C},[t("div",oe,[t("div",{class:"rounded-full p-2",style:O({"background-color":F[C%4]})},[e(A,{iconName:u.icon,white:"",className:"text-6xl"},null,8,["iconName"])],4)]),t("div",null,[t("div",ne,p(u.name),1),t("div",ue,p(u.num),1),t("div",ae,[y("\u73AF\u6BD4\u589E\u957F: "),t("span",{class:k(u.percent>0?"text-success":"text-danger")},p(u.percent)+"%",3)])])]))),128))]),t("div",null,[e(i(Q),{style:{height:"400px"},option:i(f),autoresize:!0},null,8,["option"])])]),_:1}),e(E,{shadow:"never",class:"mt-4 !border-none"},{default:s(()=>[t("div",se,[le,t("div",re,[ie,e(g,{modelValue:i(n),"onUpdate:modelValue":o[1]||(o[1]=u=>Y(n)?n.value=u:null),type:"daterange","range-separator":"\u81F3","start-placeholder":"\u5F00\u59CB\u65E5\u671F","end-placeholder":"\u7ED3\u675F\u65E5\u671F","unlink-panels":"",shortcuts:l},null,8,["modelValue"]),e(x,{type:"primary",class:"ml-4",onClick:h},{default:s(()=>[y("\u67E5\u8BE2")]),_:1})])]),t("div",null,[e(L,{data:i(M)},{default:s(()=>[e(a,{label:"\u5546\u54C1\u56FE\u7247"},{default:s(({row:u})=>[e(R,{src:u.image,fit:"cover",style:{width:"50px",height:"50px"}},null,8,["src"])]),_:1}),e(a,{label:"\u5546\u54C1\u540D\u79F0",prop:"store_name","min-width":"250"}),e(a,{label:"\u6E38\u89C8\u91CF",prop:"visit","min-width":"120"}),e(a,{label:"\u8BBF\u5BA2\u6570",prop:"user","min-width":"120"}),e(a,{label:"\u52A0\u8D2D\u4EF6\u6570",prop:"cart","min-width":"120"}),e(a,{label:"\u4E0B\u5355\u4EF6\u6570",prop:"orders","min-width":"120"}),e(a,{label:"\u652F\u4ED8\u4EF6\u6570",prop:"pay","min-width":"120"}),e(a,{label:"\u652F\u4ED8\u91D1\u989D",prop:"price","min-width":"120"}),e(a,{label:"\u6536\u85CF\u6570",prop:"collect","min-width":"120"}),e(a,{label:"\u6BDB\u5229\u7387(%)",prop:"profit","min-width":"120"},{default:s(({row:u})=>[t("span",null,p(u.profit)+"%",1)]),_:1})]),_:1},8,["data"])])]),_:1})])}}});export{Qe as default};