aboutsummaryrefslogtreecommitdiff
path: root/app/templates/macros
diff options
context:
space:
mode:
Diffstat (limited to 'app/templates/macros')
-rw-r--r--app/templates/macros/threads.html14
1 files changed, 13 insertions, 1 deletions
diff --git a/app/templates/macros/threads.html b/app/templates/macros/threads.html
index e94cded..21283d7 100644
--- a/app/templates/macros/threads.html
+++ b/app/templates/macros/threads.html
@@ -22,8 +22,20 @@
</div>
<div class="card-body">
+ {% if current_user == thread.author and thread.review and thread.replies[0] == r %}
+ <a class="float-right btn btn-primary btn-sm ml-2"
+ href="{{ thread.review.package.getReviewURL() }}">
+ <i class="fas fa-edit"></i>
+ </a>
+ {% elif r.checkPerm(current_user, "EDIT_REPLY") %}
+ <a class="float-right btn btn-primary btn-sm ml-2"
+ href="{{ url_for('threads.edit_reply', id=thread.id, reply=r.id) }}">
+ <i class="fas fa-edit"></i>
+ </a>
+ {% endif %}
+
{% if r.checkPerm(current_user, "DELETE_REPLY") %}
- <a class="float-right btn btn-secondary btn-sm"
+ <a class="float-right btn btn-secondary btn-sm ml-2"
href="{{ url_for('threads.delete_reply', id=thread.id, reply=r.id) }}">
<i class="fas fa-trash"></i>
</a>