mirror of
https://github.com/freedombox/FreedomBox.git
synced 2026-11-29 08:25:10 +00:00
frontpage: Show config options only to admins
This commit is contained in:
1 parent
b0321d7d29
commit
0f3189c6bd
2 files changed
+3
-2
No files matched your search
@@ -76,7 +76,7 @@
|
||||
{% endfor %}
|
||||
<br>
|
||||
|
||||
{% if user.is_authenticated and configure_url %}
|
||||
{% if user.is_authenticated and user_is_admin and configure_url %}
|
||||
<a class="btn btn-primary btn-sm"
|
||||
style="margin-left : 10px; margin-bottom : 5px"
|
||||
href="{{ configure_url }}">
|
||||
|
||||
+2
-1
@@ -50,7 +50,8 @@ def index(request):
|
||||
'selected_id': selection,
|
||||
'details': details,
|
||||
'details_label': details_label,
|
||||
'configure_url': configure_url })
|
||||
'configure_url': configure_url,
|
||||
'user_is_admin': request.user.groups.filter(name='admin').exists()})
|
||||
|
||||
|
||||
class ServiceView(FormView):
|
||||
|
||||
Reference in new issue
Block a user