This commit is contained in:
2025-04-22 15:37:22 +01:00
parent 9760fc88e4
commit e9dc5e5056
9 changed files with 126 additions and 42 deletions

View File

@@ -7,8 +7,15 @@
<h6><b>ref post:</b> <a href="/posts/{{ post.reference.id }}">{{ post.reference.content }}</a></h6>
{% endif %}
<p>{{ post.content }}</p>
{% if session.name == "SYSTEM" %}
<h6><a href="/delete/post/{{ post.id }}">Delete</a></h6>
{% elif session.name == post.user.name %}
<h6><a href="/delete/post/{{ post.id }}">Delete</a></h6>
{% endif %}
<br>
<h3>Replies:</h3>
<ul class="posts">
{% for reply in post.replies %}
<li>
@@ -16,11 +23,10 @@
<h6>posted at {{ reply.created_at }}</h6>
<p>{{ reply.short_content }}</p>
<h6><a href="/posts/{{ reply.id }}">View Reply</a>
{% if post.replies|length > 0 %}
| ({{ post.replies|length }} replies)
{% endif %}
{% if session.name == "SYSTEM" %}
| <a href="/delete/post/{{ post.id }}">Delete</a>
| <a href="/delete/post/{{ reply.id }}">Delete</a>
{% elif session.name == post.user.name %}
| <a href="/delete/post/{{ reply.id }}">Delete</a>
{% endif %}
</h6>
</li>