Project

General

Profile

Download (29.5 KB) Statistics
| Branch: | Tag: | Revision:

calebasse / calebasse / dossiers / templates / dossiers / patientrecord_update.html @ 5f051f56

1
{% extends "dossiers/base.html" %}
2
{% load url from future %}
3

    
4
{% block extrascripts %}
5
<link rel="stylesheet" type="text/css" media="all" href="{{ STATIC_URL }}filter-widget/css/filter-widget.css"/>
6
<script src="{{ STATIC_URL }}js/jquery.parse-url.js"></script>
7
<script src="{{ STATIC_URL }}js/calebasse.dossiers.js"></script>
8
<script src="{{ STATIC_URL }}filter-widget/js/i18n.js"></script>
9
<script src="{{ STATIC_URL }}filter-widget/js/core.js"></script>
10
<script src="{{ STATIC_URL }}filter-widget/js/SelectBox.js"></script>
11
<script src="{{ STATIC_URL }}filter-widget/js/SelectFilter2.js"></script>
12
{% endblock %}
13

    
14

    
15
{% block appbar %}
16
<h2><span class="lastname">{{ object.last_name }}</span> {{ object.first_name }} - Dossier {{ object.paper_id|default_if_none:"" }}</h2>
17
<span id="ajax-redirect" data-url="{{ object.id }}/view"/>
18
<a href="..">Retourner aux dossiers</a>
19
{% if object.can_be_deleted %}<button type="button" id="patientrecord-delete">Supprimer</button>{% endif %}
20
{% endblock %}
21

    
22
{% block content %}
23

    
24
{% if messages %}
25
<ul class="messages">
26
    {% for message in messages %}
27
    <li{% if message.tags %} class="{{ message.tags }}"{% endif %}>{{ message }}</li>
28
    {% endfor %}
29
</ul>
30
<script type="text/javascript">
31
$('.messages').delay(1000*(1+{{ messages|length }})).fadeOut('slow');
32
</script>
33
{% endif %}
34

    
35
<div id="tabs">
36
  <ul>
37
    <li><a data-id="0" class="atabs" href="#tabs-1">Général</a></li>
38
    <li><a data-id="1" class="atabs" href="#tabs-2">Fiche administrative</a></li>
39
    <li><a data-id="2" class="atabs" href="#tabs-3">Adresses / contacts</a></li>
40
    {% if object.service.name == "CMPP" %}
41
    <li><a data-id="3"  class="atabs" href="#tabs-4">Prise en charge</a></li>
42
    {% endif %}
43
    {% if object.service.name == "SESSAD TED" or object.service.name == "SESSAD DYS" %}
44
    <li><a data-id="3" class="atabs" href="#tabs-4">Notifications</a></li>
45
    {% endif %}
46
    <li><a data-id="4" class="atabs" href="#tabs-5">Actes passés</a>
47
    <li><a data-id="5" class="atabs" href="#tabs-6">Prochains rendez-vous</a>
48
    <li><a data-id="6" class="atabs" href="#tabs-7">Socialisation</a>
49
    <li><a data-id="7" class="atabs" href="#tabs-8">Données à caractère médical</a>
50
  </ul>
51
  <div id="tabs-1"> <!-- Général -->
52
      {% include "dossiers/patientrecord_tab1.html" %}
53
  </div>
54

    
55
  <div id="tabs-2"> <!-- Fiche administrative -->
56
      {% include "dossiers/patientrecord_tab2.html" %}
57
  </div>
58

    
59
    <div id="tabs-3"> <!-- Adresses / Contacts -->
60
    <form method="post" id="policyholder-form" class="patientrecordform">{% csrf_token %}
61

    
62
            <div class="contact patient">
63
                <h4>{% if object.gender == 1 %}M.{% elif object.gender == 2 %}Mme{% endif %}
64
                    {{ object.first_name }} <span class="lastname">{{ object.last_name }}</span> {% if object.id == object.id %} (PATIENT){% endif %}</h4>
65
                <div class="right">Assuré
66
                    <input type="radio"
67
                    {% if object.policyholder.id == object.id %} checked="checked" {% endif %}
68
                    id="id_policyholder-policyholder_{{ object.id }}"
69
                    value="{{ object.id }}"
70
                    class="policyholder-radio"
71
                    name="policyholder-policyholder">
72
                    <button type="button" data-id="{{ object.id }}" class="update-contact-btn icon-edit" title="Modifier"></button>
73
                </div>
74
                <div>
75
                    <ul>
76
                        {% if object.parente %}
77
                            <li><label>Lien avec le patient :</label>
78
                            {{ object.parente }}</li>
79
                        {% endif %}
80
                        {% if object.mobile %}
81
                            <li>
82
                            <span class="icon-user-space">{{ object.mobile }} (perso)</span>
83
                            </li>
84
                        {% endif %}
85
                        {% if object.phone %}
86
                            <li>
87
                            <span class="icon-user-space">{{ object.phone }} (pro)</span>
88
                            </li>
89
                        {% endif %}
90
                        {% if object.email %}
91
                            <li>
92
                            <label>Courriel :</label>
93
                            {{ object.email }}
94
                            </li>
95
                        {% endif %}
96
                        {% if object.job %}
97
                            <li>
98
                            <label>Profession :</label>
99
                            {{ object.job }}
100
                            </li>
101
                        {% endif %}
102
                        {% if object.contact_comment %}
103
                            <li>
104
                            <label>Commentaire :</label>
105
                            {{ object.contact_comment }}
106
                            </li>
107
                        {% endif %}
108
                        <li><label>Données d'assuré social</label>
109
<!--                            <button class="blind">détails</button>-->
110
                            <ul>
111
                            {% if object.social_security_id %}
112
                                <li><label>Numéro d'assuré social :</label>
113
                                {{ object.social_security_id }} {{ object.get_control_key }}</li>
114
                            {% endif %}
115
                            {% if object.birthdate %}
116
                                <li><label>Date de naissance :</label>
117
                                {{ object.birthdate }}</li>
118
                            {% endif %}
119
                            {% if object.birthplace %}
120
                                <li><label>Lieu de naissance :</label>
121
                                {{ object.birthplace }}</li>
122
                            {% endif %}
123
                            {% if object.begin_rights %}
124
                                <li><label>Début de droits :</label>
125
                                {{ object.begin_rights }}</li>
126
                            {% endif %}
127
                            {% if object.end_rights %}
128
                                <li><label>Fin de droits :</label>
129
                                {{ object.end_rights }}</li>
130
                            {% endif %}
131
                            {% if object.health_center %}
132
                                <li><label>Caisse :</label>
133
                                {{ object.health_center }}</li>
134
                            {% endif %}
135
                            {% if object.other_health_center %}
136
                                <li><label>Centre spécifique :</label>
137
                                {{ object.other_health_center }}</li>
138
                            {% endif %}
139
                            <li><label>Tiers-payant :</label>
140
                                {% if object.thirdparty_payer %}
141
                                    Oui
142
                                {% else %}
143
                                    Non
144
                                {% endif %}
145
                            </li>
146
                            {% if object.twinning_rank %}
147
                                <li><label>Rang (gémellité) :</label>
148
                                {{ object.twinning_rank }}</li>
149
                            {% endif %}
150
                            </ul>
151
                        </li>
152
                    </ul>
153
                </div>
154
            </div>
155

    
156
        <button type="button" id="new-address-btn">Nouvelle adresse</button>
157
        <button type="button" id="new-contact-btn">Nouveau contact</button>
158

    
159
        {% for address in object.addresses.all %}
160
        <div class="frame">
161
            <h3>{% if not address.display_name %}Non renseigné{% else %}{{ address.display_name }}{% endif %}</h3>
162
            <div class="buttons">
163
                <button type="button" data-id="{{ address.id }}" class="del-address icon-minus" title="Supprimer"></button>
164
                <button type="button" data-id="{{ address.id }}" class="update-address-btn icon-edit" title="Modifier"></button>
165
            </div>
166
            <div class="right">
167
                <input type="checkbox" data-id="{{ address.id }}" class="place_of_life" {% if address.place_of_life %}checked{% endif %}>Lieu de vie</input>
168
            </div>
169
            {% if address.phone %}<p><span class="icon-home-space">{{ address.phone }}</span></p>{% endif %}
170
            {% if address.comment %}<p><label>Commentaire :</label>{{ address.comment }}</p>{% endif %}
171
            {% if not address.phone and not address.comment %}<p>&nbsp;<!-- intentionaly empty --></p>{% endif %}
172
            {% for contact in address.patientcontact_set.all  %}
173
            {% if contact.id != object.id %}
174
            <div class="contact{% if contact.id == object.id %} patient{% endif %}">
175
                <h4>{% if contact.gender == 1 %}M.{% elif contact.gender == 2 %}Mme{% endif %}
176
                    {{ contact.first_name }} <span class="lastname">{{ contact.last_name }}</span> {% if contact.id == object.id %} (PATIENT){% endif %}</h4>
177
                <div class="right">Assuré
178
                    <input type="radio"
179
                    {% if object.policyholder.id == contact.id %} checked="checked" {% endif %}
180
                    id="id_policyholder-policyholder_{{ contact.id }}"
181
                    value="{{ contact.id }}"
182
                    class="policyholder-radio"
183
                    name="policyholder-policyholder">
184
                    <button type="button" data-id="{{ contact.id }}" data-address-id="{{ address.id }}" class="del-contact icon-minus" title="Supprimer"></button>
185
                    <button type="button" data-id="{{ contact.id }}" class="update-contact-btn icon-edit" title="Modifier"></button>
186
                </div>
187
                <div>
188
                    <ul>
189
                        {% if contact.parente %}
190
                            <li><label>Lien avec le patient :</label>
191
                            {{ contact.parente }}</li>
192
                        {% endif %}
193
                        {% if contact.mobile %}
194
                            <li>
195
                            <span class="icon-user-space">{{ contact.mobile }} (perso)</span>
196
                            </li>
197
                        {% endif %}
198
                        {% if contact.phone %}
199
                            <li>
200
                            <span class="icon-user-space">{{ contact.phone }} (pro)</span>
201
                            </li>
202
                        {% endif %}
203
                        {% if contact.email %}
204
                            <li>
205
                            <label>Courriel :</label>
206
                            {{ contact.email }}
207
                            </li>
208
                        {% endif %}
209
                        {% if contact.job %}
210
                            <li>
211
                            <label>Profession :</label>
212
                            {{ contact.job }}
213
                            </li>
214
                        {% endif %}
215
                        {% if contact.contact_comment %}
216
                            <li>
217
                            <label>Commentaire :</label>
218
                            {{ contact.contact_comment }}
219
                            </li>
220
                        {% endif %}
221
                        <li><label>Données d'assuré social</label>
222
<!--                            <button class="blind">détails</button>-->
223
                            <ul>
224
                            {% if contact.social_security_id %}
225
                                <li><label>Numéro d'assuré social :</label>
226
                                {{ contact.social_security_id }} {{ contact.get_control_key }}</li>
227
                            {% endif %}
228
                            {% if contact.birthdate %}
229
                                <li><label>Date de naissance :</label>
230
                                {{ contact.birthdate }}</li>
231
                            {% endif %}
232
                            {% if contact.birthplace %}
233
                                <li><label>Lieu de naissance :</label>
234
                                {{ contact.birthplace }}</li>
235
                            {% endif %}
236
                            {% if contact.begin_rights %}
237
                                <li><label>Début de droits :</label>
238
                                {{ contact.begin_rights }}</li>
239
                            {% endif %}
240
                            {% if contact.end_rights %}
241
                                <li><label>Fin de droits :</label>
242
                                {{ contact.end_rights }}</li>
243
                            {% endif %}
244
                            {% if contact.health_center %}
245
                                <li><label>Centre de santé :</label>
246
                                {{ contact.health_center }}</li>
247
                            {% endif %}
248
                            <li><label>Tiers-payant :</label>
249
                                {% if contact.thirdparty_payer %}
250
                                    Oui
251
                                {% else %}
252
                                    Non
253
                                {% endif %}
254
                            </li>
255
                            {% if contact.twinning_rank %}
256
                                <li><label>Rang (gémellité) :</label>
257
                                {{ contact.twinning_rank }}</li>
258
                            {% endif %}
259
                            </ul>
260
                        </li>
261
                    </ul>
262
                </div>
263
            </div>
264
            {% endif %}
265
            {% endfor %}
266
        </div>
267
        {% endfor %}
268
    </form>
269

    
270
    </div>
271

    
272
    <div id="tabs-4"> <!-- Prise en charge -->
273

    
274
    {% if object.service.name == "CMPP" %}
275
        <p>
276
        <button id="new-hcdiag-btn">Nouvelle PC diagnostic</button>
277
        <button id="new-hctrait-btn">Nouvelle PC traitement</button>
278
        </p>
279
        {% if hcs %}
280
            {% for hc in hcs %}
281
                {% if hc.cmpphealthcarediagnostic %}
282
                  <div id="patient-diag">
283
                    <div class="frame">
284
                    <div class="buttons">
285
                        <button type="button" data-id="{{ hc.id }}" class="del-hcdiag icon-minus" title="Supprimer"></button>
286
                        <button type="button" data-id="{{ hc.id }}" class="update-hcdiag-btn icon-edit" title="Modifier"></button>
287
                    </div>
288
                      <h3>En diagnostic depuis le {{ hc.start_date }}</h3>
289
                      <ul>
290
                        <li><label>Actes prévus</label> : {{ hc.cmpphealthcarediagnostic.act_number }}</li>
291
                        {% if hc.comment %}<li><label>Commentaire</label> : {{ hc.comment }}</li>{% endif %}
292
                        <li>{% if hc.get_nb_acts_cared %}<strong>{{ hc.get_nb_acts_cared }}</strong> actes déja facturés.{% else %}Aucun acte facturé.{% endif %}</li>
293
                      </ul>
294
                    </div>
295
                  </div>
296
                {% else %}
297
                  <div id="patient-traitement">
298
                    <div class="frame">
299
                    <div class="buttons">
300
                        <button type="button" data-id="{{ hc.id }}" class="del-hctrait icon-minus" title="Supprimer"></button>
301
                        <button type="button" data-id="{{ hc.id }}" class="update-hctrait-btn icon-edit" title="Modifier"></button>
302
                    </div>
303
                      <h3>En traitement depuis le {{ hc.start_date }}{% if hc.end_date %} jusqu'au {{ hc.end_date }}{% endif %}</h3>
304
                      <ul>
305
                        <li><label>Actes prévus</label> : {{ hc.cmpphealthcaretreatment.act_number }}</li>
306
                        {% if hc.comment %}<li><label>Commentaire</label> : {{ hc.comment }}</li>{% endif %}
307
                        <li>{% if hc.get_nb_acts_cared %}<strong>{{ hc.get_nb_acts_cared }}</strong> actes déja facturés.{% else %}Aucun acte facturé.{% endif %}</li>
308
                      </ul>
309
                    </div>
310
                  </div>
311
                {% endif %}
312
            {% endfor %}
313
        {% endif %}
314
    {% endif %}
315
    {% if object.service.name == "SESSAD TED" or object.service.name == "SESSAD DYS" %}
316
        <button id="new-notification-btn">Nouvelle notification</button>
317
    {% endif %}
318

    
319

    
320
<!--      <div id="patient-diag">-->
321
<!--        <div class="frame">-->
322
<!--          <h3>En diagnostic depuis le 11 juin 2012</h3>-->
323
<!--          <ul>-->
324
<!--            <li><input size="4" value="6"/> actes prévus</li>-->
325
<!--            <li><strong>3</strong> actes réalisés dont <strong>2</strong> facturés <button class="blind">détails</button>-->
326
<!--            <ul>-->
327
<!--              <li>Facturation <strong>28</strong> (assuré: Sophie Fonfec) - <strong>2</strong> actes-->
328
<!--              <ul>-->
329
<!--                <li>Accueil le 11 juin 2012 - 9h00 - 45 minutes - Bob Leponge</li>-->
330
<!--                <li>Dialogue le 12 juin 2012 - 10h00 - 30 minutes - Bob Leponge</li>-->
331
<!--              </ul></li>-->
332
<!--              <li>Non facturé - <strong>1 acte</strong>-->
333
<!--              <ul>-->
334
<!--                <li>Dialogue le 13 juin 2012 - 11h00 - 45 minutes - Sandy Kilo</li>-->
335
<!--              </ul></li>-->
336
<!--            </ul>-->
337
<!--            </li>-->
338
<!--          </ul>-->
339
<!--        </div>-->
340
<!--      </div>-->
341

    
342
<!--      <div id="patient-traitement">-->
343
<!--        <div class="frame">-->
344
<!--          <h3>En diagnostic depuis le 6 mars 2012</h3>-->
345
<!--          <ul>-->
346
<!--            <li><strong>6</strong> actes réalisés et facturés <button class="blind">détails</button>-->
347
<!--            <ul>-->
348
<!--              <li>Facturation <strong>28</strong> (assuré: Sophie Fonfec) - <strong>6</strong> actes-->
349
<!--              <ul>-->
350
<!--                <li>...</li>-->
351
<!--              </ul></li>-->
352
<!--            </ul>-->
353
<!--            </li>-->
354
<!--          </ul>-->
355
<!--        </div>-->
356

    
357
<!--        <div class="frame">-->
358
<!--          <h3>En traitement depuis le 11 juin 2012</h3>-->
359
<!--          <ul>-->
360
<!--            <li><strong>4</strong> actes réalisés <button class="blind">détails</button>-->
361
<!--            <ul><li>...</li></ul>-->
362
<!--            </li>-->
363
<!--            <li>Pas de prise en charge - <button id="add-prise-en-charge-btn">Ajouter une prise en charge</button></li>-->
364
<!--          </ul>-->
365
<!--        </div>-->
366

    
367
<!--      </div>-->
368

    
369
<!--      <div id="patient-traitement-charge" style="display: none;">-->
370

    
371
<!--        <div class="frame">-->
372
<!--          <h3>En diagnostic depuis le 2 avril 2008</h3>-->
373
<!--          <ul>-->
374
<!--            <li><strong>3</strong> actes réalisés et facturés <button class="blind">détails</button>-->
375
<!--            <ul>-->
376
<!--              <li>Facturation <strong>28</strong> (assuré: Sophie Fonfec) - <strong>3</strong> actes-->
377
<!--              <ul>-->
378
<!--                <li>...</li>-->
379
<!--              </ul></li>-->
380
<!--            </ul>-->
381
<!--            </li>-->
382
<!--          </ul>-->
383
<!--        </div>-->
384

    
385
<!--        <div class="frame">-->
386
<!--          <h3>En diagnostic depuis le 5 octobre 2010</h3>-->
387
<!--          <ul>-->
388
<!--            <li><strong>6</strong> actes réalisés et facturés <button class="blind">détails</button>-->
389
<!--            <ul>-->
390
<!--              <li>Facturation <strong>28</strong> (assuré: Sophie Fonfec) - <strong>6</strong> actes-->
391
<!--              <ul>-->
392
<!--                <li>...</li>-->
393
<!--              </ul></li>-->
394
<!--            </ul>-->
395
<!--            </li>-->
396
<!--          </ul>-->
397
<!--        </div>-->
398

    
399
<!--        <div class="frame">-->
400
<!--          <h3>En traitement depuis le 12 décembre 2010</h3>-->
401
<!--          <ul>-->
402
<!--            <li>Prise en charge depuis le 12 décembre 2010-->
403
<!--            <ul>-->
404
<!--              <li><strong>30</strong> actes réalisés et facturés <button class="blind">détails</button>-->
405
<!--              <ul><li>...</li></ul></li>-->
406
<!--              <li><strong>10</strong> actes réalisés et facturés en prolongation <button class="blind">détails</button>-->
407
<!--              <ul><li>...</li></ul></li>-->
408
<!--              <li><strong>6</strong> actes réalisés et non pris en charge <button class="blind">détails</button>-->
409
<!--              <ul><li>...</li></ul></li>-->
410
<!--            </ul>-->
411
<!--            </li>-->
412
<!--            <li>Prise en charge depuis le 15 décembre 2011-->
413
<!--            <ul>-->
414
<!--              <li><strong>30</strong> actes réalisés et facturés <button class="blind">détails</button>-->
415
<!--              <ul><li>...</li></ul></li>-->
416
<!--              <li><strong>6</strong> actes réalisés non facturés <button class="blind">détails</button>-->
417
<!--              <ul><li>...</li></ul></li>-->
418
<!--              <li><button id="add-prolongation-btn">Ajouter une prolongation</button></li>-->
419
<!--            </ul>-->
420
<!--            </li>-->
421
<!--          </ul>-->
422
<!--        </div>-->
423

    
424

    
425
<!--      </div>-->
426

    
427
<!--      <div id="overlay">-->
428
<!--       <p>-->
429
<!--       Exemples pour cet onglet :-->
430
<!--        <a href="#" onclick="$('#patient-diag').show(); $('#patient-traitement').hide(); $('#patient-traitement-charge').hide();">Patient en diagnostic</a>-->
431
<!--        <a href="#" onclick="$('#patient-diag').hide(); $('#patient-traitement').show(); $('#patient-traitement-charge').hide();">Patient en traitement</a>-->
432
<!--        <a href="#" onclick="$('#patient-diag').hide(); $('#patient-traitement').hide(); $('#patient-traitement-charge').show();">Patient en traitement avec prise en charge</a>-->
433
<!--        </p>-->
434
<!--      </div>-->
435

    
436
    </div>
437

    
438
    <div id="tabs-5"> <!-- Actes passés -->
439
        {% for act, state in last_rdvs %}
440
        <div class="frame">
441
            <h3>{% firstof act.start_datetime|date:"d/m/y H:i" act.date %} {{ act.act_type }}</h3>
442
            <ul>
443
            {% if act.doctors.all %}
444
            <li><label>Praticiens :</label>
445
            {% for doctor in act.doctors.all %}
446
            {{ doctor.first_name }} <span class="lastname">{{ doctor.last_name }}</span>
447
            {% endfor %}
448
            </li>
449
            {% endif %}
450
            {% if act.parent_event.room %}
451
            <li>
452
            Salle : {{ act.parent_event.room }}
453
            </li>
454
            {% endif %}
455
            <li>{% if state %}<strong>{{ state }}</strong>, le {{ state.created }}.
456
            {% else %}
457
              Non pointé.
458
            {% endif %}
459
            </li>
460
        </ul>
461
        </div>
462
        {% endfor %}
463
    </div>
464

    
465
    <div id="tabs-6"> <!-- Prochains rendez-vous -->
466
        {% for act, state in next_rdvs %}
467
        <div class="frame">
468
            <h3>{% firstof act.start_datetime|date:"d/m/y H:i" act.date %} {{ act.act_type }}</h3>
469
            <ul>
470
            {% if act.doctors.all %}
471
            <li><label>Praticiens :</label>
472
            {% for doctor in act.doctors.all %}
473
            {{ doctor.first_name }} <span class="lastname">{{ doctor.last_name }}</span>
474
            {% endfor %}
475
            </li>
476
            {% endif %}
477
            {% if act.parent_event.room %}
478
            <li>
479
            Salle : {{ act.parent_event.room }}
480
            </li>
481
            {% endif %}
482
            <li>{% if state %}<strong>{{ state }}</strong>, le {{ state.created }}.
483
            {% else %}
484
              Non pointé.
485
            {% endif %}
486
            </li>
487
        </ul>
488
        </div>
489
        {% endfor %}
490
    </div>
491

    
492
    <div id="tabs-7">
493
        <div class="frame">
494
            <h3>Périodes de socialisation</h3>
495
            <p><button id="new-socialisation-duration-btn">Nouvelle période de socialisation</button></p>
496
            {% for duration in object.socialisation_durations.all %}
497
                <div class="subframe">
498
                Arrivée le <strong>{{ duration.start_date }}</strong> dans {% if duration.school %}l'établissement <strong>{{ duration.school }}</strong>{% else %}un établissement non renseigné{% endif %}{% if duration.level %} (en {{ duration.level }}){% endif %}
499
                <div class="buttons">
500
                    <button type="button" data-id="{{ duration.id }}" class="del-duration icon-minus" title="Supprimer"></button>
501
                    <button type="button" data-id="{{ duration.id }}" class="update-duration-btn icon-edit" title="Modifier"></button>
502
                </div>
503
                <div>
504
                    <ul>
505
                        {% if duration.end_date %}<li><label>Date de départ</label> : {{ duration.end_date }}</li>{% endif %}
506
                        {% if duration.comment %}<li><label>Commentaire</label> : {{ duration.comment }}</li>{% endif %}
507
                    </ul>
508
                </div>
509
                </div>
510
            {% endfor %}
511
        </div>
512

    
513
        <div class="frame">
514
            <h3>Demandes MDPH</h3>
515
            <p><button id="new-mdph-request-btn">Nouvelle demande MDPH</button></p>
516
            {% for request in object.mdph_requests.all %}
517
                <div class="subframe">
518
                Demande le <strong>{{ request.start_date }}</strong> à la MDPH <strong>{{ request.mdph }}</strong>
519
                <div class="buttons">
520
                    <button type="button" data-id="{{ request.id }}" class="del-mdph-request icon-minus" title="Supprimer"></button>
521
                    <button type="button" data-id="{{ request.id }}" class="update-mdph-request-btn icon-edit" title="Modifier"></button>
522
                </div>
523
                <div>
524
                    <ul>
525
                        {% if request.comment %}<li><label>Commentaire</label> : {{ request.comment }}</li>{% endif %}
526
                    </ul>
527
                </div>
528
                </div>
529
            {% endfor %}
530
        </div>
531

    
532
        <div class="frame">
533
            <h3>Réponses MDPH</h3>
534
            <p><button id="new-mdph-response-btn">Nouvelle réponse MDPH</button></p>
535
            {% for response in object.mdph_responses.all %}
536
                <div class="subframe">
537
                Du <strong>{{ response.start_date }}</strong> au <strong>{{ response.end_date }}</strong> à la MDPH <strong>{{ response.mdph }}</strong>
538
                <div class="buttons">
539
                    <button type="button" data-id="{{ response.id }}" class="del-mdph-response icon-minus" title="Supprimer"></button>
540
                    <button type="button" data-id="{{ response.id }}" class="update-mdph-response-btn icon-edit" title="Modifier"></button>
541
                </div>
542
                <div>
543
                    <ul>
544
                        {% if response.comment %}<li><label>Commentaire</label> : {{ response.comment }}</li>{% endif %}
545
                        {% if response.type_aide %}<li><label>Type d'aide</label> : {{ response.type_aide }}</li>{% endif %}
546
                        {% if response.name %}<li><label>Nom</label> : {{ response.name }}</li>{% endif %}
547
                        {% if response.rate %}<li><label>Taux</label> : {{ response.rate }}</li>{% endif %}
548
                    </ul>
549
                </div>
550
                </div>
551
            {% endfor %}
552
        </div>
553
    </div>
554

    
555
    <div id="tabs-8">
556
        <form method="post" id="physiology-form" class="patientrecordform">
557
          {% csrf_token %}
558
            <button class="save enable-on-change">Enregistrer</button>
559
            {% for field in forms.physiology %}
560
            <p>
561
                {{ field.errors }}
562
            </p>
563
            <p>
564
                {{ field.label_tag  }}
565
                {{ field }}
566
            </p>
567
            {% endfor %}
568
            </p>
569
            <input type="hidden"  name="tab"  value="7">
570
            <button class="save enable-on-change">Enregistrer</button>
571
        </form>
572
    </div>
573
  </div>
574
</div>
575
{% endblock %}
576

    
577
{% block dialogs %}
578
<div id="ajax-dlg" style="display: none;"></div>
579
<div id="change-record" style="display: none;" data-id="{{ object.id }}" data-service-id="{{ service_id }}">
580
 </div>
581

    
582
  <div id="dossier-histo-dlg" style="display: none;">
583
   <dl>
584
    {% for state in states %}
585
    <dt><b>{{ state.date_selected|date:"d/m/Y" }}</b> <!--<small>(date info: {{ state.created|date:"d/m/Y" }})</small>-->
586
      <button data-id="{{ state.id }}" class="update-patient-state-btn icon-edit" title="Modifier"></button>
587
      <button data-id="{{ state.id }}" class="del-patient-state-btn icon-remove"></button>
588
    </dt>
589
    <dd>
590
    <p><b>{{ state.status.name }}</b>{% if state.comment %}; <label>commentaire:</label> {{ state.comment }}{% endif %}</p>
591
    </dd>
592
    <dd class="edit-histo-item" style="display: none;">
593

    
594
<form action="{{ request.get_full_path }}/../update-state" method="post">
595
  <input type="hidden" name="state_id" value="{{ state.id }}"/>
596
  {% csrf_token %}
597
   <p>
598
   <label for="id_date">Date :</label>
599
   {{ form.date.errors }}
600
   <input id="id_date" class="date" name="date" value="{{ state.created|date:"d/m/Y" }}"/>
601
   </p>
602
   <p>
603
    <label for="id_comment">Commentaire :</label>
604
    <textarea id="id_comment" style="width: 90%;" name="comment">{% if state.comment %}{{ state.comment }}{% endif %}</textarea>
605
   </p>
606
   <button>Modifier</button>
607
 </form>
608

    
609
    </dd>
610
    {% endfor%}
611
   </dl>
612
  </div>
613

    
614

    
615

    
616
  <div id="add-prise-en-charge-dlg" style="display: none;">
617
   <div>
618
    <label for="id_partir">À partir du :</label>
619
    <input id="id_partir" class="partir" name="partir" size="10" value="11/06/2012"/>
620
   </div>
621
   <div>
622
    <label for="id_pour">Pour :</label>
623
    <input id="id_pour" class="pour" name="pour" size="4" value="30"/> séances
624
   </div>
625
  </div>
626

    
627
  <div id="add-prolongation-dlg" style="display: none;">
628
   <div>
629
    <label for="id_pour">Pour :</label>
630
    <input id="id_pour" class="pour" name="pour" size="4" value="10"/> actes
631
   </div>
632
  </div>
633

    
634
<div id="finaccueil-patientrecord-dialog" title="Patient en fin d'accueil">
635
  <div id="finaccueil-patientrecord-dialog-content">
636
  </div>
637
  <form method="post" action="finaccueil-patientrecord/">
638
    {% csrf_token %}
639
    <input type="hidden" name="Close" value="1">
640
  </form>
641
</div>
642

    
643
{% endblock %}
(15-15/19)