Skip to content

Commit

Permalink
feat(vue,php):Display the groups we're looking for
Browse files Browse the repository at this point in the history
Signed-off-by: Baptiste Fotia <[email protected]>
  • Loading branch information
zak39 committed Apr 8, 2024
1 parent 34576f3 commit ac2135c
Show file tree
Hide file tree
Showing 3 changed files with 44 additions and 10 deletions.
2 changes: 1 addition & 1 deletion lib/Service/Group/GroupFormatter.php
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ public static function formatGroups(array $groups): array {
$isLdap = true;
}

$groupsFormat[$group->getGID()] = [
$groupsFormat[] = [
'gid' => $group->getGID(),
'displayName' => $group->getDisplayName(),
'types' => $group->getBackendNames(),
Expand Down
51 changes: 43 additions & 8 deletions src/SelectConnectedGroups.vue
Original file line number Diff line number Diff line change
@@ -1,13 +1,19 @@
<template>
<div>
<h1>Connect a group</h1>
<div class="container-select-groups">
<header class="header-select-groups">
<h1>Connect a group</h1>
</header>

<NcSelect
label="Start typing to lookup groups"
limit="10"
:options="groupsSelectable"
@search="lookupGroups"
@close="groupsSelectable=[]" />
<div class="body-select-groups">
<NcSelect
class="searchbar-groups"
track-by="gid"
label="displayName"
limit="10"
:options="groupsSelectable"
@search="lookupGroups"
@close="groupsSelectable=[]" />
</div>
</div>
</template>

Expand Down Expand Up @@ -45,6 +51,7 @@ export default {
axios.get(generateUrl('/apps/workspace/groups'), {
params: {
pattern: term,
ignoreSpaces: true,
},
})
.then(response => {
Expand All @@ -61,4 +68,32 @@ export default {
</script>

<style>
.container-select-groups {
display: flex;
flex-direction: column;
width: 100%;
justify-content: center;
align-items: center;
}
.header-select-groups {
display: flex;
align-items: start;
width: 100%;
padding: 10px;
}
.header-select-groups h1 {
margin: 10px;
font-size: 24px;
}
.body-select-groups {
display: flex;
}
.searchbar-groups {
width: 400px;
}
</style>
1 change: 0 additions & 1 deletion src/SelectUsers.vue
Original file line number Diff line number Diff line change
Expand Up @@ -358,7 +358,6 @@ export default {
}

.modal-container {
display: flex !important;
min-height: 520px !important;
max-height: 520px !important;
width: 640px !important;
Expand Down

0 comments on commit ac2135c

Please sign in to comment.