summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMikaël Ates <mates@entrouvert.com>2014-11-30 07:32:06 (GMT)
committerMikaël Ates <mates@entrouvert.com>2014-11-30 07:41:09 (GMT)
commit8bec338cb1386b4e29bf2052e4d5f22fe0e0daed (patch)
treea232854e4349879dab04603b986bc6846c0173bd
parentd27b1de75b2f4da21224e7567243ff31065e735e (diff)
downloadcalebasse-8bec338cb1386b4e29bf2052e4d5f22fe0e0daed.zip
calebasse-8bec338cb1386b4e29bf2052e4d5f22fe0e0daed.tar.gz
calebasse-8bec338cb1386b4e29bf2052e4d5f22fe0e0daed.tar.bz2
[agenda] Fix patient display_name missing on periodic event title on periodic events page.
Since commit e90f4c7328e522e3a22fea48a5c32ffefa620a9b the patient display name is not saved in the event title field anymore. Appointment building set event title with patient display_name but when an event is displayed without using appointement building step, the event type should be tested and if it is 1, event.patient.display_name must be used instead of event.title.
-rw-r--r--calebasse/agenda/templates/agenda/periodic-events.html2
1 files changed, 1 insertions, 1 deletions
diff --git a/calebasse/agenda/templates/agenda/periodic-events.html b/calebasse/agenda/templates/agenda/periodic-events.html
index f3fe5c5..a6d62c3 100644
--- a/calebasse/agenda/templates/agenda/periodic-events.html
+++ b/calebasse/agenda/templates/agenda/periodic-events.html
@@ -86,7 +86,7 @@
<span>{% if event.patient %}Rendez-vous patient{% else %}Évènement{% endif %}: {{ event.recurrence_description|lower }}</span>
<span class="hour">{{ event.start_datetime.time }}</span>
- {% if event.title %} — {{ event.title }} {% endif %}
+ {% if event.patient %} — {{ event.patient.display_name }} {% else %}{% if event.title %} — {{ event.title }} {% endif %}{% endif %}
{% if event.patient.paper_id %} — {{ event.patient.paper_id }} {% endif %}
{% if event.length %} — {{ event.length }} min {% endif %}
{% if event.workers_initial %} — {{ event.workers_initial }} {% endif %}