Loading src/UnicaenUtilisateurLdapAdapter/Entity/LdapIndividu.php +5 −5 Original line number Diff line number Diff line Loading @@ -31,23 +31,23 @@ class LdapIndividu implements RechercheIndividuResultatInterface public function getId() { return $this->people->getId(); return $this->people['uid']; } public function getUsername(string $attribut = "supannAliasLogin") { return $this->people->get('supannAliasLogin'); return $this->people[$attribut]; } public function getDisplayname() { $tmp_name = $this->people->get('sn'); $tmp_name = $this->people['displayName']; if (!is_string($tmp_name)) $tmp_name = implode("-", $this->people->get('sn')); return $tmp_name . " " . $this->people->get('givenName'); return $tmp_name; //$tmp_name . " " . $this->people->get('givenName'); } public function getEmail() { return $this->people->get('mail'); return $this->people['mail']; } } No newline at end of file src/UnicaenUtilisateurLdapAdapter/Service/LdapService.php +8 −3 Original line number Diff line number Diff line Loading @@ -22,13 +22,17 @@ class LdapService implements RechercheIndividuServiceInterface */ public function findById($id) { $filter = PeopleFilter::uid($id); /** * @var PeopleEntity $people */ $people = $this->ldapPeopleService->get($id); /** TODO retirer ce contournement une fois le problème compris */ // $people = $this->ldapPeopleService->get($id); $people = $this->ldapPeopleService->searchAttributes($filter, ['id', 'uid', 'supannaliaslogin', 'supannAliasLogin','displayName', 'mail']); $peep = $people[$id]; $p = new LdapIndividu(); $p->setPeople($people); $p->setPeople($peep); return $p; } Loading @@ -45,7 +49,8 @@ class LdapService implements RechercheIndividuServiceInterface ); /** @var PeopleService $ldapService */ try { $people = $this->ldapPeopleService->search($filter); $people = $this->ldapPeopleService->searchAttributes($filter, ['id', 'uid', 'supannaliaslogin', 'supannAliasLogin','displayName', 'mail']); // $people = $this->ldapPeopleService->search($filter); } catch (Exception $e) { throw new RuntimeException("Un exception ldap est survenue :", $e); } Loading Loading
src/UnicaenUtilisateurLdapAdapter/Entity/LdapIndividu.php +5 −5 Original line number Diff line number Diff line Loading @@ -31,23 +31,23 @@ class LdapIndividu implements RechercheIndividuResultatInterface public function getId() { return $this->people->getId(); return $this->people['uid']; } public function getUsername(string $attribut = "supannAliasLogin") { return $this->people->get('supannAliasLogin'); return $this->people[$attribut]; } public function getDisplayname() { $tmp_name = $this->people->get('sn'); $tmp_name = $this->people['displayName']; if (!is_string($tmp_name)) $tmp_name = implode("-", $this->people->get('sn')); return $tmp_name . " " . $this->people->get('givenName'); return $tmp_name; //$tmp_name . " " . $this->people->get('givenName'); } public function getEmail() { return $this->people->get('mail'); return $this->people['mail']; } } No newline at end of file
src/UnicaenUtilisateurLdapAdapter/Service/LdapService.php +8 −3 Original line number Diff line number Diff line Loading @@ -22,13 +22,17 @@ class LdapService implements RechercheIndividuServiceInterface */ public function findById($id) { $filter = PeopleFilter::uid($id); /** * @var PeopleEntity $people */ $people = $this->ldapPeopleService->get($id); /** TODO retirer ce contournement une fois le problème compris */ // $people = $this->ldapPeopleService->get($id); $people = $this->ldapPeopleService->searchAttributes($filter, ['id', 'uid', 'supannaliaslogin', 'supannAliasLogin','displayName', 'mail']); $peep = $people[$id]; $p = new LdapIndividu(); $p->setPeople($people); $p->setPeople($peep); return $p; } Loading @@ -45,7 +49,8 @@ class LdapService implements RechercheIndividuServiceInterface ); /** @var PeopleService $ldapService */ try { $people = $this->ldapPeopleService->search($filter); $people = $this->ldapPeopleService->searchAttributes($filter, ['id', 'uid', 'supannaliaslogin', 'supannAliasLogin','displayName', 'mail']); // $people = $this->ldapPeopleService->search($filter); } catch (Exception $e) { throw new RuntimeException("Un exception ldap est survenue :", $e); } Loading