diff --git a/views/agent/view-ticket.ejs b/views/agent/view-ticket.ejs index 3f0a51c..33b8308 100644 --- a/views/agent/view-ticket.ejs +++ b/views/agent/view-ticket.ejs @@ -146,9 +146,11 @@
Fotos de campo:
- <% visita.historial.evidencias.forEach(foto => { %> - - Evidencia + <% visita.historial.evidencias.forEach(foto => { + const fotoUrl = foto.url.startsWith('http') ? foto.url : ('https://tareas.telcotronics.com' + foto.url); + %> + + Evidencia <% }) %>
@@ -156,10 +158,19 @@ <% } %> - <% if (visita.historial && visita.historial.firma_cliente && visita.historial.firma_cliente.firmado) { %> -
+ <% if (visita.historial && visita.historial.firma_cliente && visita.historial.firma_cliente.firmado) { + const firmaUrl = visita.historial.firma_cliente.firmaUrl ? (visita.historial.firma_cliente.firmaUrl.startsWith('http') ? visita.historial.firma_cliente.firmaUrl : ('https://tareas.telcotronics.com' + visita.historial.firma_cliente.firmaUrl)) : null; + %> +
Firmado: <%= visita.historial.firma_cliente.nombreFirmante %>
+ <% if (firmaUrl) { %> +
+ + Firma cliente + +
+ <% } %> <% } else { %> Pendiente firma cliente <% } %> @@ -188,6 +199,27 @@
+ + <% if (visita.historial && visita.historial.timeline_eventos && visita.historial.timeline_eventos.length > 0) { %> +
+ +
+ +
+
+ <% } %> +
Abrir en tareas.telcotronics.com