import{af as p,ey as F,ce as m,cA as d,db as B,a7 as y,_ as w,d as k,n as x,ci as N,r,o as f,A as v,y as c,i as s,h as A,H as S,a as V,ak as R,cC as H,cm as b}from"./index.js";import{e as L}from"./index.5741d39c.js";const M=[{type:"selection",width:40,align:"center",fixed:"left"},{label:"\u53D1\u7968\u7F16\u7801",prop:"InvCode",width:140},{label:"\u7A0E\u524D\u91D1\u989D",prop:"invoice_total",width:100},{label:"\u7A0E\u540E\u91D1\u989D",prop:"invoice_subtotal",width:100},{label:"\u72B6\u6001",prop:"status",width:120,cellRenderer:({row:e,props:u})=>p(m,{size:u.size},{default:()=>{var t;return(t=F.find(l=>String(e.status)===String(l.value)))==null?void 0:t.label}})},{label:"\u5356\u51FA\u65B9\u516C\u53F8",prop:"supplierName",width:145,...d("supplierNo","supplierName","\u5356\u51FA\u65B9\u516C\u53F8\u7F16\u7801:")},{label:"\u4E70\u5165\u65B9\u516C\u53F8",prop:"companyName",width:145,...d("companyNo","companyName","\u4E70\u5165\u65B9\u516C\u53F8\u7F16\u7801:")},{label:"\u53D1\u7968\u7C7B\u578B",width:185,cellRenderer({row:e}){return p(m,null,{default:()=>{var u;return((u=B.find(({value:t})=>t===e.invoice_type))==null?void 0:u.label)||"--"}})}},{label:"\u53D1\u7968\u53F7\u7801",width:110,prop:"invoice_number"},{label:"\u7533\u8BF7\u4EBA",prop:"apply_name"},{label:"\u521B\u5EFA\u65F6\u95F4",prop:"addtime",width:150,formatter:({addtime:e})=>y(e).format("YYYY-MM-DD HH:mm:ss")}],P={title:"\u91C7\u8D2D\u56DE\u7968",statusProp:"companyNo",columns:M,apis:{httpList:L}},g={formItems:[]},Y=k({__name:"index",props:{visible:{type:Boolean,required:!0}},emits:["submit"],setup(e,{emit:u}){const t=u,l=e,n=x([]),a=N(l,"visible"),E={pageSearchHook:()=>H(void 0,void 0,g)};async function h(){if(n.value.length===0){b.warning("\u8BF7\u9009\u62E9\u4E00\u6761\u6570\u636E");return}if(n.value.length>1){b.warning("\u53EA\u80FD\u9009\u62E9\u4E00\u6761\u6570\u636E");return}a.value=!1,t("submit",n.value[0])}return(I,o)=>{const D=r("ElButton"),_=r("PageContainer"),C=r("ElDialog");return f(),v(C,{"close-on-click-modal":!1,"close-on-press-escape":!1,title:"\u9009\u62E9\u8FDB\u9879\u53D1\u7968",modelValue:s(a),"onUpdate:modelValue":o[1]||(o[1]=i=>R(a)?a.value=i:null),top:"10px",center:""},{default:c(()=>[s(a)?(f(),v(_,{key:0,hooks:E,notice:!1,"search-config":s(g),"content-config":s(P),onContentSelectChange:o[0]||(o[0]=i=>n.value=i)},{search_action:c(()=>[A(D,{type:"primary",onClick:h},{default:c(()=>o[2]||(o[2]=[S(" \u4FDD\u5B58 ")])),_:1})]),_:1},8,["search-config","content-config"])):V("v-if",!0)]),_:1},8,["modelValue"])}}});var z=w(Y,[["__file","D:/work/jiesuan/settle-vue3/src/views/purchase/ticketReturn/components/choose-invoice-modal/index.vue"]]);export{z as default};
