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