matrix.html

22 Zeilen · 1,3 KB · HTML
Rohdatei
{% extends 'base.html' %}
{% block title %}Qualifikationsmatrix{% endblock %}
{% block content %}
<div class="page-head"><h1>Qualifikationen &amp; Unterweisungen</h1>
  <div class="actions"><a class="btn" href="/personal/uebersicht/typen">Arten verwalten</a><button type="button" onclick="window.print()">Drucken</button></div></div>
<p class="muted no-print"><span class="dot ok"></span> gültig &nbsp; <span class="dot soon"></span> läuft bald ab &nbsp; <span class="dot overdue"></span> abgelaufen / Pflicht fehlt &nbsp; <span class="dot"></span> nicht vorhanden</p>
<div class="panel flush table-wrap">
  <table class="matrix">
    <thead><tr><th>Mitarbeiter/in</th>{% for t in types %}<th title="{{ t.description or '' }}">{{ t.name }}{% if t.validity_months %}<br><small>{{ t.validity_months }} Mon.</small>{% endif %}</th>{% endfor %}</tr></thead>
    <tbody>
    {% for u in users %}
    <tr><td><a href="/personal/{{ u.id }}"><b>{{ u.full_name }}</b></a><br><small>{{ u.job_title or '' }}</small></td>
      {% for t in types %}{% set c = cells[(u.id, t.id)] %}
      <td class="cell-{{ c.status }}">
        {% if c.q %}{{ (c.q.valid_until|d) if c.q.valid_until else '✔' }}{% elif c.status == 'missing' %}fehlt{% else %}·{% endif %}
      </td>{% endfor %}
    </tr>
    {% endfor %}
    </tbody>
  </table>
</div>
{% endblock %}