Split db::Connection implementation in submodules (db::user and db::recipe).
This commit is contained in:
parent
4248d11aa9
commit
fce4eade73
17 changed files with 1307 additions and 1234 deletions
18
backend/templates/recipe_view.html
Normal file
18
backend/templates/recipe_view.html
Normal file
|
|
@ -0,0 +1,18 @@
|
|||
{% extends "base_with_list.html" %}
|
||||
|
||||
{% block content %}
|
||||
|
||||
<h2 class="recipe-title" >{{ recipe.title }}</h2>
|
||||
|
||||
|
||||
{% if user.is_some() && recipe.user_id == user.as_ref().unwrap().id %}
|
||||
<a class="edit-recipe" href="/recipe/edit/{{ recipe.id }}" >Edit</a>
|
||||
{% endif %}
|
||||
|
||||
{% if !recipe.description.is_empty() %}
|
||||
<div class="recipe-description" >
|
||||
{{ recipe.description.clone()|markdown }}
|
||||
</div>
|
||||
{% endif %}
|
||||
|
||||
{% endblock %}
|
||||
Loading…
Add table
Add a link
Reference in a new issue