Fahiz_countries Table Complete and Mashrafee Problem Fixed....#92
Merged
Conversation
Closed
Contributor
There was a problem hiding this comment.
Pull request overview
This PR adds a complete CRUD implementation for a Countries table and refactors the SendOtpCommandHandler to use a simpler using statement pattern (the "Mashrafee Problem" fix). The Countries feature follows the existing Clean Architecture pattern with Domain, Application, Infrastructure, and Web.Api layers.
Key Changes
- Added full CRUD operations for Countries entity (Create, Read, GetById, Update, Delete)
- Refactored
SendOtpCommandHandlerto use declaration pattern instead of traditional using blocks - Added Countries DbSet to ApplicationDbContext and IApplicationDbContext
Reviewed changes
Copilot reviewed 26 out of 26 changed files in this pull request and generated 12 comments.
Show a summary per file
| File | Description |
|---|---|
src/Domain/Countries/Country.cs |
New domain entity for Country with Id, Name, Capital, PhoneCode, and IsActive properties |
src/Infrastructure/Countries/CountryConfiguration.cs |
EF Core entity configuration defining table mapping and constraints for Country entity |
src/Infrastructure/Database/ApplicationDbContext.cs |
Added Countries DbSet to the database context |
src/Application/Abstractions/Data/IApplicationDbContext.cs |
Added Countries DbSet to the interface |
src/Application/Countries/Create/* |
Command, handler, and validator for creating countries |
src/Application/Countries/Update/* |
Command, handler, and validator for updating countries |
src/Application/Countries/Delete/* |
Command, handler, and validator for deleting countries |
src/Application/Countries/Get/* |
Query, handler, and response for getting all countries |
src/Application/Countries/GetById/* |
Query, handler, and response for getting country by ID |
src/Web.Api/Endpoints/Countries/* |
Five endpoint classes (Create, Update, Delete, Get, GetById) for the Countries API |
src/Web.Api/Endpoints/Tags.cs |
Added "Countries" tag constant for API documentation |
src/Application/SmtpConfigs/OtpMail/SendOtpCommandHandler.cs |
Refactored to use using declaration pattern instead of traditional using blocks |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
No description provided.