feat(#135): mode édition dossier + ajout co-parent (squash develop).

Wizard edit famille/AM, POST co-parent, PATCH enfants avec photo.

Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
2026-09-08 17:32:06 +02:00
co-authored by Cursor
parent 84e46162fd
commit ea0e97d930
15 changed files with 1246 additions and 69 deletions
@@ -141,12 +141,20 @@ export class EnfantsController {
RoleType.GESTIONNAIRE,
)
@Patch(':id')
@ApiOperation({
summary: 'Mettre à jour un enfant',
description:
'JSON sans photo OK ; avec nouvelle photo → multipart (champ fichier `photo`, max 5 Mo).',
})
@ApiConsumes('application/json', 'multipart/form-data')
@UseInterceptors(OptionalEnfantPhotoInterceptor)
update(
@Param('id', new ParseUUIDPipe()) id: string,
@Body() dto: UpdateEnfantsDto,
@UploadedFile() photo: Express.Multer.File,
@User() currentUser: Users,
) {
return this.enfantsService.update(id, dto, currentUser);
return this.enfantsService.update(id, dto, currentUser, photo);
}
@Roles(RoleType.SUPER_ADMIN)