1 |
5acde67b
|
Serghei MIHAI
|
{% load url from future %}
|
2 |
|
|
{% load apptags %}
|
3 |
|
|
<a class="print" href="#">Imprimer</a>
|
4 |
|
|
<div>
|
5 |
|
|
{% for appointment in ressource_agenda.appointments %}
|
6 |
|
|
<h3 class="{{ appointment.type }} {% if appointment.act_absence %}act-absence{% endif %} appointment"
|
7 |
3e29d8ec
|
Serghei MIHAI
|
{% if appointment.act_absence %}title="{{appointment.act_absence}}"{% endif %} id="{{ appointment.event_id }}">
|
8 |
5acde67b
|
Serghei MIHAI
|
<span class="hour">{{ appointment.begin_hour }}</span>
|
9 |
ee4ee326
|
Serghei MIHAI
|
{% if appointment.title %}<span class="title">{{ appointment.title }}</span>{% endif %}
|
10 |
a56af5e1
|
Frédéric Péters
|
{% if appointment.length %}<span class="length">{{ appointment.length }} min</span> {% endif %}
|
11 |
ee4ee326
|
Serghei MIHAI
|
{% if appointment.act_type %}<span class="act_type">{{ appointment.act_type }}</span>{% endif %}
|
12 |
|
|
<span class="participants">
|
13 |
fbfab2cc
|
Serghei MIHAI
|
{% if appointment.len_workers > 4 %}
|
14 |
|
|
{% if appointment.workers_absent %}<span class="absent" title="Au moins un intervenant est absent">{% endif %}
|
15 |
ee4ee326
|
Serghei MIHAI
|
{{ appointment.len_workers }} inter.
|
16 |
|
|
{% if appointment.workers_absent %}</span>{% endif %}
|
17 |
fbfab2cc
|
Serghei MIHAI
|
{% else %}
|
18 |
|
|
{% if appointment.workers %}
|
19 |
|
|
{% for worker in appointment.workers %}
|
20 |
|
|
{% if worker in appointment.workers_absent %}<span class="absent" title="Absent">{% endif %}
|
21 |
ee4ee326
|
Serghei MIHAI
|
{{ worker.worker.initials }}{% if not forloop.last %} {% endif %}
|
22 |
|
|
{% if worker in appointment.workers_absent %}</span>{% endif %}
|
23 |
fbfab2cc
|
Serghei MIHAI
|
{% endfor %}
|
24 |
|
|
{% endif %}
|
25 |
|
|
{% endif %}
|
26 |
ee4ee326
|
Serghei MIHAI
|
</span>
|
27 |
|
|
|
28 |
5acde67b
|
Serghei MIHAI
|
<span class="right">
|
29 |
|
|
{% for service_name in appointment.other_services_names %}
|
30 |
|
|
<span class="box {{ service_name }}" title="{{ service_name }}"></span>
|
31 |
|
|
{% endfor %}
|
32 |
3e29d8ec
|
Serghei MIHAI
|
<span title="Un commentaire existe" class="icon-comment" {% if appointment.description %}style='display: inline'{% endif %}></span>
|
33 |
5acde67b
|
Serghei MIHAI
|
{% if appointment.event_id %}
|
34 |
|
|
{% if appointment.is_recurrent %} R {% endif %}
|
35 |
a142f551
|
Serghei MIHAI
|
{% if service in appointment.services_names %}
|
36 |
fbfab2cc
|
Serghei MIHAI
|
{% if appointment.patient_record_id %}
|
37 |
|
|
<button title="Éditer un rendez-vous" class="edit-appointment icon-edit" data-event-id="{{ appointment.event_id }}"></button>
|
38 |
|
|
{% else %}
|
39 |
|
|
<button title="Éditer un événement" class="edit-event icon-edit" data-event-id="{{ appointment.event_id }}">
|
40 |
|
|
{% endif %}
|
41 |
|
|
<button class="remove-appointment icon-remove-sign" title="Supprimer un rendez-vous" data-url="{% url 'delete-occurrence' date=date service=service pk=appointment.event_id %}" data-rdv="{{ appointment.title }}"></button>
|
42 |
5acde67b
|
Serghei MIHAI
|
{% endif %}
|
43 |
|
|
{% endif %}
|
44 |
|
|
</span>
|
45 |
|
|
</h3>
|
46 |
|
|
<div>
|
47 |
|
|
{% if appointment.type == 'free' %}
|
48 |
ad2b7483
|
Serghei MIHAI
|
<button class='newrdv' data-url="{% url 'nouveau-rdv' service=service date=date %}" data-hour="{{ appointment.begin_hour }}" data-duration="{{ appointment.length }}">Nouveau rendez-vous patient</button>
|
49 |
|
|
<button class='newevent' data-url="{% url 'new-event' service=service date=date %}" data-hour="{{ appointment.begin_hour }}" data-duration="{{ appointment.length }}">Nouvel événement</button>
|
50 |
5acde67b
|
Serghei MIHAI
|
{% endif %}
|
51 |
|
|
{% if appointment.event_id %}
|
52 |
|
|
{% if appointment.workers %}
|
53 |
|
|
<p class="workers">
|
54 |
|
|
Intervenants :
|
55 |
|
|
{% for worker in appointment.workers %}
|
56 |
|
|
{{ worker.first_name }} <span class="lastname">{{ worker.last_name }}</span>{% if forloop.last %}.{% else %}, {% endif %}
|
57 |
|
|
{% endfor %}
|
58 |
|
|
</p>
|
59 |
fbfab2cc
|
Serghei MIHAI
|
<p class="phones">
|
60 |
|
|
{% if appointment.patient.mobile %}
|
61 |
|
|
<span title="{{ appointment.patient.first_name }} {{ appointment.patient.last_name|upper }} (Patient - Perso)" class="icon-user-space">
|
62 |
|
|
{{ appointment.patient.mobile }}
|
63 |
|
|
</span>
|
64 |
5acde67b
|
Serghei MIHAI
|
{% endif %}
|
65 |
fbfab2cc
|
Serghei MIHAI
|
{% if appointment.patient.phone %}
|
66 |
|
|
<span title="{{ appointment.patient.first_name }} {{ appointment.patient.last_name|upper }} (Patient - Pro)" class="icon-user-space">
|
67 |
|
|
{{ appointment.patient.phone }}
|
68 |
|
|
</span>
|
69 |
5acde67b
|
Serghei MIHAI
|
{% endif %}
|
70 |
fbfab2cc
|
Serghei MIHAI
|
{% for address in appointment.patient.addresses.all %}
|
71 |
|
|
{% if address.place_of_life %}
|
72 |
|
|
{% if address.phone %}<span title="{{ address.display_name }}" class="icon-home-space">{{ address.phone }}</span>{% endif %}
|
73 |
|
|
{% for contact in address.patientcontact_set.all %}
|
74 |
|
|
{% if contact.id != appointment.patient.id %}
|
75 |
|
|
{% if contact.mobile %}<span title="{{ contact.first_name }} {{ contact.last_name|upper }} (Perso)" class="icon-user-space">{{ contact.mobile }}</span>{% endif %}
|
76 |
|
|
{% if contact.phone %}<span title="{{ contact.first_name }} {{ contact.last_name|upper }} (Pro)" class="icon-user-space">{{ contact.phone }}</span>{% endif %}
|
77 |
|
|
{% endif %}
|
78 |
|
|
{% endfor %}
|
79 |
5acde67b
|
Serghei MIHAI
|
{% endif %}
|
80 |
fbfab2cc
|
Serghei MIHAI
|
{% endfor %}
|
81 |
5acde67b
|
Serghei MIHAI
|
</p>
|
82 |
fbfab2cc
|
Serghei MIHAI
|
{% endif %}
|
83 |
|
|
{% endif %}
|
84 |
|
|
|
85 |
|
|
{% if appointment.patient_record_id %}
|
86 |
5acde67b
|
Serghei MIHAI
|
<a href="/{{ service }}/dossiers/{{ appointment.patient_record_id }}/view" target="_blank">Dossier patient</a> -
|
87 |
|
|
<a href="/{{ service }}/dossiers/{{ appointment.patient_record_id }}/view#tab=5" target="_blank">Prochains rendez-vous</a> -
|
88 |
|
|
<a href="#" class="generate-mail-btn" data-dossier-id="{{ appointment.patient_record_id }}" data-date="{{date|date:"Y-m-d"}}" data-event-id="{{ appointment.event_id }}" data-next-url="{{ request.get_full_path }}">Courrier</a>
|
89 |
|
|
{% endif %}
|
90 |
fbfab2cc
|
Serghei MIHAI
|
|
91 |
5acde67b
|
Serghei MIHAI
|
{% if appointment.validation %}
|
92 |
fbfab2cc
|
Serghei MIHAI
|
<div>
|
93 |
|
|
<span>{% if appointment.validation.1 %}<strong>{{ appointment.validation.2 }}</strong>, le {{ appointment.validation.1.created }} par {{ appointment.validation.1.author }}
|
94 |
5acde67b
|
Serghei MIHAI
|
{% if appointment.validation.1.auto %}(par validation automatique){% endif %}. {% if appointment.validation.0.is_billed %}<strong>Acte facturé</strong>{% endif %}
|
95 |
|
|
{% else %}
|
96 |
|
|
Non pointé.
|
97 |
|
|
{% endif %}
|
98 |
|
|
</span>
|
99 |
|
|
</div>
|
100 |
|
|
{% endif %}
|
101 |
fbfab2cc
|
Serghei MIHAI
|
|
102 |
|
|
{% if not appointment.validation.0.validation_locked and appointment.validation.3 %}
|
103 |
|
|
<form method="post" class="inline-form">
|
104 |
|
|
{% csrf_token %}
|
105 |
|
|
<input type="hidden" value="{{appointment.validation.0.id}}" name="acte-id">
|
106 |
|
|
<select data-previous="{{ last_status.state_name }}" name="act_state">
|
107 |
|
|
{% for state_name, display_state_name in appointment.validation.3.items %}
|
108 |
|
|
<option value="{{ state_name }}" {% if state_name == appointment.validation.1.state_name %}selected{% endif %}>{{ display_state_name }}</option>
|
109 |
|
|
{% endfor %}
|
110 |
|
|
</select>
|
111 |
|
|
<button>Pointer</button>
|
112 |
|
|
</form>
|
113 |
|
|
{% endif %}
|
114 |
|
|
|
115 |
|
|
{% if service in appointment.services_names %}
|
116 |
|
|
<div class="tabs-ressource-{{ ressource_agenda.ressource.id }} textedit">
|
117 |
|
|
<span></span>
|
118 |
|
|
<textarea>{{ appointment.description }}</textarea>
|
119 |
|
|
<button disabled="disabled" data-event-id="{{ appointment.event_id }}" data-date="{{ date|date:"Y-m-d" }}">✔</button>
|
120 |
|
|
</div>
|
121 |
|
|
{% else %}
|
122 |
|
|
<p>{{ appointment.description }}</p>
|
123 |
|
|
{% endif %}
|
124 |
5acde67b
|
Serghei MIHAI
|
</div>
|
125 |
|
|
{% endfor %}
|
126 |
|
|
</div>
|
127 |
|
|
</div>
|