import{Y as j,_ as O,$,D as q,C as z,Q,R as W,w as G,F as H,I as J,L as K,M as X,N as Z}from"./element-plus.0a93cab1.js";import{_ as ee}from"./index.vue_vue_type_script_setup_true_lang.3863431c.js";import{u as te}from"./usePaging.d25ebf19.js";import{a as oe}from"./index.c06febf8.js";import{c as le}from"./store_finance_flow.58ed76a3.js";import{h as ae}from"./goodsList.37611b88.js";import{d as y,a0 as ne,r as i,o as p,c,W as e,O as t,u as l,j as v,V as se,a7 as re,M as F,T as E,P as ue,a as g,U as C}from"./@vue.c3e77981.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";const ie={key:0,class:"text-success"},pe={key:1,class:"text-danger"},me={class:"flex mt-4 justify-end"},de=y({name:"storeFinanceFlowLists"}),Xe=y({...de,setup(_e){const V=oe().userInfo,a=ne({keyword:"",start_time:"",end_time:"",order:"",staff_id:"",store_id:V.store_id}),r=i(null),k=()=>{r.value=[],x()},D=i([]),B=u=>{D.value=u.map(({id:n})=>n)},{pager:m,getLists:f,resetParams:x,resetPage:L}=te({fetchFun:le,params:a});f(),i(!1),i([]),i([]);const S=()=>{var u;(u=r.value)!=null&&u.length?(a.start_time=r.value[0]+" 00:00:00",a.end_time=r.value[1]+" 23:59:59"):(a.start_time="",a.end_time=""),L()},w=i([]);return(async()=>{let u=await ae({page_no:1,page_size:100});w.value=u.lists})(),(u,n)=>{const P=j,d=q,_=O,I=z,U=Q,A=W,b=G,R=$,Y=H,h=J,s=K,M=X,N=ee,T=Z;return p(),c("div",null,[e(h,{class:"!border-none mb-4",shadow:"never"},{default:t(()=>[e(Y,{class:"mb-[-16px]",model:l(a),"label-width":"80px"},{default:t(()=>[e(R,null,{default:t(()=>[e(_,{span:6},{default:t(()=>[e(d,{label:"\u65F6\u95F4\u7B5B\u9009"},{default:t(()=>[e(P,{modelValue:l(r),"onUpdate:modelValue":n[0]||(n[0]=o=>v(r)?r.value=o:null),type:"daterange","range-separator":"-","start-placeholder":"\u5F00\u59CB\u65F6\u95F4","end-placeholder":"\u7ED3\u675F\u65F6\u95F4","value-format":"YYYY-MM-DD",clearable:!1},null,8,["modelValue"])]),_:1})]),_:1}),e(_,{span:6},{default:t(()=>[e(d,{label:"\u8BA2\u5355\u641C\u7D22"},{default:t(()=>[e(I,{modelValue:l(a).keyword,"onUpdate:modelValue":n[1]||(n[1]=o=>l(a).keyword=o),clearable:"",placeholder:"\u8BF7\u8F93\u5165\u4EA4\u6613\u5355\u53F7"},null,8,["modelValue"])]),_:1})]),_:1}),e(_,{span:6},{default:t(()=>[e(d,{label:"\u5E97\u5458"},{default:t(()=>[e(A,{class:"flex-1",modelValue:l(a).staff_id,"onUpdate:modelValue":n[2]||(n[2]=o=>l(a).staff_id=o),placeholder:"\u8BF7\u9009\u62E9\u5E97\u5458"},{default:t(()=>[(p(!0),c(se,null,re(l(w),(o,fe)=>(p(),F(U,{label:o.staff_name,value:o.id},null,8,["label","value"]))),256))]),_:1},8,["modelValue"])]),_:1})]),_:1}),e(_,{span:6},{default:t(()=>[e(d,null,{default:t(()=>[e(b,{type:"primary",onClick:S},{default:t(()=>[E("\u67E5\u8BE2")]),_:1}),e(b,{onClick:k},{default:t(()=>[E("\u91CD\u7F6E")]),_:1})]),_:1})]),_:1})]),_:1})]),_:1},8,["model"])]),_:1}),ue((p(),F(h,{class:"!border-none",shadow:"never"},{default:t(()=>[g("div",null,[e(M,{data:l(m).lists,onSelectionChange:B,"row-key":"id","tree-props":{children:"list"}},{default:t(()=>[e(s,{label:"ID",prop:"id","min-width":"100","show-overflow-tooltip":""}),e(s,{label:"\u4EA4\u6613\u5355\u53F7",prop:"order_sn","min-width":"120","show-overflow-tooltip":""}),e(s,{label:"\u4EA4\u6613\u65F6\u95F4",prop:"create_time","min-width":"120","show-overflow-tooltip":""}),e(s,{label:"\u91D1\u989D",prop:"number","min-width":"100","show-overflow-tooltip":""},{default:t(({row:o})=>[o.number>0?(p(),c("span",ie,C(o.number),1)):(p(),c("span",pe,C(o.number),1))]),_:1}),e(s,{label:"\u95E8\u5E97\u540D\u79F0",prop:"store_name","show-overflow-tooltip":""}),e(s,{label:"\u7528\u6237",prop:"nickname","min-width":"80","show-overflow-tooltip":""}),e(s,{label:"\u6536\u76CA/\u6263\u9664",prop:"financial_type_name","show-overflow-tooltip":""}),e(s,{label:"\u652F\u4ED8\u65B9\u5F0F",prop:"pay_type_name","show-overflow-tooltip":""}),e(s,{label:"\u5907\u6CE8",prop:"remark","show-overflow-tooltip":""})]),_:1},8,["data"])]),g("div",me,[e(N,{modelValue:l(m),"onUpdate:modelValue":n[3]||(n[3]=o=>v(m)?m.value=o:null),onChange:l(f)},null,8,["modelValue","onChange"])])]),_:1})),[[T,l(m).loading]])])}}});export{Xe as default};