From e162ee3fe1cd54d512153c52fc97ad743f31fc53 Mon Sep 17 00:00:00 2001 From: Christian Date: Sun, 17 May 2026 09:36:09 +0200 Subject: [PATCH] fix(telefoni): render initial calls server-side on log page --- app/modules/telefoni/templates/log.html | 28 ++++++++++++++++++++++++- 1 file changed, 27 insertions(+), 1 deletion(-) diff --git a/app/modules/telefoni/templates/log.html b/app/modules/telefoni/templates/log.html index c40ab5a..2782c5f 100644 --- a/app/modules/telefoni/templates/log.html +++ b/app/modules/telefoni/templates/log.html @@ -59,7 +59,33 @@ - Indlæser... + {% if initial_calls and initial_calls|length > 0 %} + {% for call in initial_calls %} + + {{ call.started_at or '-' }} + {{ call.full_name or call.username or '-' }} + {% if call.direction == 'outbound' %}Udgående{% else %}Indgående{% endif %} + {{ call.display_number or '-' }} + + {% if call.kontakt_id %} + {{ (call.contact_name or ('Kontakt #' ~ call.kontakt_id))|trim }} + {% else %} + - + {% endif %} + + + {% if call.sag_id %} + {{ call.sag_titel or ('Sag #' ~ call.sag_id) }} + {% else %} + - + {% endif %} + + {{ call.duration_sec if call.duration_sec is not none else '-' }} + + {% endfor %} + {% else %} + Indlæser... + {% endif %}