import{U as R,k as j,C as $,D as J,J as Z,K as G,w as Q,F as W,L as X,M as ee,b as oe,N as te,O as ae}from"./element-plus.91c68cc0.js";import{_ as le}from"./index.vue_vue_type_script_setup_true_lang.863ae816.js";import{_ as re}from"./index.vue_vue_type_script_setup_true_lang.d134accc.js";import{d as Y,r as u,Z as ne,i as se,o as c,c as y,U as e,L as l,u as o,aa as ue,T as ie,a9 as me,K as V,j as B,R as v,M as pe,a as k}from"./@vue.76ce7aa3.js";import{u as de}from"./usePaging.f8c888e4.js";import{u as _e}from"./useDictOptions.1f11cf62.js";import{n as x,o as ce}from"./store_order.c4fc87ec.js";import"./lodash.4e6d2a38.js";import"./index.d12b3af4.js";import{u as fe}from"./vue-router.10bd5b90.js";import{a as we}from"./system_store.de1a4364.js";import{h as f}from"./moment.40bc58bf.js";import"./lodash-es.f52bd8b1.js";import"./async-validator.fb49d0f5.js";import"./@vueuse.9ffef7f8.js";import"./@element-plus.73235148.js";import"./dayjs.0112e2c7.js";import"./@babel.80d29b7b.js";import"./@ctrl.b082b0c1.js";import"./normalize-wheel-es.8aeb3683.js";import"./@popperjs.36402333.js";import"./index.e03c2e5b.js";import"./index.vue_vue_type_style_index_0_scoped_d380c88d_lang.cf0d972e.js";import"./axios.cffda5ac.js";import"./jspdf.6c61b9d3.js";import"./fflate.0418c72f.js";import"./pinia.f3529286.js";import"./css-color-function.bb8c34b2.js";import"./color.fbd63fe8.js";import"./clone.31a3aa2c.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.b502f541.js";import"./vue-clipboard3.e775fc74.js";import"./clipboard.6417898a.js";import"./echarts.5016c48c.js";import"./zrender.58d022a1.js";import"./tslib.60310f1a.js";import"./highlight.js.31cd7941.js";import"./@highlightjs.8d65305c.js";const he={class:"mt-4"},ge={class:"flex mt-4 justify-end"},ve=Y({name:"storeProductLists"}),mo=Y({...ve,setup(Ee){const E=fe();u(null);const s=u([new Date,new Date]),r=ne({start_time:f(s.value[0]).format("YYYY-MM-DD")+" 00:00:00",end_time:f(s.value[1]).format("YYYY-MM-DD")+" 23:59:59",is_group:"",store_id:"",store_name:""}),M=()=>{s.value[0]&&s.value[1]?(r.start_time=f(s.value[0]).format("YYYY-MM-DD HH:mm:ss"),r.end_time=f(s.value[1]).format("YYYY-MM-DD HH:mm:ss")):(r.start_time="",r.end_time=""),w()},d=u(!1),C=u([]),T=(m="")=>{d.value=!0,we({name:m,page_size:50}).then(t=>{C.value=t.lists,setTimeout(()=>{d.value=!1},300)}).catch(t=>{setTimeout(()=>{d.value=!1},300)})},L=u([]),S=m=>{L.value=m.map(({id:t})=>t)};_e("");let F=1;E.query.page_no&&(F=parseInt(E.query.page_no));const{pager:i,getLists:w,resetParams:I,resetPage:_}=de({page:F,fetchFun:x,params:r}),U=()=>{ce(r).then(m=>{window.open(m.url,"_blank"),j.success("\u5BFC\u51FA\u6210\u529F")})};return u(!1),u("primary"),u(""),se(()=>{w()}),(m,t)=>{const A=$,p=J,h=Z,b=G,P=R,g=Q,K=re,z=W,D=X,n=ee,H=oe,N=te,O=le,q=ae;return c(),y("div",null,[e(D,{class:"!border-none mb-4",shadow:"never"},{default:l(()=>[e(z,{class:"mb-[-16px]",model:o(r),inline:""},{default:l(()=>[e(p,{label:"\u5546\u54C1\u540D\u79F0",prop:"store_name"},{default:l(()=>[e(A,{class:"w-[280px]",modelValue:o(r).store_name,"onUpdate:modelValue":t[0]||(t[0]=a=>o(r).store_name=a),onKeydown:ue(o(_),["enter"]),clearable:"",placeholder:"\u8BF7\u8F93\u5165\u5546\u54C1\u540D\u79F0"},null,8,["modelValue","onKeydown"])]),_:1}),e(p,{label:"\u95E8\u5E97",prop:"store_id"},{default:l(()=>[e(b,{modelValue:o(r).store_id,"onUpdate:modelValue":t[1]||(t[1]=a=>o(r).store_id=a),filterable:"",remote:"","reserve-keyword":"",placeholder:"\u8F93\u5165\u95E8\u5E97\u540D\u79F0\u641C\u7D22","remote-show-suffix":"","remote-method":T,loading:o(d),style:{width:"240px"},onChange:o(_)},{default:l(()=>[(c(!0),y(ie,null,me(o(C),a=>(c(),V(h,{key:a.id,label:a.name,value:a.id},null,8,["label","value"]))),128))]),_:1},8,["modelValue","loading","onChange"])]),_:1}),e(p,{label:"\u7EDF\u8BA1",prop:"is_group"},{default:l(()=>[e(b,{modelValue:o(r).is_group,"onUpdate:modelValue":t[2]||(t[2]=a=>o(r).is_group=a),placeholder:"\u8BF7\u9009\u62E9\u662F\u5426\u7EDF\u8BA1",style:{width:"240px"},onChange:o(_)},{default:l(()=>[e(h,{label:"\u7EDF\u8BA1",value:"1"}),e(h,{label:"\u4E0D\u7EDF\u8BA1",value:"0"})]),_:1},8,["modelValue","onChange"])]),_:1}),e(p,{label:"",prop:"create_time"},{default:l(()=>[e(P,{modelValue:o(s),"onUpdate:modelValue":t[3]||(t[3]=a=>B(s)?s.value=a:null),type:"datetimerange","range-separator":"\u81F3","start-placeholder":"\u5F00\u59CB\u65E5\u671F","end-placeholder":"\u7ED3\u675F\u65E5\u671F","unlink-panels":"",onChange:M},null,8,["modelValue"])]),_:1}),e(p,null,{default:l(()=>[e(g,{type:"primary",onClick:o(_)},{default:l(()=>t[5]||(t[5]=[v("\u67E5\u8BE2")])),_:1},8,["onClick"]),e(g,{onClick:o(I)},{default:l(()=>t[6]||(t[6]=[v("\u91CD\u7F6E")])),_:1},8,["onClick"]),e(K,{class:"ml-2.5","fetch-fun":o(x),params:o(r),"page-size":o(i).size},null,8,["fetch-fun","params","page-size"]),e(g,{onClick:U},{default:l(()=>t[7]||(t[7]=[v("\u5BFC\u51FA\u914D\u9001\u8868\u683C")])),_:1})]),_:1})]),_:1},8,["model"])]),_:1}),pe((c(),V(D,{class:"!border-none",shadow:"never"},{default:l(()=>[k("div",he,[e(N,{data:o(i).lists,onSelectionChange:S},{default:l(()=>[e(n,{type:"selection",width:"55"}),e(n,{label:"\u5546\u54C1ID",prop:"product_id","show-overflow-tooltip":""}),e(n,{label:"\u5546\u54C1\u56FE\u7247",prop:"image","min-width":"80"},{default:l(({row:a})=>[e(H,{style:{width:"50px",height:"50px"},src:a.image,"preview-teleported":!0},null,8,["src"])]),_:1}),e(n,{label:"\u95E8\u5E97",prop:"system_store","min-width":"200","show-overflow-tooltip":""}),e(n,{label:"\u5546\u54C1\u540D\u79F0",prop:"store_name","min-width":"200","show-overflow-tooltip":""}),e(n,{label:"\u5206\u7C7B",prop:"cate_name","min-width":"120","show-overflow-tooltip":""}),e(n,{label:"\u5355\u4F4D",prop:"unit_name","min-width":"80","show-overflow-tooltip":""}),e(n,{label:"\u89C4\u683C",prop:"store_info","min-width":"100","show-overflow-tooltip":""}),e(n,{label:"\u6570\u91CF",prop:"cart_num","min-width":"100","show-overflow-tooltip":""}),e(n,{label:"\u5355\u4EF7",prop:"price","min-width":"120","show-overflow-tooltip":""}),e(n,{label:"\u603B\u4EF7",prop:"total_price","min-width":"120","show-overflow-tooltip":""})]),_:1},8,["data"])]),k("div",ge,[e(O,{modelValue:o(i),"onUpdate:modelValue":t[4]||(t[4]=a=>B(i)?i.value=a:null),onChange:o(w)},null,8,["modelValue","onChange"])])]),_:1})),[[q,o(i).loading]])])}}});export{mo as default};