Project

General

Profile

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

calebasse / calebasse / agenda / templates / agenda / act-validation.html @ a5a20700

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

    
4
{% block appbar %}
5
<h2>Validation des actes - {{ date|date:"DATE_FORMAT" }}</h2>
6
    <a href="..">Retourner à l'agenda</a>
7
    {% if day_locked %}<button id="unlock-all" data-url="{% url 'unlock-all' service=service date=date %}">Tout déverrouiller</button> {% endif %}<button id="validation-all" data-url="{% url 'validation-all' service=service date=date %}">Validation automatique</button>
8
{% endblock %}
9

    
10
{% block agenda-content %}
11
    {% if validation_msg %}
12
    <ul>
13
    {% for message in validation_msg %}
14
     <li>message</li>
15
    {% endfor %}
16
    </ul>
17
    {% endif %}
18

    
19

    
20
    {% if actes %}
21
    <div id="actes">
22
    {% for acte, last_status in actes %}
23
    <div class="frame acte" id="acte-frame-{{ acte.id }}">
24
      <h3>{{ acte.date }} - <strong>{{ acte.patient.last_name }} {{ acte.patient.first_name }}</strong>
25
          {% if acte.patient.paper_id %} ({{ acte.patient.paper_id }}){% endif %}
26
          {% if acte.doctors %}{% for doctor in acte.doctors.all %} - {{ doctor.last_name }} {{ doctor.first_name }}{% endfor %}{% endif %} - 
27
          <strong>{{ acte.act_type }}</strong>
28
          {% if acte.description %} <img title="Un commentaire existe" src="{{ STATIC_URL }}images/emblem-documents.png">{% endif%}
29
      </h3>
30
      <p>{% if last_status %}<strong>{{ last_status.state_name }}</strong>, le {{ last_status.created }} par {{ last_status.author }}
31
           {% if last_status.auto %}(par validation automatique){% endif %}.
32
         {% else %}
33
           Non pointé.
34
         {% endif %}
35
         {% if acte.validation_locked %}
36
            {% if authorized_lock %}<button>Déverrouiller</button>{% endif %}
37
         {% else %}
38
           <select name="acte_state" id="acte_state">
39
             {% for state_name, display_state_name in validation_states.items %}
40
               <option value="{{ state_name }}">{{ display_state_name }}</option>
41
             {% endfor %}
42
           </select>
43
           <button>Modifier</button>
44
           {% if authorized_lock %}
45
              {% if last_status %}<button>Verrouiller</button>{% endif %}
46
           {% endif %}
47
         {% endif %}
48
      </p>
49
    </div>
50
    {% endfor %}
51
    </div>
52
    {% else %}
53
    <p><strong>Il n'y a pas d'acte à valider le {{ date|date:"DATE_FORMAT" }}.</strong></p>
54
    {% endif %}
55
{% endblock %}
(1-1/8)