From 2a69807f7c4cb037db257e9c0be06ab6f0e51887 Mon Sep 17 00:00:00 2001 From: Ioannis Igoumenos Date: Tue, 2 Apr 2024 12:03:20 +0300 Subject: [PATCH] added peoplepicker module --- View/Elements/actAsPeopleAutocomplete.ctp | 127 ++++++++++++++++++++++ View/Elements/empty | 0 View/GrouperGroups/index.ctp | 40 +++---- webroot/css/co-grouper-base.css | 8 +- webroot/js/autocomplete.js | 1 - webroot/js/page/ActAsUser.js | 81 -------------- 6 files changed, 149 insertions(+), 108 deletions(-) create mode 100644 View/Elements/actAsPeopleAutocomplete.ctp delete mode 100644 View/Elements/empty delete mode 100644 webroot/js/page/ActAsUser.js diff --git a/View/Elements/actAsPeopleAutocomplete.ctp b/View/Elements/actAsPeopleAutocomplete.ctp new file mode 100644 index 0000000..49ee1b7 --- /dev/null +++ b/View/Elements/actAsPeopleAutocomplete.ctp @@ -0,0 +1,127 @@ + 0 ? '?time=' . time() : ''; + + +?> + + + +
+ + +
diff --git a/View/Elements/empty b/View/Elements/empty deleted file mode 100644 index e69de29..0000000 diff --git a/View/GrouperGroups/index.ctp b/View/GrouperGroups/index.ctp index 95e10d6..fe539cd 100644 --- a/View/GrouperGroups/index.ctp +++ b/View/GrouperGroups/index.ctp @@ -8,6 +8,14 @@ print $this->Html->script('GrouperLiteWidget.vue-router.js'); // Add Breadcrumb $this->Html->addCrumb(_txt('pl.grouperlite.title.dashboard')); + +$baseUrl = $vv_config['CoGrouperLiteWidget']['grouper_url']; +$path = '/grouper/grouperUi/app/UiV2Main.index'; +$groupOperation = '?operation=UiV2Group.viewGroup&groupId='; +$grouperUrlBase = $baseUrl . $path . $groupOperation; + +$htmlId = 'act-as-picker'; +$suffix = Configure::read('debug') > 0 ? '?time=' . time() : ''; ?>
@@ -16,20 +24,12 @@ $this->Html->addCrumb(_txt('pl.grouperlite.title.dashboard'));
-
-
+
+
diff --git a/webroot/css/co-grouper-base.css b/webroot/css/co-grouper-base.css index 84c5a0e..836c05c 100644 --- a/webroot/css/co-grouper-base.css +++ b/webroot/css/co-grouper-base.css @@ -14,12 +14,6 @@ --secondary: var(--darkteal) } -.grouper_groups .grouper-table { - display: grid; - grid-template-columns: auto 20%; - grid-gap: 1em; -} - .text-grouper { color: var(--primary); } @@ -148,4 +142,4 @@ to { opacity: 1; } -} \ No newline at end of file +} diff --git a/webroot/js/autocomplete.js b/webroot/js/autocomplete.js index 6a4bed2..a60e81d 100644 --- a/webroot/js/autocomplete.js +++ b/webroot/js/autocomplete.js @@ -68,7 +68,6 @@ export default { }, success: function (data) { $("#grouper-search-container .co-loading-mini").hide(); - // If i have more data from before append at the end response( data ); }, error: function(data) { diff --git a/webroot/js/page/ActAsUser.js b/webroot/js/page/ActAsUser.js deleted file mode 100644 index 4f7f276..0000000 --- a/webroot/js/page/ActAsUser.js +++ /dev/null @@ -1,81 +0,0 @@ -import PageCount from '../pagecount.js'; -import Pagination from '../pagination.js'; -import GroupsTable from '../groups-table.js'; -import Members from '../members.js'; -import Autocomplete from '../autocomplete.js'; -import Loader from '../loader.js'; -export default { - components: { - Autocomplete, - Loader - }, - data() { - return { - loading: false, - subscribers: [], - user: {}, - rowLoading: false, - searched: false - } - }, - inject: ['api', 'txt'], - computed: { - preInfoTxt() { - return '' + this.txt.search + ':' - } - }, - methods: { - reset() { - this.searched = false - // If you are in the middle of a row action we do not want to clear - // the results because we are breaking the user experience - if(!this.rowLoading) { - this.subscribers = [] - } - }, - async disableActAs() { - - }, - async findUsersIManage(user) { - } - }, - template: /*html*/` - - -
-
- {{ txt.noaccess }} - {{ txt.empty }} -
-
- - - - - - - - -
- {{ subscriber.name }} - - {{ subscriber.id }} - - -
- - {{ txt.empty }} - -
-
- ` -} \ No newline at end of file