1 |
- import{az as _,d as de,r as c,Q as ce,x as pe,w as ue,b as _e,a3 as me,o as p,c as L,C as B,A as y,B as t,F as O,R as ye,a as l,D as Q,f as a,aC as fe,k as C,v as ge,E as n,G as s,dx as D,P as f,S as ve,U as he,K as we,_ as be,V as Ie,I as xe,L as Ce,W as Pe,X as Be,Y as De,Z as ke,__tla as Ne}from"./index-e8bff8cb.js";import{_ as Se,__tla as Te}from"./ContentWrap.vue_vue_type_script_setup_true_lang-33dea697.js";import{_ as ze,__tla as Re}from"./index.vue_vue_type_script_setup_true_lang-75f84d87.js";import{f as Ye,__tla as Me}from"./formatTime-4fdd5566.js";import{d as X}from"./download-20922b56.js";import{_ as Ue,__tla as Ve}from"./DailyBillForm.vue_vue_type_style_index_0_lang-8f2e23d5.js";import{g as Fe,__tla as je}from"./index-dc2d6a93.js";import{u as Ae,__tla as Ke}from"./useMessage-de42a595.js";import{_ as Le}from"./_plugin-vue_export-helper-1b428a4d.js";let w,k,q,Oe=Promise.all([(()=>{try{return Ne}catch{}})(),(()=>{try{return Te}catch{}})(),(()=>{try{return Re}catch{}})(),(()=>{try{return Me}catch{}})(),(()=>{try{return Ve}catch{}})(),(()=>{try{return je}catch{}})(),(()=>{try{return Ke}catch{}})()]).then(async()=>{let N,S,T;w={getDailyBillPage:async r=>await _.get({url:"/distri/daily-bill/page",params:r}),getDailyBill:async r=>await _.get({url:"/distri/daily-bill/get?id="+r}),createDailyBill:async r=>await _.post({url:"/distri/daily-bill/create",data:r}),updateDailyBill:async r=>await _.put({url:"/distri/daily-bill/update",data:r}),deleteDailyBill:async r=>await _.delete({url:"/distri/daily-bill/delete?id="+r}),exportDailyBill:async r=>await _.download({url:"/distri/daily-bill/export-excel",params:r}),exportDailyBillByRow:async r=>await _.download({url:"/trade/order/export-excel/dailyBill",params:r})},N={class:"search-one"},S={style:{"text-align":"right"},class:"search-input"},T={class:"searchMore",style:{width:"calc(100% - 60px)"}},k=Le(de({name:"DailyBill",__name:"index",props:{merchantId:{type:Number,default:void 0},ptDailyBillId:{type:Number,default:void 0}},setup(r){const z=r,b=c(!1),E=()=>{b.value=!b.value},P=()=>{b.value=!1};let R=c([]);const Y=Ae();ce();const I=c(!0),M=c([]),U=c(0),o=pe({pageNo:1,pageSize:10,price:void 0,receivedPrice:void 0,orderCount:void 0,shopId:void 0,merchantId:void 0,orderIds:void 0,createTime:[],refundPrice:void 0,integral:void 0,receivedIntegral:void 0,refundIntegral:void 0,orderCalcTime:[],ptDailyBillId:void 0}),V=c(),g=c(!1),v=async()=>{I.value=!0;try{const u=await w.getDailyBillPage(o);M.value=u.list,U.value=u.total}finally{I.value=!1}},F=()=>{o.pageNo=1,v(),P()},G=()=>{V.value.resetFields(),o.shopId=void 0,F(),P()},j=c(),W=async()=>{try{await Y.exportConfirm(),g.value=!0;const u=await w.exportDailyBill(o);X.excel(u,"\u6BCF\u65E5\u8D26\u5355.xls")}catch{}finally{g.value=!1}};return ue(()=>o.shopId,()=>{v()}),_e(async()=>{o.merchantId=z.merchantId,o.ptDailyBillId=z.ptDailyBillId,v(),await(async()=>{I.value=!0;const u=await Fe();R.value=u})()}),(u,d)=>{const Z=ve,H=he,m=we,A=be,J=Ie,$=xe,ee=Ce,ae=Pe,i=Be,le=De,te=ze,re=Se,K=me("hasPermi"),ie=ke;return p(),L(O,null,[B("div",N,[B("div",S,[r.merchantId?Q("",!0):(p(),y(H,{key:0,modelValue:l(o).shopId,"onUpdate:modelValue":d[0]||(d[0]=e=>l(o).shopId=e),placeholder:"\u5E97\u94FA\u540D\u79F0",filterable:"",clearable:""},{default:t(()=>[(p(!0),L(O,null,ye(l(R),e=>(p(),y(Z,{key:e.id,label:e.name,value:e.id},null,8,["label","value"]))),128))]),_:1},8,["modelValue"])),a(m,{icon:l(fe),onClick:E,style:{"margin-left":"0"}},null,8,["icon"])])]),C(B("div",T,[a(ae,{model:l(o),ref_key:"queryFormRef",ref:V,inline:!0,"label-width":"120px"},{default:t(()=>[a(ee,null,{default:t(()=>[a($,null,{default:t(()=>[a(J,null,{default:t(()=>[C((p(),y(m,{type:"success",plain:"",onClick:W,loading:l(g)},{default:t(()=>[n(" \u5BFC\u51FA ")]),_:1},8,["loading"])),[[K,["distri:daily-bill:export"]]]),a(m,{onClick:P},{default:t(()=>[n(" \u6536\u8D77 ")]),_:1}),a(m,{onClick:G},{default:t(()=>[a(A,{class:"mr-5px",icon:"ep:refresh"}),n(" \u91CD\u7F6E ")]),_:1}),a(m,{onClick:F,plain:"",type:"primary"},{default:t(()=>[a(A,{class:"mr-5px",icon:"ep:search"}),n(" \u641C\u7D22 ")]),_:1})]),_:1})]),_:1})]),_:1})]),_:1},8,["model"])],512),[[ge,l(b)]]),a(re,{class:"mt-15px"},{default:t(()=>[C((p(),y(le,{data:l(M),stripe:!0,"show-overflow-tooltip":!0,onRowClick:d[1]||(d[1]=e=>{return x=e,void j.value.open(x);var x}),"row-class-name":"row"},{default:t(()=>[a(i,{label:"\u8D26\u5355\u7F16\u53F7",align:"center",prop:"id"}),a(i,{label:"\u91D1\u989D",align:"center",prop:"price"},{default:t(e=>[n(" \uFFE5"+s(l(D)(e.row.price)),1)]),_:1}),a(i,{label:"\u786E\u6536\u91D1\u989D",align:"center",prop:"receivedPrice"},{default:t(e=>[n(" \uFFE5"+s(l(D)(e.row.receivedPrice)),1)]),_:1}),a(i,{label:"\u9000\u6B3E\u91D1\u989D",align:"center",prop:"refundPrice"},{default:t(e=>[n(" \uFFE5"+s(l(D)(e.row.refundPrice)),1)]),_:1}),a(i,{label:"\u4F63\u91D1",align:"center",prop:"integral"},{default:t(e=>[n(s(l(f)(e.row.integral)),1)]),_:1}),a(i,{label:"\u786E\u6536\u4F63\u91D1",align:"center",prop:"receivedIntegral"},{default:t(e=>[n(s(l(f)(e.row.receivedIntegral)),1)]),_:1}),a(i,{label:"\u9000\u6B3E\u4F63\u91D1",align:"center",prop:"refundIntegral"},{default:t(e=>[n(s(l(f)(e.row.refundIntegral)),1)]),_:1}),a(i,{label:"\u6D88\u8D39\u5206",align:"center",prop:"consumptionPoints"},{default:t(e=>[n(s(l(f)(e.row.consumptionPoints)),1)]),_:1}),a(i,{label:"\u786E\u6536\u6D88\u8D39\u5206",align:"center",prop:"receivedConsumptionPoints"},{default:t(e=>[n(s(l(f)(e.row.receivedConsumptionPoints)),1)]),_:1}),a(i,{label:"\u9000\u6B3E\u6D88\u8D39\u5206",align:"center",prop:"refundConsumptionPoints"},{default:t(e=>[n(s(l(f)(e.row.refundConsumptionPoints)),1)]),_:1}),a(i,{label:"\u8BA2\u5355\u6570",align:"center",prop:"orderCount"}),r.merchantId?Q("",!0):(p(),y(i,{key:0,label:"\u5546\u6237\u540D",align:"center",prop:"merchantName"})),a(i,{label:"\u5E97\u94FA\u540D",align:"center",prop:"shopName"}),a(i,{label:"\u8D26\u5355\u65E5\u671F",align:"center",prop:"orderCalcTime"}),a(i,{label:"\u64CD\u4F5C",align:"center"},{default:t(e=>[C((p(),y(m,{type:"success",plain:"",size:"small",onClick:x=>(async(oe,h)=>{oe.stopPropagation();try{await Y.exportConfirm(),g.value=!0;const ne=await w.exportDailyBillByRow({shopId:h.shopId,orderCalcTime:h.orderCalcTime,merchantId:h.merchantId,payStatus:1}),se=h.shopName+Ye(h.createTime,"YYYY-MM-DD")+"\u8D26\u5355.xls";X.excel(ne,se)}catch{}finally{g.value=!1}})(x,e.row)},{default:t(()=>[n(" \u5BFC\u51FA ")]),_:2},1032,["onClick"])),[[K,["distri:daily-bill:export"]]])]),_:1})]),_:1},8,["data"])),[[ie,l(I)]]),a(te,{total:l(U),page:l(o).pageNo,"onUpdate:page":d[2]||(d[2]=e=>l(o).pageNo=e),limit:l(o).pageSize,"onUpdate:limit":d[3]||(d[3]=e=>l(o).pageSize=e),onPagination:v},null,8,["total","page","limit"])]),_:1}),a(Ue,{ref_key:"formRef",ref:j,onSuccess:v},null,512)],64)}}}),[["__scopeId","data-v-ca976563"]]),q=Object.freeze(Object.defineProperty({__proto__:null,default:k},Symbol.toStringTag,{value:"Module"}))});export{w as D,Oe as __tla,k as d,q as i};
|