import{_ as D,d as E,aP as A,w as f,a0 as B,o as i,c as d,b as e,L as l,u as c,F as h,a as g,D as C,y as k}from"./index.42bf163d.js";import{a as m}from"./calc.1104f430.js";var T=` `;const z={id:"print-template"},q={class:"header"},I={class:"first"},L={class:"title"},O={class:"record"},R={class:"column"},U={class:"supplier"},S={class:"create"},j={class:"column"},H={class:"company"},M={key:0,class:"total"},V={key:1,class:"total"},W=e("th",{style:{"text-align":"left"},width:"35px"},"\u5E8F\u53F7",-1),G=e("th",{style:{"text-align":"left"},width:"135px"},"\u91C7\u8D2D\u5355\u7F16\u53F7",-1),J=e("th",{style:{"text-align":"left"},width:"135px"},"\u9500\u552E\u5355\u7F16\u53F7",-1),K=e("th",{style:{"text-align":"left"}},"\u5546\u54C1\u540D\u79F0",-1),Q=e("th",{style:{"text-align":"left"},width:"25px"},"\u5355\u4F4D",-1),X=e("th",{style:{"text-align":"left"},width:"95px"},"\u6570\u91CF",-1),Y=e("th",{style:{"text-align":"left"},width:"95px"},"\u5546\u54C1\u5355\u4EF7",-1),Z=e("th",{style:{"text-align":"left"},width:"95px"},"\u603B\u8D27\u6B3E",-1),$=e("th",{style:{"text-align":"left"},width:"30px"},"\u7A0E\u7387",-1),ee=E({__name:"index",props:{record:{type:Object,required:!0}},setup(v,{expose:y}){const p=v,x={createTime:"",supplierName:"",companyName:"",totalPrice:0,totalNum:0,payNo:""},s=A(!1),_=f([]),t=f({...x});function F(r){t.value={...x};const{cgdlist:u,payNo:o,companyName:n,supplierName:b,addtime:w}=r;u.forEach((a,P)=>{t.value.totalPrice=m(t.value.totalPrice,a.totalPrice),t.value.totalNum=m(t.value.totalNum,a.goodNum),_.value.push({index:P+1,qrdNo:a.qrdCode,tax:Number(a.tax)+"%",goodNum:a.goodNum,cgdNo:a.sequenceNo,goodUnit:a.goodUnit,goodName:a.goodName,goodPrice:a.goodPrice,totalPrice:a.totalPrice})}),t.value.totalPrice=Number(t.value.totalPrice.toFixed(2)),t.value.supplierName=b,t.value.companyName=n,t.value.payNo=o,t.value.createTime=w}function N(r=!1){s.value=r,k(()=>{const u=document.getElementById("print-template").innerHTML,o=document.createElement("iframe");o.setAttribute("style","position: absolute; width: 0; height: 0;"),document.body.appendChild(o);const n=o.contentWindow.document;n.write(T),n.write("