1 |
- import{d as N,b as Q,e as x,r as _,f as M,g as W,h as X,o as l,c as h,i as a,w as o,a as e,j as g,k as s,l as w,m as $,t as O,F as ee,n as I,E as re,_ as te,p as oe,q as ae,s as ie,v as me}from"./index-92f7a16c.js";import{_ as se}from"./Echart.vue_vue_type_script_setup_true_lang-cacf85c1.js";import{E as le}from"./el-card-e60c275e.js";import{E as ne}from"./el-skeleton-item-949118f6.js";import{l as q}from"./echarts-data-0ea86435.js";import{T as de,g as pe}from"./ToBeDone-b1501daf.js";import ue from"./index-e6407e3d.js";import{c as f}from"./permission-46fcc7d7.js";import{_ as fe}from"./_plugin-vue_export-helper-1b428a4d.js";import"./ToBeDoneDialog-6321d03f.js";import"./Dialog-524c7d28.js";import"./ContentWrap.vue_vue_type_script_setup_true_lang-93cdc892.js";import"./SPuUploadImg-344a2a88.js";import"./SPuUploadImg.vue_vue_type_style_index_0_scoped_5dfa4534_lang-9ca6f58d.js";import"./index-53ab5084.js";import"./el-image-viewer-668f12f8.js";import"./useMessage-f6048a9f.js";import"./spu-7bbcf2cd.js";import"./InfoForm-fff40575.js";import"./UploadImgs-905a3324.js";import"./UploadImgs.vue_vue_type_style_index_0_scoped_bad238b9_lang-c7fc1fae.js";import"./tree-0af4953a.js";import"./category-8e584cf1.js";import"./brand-412278ee.js";import"./formRules-ffb17ad4.js";import"./DescriptionForm-5ea82a80.js";import"./style.css_vue_type_style_index_0_src_true_lang-d17c7064.js";import"./OtherForm-8ce33f73.js";import"./SkuForm-b8b5bf3c.js";import"./index-2e6bfa2a.js";import"./SkuList.vue_vue_type_script_setup_true_lang-b6defbcf.js";import"./el-image-b5c91f66.js";import"./UploadImg-7f651e4b.js";import"./UploadFile.vue_vue_type_style_index_0_scoped_a9e67aa2_lang-10e7d64a.js";import"./PcComponents.css_vue_type_style_index_0_src_5455114c_scoped_5455114c_lang-b0291120.js";import"./ProductAttributes.vue_vue_type_script_setup_true_lang-df1f238e.js";import"./el-text-79d6dacd.js";import"./property-0d16eb70.js";import"./ProductPropertyAddForm.vue_vue_type_script_setup_true_lang-360676a1.js";import"./MobileSkuList-595645c2.js";import"./DeliveryForm-e85af03a.js";import"./index-6d030a99.js";import"./dict-b31d62c6.js";import"./constants-e43f22dd.js";import"./Service-abb87787.js";import"./index-672652a7.js";import"./AfterSale-d83f2ca1.js";import"./index.vue_vue_type_script_setup_true_lang-059ec67a.js";import"./index-579dde8f.js";import"./index-7812e0eb.js";import"./Comment-fcdb87f9.js";import"./Apply-eea07826.js";import"./formatTime-71947df8.js";const ce={class:"flex flex-row flex-wrap gap-8 p-4",style:{"min-height":"200px"}},xe={class:"bg-orange-400 h-48px w-48px flex items-center justify-center rounded text-white"},he={class:"h-3 flex justify-between items-center"},ge={key:0,class:"!w-240px flex"},we=fe(N({name:"Home",__name:"Index",setup(ye){const V=Q(),v=x(()=>V.getMobile),p=_(!0),A=x(()=>f(["trade:order:query"])),F=x(()=>f(["product:spu:create"])),R=x(()=>f(["trade:order:backlog:query"])||f(["after:sale:backlog:query"])),t=M({orderTime:"",orderStatrTime:"",orderEndTime:"",mobileOrderTimeShow:!1}),b=_(),k=_(null),S=W(()=>{k.value.getList()},1e3);let y;function U(i){y=i}const z=new Date(2024,5,12);let c=M(q);const T=async(i,r)=>{const m=await pe({startTime:i,endTime:r});me(c,"xAxis.data",m.xaxis.data);const u=m==null?void 0:m.series.map(n=>({count:n.count,value:n.money/100}));c.series[0].data=u,y&&(y.setOption(c,!0),console.log(c))};function B(i){t.orderStatrTime=i[0],t.orderEndTime=i[1],T(t.orderStatrTime,t.orderEndTime)}function Y(){t.mobileOrderTimeShow=!0}function H(i){t.mobileOrderTimeShow=!1,t.orderStatrTime=I(i[0]).format("YYYY-MM-DD"),t.orderEndTime=I(i[1]).format("YYYY-MM-DD"),T(t.orderStatrTime,t.orderEndTime)}return(async()=>(await Promise.all([T()]),p.value=!1))(),(i,r)=>{const m=ne,u=le,n=re,L=te,P=oe,Z=ae,G=X("van-calendar"),J=se,D=ie;return l(),h(ee,null,[a(D,{class:"mt-8px",gutter:8,justify:"space-between"},{default:o(()=>[e(R)?(l(),g(n,{key:0,xl:12,lg:12,md:24,sm:24,xs:24,class:"mb-8px"},{default:o(()=>[a(u,{shadow:"never"},{header:o(()=>[s("div",{class:"h-3 flex justify-between cursor-pointer items-center",onClick:r[0]||(r[0]=(...d)=>e(S)&&e(S)(...d))},r[4]||(r[4]=[s("span",null,"\u5F85\u529E",-1)]))]),default:o(()=>[a(m,{loading:e(p),animated:""},{default:o(()=>[a(de,{ref_key:"toBeDoneRef",ref:k},null,512)]),_:1},8,["loading"])]),_:1})]),_:1})):w("",!0),e(F)?(l(),g(n,{key:1,xl:12,lg:12,md:24,sm:24,xs:24,class:"mb-8px"},{default:o(()=>[a(u,{shadow:"never"},{header:o(()=>r[5]||(r[5]=[s("div",{class:"h-3 flex justify-between items-center"},[s("span",null,"\u5FEB\u6377\u65B9\u5F0F")],-1)])),default:o(()=>[a(m,{loading:e(p),animated:""},{default:o(()=>[s("div",ce,[e(f)(["product:spu:create"])?(l(),h("div",{key:0,class:"h-20 w-20% flex flex-col cursor-pointer items-center justify-center gap-2",onClick:r[1]||(r[1]=d=>{return E="create",C="",j=0,void b.value.open(E,C,j,K);var E,C,j,K})},[s("div",xe,[a(L,{icon:"fluent-mdl2:product",class:"text-7.5!"})]),r[6]||(r[6]=s("span",null,"\u65B0\u589E\u5546\u54C1",-1))])):w("",!0)])]),_:1},8,["loading"])]),_:1})]),_:1})):w("",!0),e(A)?(l(),g(n,{key:2,xl:24,lg:24,md:24,sm:24,xs:24,class:"mb-8px"},{default:o(()=>[a(u,{shadow:"never"},{header:o(()=>[s("div",he,[r[8]||(r[8]=s("span",null,"\u8BA2\u5355",-1)),e(v)?!e(v)||e(t).orderStatrTime||e(t).orderEndTime?(l(),h("span",{key:2,style:{"font-size":"14px"},onClick:Y},O(e(t).orderStatrTime)+" - "+O(e(t).orderEndTime),1)):(l(),g(Z,{key:1,onClick:Y},{default:o(()=>r[7]||(r[7]=[$("\u9009\u62E9\u65E5\u671F")])),_:1})):(l(),h("div",ge,[a(P,{modelValue:e(t).orderTime,"onUpdate:modelValue":r[2]||(r[2]=d=>e(t).orderTime=d),"value-format":"YYYY-MM-DD",type:"daterange","start-placeholder":"\u5F00\u59CB\u65E5\u671F","end-placeholder":"\u7ED3\u675F\u65E5\u671F","default-time":[new Date("1"),new Date("1")],onChange:B},null,8,["modelValue","default-time"])])),a(G,{show:e(t).mobileOrderTimeShow,"onUpdate:show":r[3]||(r[3]=d=>e(t).mobileOrderTimeShow=d),type:"range","min-date":e(z),onConfirm:H},null,8,["show","min-date"])])]),default:o(()=>[a(m,{loading:e(p),animated:""},{default:o(()=>[a(D,null,{default:o(()=>[a(n,null,{default:o(()=>[a(m,{loading:e(p),animated:""},{default:o(()=>[a(J,{options:e(q),height:250,onChartInit:U},null,8,["options"])]),_:1},8,["loading"])]),_:1})]),_:1})]),_:1},8,["loading"])]),_:1})]),_:1})):w("",!0)]),_:1}),a(ue,{ref_key:"spuFormRef",ref:b},null,512)],64)}}}),[["__scopeId","data-v-5303987b"]]);export{we as default};
|