diff options
author | Côme Chilliet <come.chilliet@nextcloud.com> | 2024-11-21 17:13:49 +0100 |
---|---|---|
committer | Côme Chilliet <come.chilliet@nextcloud.com> | 2024-11-21 17:13:49 +0100 |
commit | 95d655b43ab4072be0813de5228bc8da7433ba88 (patch) | |
tree | d6eccaae00f8380d7da96f3f8233916d4b81b449 | |
parent | fd366a6d8f8b987c3a72d7764848b80785c6d68e (diff) | |
download | nextcloud-server-enh/add-user-creation-date.tar.gz nextcloud-server-enh/add-user-creation-date.zip |
feat(users): Add user creation date support (WIP)enh/add-user-creation-date
Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
-rw-r--r-- | apps/user_ldap/lib/User_LDAP.php | 3 | ||||
-rw-r--r-- | apps/user_ldap/lib/User_Proxy.php | 7 |
2 files changed, 9 insertions, 1 deletions
diff --git a/apps/user_ldap/lib/User_LDAP.php b/apps/user_ldap/lib/User_LDAP.php index 6970a52d3d7..8f6065739f6 100644 --- a/apps/user_ldap/lib/User_LDAP.php +++ b/apps/user_ldap/lib/User_LDAP.php @@ -634,4 +634,7 @@ class User_LDAP extends BackendUtility implements IUserBackend, UserInterface, I public function getDisabledUserList(?int $limit = null, int $offset = 0, string $search = ''): array { throw new \Exception('This is implemented directly in User_Proxy'); } + + public function getUserCreationDate(string $uid): ?\DateTime { + } } diff --git a/apps/user_ldap/lib/User_Proxy.php b/apps/user_ldap/lib/User_Proxy.php index 7786b8f0497..2981beb58d3 100644 --- a/apps/user_ldap/lib/User_Proxy.php +++ b/apps/user_ldap/lib/User_Proxy.php @@ -14,11 +14,12 @@ use OCP\IUserBackend; use OCP\Notification\IManager as INotificationManager; use OCP\User\Backend\ICountMappedUsersBackend; use OCP\User\Backend\ICountUsersBackend; +use OCP\User\Backend\IGetUserCreationDateBackend; use OCP\User\Backend\IProvideEnabledStateBackend; use OCP\UserInterface; use Psr\Log\LoggerInterface; -class User_Proxy extends Proxy implements IUserBackend, UserInterface, IUserLDAP, ICountUsersBackend, ICountMappedUsersBackend, IProvideEnabledStateBackend { +class User_Proxy extends Proxy implements IUserBackend, UserInterface, IUserLDAP, ICountUsersBackend, ICountMappedUsersBackend, IProvideEnabledStateBackend, IGetUserCreationDateBackend { /** @var User_LDAP[] */ private array $backends = []; private ?User_LDAP $refBackend = null; @@ -443,4 +444,8 @@ class User_Proxy extends Proxy implements IUserBackend, UserInterface, IUserLDAP ) ); } + + public function getUserCreationDate(string $uid): ?\DateTime { + return $this->handleRequest($uid, 'getUserCreationDate', [$uid]) ?: null; + } } |