projects.html 1.11 KB
{% extends "base_page.html" %}

{% block more_heads %}
    <link rel="stylesheet" type="text/css" href="{{ url_for('static', filename='lib/datatables-1.10.24/css/buttons.dataTables.min.css') }}"/>
    <link rel="stylesheet" type="text/css" href="{{ url_for('static', filename='lib/datatables-1.10.24/css/datatables.min.css') }}"/>
{% endblock %}

{% block content %}

<!-- Invisible span to definte wich ul and a in the navbar are actived -->
<span id="nav_actived" style="display: none">project,projects</span>

<table id="table_datatables" class="table table-hover">
  <thead>
  <tr>
    {% for c_title in projects[0][1:] %}
    <th scope="col">{{c_title}}</th>
    {% endfor %}
  </tr>
  </thead>
  <tbody>
  {% for project in projects[1:] %}
  <tr>
    <td><a href="{{url_for('main.project', project_id=project[0])}}">
      {{ project[1] }}</a>
    </td>
    {#the category cells#}
    {% for c in project[2:-1] %}
    <td>{{c|join(',')}}</td>
    {% endfor %}
    <td>{{ project[-1] /100}}</td>
  </tr>
  {% endfor %}
  </tbody>
</table>
{% endblock %}

{% block more_scripts %}
{% include 'datatables-includes.html' %}
{% endblock %}