mirror of
https://github.com/minetest/contentdb.git
synced 2025-01-24 06:51:29 +01:00
Fix non-editors seeing create buttons for topics
This commit is contained in:
parent
272be09ba1
commit
f5744f5188
@ -23,10 +23,12 @@
|
|||||||
<td>{{ topic.name or ""}}</td>
|
<td>{{ topic.name or ""}}</td>
|
||||||
<td>{{ topic.created_at | date }}</td>
|
<td>{{ topic.created_at | date }}</td>
|
||||||
<td class="btn-group">
|
<td class="btn-group">
|
||||||
<a class="btn btn-primary"
|
{% if topic.author.checkPerm(current_user, "CHANGE_AUTHOR") %}
|
||||||
href="{{ url_for('create_edit_package_page', author=topic.author.username, repo=topic.getRepoURL(), forums=topic.topic_id, title=topic.title, bname=topic.name) }}">
|
<a class="btn btn-primary"
|
||||||
Create
|
href="{{ url_for('create_edit_package_page', author=topic.author.username, repo=topic.getRepoURL(), forums=topic.topic_id, title=topic.title, bname=topic.name) }}">
|
||||||
</a>
|
Create
|
||||||
|
</a>
|
||||||
|
{% endif %}
|
||||||
{% if show_discard and current_user.is_authenticated and topic.checkPerm(current_user, "TOPIC_DISCARD") %}
|
{% if show_discard and current_user.is_authenticated and topic.checkPerm(current_user, "TOPIC_DISCARD") %}
|
||||||
<a class="btn btn-{% if topic.discarded %}success{% else %}danger{% endif %} topic-discard" data-tid={{ topic.topic_id }}>
|
<a class="btn btn-{% if topic.discarded %}success{% else %}danger{% endif %} topic-discard" data-tid={{ topic.topic_id }}>
|
||||||
{% if topic.discarded %}
|
{% if topic.discarded %}
|
||||||
|
Loading…
Reference in New Issue
Block a user