Skip to content

Commit

Permalink
2.63.3 Fixes for status message clearing on admin pages
Browse files Browse the repository at this point in the history
  • Loading branch information
classaxe committed Mar 6, 2024
1 parent fe5ff5d commit 9a32930
Show file tree
Hide file tree
Showing 8 changed files with 27 additions and 1 deletion.
4 changes: 4 additions & 0 deletions src/Controller/Web/Admin/Help.php
Expand Up @@ -28,7 +28,11 @@ public function adminHelpController(
$this->session->set('route', 'admin/help');
return $this->redirectToRoute('logon', ['system' => $system]);
}

$this->session->set('route', '');
$this->session->set('lastMessage', '');
$this->session->set('lastError', '');

$parameters = [
'_locale' => $_locale,
'mode' => 'Admin Help',
Expand Down
5 changes: 5 additions & 0 deletions src/Controller/Web/Admin/Info.php
Expand Up @@ -33,6 +33,11 @@ public function controller(
$this->session->set('route', 'admin/info');
return $this->redirectToRoute('logon', ['system' => $system]);
}

$this->session->set('route', '');
$this->session->set('lastMessage', '');
$this->session->set('lastError', '');

$parameters = [
'_locale' => $_locale,
'mode' => 'System Info',
Expand Down
4 changes: 4 additions & 0 deletions src/Controller/Web/Donations/Collection.php
Expand Up @@ -48,7 +48,11 @@ public function index(
}
throw $this->createAccessDeniedException('You do not have access to this page');
}

$this->session->set('route', '');
$this->session->set('lastMessage', '');
$this->session->set('lastError', '');

$args = [
'limit' => static::defaultlimit,
'order' => static::defaultOrder,
Expand Down
4 changes: 4 additions & 0 deletions src/Controller/Web/Donors/Collection.php
Expand Up @@ -48,7 +48,11 @@ public function index(
}
throw $this->createAccessDeniedException('You do not have access to this page');
}

$this->session->set('route', '');
$this->session->set('lastMessage', '');
$this->session->set('lastError', '');

$args = [
'limit' => static::defaultlimit,
'order' => static::defaultOrder,
Expand Down
6 changes: 5 additions & 1 deletion src/Controller/Web/Users/Collection.php
Expand Up @@ -41,10 +41,14 @@ public function users(
Form $form
) {
if (!((int)$this->parameters['access'] & UserEntity::MASTER)) {
$this->session->set('route', 'admin/info');
$this->session->set('route', 'users');
return $this->redirectToRoute('logon', ['system' => $system]);
}

$this->session->set('route', '');
$this->session->set('lastMessage', '');
$this->session->set('lastError', '');

$args = [
'limit' => static::defaultlimit,
'order' => static::defaultOrder,
Expand Down
3 changes: 3 additions & 0 deletions src/Controller/Web/Users/YourProfile.php
Expand Up @@ -46,6 +46,9 @@ public function profile(
}

$this->session->set('route', '');
$this->session->set('lastMessage', '');
$this->session->set('lastError', '');

$id = $this->session->get('user_id');
if (!$user = $this->getValidUser($id)) {
throw $this->createAccessDeniedException('You do not have access to this page');
Expand Down
1 change: 1 addition & 0 deletions templates/admin/help/index.html.twig
Expand Up @@ -10,6 +10,7 @@
]
</div>
<h1>Administrator Help</h1>
{% include 'status.html.twig' %}
<p>This page extends from the standard help available to all users.</p>

<h2 class="margin-top-2" id="listenerEdit">Editing Listener Details <small>[ <a href='#top'><strong>Top</strong></a> ]</small></h2>
Expand Down
1 change: 1 addition & 0 deletions templates/admin/info/index.html.twig
Expand Up @@ -4,6 +4,7 @@
<div class="main">
<h1>{{ mode | trans }}</h1>
</div>
{% include 'status.html.twig' %}
<div id='sysinfo'>
<table border="0" cellpadding="3">
<tr class='h'>
Expand Down

0 comments on commit 9a32930

Please sign in to comment.