<thead>
  <tr>
    <th colspan="2">N° dossier
    </th><th rowspan="2">Nom</th>
    <th rowspan="2">Prénom</th>
    <th rowspan="2">Position</th>
    <th rowspan="2">Date d'accueil</th>
    <th rowspan="2">Prochain rendez-vous</th>
    <th rowspan="2">Intervenant(s)</th>
    <th rowspan="2">Commentaire</th>
  </tr>
  <tr>
    <th>papier</th>
    <th>inform.</th>
  </tr>
</thead>
<tbody>

  {% for patient_record in patient_records %}
  <tr style="display: table-row;" class="pr-line {{ patient_record.state_class }}" data-link="{{ patient_record.object.id }}/view">
      <td>{{ patient_record.object.paper_id|default_if_none:"" }}</td>
      <td>{{ patient_record.object.id }}</td>
      <td><span class="lastname">{{ patient_record.object.last_name }}</span></td>
      <td>{{ patient_record.object.first_name }}</td>
      <td>{{ patient_record.position }}</td>
      <td>{{ patient_record.object.last_state.date_selected|date:"SHORT_DATE_FORMAT" }}</td>
      <td>{{ patient_record.object.get_next_rdv.start_datetime|date:"d/m/Y H:i" }} {{ patient_record.object.get_next_rdv.act_type }}</td>
      <td>{% for participant in patient_record.object.get_next_rdv.participants.all %}{{ participant.last_name }} {% endfor %}</td>
      <td>{{ patient_record.object.last_state.comment|default_if_none:"" }}</td>
  </tr>
  {% endfor %}

</tbody>
