recettes/templates/recette.html

27 lines
579 B
HTML
Raw Normal View History

2018-05-26 16:01:04 +02:00
{% extends 'base.html' %}
{% block content %}
<h1>{{ recette.nom }}</h1>
2018-05-27 11:48:40 +02:00
<div>{{ recette.prep|linebreaksbr }}</div>
2018-05-26 16:01:04 +02:00
{% if recette.ingredients.count %}
2018-05-27 12:01:15 +02:00
<div class="ingredients">
2018-05-27 11:48:40 +02:00
<h2>Ingrédients</h2>
2018-05-26 16:01:04 +02:00
<ul>
{% for comp in recette.ingredients.all %}
<li>{{ comp }}</li>
{% endfor %}
</ul>
2018-05-27 12:01:15 +02:00
</div>
{% endif %}
{% if recette.photo %}
<div class="photo"><img src="{{ recette.photo.url }}"></div>
2018-05-26 16:01:04 +02:00
{% endif %}
{% endblock %}
2018-05-26 16:55:07 +02:00
{% block footer %}
<div style="text-align: right;"><a href="{% url 'admin:recette_recette_change' recette.pk %}">Modifier</a></div>
{% endblock %}