C
C#4w ago
Matt

Attempting to create a CRUD API

Im coming from a spring boot background so Im not sure if im doing this correctly. I have a store entity which will have a store manager class to perform crud operations however Im not sure if this setup is correct
No description
No description
22 Replies
Matt
Matt4w ago
No description
Matt
Matt4w ago
I've desgined a doc on how it should function
Matt
Matt4w ago
No description
Matt
Matt4w ago
Im not actually sure how I will accept HTTP requests yet but first I'd want to make sure this is the proper way to do it
Jimmacle
Jimmacle4w ago
you shouldn't be writing repositories on top of EF Core DbContexts actually you're not so nvm, but it seems like there is an excessive amount of layering
Matt
Matt4w ago
Im attempting to use encapsulation Or really abstraction sorry
Unknown User
Unknown User4w ago
Message Not Public
Sign In & Join Server To View
Matt
Matt4w ago
Hmm I don’t get it
Unknown User
Unknown User4w ago
Message Not Public
Sign In & Join Server To View
Matt
Matt4w ago
So which class should I edit
Unknown User
Unknown User4w ago
Message Not Public
Sign In & Join Server To View
Matt
Matt4w ago
Yeah 👍
Unknown User
Unknown User4w ago
Message Not Public
Sign In & Join Server To View
Matt
Matt4w ago
Right I’m already using it
Unknown User
Unknown User4w ago
Message Not Public
Sign In & Join Server To View
Matt
Matt4w ago
In my DatabaseContext
Unknown User
Unknown User4w ago
Message Not Public
Sign In & Join Server To View
Matt
Matt4w ago
I think I get it
Unknown User
Unknown User4w ago
Message Not Public
Sign In & Join Server To View
Matt
Matt4w ago
I’ll revise it
Unknown User
Unknown User4w ago
Message Not Public
Sign In & Join Server To View
Angius
Angius4w ago
Nitpick, but .ExecuteUpdate for Update and .ExecuteDelete for Delete. Buth can be done in a single query