recettes/templates/index.html

20 lines
412 B
HTML
Raw Normal View History

2018-05-26 16:01:04 +02:00
{% extends 'base.html' %}
{% block content %}
<h1>Recettes</h1>
<form method="POST">{% csrf_token %}
{{ form.as_p }}
<button>Rechercher</button>
</form>
2018-05-27 11:22:55 +02:00
{% if num_results is not None %}
<div class="results">{{ num_results }} résultat(s)</div>
{% endif %}
2018-05-26 16:01:04 +02:00
<ul>
{% for recette in recettes %}
<li><a href="{{ recette.get_absolute_url }}">{{ recette.nom }}</a></li>
{% endfor %}
</ul>
{% endblock %}