mirror of
https://github.com/ae-utbm/sith.git
synced 2025-07-04 17:15:17 +00:00
Fix empty tools category on tools page
This commit is contained in:
parent
33d9e024a2
commit
4c921549c2
@ -34,6 +34,15 @@
|
||||
</div>
|
||||
{% endif %}
|
||||
|
||||
{% set isAdminOnACounter = false %}
|
||||
{% for b in settings.SITH_COUNTER_BARS if user.is_in_group(b[1] + " admin") %}
|
||||
{% set isAdminOnACounter = true %}
|
||||
{% endfor %}
|
||||
|
||||
{% if
|
||||
user.is_in_group(settings.SITH_GROUP_COUNTER_ADMIN_ID) or user.is_root
|
||||
or isAdminOnACounter
|
||||
%}
|
||||
<div>
|
||||
<h4>{% trans %}Counters{% endtrans %}</h4>
|
||||
<ul>
|
||||
@ -63,6 +72,12 @@
|
||||
{% endfor %}
|
||||
</ul>
|
||||
</div>
|
||||
{% endif %}
|
||||
|
||||
{% if
|
||||
user.is_in_group(settings.SITH_GROUP_ACCOUNTING_ADMIN_ID) or user.is_root
|
||||
or user.memberships.filter(end_date=None).filter(role__gte=7).all() | length > 10
|
||||
%}
|
||||
<div>
|
||||
<h4>{% trans %}Accounting{% endtrans %}</h4>
|
||||
<ul>
|
||||
@ -91,6 +106,8 @@
|
||||
{%- endfor %}
|
||||
</ul>
|
||||
</div>
|
||||
{% endif %}
|
||||
|
||||
{% if user.is_in_group(settings.SITH_GROUP_SAS_ADMIN_ID) or user.is_in_group(settings.SITH_GROUP_COM_ADMIN_ID) or user.is_root %}
|
||||
<div>
|
||||
<h4>{% trans %}Communication{% endtrans %}</h4>
|
||||
|
Loading…
x
Reference in New Issue
Block a user