import{P as R}from"./page.3b4d44cb.js";import{b as $,c as M}from"./account.95b5dca2.js";import{b as w,a as C,ar as U,_ as x,c as r,e as _,k as f,i as l,g as u,f as y,j as F,h as s,m as b,t as g,F as k,A as Q,H as S}from"./index.0308b213.js";const T={components:{Page:R},setup(){const a=(o,n)=>({title:o,val:n}),e=w({loading:!0,total:0,radioList:[{lable:"\u7C7B\u578B",selected:0,radios:[]},{lable:"\u53D8\u66F4\u65F6\u95F4",selected:-2,radios:[a("\u4E0D\u9650",-2),a("\u8FD1\u4E00\u5468",7),a("\u8FD1\u4E00\u6708",30),a("\u8FD1\u4E09\u6708",90),a("\u81EA\u5B9A\u4E49",-1)]}],time:[],tableData:[]}),i=w({page:1,limit:10,trade_type:0,days:-2,startday:"",endday:""});$().then(o=>{e.radioList[0].radios=o.store_yucunjin_type.map(n=>a(n.text,Number(n.type))),e.radioList[0].radios.unshift(a("\u4E0D\u9650",0)),m()},o=>{e.loading=!1});const m=()=>{var o,n;e.loading=!0,i.trade_type=e.radioList[0].selected,i.startday=((o=e.time)==null?void 0:o.length)&&i.days==-1?C(e.time[0]).format("YYYY-MM-DD"):"",i.endday=((n=e.time)==null?void 0:n.length)&&i.days==-1?C(e.time[1]).format("YYYY-MM-DD"):"",M(i).then(p=>{console.log("\u8BF7\u6C42\u7ED3\u679C\uFF1A",p),e.tableData=p.list}).finally(()=>{e.loading=!1})},h=(o,n)=>{var p;if(console.log("\u6253\u5370",o,n),n==0)i.trade_type=o;else if(n==1&&(i.days=o,o==-1&&!((p=e.time)!=null&&p.length)))return;m()},D=(o,n)=>{o=="page"?i.page=n:i.limit=n,m()};return{...U(e),radioChange:h,getPage:m,pagination:D}}};const H={class:"header"},I={class:"col-row"},O={class:"row-left"},q={key:0,class:"row-right"},G={class:"container"},J={class:"footer"};function K(a,e,i,m,h,D){const o=r("el-col"),n=r("el-radio-button"),p=r("el-radio-group"),V=r("el-date-picker"),B=r("el-row"),c=r("el-table-column"),E=r("el-tag"),j=r("QuestionFilled"),Y=r("el-icon"),P=r("el-tooltip"),z=r("el-table"),A=r("el-pagination"),L=r("Page");return _(),f(L,{showBorder:!1,loading:a.loading},{header:l(()=>[u("div",H,[(_(!0),y(k,null,F(a.radioList,(t,v)=>(_(),f(B,{gutter:20,align:"middle",key:v},{default:l(()=>[s(o,{span:2},{default:l(()=>[b(g(t.lable),1)]),_:2},1024),s(o,{span:18},{default:l(()=>[u("div",I,[u("div",O,[s(p,{modelValue:t.selected,"onUpdate:modelValue":d=>t.selected=d,size:"large",onChange:d=>a.radioChange(d,v)},{default:l(()=>[(_(!0),y(k,null,F(t.radios,(d,N)=>(_(),f(n,{key:N,label:d.val},{default:l(()=>[b(g(d.title),1)]),_:2},1032,["label"]))),128))]),_:2},1032,["modelValue","onUpdate:modelValue","onChange"])]),t.selected==-1?(_(),y("div",q,[s(V,{modelValue:a.time,"onUpdate:modelValue":e[0]||(e[0]=d=>a.time=d),type:"daterange",size:"large","range-separator":"\u5230","start-placeholder":"\u5F00\u59CB\u65F6\u95F4","end-placeholder":"\u7ED3\u675F\u65F6\u95F4",onChange:e[1]||(e[1]=d=>a.getPage())},null,8,["modelValue"])])):Q("",!0)])]),_:2},1024)]),_:2},1024))),128))])]),main:l(()=>[u("div",G,[s(z,{data:a.tableData,border:"",style:{width:"100%"}},{default:l(()=>[s(c,{align:"center",label:"\u7F16\u53F7"},{default:l(t=>[u("span",null,"#"+g(t.row.id),1)]),_:1}),s(c,{align:"center",prop:"addtime",label:"\u65F6\u95F4"}),s(c,{align:"center",label:"\u7C7B\u578B"},{default:l(t=>[s(E,{type:t.row.store_yucunjin_type.type==="1"?"success":"danger"},{default:l(()=>[b(g(t.row.store_yucunjin_type.text),1)]),_:2},1032,["type"])]),_:1}),s(c,{align:"center",label:"\u6536\u5165 | \u652F\u51FA(\u5143)"},{default:l(t=>[u("span",{class:S(t.row.fee>0?"text-green":"text-red")},g(t.row.fee),3),s(P,{class:"box-item",effect:"dark",content:t.row.remark,placement:"right-start"},{default:l(()=>[u("span",null,[s(Y,{size:14,class:"tipicon"},{default:l(()=>[s(j)]),_:1})])]),_:2},1032,["content"])]),_:1}),s(c,{align:"center",label:"\u9884\u5B58\u91D1\u4F59\u989D"},{default:l(t=>[u("span",null,g(t.row.yucunjin)+"\u5143",1)]),_:1}),s(c,{align:"center",prop:"operate",label:"\u64CD\u4F5C"})]),_:1},8,["data"])])]),footer:l(()=>[u("div",J,[s(A,{layout:"total, sizes, prev, pager, next, jumper",total:a.total,onSizeChange:e[2]||(e[2]=t=>a.pagination("limit",t)),onCurrentChange:e[3]||(e[3]=t=>a.pagination("page",t))},null,8,["total"])])]),_:1},8,["loading"])}const ee=x(T,[["render",K],["__scopeId","data-v-fa6303f9"]]);export{ee as default};
