-
Notifications
You must be signed in to change notification settings - Fork 72
Project finished #80
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Project finished #80
Conversation
This commit is just test commit without -m flag. Purpose was to practice commits without the flag and see how it looks in the editor.
Exercise service class used Exercise model directly. Refactored service and Service interface to use DTO and addded extention method for RepositoryResult used to map repository result accordingly
Ui service used Exercise model for all its operations. Uses only ExerciseDto model now View all method tested - working now
All functionality rewritten using DTOs. All CRUD ops tested and working.
Test implementation of get all method for dapper repository. First time working with dapper with navigational properties so wanted to test it. Working implementation done
Implemented and tested autoseed functionality for dapper repo.
All CRUD operations within dapper repository implemented and working
Added new 2 interfaces IWeightExerciseService, ICardioExerciseService. Both of them are implemented by service class and properly registered in DI container
Cleared migration tree to contain only the production one.
Project is now completed using 2 separate services to access 2 tables - one using EF core, one using Dapper. User is presented with choice for table which will be used.
Came up with solution to have mapping done in Service class, in ExecuteSafeAsync method. This allowed to get rid of RepositoryResultExtensions class. Previous implementation needed to re-wrap RepositoryResult from Model to DTO. This is history now. Code is now simpler, more readable and more efficient.
Documentation added for rest of the code: ExerciseController ExerciseDto IExerciseRepository ExerciseService IUserInputOutput UserInputOutput
List of issues and applied fixes: 1.Migration name was in lowercase - removed and re-added the migration with upper case name 2. Unused param array in Program.cs Main method - deleted the parameter 3-4. Empty statements in UserInputOutput GetExercise method - removed redundant semicolons after start and end time date initialization statements 5. Unused variable in ExerciseController ProcessCreate method - removed unused variable
Removed unused variable in ExerciseController ProcessUpdate method
chrisjamiecarter
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hey @BrozDa 👋,
Excellent work on your Exercise Tracker project submission 🎉!
I have performed a peer review. Review/ignore any comments as you wish.
🟢 Requirements
⭐ You have fulfilled all of the project requirements!
I will go ahead and mark as approved, keep up the excellent work on the next projects! 😊
Best regards,
@chrisjamiecarter 👍
| using Microsoft.Extensions.Configuration; | ||
| using System.Text.Json; | ||
|
|
||
| namespace ExerciseTracker.Brozda.Data |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🟠 Namespaces
As per the academy's code-conventions - Use the newest namespaces.
Use file-scoped namespaces to save an indentation level:
❌
// Block-Scoped Namespace
namespace YourNamespace
{
// Code here...
}
✔️
// File-Scoped Namespace
namespace YourNamespace;
// Code here...
First pull request iteration
Readme to be added after initial codacy check