diff --git a/nuxt4/app/utils/pdf/pdfFormulario.ts b/nuxt4/app/utils/pdf/pdfFormulario.ts index 822b8dd..6ac10c4 100644 --- a/nuxt4/app/utils/pdf/pdfFormulario.ts +++ b/nuxt4/app/utils/pdf/pdfFormulario.ts @@ -48,14 +48,15 @@ export function renderizarFormulario( // Renderizar cada sección con posiciones ajustadas para layout compacto // Fragancia-Aroma y Sabores: 28mm cada una (layout horizontal) + // SubTotal debe terminar exactamente en formHeight (130mm) renderizarEncabezado(doc, xBase, yBase, muestra) renderizarTablaIntensidades(doc, xBase, yBase + 14, muestra) renderizarSeccionFraganciaAroma(doc, xBase + 55, yBase + 14, muestra) // 28mm renderizarSeccionSabores(doc, xBase + 55, yBase + 42, muestra) // 28mm (14+28=42) renderizarSeccionSensacionGustos(doc, xBase, yBase + 70, muestra) // Después de Sabores (42+28=70) renderizarSeccionTazasDefectos(doc, xBase, yBase + 86, muestra) // 70+16=86 - renderizarSeccionOtrasNotas(doc, xBase, yBase + 102, muestra) // 86+16=102 - renderizarSeccionSubTotal(doc, xBase, yBase + 112, muestra) // 102+10=112 + renderizarSeccionOtrasNotas(doc, xBase, yBase + 102, muestra) // 86+16=102, altura 20mm + renderizarSeccionSubTotal(doc, xBase, yBase + 122, muestra) // 122+8=130 (exacto al borde) } /** @@ -469,7 +470,7 @@ function renderizarSeccionOtrasNotas( muestra: Muestra ): void { const width = PDF_CONFIG.formWidth - const sectionHeight = 10 + const sectionHeight = 20 // Expandida para llenar espacio hasta SubTotal // Borde de la sección dibujarRectangulo(doc, x, y, width, sectionHeight, PDF_CONFIG.lineWidth.normal) @@ -491,8 +492,10 @@ function renderizarSeccionOtrasNotas( doc.text(notaTruncada, x + 38, y + 6) } - // Línea para escribir + // Líneas para escribir (múltiples líneas para el espacio expandido) dibujarLineaHorizontal(doc, x + 38, y + 7, x + width - 3, PDF_CONFIG.lineWidth.thin) + dibujarLineaHorizontal(doc, x + 3, y + 12, x + width - 3, PDF_CONFIG.lineWidth.thin) + dibujarLineaHorizontal(doc, x + 3, y + 17, x + width - 3, PDF_CONFIG.lineWidth.thin) } /**