import{useColumns as E}from"./columns.6b8bb22c.js";import{aK as L,aL as R,_ as T,q as z,A,a4 as f,x as I,B as g,C as P,r as v,o as D,n as N,t as u,H as c,v as d,S as O}from"./index.7a111e62.js";import{T as V}from"./index.3ac3c8f0.js";import{u as h}from"./hooks.f4063c52.js";import{r as q}from"./responseHandle.6edfaed2.js";const{VITE_PROXY_DOMAIN_REAL:ee,VITE_PROXY_USER_REAL:F}=R(),$=F+"/admin/",H=_=>L.request("post",`${$}report`,{data:_});const M={class:"main"},X=O(" \u6DFB\u52A0\u641C\u7D22\u6761\u4EF6 "),Y={name:"standBook"},K=z({...Y,setup(_){const{logout:C}=A(),t=f({...{inv_in:"",inv_out:"",apply_name:"",status:"",inv_type:"",start:"",end:"",page:1,size:15}}),{push:y}=I(),p=g([]),o=g(!1),{columns:S}=E(),s=f({total:0,pageSize:15,currentPage:1,background:!0});async function k(e){t.page=e,await i()}async function b(e){t.size=e,t.page=1,await i()}function x(e){}async function i(){if(o.value)return;o.value=!0;const{code:e,data:r,message:l}=await H(t);q({code:e,message:l,logout:C,handler:()=>{const{list:n,count:a}=r;p.value=n!=null?n:[],s.total=a!=null?a:0,s.pageSize=t.size,s.currentPage=t.page}}),o.value=!1}function m(e){y({path:"/InvoiceSales/standBookDeatil",query:{id:e}})}return P(()=>{i()}),(e,r)=>{const l=v("el-button"),n=v("PureTable");return D(),N("div",M,[u(d(V),{title:"\u53D1\u7968\u7533\u8BF7\u7BA1\u7406",loading:o.value,dataList:p.value,onRefresh:i},{buttons:c(()=>[u(l,{type:"primary",icon:d(h)("add"),onClick:r[0]||(r[0]=a=>m(""))},{default:c(()=>[X]),_:1},8,["icon"])]),default:c(({size:a,checkList:B})=>[u(n,{border:"",align:"left",showOverflowTooltip:"","table-layout":"auto",size:a,data:p.value,columns:d(S),checkList:B,pagination:s,paginationSmall:a==="small","header-cell-style":{background:"#fafafa",color:"#606266"},onSelectionChange:x,onSizeChange:b,onCurrentChange:k},{operation:c(({row:w})=>[u(l,{class:"reset-margin",link:"",type:"primary",size:a,onClick:j=>m(w.id),icon:d(h)("eye-view")},null,8,["size","onClick","icon"])]),_:2},1032,["size","data","columns","checkList","pagination","paginationSmall"])]),_:1},8,["loading","dataList"])])}}});var ae=T(K,[["__scopeId","data-v-7396d91c"]]);export{ae as default};
