Actualizar contabilidad.html
This commit is contained in:
@@ -1022,8 +1022,8 @@
|
||||
document.getElementById('pdf-client-address').innerText = budget.client_address || "-";
|
||||
|
||||
const itemsHtml = (budget.items || []).map(item => `
|
||||
<tr>
|
||||
<td style="padding: 8px 10px; border-bottom: 1px solid #e2e8f0; font-size: 12px; color: #334155;">${item.concept}</td>
|
||||
<tr style="page-break-inside: avoid;">
|
||||
<td style="padding: 12px 10px; border-bottom: 1px solid #e2e8f0; font-size: 12px; color: #334155; text-align: justify; line-height: 1.5;">${item.concept.replace(/\n/g, '<br>')}</td>
|
||||
<td style="padding: 8px 10px; border-bottom: 1px solid #e2e8f0; font-size: 12px; color: #334155; text-align: center;">${item.qty}</td>
|
||||
<td style="padding: 8px 10px; border-bottom: 1px solid #e2e8f0; font-size: 12px; color: #334155; text-align: right;">${parseFloat(item.price).toFixed(2)} €</td>
|
||||
<td style="padding: 8px 10px; border-bottom: 1px solid #e2e8f0; font-size: 12px; font-weight: 700; color: #0f172a; text-align: right;">${(item.qty * item.price).toFixed(2)} €</td>
|
||||
@@ -1059,7 +1059,7 @@
|
||||
|
||||
const element = document.getElementById('pdf-content');
|
||||
const opt = {
|
||||
margin: 0,
|
||||
margin: [0.5, 0, 0.5, 0],
|
||||
filename: `Presupuesto_PRE${budget.id}_${budget.client_name.replace(/\s+/g, '_')}.pdf`,
|
||||
image: { type: 'jpeg', quality: 1 },
|
||||
html2canvas: { scale: 2, useCORS: true, logging: false },
|
||||
|
||||
Reference in New Issue
Block a user