manager: update appbar actions to new markup (#25960)

This commit is contained in:
Frédéric Péters 2018-08-21 07:30:06 +02:00
parent 8000a00cb9
commit 3b88db2cfc
8 changed files with 16 additions and 0 deletions

View File

@ -7,11 +7,13 @@
{% block appbar %}
<h2>{% blocktrans %}Here you can manage objects related to organizational units, users, roles and applications.{% endblocktrans %}</h2>
{% if user.is_superuser %}
<span class="actions">
<a class="extra-actions-menu-opener"></a>
<ul class="extra-actions-menu">
<li><a href="{% url 'a2-manager-site-export' %}">{% trans 'Export Site' %}</a></li>
<li><a href="{% url 'a2-manager-site-import' %}">{% trans 'Import Site' %}</a></li>
</ul>
</span>
{% endif %}
{% endblock %}

View File

@ -16,6 +16,7 @@
{% block appbar %}
{{ block.super }}
<span class="actions">
{% if view.can_delete %}
<a rel="popup" href="{% url "a2-manager-ou-delete" pk=object.pk %}">{% trans "Delete" %}</a>
{% else %}
@ -27,4 +28,5 @@
{% else %}
<a class="disabled" title="{% trans "You do not have the rights to edit this organizational unit." %}" href="#">{% trans "Edit" %}</a>
{% endif %}
</span>
{% endblock %}

View File

@ -9,9 +9,11 @@
{% block appbar %}
{{ block.super }}
<span class="actions">
{% if view.can_add %}
<a href="{% url "a2-manager-ou-add" %}" rel="popup">{% trans "Add organizational unit" %}</a>
{% endif %}
</span>
{% endblock %}
{% block sidebar %}

View File

@ -18,6 +18,7 @@
{% block appbar %}
{{ block.super }}
<span class="actions">
{% if not object.is_internal and view.can_delete %}
<a rel="popup" href="{% url "a2-manager-role-delete" pk=object.pk %}">{% trans "Delete" %}</a>
{% else %}
@ -35,6 +36,7 @@
{% if perms.a2_rbac.admin_permission %}
<a href="{% url "a2-manager-role-permissions" pk=object.pk %}">{% trans "Permissions" %}</a>
{% endif %}
</span>
{% endblock %}

View File

@ -9,6 +9,7 @@
{% block appbar %}
{{ block.super }}
<span class="actions">
{% if view.can_delete %}
<a rel="popup" href="{% url "a2-manager-role-delete" pk=object.pk %}">{% trans "Delete" %}</a>
{% endif %}
@ -16,6 +17,7 @@
<a href="{% url "a2-manager-role-edit" pk=object.pk %}">{% trans "Edit" %}</a>
{% endif %}
<a href="{% url "a2-manager-role-members" pk=object.pk %}">{% trans "Members" %}</a>
</span>
{% endblock %}
{% block main %}

View File

@ -5,11 +5,13 @@
{% block appbar %}
{{ block.super }}
<span class="actions">
{% if view.can_add %}
<a href="{% url "a2-manager-role-add" %}" rel="popup">{% trans "Add role" %}</a>
{% else %}
<a href="#" class="disabled" rel="popup">{% trans "Add role" %}</a>
{% endif %}
</span>
{% endblock %}
{% block sidebar %}

View File

@ -5,6 +5,7 @@
{% block appbar %}
{{ block.super }}
<span class="actions">
{% if view.can_delete %}
<a rel="popup" href="{% url "a2-manager-user-delete" pk=object.pk %}">{% trans "Delete" %}</a>
{% else %}
@ -16,6 +17,7 @@
{% else %}
<a class="disabled" title="{% trans "You do not have the rights to edit this user." %}" href="#">{% trans "Edit" %}</a>
{% endif %}
</span>
{% endblock %}
{% block breadcrumb %}

View File

@ -5,6 +5,7 @@
{% block appbar %}
{{ block.super }}
<span class="actions">
{% if add_ou %}
<a
href="{% url "a2-manager-user-add" ou_pk=add_ou.pk %}"
@ -19,6 +20,7 @@
{% trans "Add user" %}
</a>
{% endif %}
</span>
{% endblock %}
{% block breadcrumb %}