An ASP.NET Core MVC web application for tracking workouts, exercises, and calorie burn.
The system allows users to log workouts, assign exercises, and visualize their activity through a statistics dashboard.
- User registration and authentication (ASP.NET Core Identity)
- Create, edit, and delete workouts
- Add exercises to workouts (many-to-many relationship)
- Track sets, reps, duration, and intensity
- View workout details with calculated calories burned
- Daily activity tracking
- Weekly and monthly summaries
- Total calories burned calculation (using LINQ aggregation)
- Interactive charts using Chart.js
- Create and manage exercises (Admin/User access based on roles)
- Define exercise type and calories per minute
- ASP.NET Core MVC
- Entity Framework Core (Code First)
- ASP.NET Core Identity
- SQLite (development database)
- LINQ for data aggregation
- Bootstrap for UI styling
- Chart.js for data visualization
The project follows a layered architecture:
-
Presentation Layer (WebHost)
- MVC Controllers
- Razor Views
-
Application Layer
- DTOs
- Service Interfaces
- Services implementation
-
Infrastructure Layer
- Database context (EF Core)
-
Domain Layer
- Entities and core models
Main relationships:
- User → Workouts (One-to-Many)
- Workout → Exercises (Many-to-Many via WorkoutExercise)
- Exercises store calorie burn rates used for calculations
The application includes two roles:
-
User
- Can manage personal workouts and view statistics
-
Admin
- Can manage exercises and system-level data
- Clone the repository
git clone https://github.com/codingburgas/project-AILalev22.git- Go into the project folder
cd project-AILalev22- Restore dependencies (NuGet packages)
dotnet restore- Build the solution (checks for compile errors)
dotnet build- Apply database migrations
dotnet ef database update --project FitnessTracker.Infrastructure --startup-project FitnessTracker.WebHost- Initialize User Secrets
dotnet user-secrets init --project FitnessTracker.WebHost- Configure Admin Credentials (User Secrets)
dotnet user-secrets set "Other:adminEmail" "your-admin-email" --project FitnessTracker.WebHostdotnet user-secrets set "Other:adminPassword" "your-secure-password" --project FitnessTracker.WebHost- Run the application
dotnet run --project FitnessTracker.WebHost