Criando urls dinâmicas no Django URL Dispatcher, view e template

This commit is contained in:
Luiz Otávio
2023-04-27 09:19:51 -03:00
parent b03360b1f8
commit 30a5ee9381
3 changed files with 23 additions and 1 deletions

View File

@@ -1,6 +1,10 @@
<article class="post">
<header>
<h2 class="post__title">{{ post.title }}</h2>
<h2 class="post__title">
<a href="{% url 'blog:post' post.id %}">
{{ post.title }}
</a>
</h2>
</header>
<div class="post__body">{{ post.body }}</div>
</article>