summaryrefslogtreecommitdiffstats
path: root/apps/user_ldap/group_ldap.php
diff options
context:
space:
mode:
authorArthur Schiwon <blizzz@owncloud.com>2013-03-05 21:23:58 +0100
committerArthur Schiwon <blizzz@owncloud.com>2013-03-05 21:23:58 +0100
commit72c293e834a41f7c0368ead099513deb8388cbc9 (patch)
tree7017dfd45d93109d342cb3875108f69811812625 /apps/user_ldap/group_ldap.php
parent5da9223d1c61257cbccbc762e6a7c28bc06f110b (diff)
downloadnextcloud-server-72c293e834a41f7c0368ead099513deb8388cbc9.tar.gz
nextcloud-server-72c293e834a41f7c0368ead099513deb8388cbc9.zip
LDAP: implementation of displayNamesInGroup
Diffstat (limited to 'apps/user_ldap/group_ldap.php')
-rw-r--r--apps/user_ldap/group_ldap.php17
1 files changed, 14 insertions, 3 deletions
diff --git a/apps/user_ldap/group_ldap.php b/apps/user_ldap/group_ldap.php
index 4fd4c636913..efa5f8b4fe3 100644
--- a/apps/user_ldap/group_ldap.php
+++ b/apps/user_ldap/group_ldap.php
@@ -210,6 +210,19 @@ class GROUP_LDAP extends lib\Access implements \OCP\GroupInterface {
}
/**
+ * @brief get a list of all display names in a group
+ * @returns array with display names (value) and user ids(key)
+ */
+ public function displayNamesInGroup($gid, $search, $limit, $offset) {
+ $users = $this->usersInGroup($gid, $search, $limit, $offset);
+ $displayNames = array();
+ foreach($users as $user) {
+ $displayNames[$user] = \OC_User::getDisplayName($user);
+ }
+ return $displayNames;
+ }
+
+ /**
* @brief get a list of all groups
* @returns array with group names
*
@@ -287,8 +300,6 @@ class GROUP_LDAP extends lib\Access implements \OCP\GroupInterface {
* compared with OC_USER_BACKEND_CREATE_USER etc.
*/
public function implementsActions($actions) {
- //always returns false, because possible actions are modifying
- // actions. We do not write to LDAP, at least for now.
- return false;
+ return (bool)(OC_GROUP_BACKEND_GET_DISPLAYNAME & $actions);
}
}