From cad2919876addfbb96276f62a3f25a711ee36030 Mon Sep 17 00:00:00 2001 From: Serghei MIHAI Date: Tue, 19 Aug 2014 14:33:26 +0200 Subject: [PATCH] agenda: ressource appointment view redesigned to look like worker's Closes #5284 --- .../templates/agenda/ajax-ressource-tab.html | 113 ++++++++++++--------- 1 file changed, 64 insertions(+), 49 deletions(-) diff --git a/calebasse/agenda/templates/agenda/ajax-ressource-tab.html b/calebasse/agenda/templates/agenda/ajax-ressource-tab.html index 19d56ec..430fcd6 100644 --- a/calebasse/agenda/templates/agenda/ajax-ressource-tab.html +++ b/calebasse/agenda/templates/agenda/ajax-ressource-tab.html @@ -10,19 +10,19 @@ {% if appointment.length %}{{ appointment.length }} min {% endif %} {% if appointment.act_type %}{{ appointment.act_type }}{% endif %} - {% if appointment.len_workers > 4 %} - {% if appointment.workers_absent %}{% endif %} + {% if appointment.len_workers > 4 %} + {% if appointment.workers_absent %}{% endif %} {{ appointment.len_workers }} inter. {% if appointment.workers_absent %}{% endif %} - {% else %} - {% if appointment.workers %} - {% for worker in appointment.workers %} - {% if worker in appointment.workers_absent %}{% endif %} + {% else %} + {% if appointment.workers %} + {% for worker in appointment.workers %} + {% if worker in appointment.workers_absent %}{% endif %} {{ worker.worker.initials }}{% if not forloop.last %} {% endif %} {% if worker in appointment.workers_absent %}{% endif %} - {% endfor %} - {% endif %} - {% endif %} + {% endfor %} + {% endif %} + {% endif %} @@ -33,17 +33,16 @@ {% if appointment.event_id %} {% if appointment.is_recurrent %} R {% endif %} {% if service in appointment.services_names %} - {% if appointment.patient_record_id %} - - {% else %} - + {% else %} + {% endif %} - {% endif %} - {% endif %} -
{% if appointment.type == 'free' %} @@ -57,55 +56,71 @@ {{ worker.first_name }} {{ worker.last_name }}{% if forloop.last %}.{% else %}, {% endif %} {% endfor %}

+

+ {% if appointment.patient.mobile %} + + {{ appointment.patient.mobile }} + {% endif %} - {% if service in appointment.services_names %} -

- - - -
- {% else %} -

{{ appointment.description }}

- {% endif %} + {% if appointment.patient.phone %} + + {{ appointment.patient.phone }} + {% endif %} - {% if appointment.patient_record_id %} -

- {% for address in appointment.patient.addresses.all %} - {% if address.place_of_life and address.phone %} - {{ address.phone }} - {% for contact in address.patientcontact_set.all %} - {% if contact.mobile %} - {{ contact.mobile }} - {% endif %} - {% endfor %} + {% for address in appointment.patient.addresses.all %} + {% if address.place_of_life %} + {% if address.phone %}{{ address.phone }}{% endif %} + {% for contact in address.patientcontact_set.all %} + {% if contact.id != appointment.patient.id %} + {% if contact.mobile %}{{ contact.mobile }}{% endif %} + {% if contact.phone %}{{ contact.phone }}{% endif %} + {% endif %} + {% endfor %} {% endif %} - {% endfor %} + {% endfor %}

+ {% endif %} + {% endif %} + + {% if appointment.patient_record_id %} Dossier patient - Prochains rendez-vous - Courrier {% endif %} + {% if appointment.validation %} -
{% if appointment.validation.1 %}{{ appointment.validation.2 }}, le {{ appointment.validation.1.created }} par {{ appointment.validation.1.author }} +
+ {% if appointment.validation.1 %}{{ appointment.validation.2 }}, le {{ appointment.validation.1.created }} par {{ appointment.validation.1.author }} {% if appointment.validation.1.auto %}(par validation automatique){% endif %}. {% if appointment.validation.0.is_billed %}Acte facturé{% endif %} {% else %} Non pointé. {% endif %} - {% if not appointment.validation.0.validation_locked and appointment.validation.3 %} -
- {% csrf_token %} - - - -
- {% endif %}
{% endif %} + + {% if not appointment.validation.0.validation_locked and appointment.validation.3 %} +
+ {% csrf_token %} + + + +
+ {% endif %} + + {% if service in appointment.services_names %} +
+ + + +
+ {% else %} +

{{ appointment.description }}

+ {% endif %}
{% endfor %}
-- 2.1.0