Ultron/templates/search/results.html

84 lines
3.0 KiB
HTML
Raw Normal View History

2021-11-12 08:11:59 +01:00
{% extends "base.html" %}
<!-- {% block page_title %}.: Search results :.{% endblock %} -->
{% block title %}Search results{% endblock %}
{% block content %}
<div class="card mb-0">
{% if jumper_list or skill_list %}
{% if jumper_list %}
<div class="card-header">
<h4 class="card-title"> Jumper's results</h4>
</div>
<div class="card-body">
<div class="table-responsive">
<table class="table" data-sort="table">
<thead>
<tr>
<th></th>
<th>Lastname</th>
<th>Firsname</th>
<th>Age</th>
<th>Gender</th>
</tr>
</thead>
<tbody>
{% for jumper in jumper_list %}
<tr>
<td>
</td>
<td><a href="{% url 'jumper_details' jumper.id %}">{{ jumper.last_name }}</a></td>
<td><a href="{% url 'jumper_details' jumper.id %}">{{ jumper.first_name }}</a></td>
<td>{{ jumper.age }}</td>
<td>{{ jumper.get_gender_display }}</td>
</tr>
{% endfor %}
</tbody>
</table>
</div>
{% endif %}
{% if skill_list %}
<div class="card-header">
<h4 class="card-title"> Skill's results</h4>
</div>
<div class="card-body">
<div class="table-responsive">
<table class="table" data-sort="table">
<thead>
<tr>
<th class="text-left">Label</th>
<th class="text-center">Notation</th>
<th class="header text-center">Diff.</th>
<th class="header text-center">Level</th>
<th class="header text-center">Rank</th>
</tr>
</thead>
<tbody>
{% for skill in skill_list %}
<tr>
<td class="text-left">&nbsp;<a href="{% url 'skill_details' skill.id %}">{{ skill.short_label }}</a></td>
<td class="text-center">{{ skill.numeric_notation }}</td>
<td class="text-center">{{ skill.difficulty }}</td>
<td class="text-center">{{ skill.level }}</td>
<td class="text-center">{{ skill.rank }}</td>
</tr>
{% endfor %}
</tbody>
</table>
</div>
</div>
{% endif %}
{% else %}
<div class="card-header">
<h4 class="card-title"> Search results</h4>
</div>
<div class="card-body">
<p>There are no items corresponding to your criterias</p>
</div>
{% endif %}
{% endblock %}