{% extends 'partials/base.html.twig' %} {% if admin.route %} {% set installing = admin.route starts with 'install' %} {% set installed = true %} {# Try installed packages first, then remote #} {% set package = admin.plugins(true)[admin.route] %} {% if (not package) %} {% set package = admin.plugins(false)[admin.route] %} {% set installed = false %} {% endif %} {% set plugin = package.toArray() %} {% set title = "PLUGIN_ADMIN.PLUGIN"|tu ~ ": " ~ plugin.name|e %} {% endif %} {% block titlebar %} {% if not admin.route or installing %}
{% if (installing) %} {{ "PLUGIN_ADMIN.BACK"|tu }} {% else %} {{ "PLUGIN_ADMIN.BACK"|tu }} {{ "PLUGIN_ADMIN.ADD"|tu }} {% if authorize(['admin.maintenance', 'admin.super']) %} {% endif %} {% endif %}

{{ "PLUGIN_ADMIN.PLUGINS"|tu }}

{% else %} {% if (installed) %}
{{ "PLUGIN_ADMIN.BACK_TO_PLUGINS"|tu }}
{% else %}
{{ "PLUGIN_ADMIN.BACK_TO_PLUGINS"|tu }}
{% endif %}

{{ "PLUGIN_ADMIN.PLUGIN"|tu }}: {{ plugin.name|e }}

{% endif %} {% endblock %} {% block content %}
{% include 'partials/messages.html.twig' %} {% if not admin.route or installing %} {% include 'partials/plugins-list.html.twig' %} {% else %} {% include 'partials/plugins-details.html.twig' %} {% endif %}
{% endblock %}