From 8bd174c4216e5628fd61bc7852fc0104e9ed6cb5 Mon Sep 17 00:00:00 2001 From: Ioannis Igoumenos Date: Wed, 3 Apr 2024 16:35:43 +0300 Subject: [PATCH] Move code at sidebar.ctp file --- Lib/lang.php | 4 ++- View/Elements/ActAsPeopleAutocomplete.ctp | 3 ++ View/Elements/ActionSideBar.ctp | 33 ++++++++++++++++- View/GrouperGroups/index.ctp | 43 ++++++----------------- 4 files changed, 48 insertions(+), 35 deletions(-) diff --git a/Lib/lang.php b/Lib/lang.php index 22fab32..11bccc5 100644 --- a/Lib/lang.php +++ b/Lib/lang.php @@ -126,8 +126,10 @@ 'pl.grouperlite.action.close' => 'Close', 'pl.grouperlite.action.clear' => 'Clear', 'pl.grouperlite.action.add-user' => 'Add', + 'pl.grouperlite.action.act-as' => 'Act As', 'pl.grouperlite.action.remove-user' => 'Remove', - 'pl.grouperlite.action.enable-act-as' => 'Enable', + 'pl.grouperlite.action.enable' => 'Enable', + 'pl.grouperlite.action.find' => 'Find', 'pl.grouperlite.message.user-not-found-error' => 'Error: User not found.', 'pl.grouperlite.message.user-not-added-error' => 'Error: Unable to add user.', 'pl.grouperlite.message.user-not-removed-error' => 'Error: Unable to remove user.', diff --git a/View/Elements/ActAsPeopleAutocomplete.ctp b/View/Elements/ActAsPeopleAutocomplete.ctp index 46d5180..c650022 100644 --- a/View/Elements/ActAsPeopleAutocomplete.ctp +++ b/View/Elements/ActAsPeopleAutocomplete.ctp @@ -21,6 +21,9 @@ $suffix = Configure::read('debug') > 0 ? '?time=' . time() : ''; url: "", grouperUrl: "", view: "action ?>", + hasActAs: , + actAsPerson: , + permissions: , txt: { adhocHeading: "", wgHeading: "", diff --git a/View/Elements/ActionSideBar.ctp b/View/Elements/ActionSideBar.ctp index a4abe2d..3c8898d 100644 --- a/View/Elements/ActionSideBar.ctp +++ b/View/Elements/ActionSideBar.ctp @@ -1,2 +1,33 @@ - + + + diff --git a/View/GrouperGroups/index.ctp b/View/GrouperGroups/index.ctp index 00a2e3e..0dc3b5e 100644 --- a/View/GrouperGroups/index.ctp +++ b/View/GrouperGroups/index.ctp @@ -71,6 +71,9 @@ $suffix = Configure::read('debug') > 0 ? '?time=' . time() : ''; url: "", grouperUrl: "", view: "action ?>", + hasActAs: , + actAsPerson: , + permissions: , txt: { adhocHeading: "", wgHeading: "", @@ -124,7 +127,6 @@ $suffix = Configure::read('debug') > 0 ? '?time=' . time() : ''; JSON_THROW_ON_ERROR) ?>, }, api: { - permissions: , co: , glid: , mode: "", @@ -158,37 +160,12 @@ $suffix = Configure::read('debug') > 0 ? '?time=' . time() : ''; - + element('ActionSideBar', + compact('vv_config', + 'vv_act_as_people', + 'vv_coid', + 'vv_is_user_owner', + 'htmlId') + ) ?> \ No newline at end of file