2 lines
5.4 KiB
JavaScript
2 lines
5.4 KiB
JavaScript
import{J as O,K as G,D as J,w as Q,F as Z,L as H,M as W,b as X,N as Y,O as ee}from"./element-plus.4a7d92a3.js";import{_ as te}from"./index.vue_vue_type_script_setup_true_lang.5d4e738c.js";import{_ as oe}from"./index.vue_vue_type_script_setup_true_lang.5bd4da59.js";import{_ as ae}from"./index.vue_vue_type_script_setup_true_lang.77dd59e0.js";import{u as le}from"./usePaging.6a6670f9.js";import{u as re}from"./useDictOptions.fea55aea.js";import{p as f}from"./workbench.c868a7bd.js";import"./lodash.9dc701ad.js";import"./index.b66d47ee.js";import{u as ie}from"./vue-router.101084e3.js";import{a as ne}from"./system_store.00b12af4.js";import{d as B,r as n,Z as se,i as me,o as m,c as D,U as e,L as r,u as t,K as h,T as pe,a9 as ue,Q as T,R as w,M as de,a as x,j as _e}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.7347fedc.js";import"./axios.4607972f.js";import"./@ctrl.b082b0c1.js";import"./normalize-wheel-es.8aeb3683.js";import"./@popperjs.36402333.js";import"./index.a2770bcd.js";import"./index.vue_vue_type_style_index_0_scoped_d380c88d_lang.d9a16ced.js";import"./pinia.a969beab.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.0d2736b7.js";import"./vue-clipboard3.7d5a7a5d.js";import"./clipboard.860a1cea.js";import"./echarts.5016c48c.js";import"./zrender.58d022a1.js";import"./tslib.60310f1a.js";import"./highlight.js.31cd7941.js";import"./@highlightjs.b0c09b66.js";const ce={class:"mt-4"},fe={class:"flex mt-4 justify-end"},he=B({name:"storeProductLists"}),lt=B({...he,setup(we){const b=ie();n(null);const o=se({start_time:"",end_time:"",is_all:"",store_id:""}),p=n(!1),y=n([]),V=(_="")=>{p.value=!0,ne({name:_,page_size:50}).then(a=>{y.value=a.lists,setTimeout(()=>{p.value=!1},300)}).catch(a=>{setTimeout(()=>{p.value=!1},300)})},L=n([]),N=_=>{L.value=_.map(({id:a})=>a)};re("");let F=1;b.query.page_no&&(F=parseInt(b.query.page_no));const g=n(f),{pager:s,getLists:u,resetParams:P,resetPage:d}=le({page:F,fetchFun:g.value,params:o});n(!1);const v=n("primary"),C=n(""),S=()=>{o.is_all="",v.value="primary",C.value="",g.value=f,u()},U=()=>{o.is_all="1",v.value="",C.value="primary",g.value=f,d(),u()};return me(()=>{u()}),(_,a)=>{const z=O,I=G,E=J,M=ae,c=Q,q=oe,R=Z,k=H,i=W,$=X,j=Y,A=te,K=ee;return m(),D("div",null,[e(k,{class:"!border-none mb-4",shadow:"never"},{default:r(()=>[e(R,{class:"mb-[-16px]",model:t(o),inline:""},{default:r(()=>[t(o).is_all==1?(m(),h(E,{key:0,label:"\u95E8\u5E97",prop:"store_id"},{default:r(()=>[e(I,{modelValue:t(o).store_id,"onUpdate:modelValue":a[0]||(a[0]=l=>t(o).store_id=l),filterable:"",remote:"","reserve-keyword":"",placeholder:"\u8F93\u5165\u95E8\u5E97\u540D\u79F0\u641C\u7D22","remote-show-suffix":"","remote-method":V,loading:t(p),style:{width:"240px"},onChange:t(d)},{default:r(()=>[(m(!0),D(pe,null,ue(t(y),l=>(m(),h(z,{key:l.id,label:l.name,value:l.id},null,8,["label","value"]))),128))]),_:1},8,["modelValue","loading","onChange"])]),_:1})):T("",!0),e(E,{label:"",prop:"create_time"},{default:r(()=>[e(M,{startTime:t(o).start_time,"onUpdate:startTime":a[1]||(a[1]=l=>t(o).start_time=l),endTime:t(o).end_time,"onUpdate:endTime":a[2]||(a[2]=l=>t(o).end_time=l),type:"daterange",onChange:t(d)},null,8,["startTime","endTime","onChange"])]),_:1}),e(E,null,{default:r(()=>[e(c,{type:"primary",onClick:t(d)},{default:r(()=>[w("\u67E5\u8BE2")]),_:1},8,["onClick"]),e(c,{onClick:t(P)},{default:r(()=>[w("\u91CD\u7F6E")]),_:1},8,["onClick"]),e(q,{class:"ml-2.5","fetch-fun":t(f),params:t(o),"page-size":t(s).size},null,8,["fetch-fun","params","page-size"])]),_:1})]),_:1},8,["model"])]),_:1}),de((m(),h(k,{class:"!border-none",shadow:"never"},{default:r(()=>[e(c,{type:t(v),onClick:S},{default:r(()=>[w(" \u5408\u5E76\u7EDF\u8BA1 ")]),_:1},8,["type"]),e(c,{type:t(C),onClick:U},{default:r(()=>[w(" \u7EC6\u5206\u7EDF\u8BA1 ")]),_:1},8,["type"]),x("div",ce,[e(j,{data:t(s).lists,onSelectionChange:N},{default:r(()=>[e(i,{type:"selection",width:"55"}),e(i,{label:"\u5546\u54C1ID",prop:"product_id","show-overflow-tooltip":""}),e(i,{label:"\u5546\u54C1\u56FE\u7247",prop:"image","min-width":"80"},{default:r(({row:l})=>[e($,{style:{width:"50px",height:"50px"},src:l.image,"preview-teleported":!0},null,8,["src"])]),_:1}),t(o).is_all==1?(m(),h(i,{key:0,label:"\u95E8\u5E97",prop:"system_store","min-width":"200","show-overflow-tooltip":""})):T("",!0),e(i,{label:"\u5546\u54C1\u540D\u79F0",prop:"store_name","min-width":"200","show-overflow-tooltip":""}),e(i,{label:"\u5206\u7C7B",prop:"cate_name","min-width":"120","show-overflow-tooltip":""}),e(i,{label:"\u5355\u4F4D",prop:"unit_name","min-width":"80","show-overflow-tooltip":""}),e(i,{label:"\u89C4\u683C",prop:"store_info","min-width":"100","show-overflow-tooltip":""}),e(i,{label:"\u6570\u91CF",prop:"cart_num","min-width":"100","show-overflow-tooltip":""}),e(i,{label:"\u5355\u4EF7",prop:"price","min-width":"120","show-overflow-tooltip":""}),e(i,{label:"\u603B\u4EF7",prop:"total_price","min-width":"120","show-overflow-tooltip":""})]),_:1},8,["data"])]),x("div",fe,[e(A,{modelValue:t(s),"onUpdate:modelValue":a[3]||(a[3]=l=>_e(s)?s.value=l:null),onChange:t(u)},null,8,["modelValue","onChange"])])]),_:1})),[[K,t(s).loading]])])}}});export{lt as default};
|