From 0e3978fb139434eac309c327439d54c9c9769313 Mon Sep 17 00:00:00 2001
From: nicolasarana <90768149+nicolasarana@users.noreply.github.com>
Date: Thu, 8 Oct 2026 15:45:44 -0300
Subject: [PATCH 1/3] TYP - Se agrega a pdf valor y nombre
---
modules/descargas/informe-rup/informe-body.ts | 45 +++++++++++++++----
1 file changed, 36 insertions(+), 9 deletions(-)
diff --git a/modules/descargas/informe-rup/informe-body.ts b/modules/descargas/informe-rup/informe-body.ts
index e3ea186e5f..92efbec5dd 100644
--- a/modules/descargas/informe-rup/informe-body.ts
+++ b/modules/descargas/informe-rup/informe-body.ts
@@ -12,6 +12,7 @@ export class InformeRupBody extends HTMLComponent {
{{ titulo }}
+
@@ -21,6 +22,12 @@ export class InformeRupBody extends HTMLComponent {
{{ fechaEjecucion }}hs
+
+ Inicio de Prestación
+
+
+ {{ fechaPrestacion }}hs
+
{{#if esValidada}}
@@ -36,16 +43,17 @@ export class InformeRupBody extends HTMLComponent {
{{/if}}
-
-
- Inicio de Prestación
-
-
- {{ fechaPrestacion }}hs
-
-
+
+ {{#if valorPrestacion}}
+
+ {{ nombrePrestacion }}:
+
+
+ {{ valorPrestacion }}
+
+ {{/if}}
{{#each registros}}
{{{this}}}
@@ -68,7 +76,8 @@ export class InformeRupBody extends HTMLComponent {
const fechaValidacion = this.getFechaEstado('validada');
const fechaPrestacion = this.prestacion.estados.find(estado => { return estado.tipo === 'ejecucion'; }).createdAt;
const esValidada = (fechaValidacion !== null);
-
+ const valorPrestacion = this.prestacion.ejecucion.registros[0].valor || null;
+ const nombrePrestacion = this.prestacion.ejecucion.registros[0].nombre || null;
if (this.registroId) {
const registro = this.prestacion.findRegistroById(this.registroId);
this.prestacion.solicitud.tipoPrestacion = registro.concepto;
@@ -93,12 +102,30 @@ export class InformeRupBody extends HTMLComponent {
fechaValidacion: fechaValidacion && moment(fechaValidacion).format('DD/MM/YYYY HH:mm'),
fechaPrestacion: fechaPrestacion && moment(fechaPrestacion).format('DD/MM/YYYY HH:mm'),
titulo: this.prestacion.solicitud.tipoPrestacion.term,
+ valorPrestacion: this.cleanValue(valorPrestacion),
+ nombrePrestacion: this.cleanValue(nombrePrestacion),
registros,
esValidada,
firmaHTML
};
}
+ cleanValue(value) {
+ if (value === null || value === undefined) {
+ return '';
+ }
+ if (typeof value === 'string') {
+ return value.replace(/ /g, ' ');
+ }
+ if (typeof value === 'object') {
+ if (value.term) {
+ return String(value.term).replace(/ /g, ' ');
+ }
+ return '';
+ }
+ return String(value);
+ }
+
async getFirmaHTML() {
if (this.validada()) {
const prof = this.prestacion.estadoActual.createdBy;
From cb6dabbf09b1c303fbb8687eaf4ebdf11c83b326 Mon Sep 17 00:00:00 2001
From: nicolasarana <90768149+nicolasarana@users.noreply.github.com>
Date: Fri, 9 Oct 2026 12:25:36 -0300
Subject: [PATCH 2/3] =?UTF-8?q?fix=20-=20Se=20corrige=20duplicaci=C3=B3n?=
=?UTF-8?q?=20de=20datos=20en=20pdf?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
modules/descargas/informe-rup/informe-body.ts | 7 +++++--
1 file changed, 5 insertions(+), 2 deletions(-)
diff --git a/modules/descargas/informe-rup/informe-body.ts b/modules/descargas/informe-rup/informe-body.ts
index 92efbec5dd..c00247bbf4 100644
--- a/modules/descargas/informe-rup/informe-body.ts
+++ b/modules/descargas/informe-rup/informe-body.ts
@@ -96,14 +96,17 @@ export class InformeRupBody extends HTMLComponent {
const registros = await Promise.all(ps);
const firmaHTML = await this.getFirmaHTML();
+ // Si el primer registro ya se renderiza en el detalle, evitamos repetir su nombre/valor en el encabezado
+ const primerRegistroRenderizado = registros.length > 0 && String(registros[0]).trim() !== '';
+
this.data = {
fechaEjecucion: fechaEjecucion && moment(fechaEjecucion).format('DD/MM/YYYY HH:mm'),
fechaValidacion: fechaValidacion && moment(fechaValidacion).format('DD/MM/YYYY HH:mm'),
fechaPrestacion: fechaPrestacion && moment(fechaPrestacion).format('DD/MM/YYYY HH:mm'),
titulo: this.prestacion.solicitud.tipoPrestacion.term,
- valorPrestacion: this.cleanValue(valorPrestacion),
- nombrePrestacion: this.cleanValue(nombrePrestacion),
+ valorPrestacion: primerRegistroRenderizado ? '' : this.cleanValue(valorPrestacion),
+ nombrePrestacion: primerRegistroRenderizado ? '' : this.cleanValue(nombrePrestacion),
registros,
esValidada,
firmaHTML
From 62f615420f0db9bd909baf7567dd1348cc11ec14 Mon Sep 17 00:00:00 2001
From: laucharin
Date: Fri, 9 Oct 2026 12:58:24 -0300
Subject: [PATCH 3/3] Corrige estilos y posiciones
---
modules/descargas/informe-rup/informe-body.ts | 25 +++++++++++--------
1 file changed, 14 insertions(+), 11 deletions(-)
diff --git a/modules/descargas/informe-rup/informe-body.ts b/modules/descargas/informe-rup/informe-body.ts
index c00247bbf4..9c883ca862 100644
--- a/modules/descargas/informe-rup/informe-body.ts
+++ b/modules/descargas/informe-rup/informe-body.ts
@@ -8,44 +8,47 @@ export class InformeRupBody extends HTMLComponent {