🎨 topic attachments

This commit is contained in:
Greg Newman
2022-12-15 15:33:36 -05:00
parent 933a4f39af
commit 68f91f926a

View File

@@ -3,12 +3,12 @@
{% get_permission 'can_download_files' post.topic.forum request.user as user_can_download_files %}
{% if post.attachments.exists and user_can_download_files %}
<div class="row attachments">
<div class="w-full attachments space-y-4">
<div class="col-md-12">
<span class="text-muted attachments-title"><i class="fa fa-files-o"></i>&nbsp;{% trans "Attachments" %}</span>
</div>
{% for attachment in post.attachments.all %}
<div class="col-md-12 attachment">
<div class="w-full attachment">
<a href="{% url 'forum_conversation:attachment' pk=attachment.id %}"><i class="fa fa-file"></i>&nbsp;{{ attachment.filename }} ({{ attachment.file.size|filesizeformat }})</a>
{% if attachment.comment %}
<p class="text-muted"><em>{{ attachment.comment }}</em></p>