feat(#25): API GET /users/pending - liste comptes en attente
- UserController: endpoint GET /users/pending (rôles SUPER_ADMIN, ADMINISTRATEUR, GESTIONNAIRE) - UserService: findPendingUsers(role?) avec filtre statut EN_ATTENTE - GestionnairesService: retrait date_consentement_photo (non présent dans DTO) Made-with: Cursor
This commit is contained in:
@@ -91,13 +91,7 @@ export class GestionnairesService {
|
||||
gestionnaire.password = await bcrypt.hash(dto.password, salt);
|
||||
}
|
||||
|
||||
if (dto.date_consentement_photo !== undefined) {
|
||||
gestionnaire.date_consentement_photo = dto.date_consentement_photo
|
||||
? new Date(dto.date_consentement_photo)
|
||||
: undefined;
|
||||
}
|
||||
|
||||
const { password, date_consentement_photo, ...rest } = dto;
|
||||
const { password, ...rest } = dto;
|
||||
Object.entries(rest).forEach(([key, value]) => {
|
||||
if (value !== undefined) {
|
||||
(gestionnaire as any)[key] = value;
|
||||
|
||||
Reference in New Issue
Block a user