Add program_table.html template
This commit is contained in:
parent
f1aa2ad418
commit
59356a783f
1 changed files with 48 additions and 0 deletions
48
publichealth/home/templates/home/program_table.html
Normal file
48
publichealth/home/templates/home/program_table.html
Normal file
|
@ -0,0 +1,48 @@
|
|||
<table class="table-program">
|
||||
{% if table_header %}
|
||||
<thead>
|
||||
<tr>
|
||||
{% for column in table_header %}
|
||||
<th>
|
||||
{% if column.strip %}
|
||||
{% if html_renderer %}
|
||||
{{ column.strip|safe|linebreaksbr }}
|
||||
{% else %}
|
||||
{{ column.strip|linebreaksbr }}
|
||||
{% endif %}
|
||||
{% endif %}
|
||||
</th>
|
||||
{% endfor %}
|
||||
</tr>
|
||||
</thead>
|
||||
{% endif %}
|
||||
<tbody>
|
||||
{% for row in data %}
|
||||
<tr>
|
||||
{% for column in row %}
|
||||
{% if first_col_is_header and forloop.first %}
|
||||
<th>
|
||||
{% if column.strip %}
|
||||
{% if html_renderer %}
|
||||
{{ column.strip|safe|linebreaksbr }}
|
||||
{% else %}
|
||||
{{ column.strip|linebreaksbr }}
|
||||
{% endif %}
|
||||
{% endif %}
|
||||
</th>
|
||||
{% else %}
|
||||
<td>
|
||||
{% if column.strip %}
|
||||
{% if html_renderer %}
|
||||
{{ column.strip|safe|linebreaksbr }}
|
||||
{% else %}
|
||||
{{ column.strip|linebreaksbr }}
|
||||
{% endif %}
|
||||
{% endif %}
|
||||
</td>
|
||||
{% endif %}
|
||||
{% endfor %}
|
||||
</tr>
|
||||
{% endfor %}
|
||||
</tbody>
|
||||
</table>
|
Loading…
Reference in a new issue