mirror of
https://github.com/getgrav/grav-plugin-admin.git
synced 2026-05-07 18:26:08 +02:00
Fixed changelog button showing up in Info page even if user cannot access it
This commit is contained in:
@@ -15,6 +15,7 @@
|
||||
* Fixed deleting list field options completely, didn't save changes [#2056](https://github.com/getgrav/grav-plugin-admin/issues/2056)
|
||||
* Fixed `onAdminAfterAddMedia` and `onAdminAfterDelMedia` events always pointing to the home page
|
||||
* Fixed ACL for Configuration tabs [#771](https://github.com/getgrav/grav-plugin-admin/issues/771)
|
||||
* Fixed changelog button showing up in Info page even if user cannot access it
|
||||
|
||||
# v1.10.3
|
||||
## 02/01/2021
|
||||
|
||||
@@ -52,12 +52,15 @@
|
||||
{% endblock %}
|
||||
|
||||
{% block content %}
|
||||
{% set accessChangelog = authorize(['admin.maintenance', 'admin.super']) %}
|
||||
{% if config_slug in configurations %}
|
||||
{% if isInfo %}
|
||||
<div id="phpinfo">
|
||||
{% if accessChangelog %}
|
||||
<div style="margin-left:1.5rem">
|
||||
<a class="button button-big" href="#" style="text-align: center;" data-remodal-target="changelog" data-remodal-changelog="{{ admin_route('/changelog/type:plugins/slug:' ~ plugin.slug) }}"><i class="fa fa-binoculars"></i> View Grav Changelog</a>
|
||||
</div>
|
||||
{% endif %}
|
||||
{{ admin.phpinfo|raw }}
|
||||
</div>
|
||||
{% else %}
|
||||
@@ -66,7 +69,9 @@
|
||||
</div>
|
||||
{% endif %}
|
||||
{% include 'partials/modal-changes-detected.html.twig' %}
|
||||
{% if accessChangelog %}
|
||||
{% include 'partials/modal-changelog.html.twig' %}
|
||||
{% endif %}
|
||||
{% else %}
|
||||
{% do page.modifyHeader('http_response_code', 404) %}
|
||||
<div class="config-wrapper">
|
||||
|
||||
Reference in New Issue
Block a user