diff --git a/ProjectOrientedSessions/Session08/Session08 Backend.md b/ProjectOrientedSessions/Session08/Session08 Backend.md index bd54829..68339a5 100644 --- a/ProjectOrientedSessions/Session08/Session08 Backend.md +++ b/ProjectOrientedSessions/Session08/Session08 Backend.md @@ -1,12 +1,24 @@ +# Session 8 +Profile + some fixes to database +## Fixes +- [ ] Check for missing `.ValueGeneratedOnAdd()` in all entity configurations in ```Infrastructure/Configurations```. -# Fixes -- [ ] Check for missing `.ValueGeneratedOnAdd()` in all entity configuration. - [ ] Adjust the database setup according to the second version of ERD -- [ ] new erd: https://github.com/TheOrderOfPhoenix/ASP.NET/blob/main/02_ProjectOrientedSessions/docs/AlibabaERD-Version02.pdf -- [ ] Pay attention to the changes in logic and implementation of Person table (Id number is not unique anymore) -- [ ] Add actual data in `TicketStatus`, `Gender`, `TransactionTypes` -- [ ] Add data in `Seat`, `Person`, `TicketOrder`, `Transaction`, `Ticket` for test. It is recommended to write python code for generating data for Seat table, according to the data already stored in Transportation and related Vehicle data + - Some aggregates are added/modified to generate the new database + - New ERD: https://github.com/TheOrderOfPhoenix/ASP.NET/blob/main/ProjectOrientedSessions/docs/AlibabaERD-Version02.pdf + - Note: Pay attention to the changes in logic and implementation of Person table (Id number is not unique anymore). So remove this code in PersonConfiguration: + + ``` + builder.HasIndex(p => p.IdNumber) + .IsUnique(); + ``` + +- [ ] Add actual data in `TicketStatus`, `Gender`, `TransactionTypes` + - You can either add the data in DbContext or the database itself + +- [ ] Add data in `Seat`, `Person`, `TicketOrder`, `Transaction`, `Ticket` for test. It is recommended to write python code for generating data for Seat table, according to the data already stored in Transportation and related Vehicle data. There is also a SeatGenerator in this repository, as well. + - [ ] Fix claim extraction (`sub` → standardize JWT claim mapping). (`IUserContext` implmentation) ### ✅ Profile Page (Account Info Tab)