import{d as D,r as E,b as w,p as B,c as i,e as N,f as V,g as c,h as e,i as t,u as d,C as k,t as z,F as A,m as n,L as P,_ as S}from"./index.0308b213.js";import{b as U}from"./report.32ea0bec.js";import"./pawnRequest.956aeb8a.js";const Y={class:"filter-form"},M={class:"dl-flex",style:{gap:"10px"}},L={style:{display:"flex",gap:"10px"}},T=n("\u4E0D\u9650"),j=n("\u4ECA\u65E5"),q=n("\u6628\u65E5"),I=n("\u8FD17\u5929"),R=n("\u8FD130\u5929"),$=n("\u7B5B\u9009"),G={class:"data"},H={class:"operation-btn"},J=n("\u6253\u5370\u5F53\u524D\u9875"),K=n("\u6253\u5370\u5168\u90E8\u9875"),O=n("\u5BFC\u51FA\u5168\u90E8\u9875"),Q=n("\u5BFC\u51FA\u5168\u90E8\u9875"),W={class:"table"},X={class:"pagination"},Z=D({setup(ee){const b=E(""),a=w({start_date:void 0,end_date:void 0,day:"all",page:1,limit:10}),g=w({list:[],total_fee:0,count:0}),x=m=>{const{columns:l,data:h}=m,u=[];return l.forEach((r,f)=>{if(f===0){u[f]=P("div",{style:{color:"#303133",fontSize:"12px"}},["\u5408\u8BA1"]);return}if(r.property=="pawn_fee"){const _=h.map(p=>Number(p[r.property]));_.every(p=>Number.isNaN(p))?u[f]="":u[f]=`${_.reduce((p,o)=>{const F=Number(o);return Number.isNaN(F)?p:p+o},0)}`}else u[f]=""}),u},v=()=>{U(a).then(m=>{g.list=m.list,g.count=m.count,g.total_fee=m.total_fee})};v();const y=()=>{b.value&&b.value.length===2?(a.start_date=b.value[0],a.end_date=b.value[1]):(a.start_date=void 0,a.end_date=void 0),v()};return B(()=>a,m=>{y()},{deep:!0,immediate:!0}),(m,l)=>{const h=i("el-date-picker"),u=i("el-form-item"),r=i("el-radio-button"),f=i("el-radio-group"),_=i("el-button"),p=i("el-form"),o=i("el-table-column"),F=i("el-table"),C=i("el-pagination");return N(),V(A,null,[c("div",Y,[e(p,{model:d(a),"label-width":"0",onSubmit:l[2]||(l[2]=k(()=>{},["prevent"]))},{default:t(()=>[c("div",M,[e(u,{class:"tn-el-form-item",style:{width:"300px"}},{default:t(()=>[e(h,{class:"tn-el-form-item--item",type:"daterange",modelValue:b.value,"onUpdate:modelValue":l[0]||(l[0]=s=>b.value=s),"range-separator":"\u81F3","start-placeholder":"\u5F00\u59CB\u65F6\u95F4","end-placeholder":"\u7ED3\u675F\u65F6\u95F4","value-format":"YYYY-MM-DD"},null,8,["modelValue"])]),_:1})]),c("div",L,[e(u,null,{default:t(()=>[e(f,{modelValue:d(a).day,"onUpdate:modelValue":l[1]||(l[1]=s=>d(a).day=s)},{default:t(()=>[e(r,{label:"all"},{default:t(()=>[T]),_:1}),e(r,{label:"0"},{default:t(()=>[j]),_:1}),e(r,{label:"1"},{default:t(()=>[q]),_:1}),e(r,{label:"7"},{default:t(()=>[I]),_:1}),e(r,{label:"30"},{default:t(()=>[R]),_:1})]),_:1},8,["modelValue"])]),_:1}),e(u,null,{default:t(()=>[e(_,{type:"primary",onClick:y},{default:t(()=>[$]),_:1})]),_:1})])]),_:1},8,["model"])]),c("div",G,[c("div",H,[e(_,{class:"btn tn-button tn-button--blue--light"},{default:t(()=>[J]),_:1}),e(_,{class:"btn tn-button tn-button--blue--light"},{default:t(()=>[K]),_:1}),e(_,{class:"btn tn-button tn-button--blue--light"},{default:t(()=>[O]),_:1}),e(_,{class:"btn tn-button tn-button--blue--light"},{default:t(()=>[Q]),_:1})]),c("div",W,[e(F,{stripe:"",border:"",data:d(g).list,"show-summary":"","summary-method":x},{default:t(()=>[e(o,{align:"center",label:"\u5F53\u7968\u7F16\u53F7",prop:"ticket_no",width:"300px"}),e(o,{align:"center",label:"\u95E8\u5E97",prop:"store_name",width:"150px"}),e(o,{align:"center",label:"\u5F53\u54C1\u7C7B\u522B",prop:"classify_text",width:"140px"}),e(o,{align:"center",label:"\u5F53\u54C1\u540D\u79F0",prop:"name",width:"200px"}),e(o,{align:"center",label:"\u91D1\u989D",prop:"pawn_fee",width:"150px"},{default:t(s=>[c("span",null,z(s.row.pawn_fee||"-"),1)]),_:1}),e(o,{align:"center",label:"\u64CD\u4F5C\u5458",prop:"nickname",width:"100px"}),e(o,{align:"center",label:"\u521B\u5EFA\u65F6\u95F4",prop:"create_time",width:"300px"}),e(o,{align:"center",label:"\u5907\u6CE8",prop:"remark",width:"300px"})]),_:1},8,["data"])])]),c("div",X,[e(C,{currentPage:d(a).page,"onUpdate:currentPage":l[3]||(l[3]=s=>d(a).page=s),"page-size":d(a).limit,"onUpdate:page-size":l[4]||(l[4]=s=>d(a).limit=s),"page-sizes":[10,20,30,40],layout:"total, sizes, prev, pager, next, jumper",total:d(g).count},null,8,["currentPage","page-size","total"])])],64)}}});const oe=S(Z,[["__scopeId","data-v-4264fd41"]]);export{oe as default};
