Fix/form design create structure
2 unresolved threads
2 unresolved threads
A utiliser avec même branche côté front + dump 04/02
Edited by Hugo SUBTIL
Merge request reports
Activity
296 297 }); 297 298 this.mailerService.send(userEmail, jsonConfig.subject, html); 298 299 } 300 301 public async updateAfterOwnerVerify(emailUser: string): Promise<Structure> { changed this line in version 4 of the diff
26 26 return this.structureService.search(query.query, body ? body.filters : null); 27 27 } 28 28 29 @Put('updateAfterOwnerVerify/:id') 30 public async updateAfterOwnerVerify(@Param('id') id: string, @Body() body: structureDto): Promise<Structure> { Ce endpoint fait exactement la même chose que le update. De plus il n'y a aucun Guard sur la route donc techniquement n'importe qui peut modifier n'importe quelle structure avec ce endpoint.
Utiliser le endpoint update avec les guard. Sinon créer un service qui avec un id utilisateur et un id structure, va t'activer une structure. En vérifiant bien que la structure appartient a l'id donné.
changed this line in version 4 of the diff
added 1 commit
- 35fa9537 - fix: user model structureid from string to objectid
mentioned in commit dfc99ce9
Please register or sign in to reply