import{a as w}from"./index.d6727940.js";import{d as I,aX as $,s as R,r as v,p as U,b as V,E as O,c as l,at as T,e as s,k as n,i as a,g as E,h as t,u as d,w as q,A as _,m as c}from"./index.0308b213.js";const G={class:"filter-form"},Q=c("\u67E5\u8BE2"),X={class:"data"},j={class:"table"},z=c("\u5DF2\u63A5\u6536"),H=c("\u6210\u529F"),J=c("\u5931\u8D25"),K=c("\u5904\u7406\u4E2D"),P=c("\u4EBA\u5DE5\u5904\u7406"),ee=I({props:{customer_number:{default:""},modelValue:{type:Boolean,default:!1}},emits:["update:modelValue","onLoadingSuccess","onClose"],setup(C,{emit:F}){const f=C;$.get("uniacid");const k=R(()=>`\u67E5\u8BE2${f.customer_number}\u7ED3\u7B97\u4FE1\u606F(\u9ED8\u8BA4\u6628\u5929)`),g=v(!1);U(()=>f.modelValue,e=>{console.log("val",e),g.value=e,e&&y()});const B=()=>{const e=new Date;e.setDate(e.getDate()-1);const r=e.getFullYear(),b=String(e.getMonth()+1).padStart(2,"0"),D=String(e.getDate()).padStart(2,"0");return`${r}-${b}-${D}`},p=V({dateRange:[B(),B()],customer_number:f.customer_number});let i=v(!1);const h=V({list:[],count:0}),A=()=>{y()},y=()=>{i.value=!0,w(p).then(e=>{console.log("res",e),h.list=e,i.value=!1}).catch(e=>{O.error(e.message),i.value=!1})},S=()=>{F("update:modelValue",!1),F("onClose")};return(e,r)=>{const b=l("el-date-picker"),D=l("el-form-item"),N=l("el-button"),Y=l("el-form"),o=l("el-table-column"),m=l("el-tag"),M=l("el-table"),x=l("el-dialog"),L=T("loading");return s(),n(x,{modelValue:g.value,"onUpdate:modelValue":r[1]||(r[1]=u=>g.value=u),title:d(k),onClose:S,width:"70%"},{default:a(()=>[E("div",G,[t(Y,{model:d(p),"label-width":"90px"},{default:a(()=>[t(D,{class:"tn-el-form-item",label:"\u65F6\u95F4\u8303\u56F4"},{default:a(()=>[t(b,{modelValue:d(p).dateRange,"onUpdate:modelValue":r[0]||(r[0]=u=>d(p).dateRange=u),type:"daterange","range-separator":"\u81F3","start-placeholder":"\u5F00\u59CB\u65E5\u671F","end-placeholder":"\u7ED3\u675F\u65E5\u671F","value-format":"YYYY-MM-DD",format:"YYYY-MM-DD",clearable:""},null,8,["modelValue"])]),_:1}),t(D,null,{default:a(()=>[t(N,{class:"tn-el-form-item--item tn-button tn-button--blue",onClick:A},{default:a(()=>[Q]),_:1})]),_:1})]),_:1},8,["model"])]),E("div",X,[E("div",j,[q((s(),n(M,{data:d(h).list},{default:a(()=>[t(o,{label:"\u5546\u6237\u7F16\u53F7",prop:"customerNumber"}),t(o,{label:"\u7ED3\u7B97\u8BA2\u5355\u53F7",prop:"orderId"}),t(o,{label:"\u7ED3\u7B97\u8D26\u6237\u540D",prop:"accountName"}),t(o,{label:"\u7ED3\u7B97\u5361\u53F7",prop:"accountNo"}),t(o,{label:"\u7ED3\u7B97\u91D1\u989D",prop:"settlementAmount"}),t(o,{label:"\u624B\u7EED\u8D39",prop:"settleFee"}),t(o,{label:"\u7ED3\u7B97\u7C7B\u578B",prop:"settleType"}),t(o,{label:"\u7ED3\u7B97\u72B6\u6001",prop:"orderStatus"},{default:a(({row:u})=>[u.orderStatus==="FAILED"?(s(),n(m,{key:0,type:""},{default:a(()=>[z]),_:1})):_("",!0),u.orderStatus==="DONE"?(s(),n(m,{key:1,type:"success"},{default:a(()=>[H]),_:1})):_("",!0),u.orderStatus==="FAILED"?(s(),n(m,{key:2,type:"danger"},{default:a(()=>[J]),_:1})):_("",!0),u.orerStatus==="DOING"?(s(),n(m,{key:3,type:"info"},{default:a(()=>[K]),_:1})):_("",!0),u.orderStatus==="MANUAL"?(s(),n(m,{key:4,type:"warning"},{default:a(()=>[P]),_:1})):_("",!0)]),_:1}),t(o,{label:"\u7ED3\u7B97\u65E5\u671F",prop:"settleDate"}),t(o,{label:"\u5230\u8D26\u65F6\u95F4",prop:"completeDate"})]),_:1},8,["data"])),[[L,d(i)]])])])]),_:1},8,["modelValue","title"])}}});export{ee as _};
