chg: [users:index] Added confirmation modal before changing disabled state for users

perm_community_admin
Sami Mokaddem 2024-04-02 13:51:56 +02:00
parent f4f17a1fa0
commit acb8fa21d3
No known key found for this signature in database
GPG Key ID: 164C473F627A06FA
1 changed files with 21 additions and 2 deletions

View File

@ -54,7 +54,27 @@ echo $this->element('genericElements/IndexTable/index_table', [
return true;
},
],
'skip_full_reload' => true
'skip_full_reload' => true,
'confirm' => [
'enable' => [
'titleHtml' => __('Confirm disabling the user?'),
'type' => 'confirm-warning',
'bodyHtml' => __('You\'re about to change the state of the user {{0}}.'),
'confirmText' => __('Disable user'),
'arguments' => [
'bodyHtml' => ['individual.email'],
]
],
'disable' => [
'titleHtml' => __('Confirm enabling the user?'),
'type' => 'confirm-success',
'bodyHtml' => __('You\'re about to change the state of the user {{0}}.'),
'confirmText' => __('Enable user'),
'arguments' => [
'bodyHtml' => ['individual.email'],
]
]
]
]
],
[
@ -168,5 +188,4 @@ echo $this->element('genericElements/IndexTable/index_table', [
]
]
]);
echo '</div>';
?>