From 99473feb2c4ee4def0a659fd92a08761ff8bd50c Mon Sep 17 00:00:00 2001 From: Jakub Onderka Date: Thu, 29 Sep 2022 14:29:43 +0200 Subject: [PATCH] chg: [ACL] Warninglist::checkValue is available for all --- app/Controller/Component/ACLComponent.php | 2 +- app/View/Warninglists/view.ctp | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/app/Controller/Component/ACLComponent.php b/app/Controller/Component/ACLComponent.php index 791e248a2..dfd13fbd3 100644 --- a/app/Controller/Component/ACLComponent.php +++ b/app/Controller/Component/ACLComponent.php @@ -778,7 +778,7 @@ class ACLComponent extends Component 'eventIndexColumnToggle' => ['*'], ), 'warninglists' => array( - 'checkValue' => array('perm_auth'), + 'checkValue' => ['*'], 'delete' => ['perm_warninglist'], 'enableWarninglist' => ['perm_warninglist'], 'getToggleField' => ['perm_warninglist'], diff --git a/app/View/Warninglists/view.ctp b/app/View/Warninglists/view.ctp index abd701275..c51b159be 100644 --- a/app/View/Warninglists/view.ctp +++ b/app/View/Warninglists/view.ctp @@ -12,14 +12,14 @@ array( 'key' => __('Enabled'), 'boolean' => $data['enabled'], - 'html' => sprintf( + 'html' => $me['Role']['perm_warninglist'] ? sprintf( ' %s', $baseurl, h($warninglist['Warninglist']['id']), $data['enabled'] ? '' : '/1', $data['enabled'] ? __('Disable') : __('Enable'), $data['enabled'] ? __('Disable') : __('Enable') - ) + ): '', ), ); @@ -37,7 +37,7 @@ '
%s

%s

', sprintf( '

%s

%s', - h(mb_strtoupper($warninglist['Warninglist']['name'])), + h($warninglist['Warninglist']['name']), $this->element('genericElements/viewMetaTable', array('table_data' => $table_data)) ), __('Values')