1 |
- import{d as M,r as g,f as X,S as q,o as S,x as C,w as n,h as G,g as a,a as e,y as Z,q as H,a_ as m,e1 as f,c1 as J,k as K,D as N,E as O,j as Q,_ as V,__tla as W}from"./index-12a7743c.js";import{E as Y,__tla as $}from"./el-card-73514116.js";import{E as ee,__tla as te}from"./el-skeleton-item-bb2b4a43.js";import{_ as ae,__tla as re}from"./Echart-735b79c4.js";import{_ as le,__tla as oe}from"./index-421feb7d.js";import{P as b,__tla as se}from"./product-dce77f79.js";import{S as p,__tla as ie}from"./index-4a75f91f.js";import{d as ce}from"./download-20922b56.js";import{C as ne,__tla as ue}from"./CardTitle-ffaf8c59.js";import{k as me,f as de,__tla as _e}from"./formatTime-adaaebb7.js";import{u as fe,__tla as pe}from"./useMessage-9e9b1c85.js";import{__tla as ye}from"./CountTo-830af9bb.js";let F,xe=Promise.all([(()=>{try{return W}catch{}})(),(()=>{try{return $}catch{}})(),(()=>{try{return te}catch{}})(),(()=>{try{return re}catch{}})(),(()=>{try{return oe}catch{}})(),(()=>{try{return se}catch{}})(),(()=>{try{return ie}catch{}})(),(()=>{try{return ue}catch{}})(),(()=>{try{return _e}catch{}})(),(()=>{try{return pe}catch{}})(),(()=>{try{return ye}catch{}})()]).then(async()=>{let P;P={class:"flex flex-row items-center justify-between"},F=V(M({name:"ProductSummary",__name:"ProductSummary",setup(ve){const k=fe(),h=g(!0),w=g(!1),t=g(),y=g(),v=X({dataset:{dimensions:["time","browseCount","browseUserCount","orderPayPrice","afterSaleRefundPrice"],source:[]},grid:{left:20,right:20,bottom:20,top:80,containLabel:!0},legend:{top:50},series:[{name:"\u5546\u54C1\u6D4F\u89C8\u91CF",type:"line",smooth:!0,itemStyle:{color:"#B37FEB"}},{name:"\u5546\u54C1\u8BBF\u5BA2\u6570",type:"line",smooth:!0,itemStyle:{color:"#FFAB2B"}},{name:"\u652F\u4ED8\u91D1\u989D",type:"bar",smooth:!0,yAxisIndex:1,itemStyle:{color:"#1890FF"}},{name:"\u9000\u6B3E\u91D1\u989D",type:"bar",smooth:!0,yAxisIndex:1,itemStyle:{color:"#00C050"}}],toolbox:{feature:{dataZoom:{yAxisIndex:!1},brush:{type:["lineX","clear"]},saveAsImage:{show:!0,name:"\u5546\u54C1\u72B6\u51B5"}}},tooltip:{trigger:"axis",axisPointer:{type:"cross"},padding:[5,10]},xAxis:{type:"category",boundaryGap:!0,axisTick:{show:!1}},yAxis:[{type:"value",name:"\u91D1\u989D",axisLine:{show:!1},axisTick:{show:!1},axisLabel:{textStyle:{color:"#7F8B9C"}},splitLine:{show:!0,lineStyle:{color:"#F5F7F9"}}},{type:"value",name:"\u6570\u91CF",axisLine:{show:!1},axisTick:{show:!1},axisLabel:{textStyle:{color:"#7F8B9C"}},splitLine:{show:!0,lineStyle:{color:"#F5F7F9"}}}]}),A=async()=>{h.value=!0;const u=y.value.times;me(u[0],u[1])&&(u[0]=de(J(u[0]).subtract(1,"d"))),await Promise.all([L(),B()]),h.value=!1},L=async()=>{const u=y.value.times;t.value=await b.getProductStatisticsAnalyse({times:u})},B=async()=>{const u=y.value.times,x=await b.getProductStatisticsList({times:u});for(let d of x)d.orderPayPrice=m(d.orderPayPrice),d.afterSaleRefundPrice=m(d.afterSaleRefundPrice);v.dataset&&v.dataset.source&&(v.dataset.source=x)},R=async()=>{try{await k.exportConfirm(),w.value=!0;const u=y.value.times,x=await b.exportProductStatisticsExcel({times:u});ce.excel(x,"\u5546\u54C1\u72B6\u51B5.xls")}catch{}finally{w.value=!1}};return(u,x)=>{const d=K,E=N,I=le,_=O,U=Q,j=ae,D=ee,T=Y,z=q("hasPermi");return S(),C(T,{shadow:"never"},{header:n(()=>[G("div",P,[a(e(ne),{title:"\u5546\u54C1\u6982\u51B5"}),a(I,{ref_key:"shortcutDateRangePicker",ref:y,onChange:A},{default:n(()=>[Z((S(),C(E,{class:"ml-4",onClick:R,loading:e(w)},{default:n(()=>[a(d,{icon:"ep:download",class:"mr-1"}),H("\u5BFC\u51FA ")]),_:1},8,["loading"])),[[z,["statistics:product:export"]]])]),_:1},512)])]),default:n(()=>[a(U,{gutter:16},{default:n(()=>[a(_,{xl:4,md:8,sm:24},{default:n(()=>{var r,l,o,s,i,c;return[a(p,{title:"\u5546\u54C1\u6D4F\u89C8\u91CF",tooltip:"\u5728\u9009\u5B9A\u6761\u4EF6\u4E0B\uFF0C\u6240\u6709\u5546\u54C1\u8BE6\u60C5\u9875\u88AB\u8BBF\u95EE\u7684\u6B21\u6570\uFF0C\u4E00\u4E2A\u4EBA\u5728\u7EDF\u8BA1\u65F6\u95F4\u5185\u8BBF\u95EE\u591A\u6B21\u8BB0\u4E3A\u591A\u6B21",icon:"ep:view","icon-color":"bg-blue-100","icon-bg-color":"text-blue-500",prefix:"\uFFE5",decimals:2,value:e(m)(((l=(r=e(t))==null?void 0:r.value)==null?void 0:l.browseCount)||0),percent:e(f)((s=(o=e(t))==null?void 0:o.value)==null?void 0:s.browseCount,(c=(i=e(t))==null?void 0:i.reference)==null?void 0:c.browseCount)},null,8,["value","percent"])]}),_:1}),a(_,{xl:4,md:8,sm:24},{default:n(()=>{var r,l,o,s,i,c;return[a(p,{title:"\u5546\u54C1\u8BBF\u5BA2\u6570",tooltip:"\u5728\u9009\u5B9A\u6761\u4EF6\u4E0B\uFF0C\u8BBF\u95EE\u4EFB\u4F55\u5546\u54C1\u8BE6\u60C5\u9875\u7684\u4EBA\u6570\uFF0C\u4E00\u4E2A\u4EBA\u5728\u7EDF\u8BA1\u65F6\u95F4\u8303\u56F4\u5185\u8BBF\u95EE\u591A\u6B21\u53EA\u8BB0\u4E3A\u4E00\u4E2A",icon:"ep:user-filled","icon-color":"bg-purple-100","icon-bg-color":"text-purple-500",prefix:"\uFFE5",decimals:2,value:e(m)(((l=(r=e(t))==null?void 0:r.value)==null?void 0:l.browseUserCount)||0),percent:e(f)((s=(o=e(t))==null?void 0:o.value)==null?void 0:s.browseUserCount,(c=(i=e(t))==null?void 0:i.reference)==null?void 0:c.browseUserCount)},null,8,["value","percent"])]}),_:1}),a(_,{xl:4,md:8,sm:24},{default:n(()=>{var r,l,o,s,i,c;return[a(p,{title:"\u652F\u4ED8\u4EF6\u6570",tooltip:"\u5728\u9009\u5B9A\u6761\u4EF6\u4E0B\uFF0C\u6210\u529F\u4ED8\u6B3E\u8BA2\u5355\u7684\u5546\u54C1\u4EF6\u6570\u4E4B\u548C",icon:"fa-solid:money-check-alt","icon-color":"bg-yellow-100","icon-bg-color":"text-yellow-500",prefix:"\uFFE5",decimals:2,value:e(m)(((l=(r=e(t))==null?void 0:r.value)==null?void 0:l.orderPayCount)||0),percent:e(f)((s=(o=e(t))==null?void 0:o.value)==null?void 0:s.orderPayCount,(c=(i=e(t))==null?void 0:i.reference)==null?void 0:c.orderPayCount)},null,8,["value","percent"])]}),_:1}),a(_,{xl:4,md:8,sm:24},{default:n(()=>{var r,l,o,s,i,c;return[a(p,{title:"\u652F\u4ED8\u91D1\u989D",tooltip:"\u5728\u9009\u5B9A\u6761\u4EF6\u4E0B\uFF0C\u6210\u529F\u4ED8\u6B3E\u8BA2\u5355\u7684\u5546\u54C1\u91D1\u989D\u4E4B\u548C",icon:"ep:warning-filled","icon-color":"bg-green-100","icon-bg-color":"text-green-500",prefix:"\uFFE5",decimals:2,value:e(m)(((l=(r=e(t))==null?void 0:r.value)==null?void 0:l.orderPayPrice)||0),percent:e(f)((s=(o=e(t))==null?void 0:o.value)==null?void 0:s.orderPayPrice,(c=(i=e(t))==null?void 0:i.reference)==null?void 0:c.orderPayPrice)},null,8,["value","percent"])]}),_:1}),a(_,{xl:4,md:8,sm:24},{default:n(()=>{var r,l,o,s,i,c;return[a(p,{title:"\u9000\u6B3E\u4EF6\u6570",tooltip:"\u5728\u9009\u5B9A\u6761\u4EF6\u4E0B\uFF0C\u6210\u529F\u9000\u6B3E\u7684\u5546\u54C1\u4EF6\u6570\u4E4B\u548C",icon:"fa-solid:wallet","icon-color":"bg-cyan-100","icon-bg-color":"text-cyan-500",prefix:"\uFFE5",decimals:2,value:e(m)(((l=(r=e(t))==null?void 0:r.value)==null?void 0:l.afterSaleCount)||0),percent:e(f)((s=(o=e(t))==null?void 0:o.value)==null?void 0:s.afterSaleCount,(c=(i=e(t))==null?void 0:i.reference)==null?void 0:c.afterSaleCount)},null,8,["value","percent"])]}),_:1}),a(_,{xl:4,md:8,sm:24},{default:n(()=>{var r,l,o,s,i,c;return[a(p,{title:"\u9000\u6B3E\u91D1\u989D",tooltip:"\u5728\u9009\u5B9A\u6761\u4EF6\u4E0B\uFF0C\u6210\u529F\u9000\u6B3E\u7684\u5546\u54C1\u91D1\u989D\u4E4B\u548C",icon:"fa-solid:award","icon-color":"bg-yellow-100","icon-bg-color":"text-yellow-500",prefix:"\uFFE5",decimals:2,value:e(m)(((l=(r=e(t))==null?void 0:r.value)==null?void 0:l.afterSaleRefundPrice)||0),percent:e(f)((s=(o=e(t))==null?void 0:o.value)==null?void 0:s.afterSaleRefundPrice,(c=(i=e(t))==null?void 0:i.reference)==null?void 0:c.afterSaleRefundPrice)},null,8,["value","percent"])]}),_:1})]),_:1}),a(D,{loading:e(h),animated:""},{default:n(()=>[a(j,{height:500,options:e(v)},null,8,["options"])]),_:1},8,["loading"])]),_:1})}}}),[["__file","D:/zx/mall-newfeifan-zx-business/src/views/mall/statistics/product/components/ProductSummary.vue"]])});export{xe as __tla,F as default};
|