forked from Code-4-Community/scaffolding
-
Notifications
You must be signed in to change notification settings - Fork 0
Open
Description
Description:
- In applications.service.ts, several functions currently use the any type. This is dangerous - replace any with the correct, strongly typed definitions to improve type safety. Also, in submitApp(), follow the existing TODO to make the user dynamic.
- Update the reviews entity: it currently has a reviewerId field. Create a proper one-to-many relationship between reviews and the user entity using TypeORM. Verify the new relationship by adding and deleting reviews through PgAdmin to ensure data integrity.
Acceptance Criteria:
- No usage of any type remains in applications.service.ts
- submitApp() dynamically handles user as intended
- One-to-many relationship between reviews and user entity is correctly implemented
- Adding and deleting reviews via PgAdmin reflects correctly in the database and respects entity relationships
Resources:
- TypeORM Documentation: https://typeorm.io/docs/relations/many-to-one-one-to-many-relations
- Crash course on database design basics (one-to-many relationships): https://www.geeksforgeeks.org/dbms/one-to-many-relationship-in-database/
T-Shirt Size: M
Metadata
Metadata
Assignees
Labels
No labels