Basics to view threads

This commit is contained in:
David Hoppenbrouwers
2022-10-07 13:18:19 +02:00
commit d72fd14c92
11 changed files with 247 additions and 0 deletions

19
templates/thread.html Normal file
View File

@@ -0,0 +1,19 @@
{% extends 'base.html' %}
{% macro render_comment(comment) %}
<div style="margin-left:20px">
<p><i>{{ comment.author }}</i></p>
<p>{{ comment.text }}</p>
{% for c in comment.children %}
{{ render_comment(c) }}
{% endfor %}
</div>
{% endmacro %}
{% block content %}
<p>{{ author }} - rjgoire</p>
<p>{{ text }}</p>
{% for c in comments %}
{{ render_comment(c) }}
{% endfor %}
{% endblock %}