added ability to link recipes to ingredients

This commit is contained in:
vabene1111
2020-03-17 18:44:11 +01:00
parent a60b09e491
commit 90dbc36402
10 changed files with 94 additions and 6 deletions

View File

@@ -134,7 +134,13 @@
</div>
</td>
<td style="font-size: large">{{ i.ingredient.name }}</td>
<td style="font-size: large">
{% if i.ingredient.recipe %}
<a href="{% url 'view_recipe' i.ingredient.recipe.pk %}" target="_blank">{{ i.ingredient.name }}</a>
{% else %}
{{ i.ingredient.name }}
{% endif %}
</td>
</tr>
{% endfor %}
</table>