How alperensamurlu/community-todo-website works
Project type and purpose
• Community To-Do is a full-stack, community-centric task management web application.
• Frontend: static HTML pages + Bootstrap 5 + custom JavaScript.
• Backend: ASP.NET Core MVC Web API using EF Core and MSSQL.
• External service: SMTP email service for verification and notifications.
File structure
• Top-level directories:
• /frontend: HTML views (index, login, signup, dashboard, password reset, verification) + /scripts (config, login, signup, dashboard, verification).
• /backend/ToDoBackend: .NET solution and project folders.
– Controllers: CommunitiesController, TasksController, UsersController, UserCommunitiesController, NotificationController
– DTOs: data-transfer objects for requests/responses
– Models: EF Core entity classes (User, Community, Task, Notification, UserCommunity)
– Data: AppDbContext (DbSet<> for each model)
– Services: EmailService
– Config: appsettings.json, launchSettings.json, web.config
– Build: .csproj, ToDoBackend.http (API testing script)
README for additional insights
• Confirms MVC pattern, EF Core ORM, JSON over HTTP for API, Bootstrap 5 for responsive UI.
• Detailed data model relationships (Users ↔ Communities ↔ Tasks ↔ Notifications via UserCommunities join table).
• Email verification and password reset flows via EmailService.
Main components
a. Frontend (Browser)
• Static pages + JS modules
• Interacts over HTTP/HTTPS with backend API
b. Backend Web API
• Presentation layer: Controllers receive HTTP requests
• Service layer: business logic (EmailService, any future services)
• Data access layer: AppDbContext via EF Core
c. Database (MSSQL)
• Tables: Users, Communities, Tasks, Notifications, UserCommunities, __EFMigrationsHistory
d. External SMTP Email Service
• Sends verification codes & notifications
Relationships and interactions
• Browser → (HTTP JSON) → Controllers (Users, Communities, Tasks, UserCommunities, Notification)
• Controllers → (calls) → Services (e.g., EmailService) or directly → DbContext
• AppDbContext → (ORM) → MSSQL Database
• EmailService → SMTP Server → User’s inbox
• NotificationController → (push pulled by frontend or polled) → Dashboard notifications
Architectural patterns and design principles
• Layered MVC architecture: clear separation of concerns
• DTOs for boundary objects (incoming requests, outgoing responses)
• EF Core as repository/Unit-of-Work pattern via DbContext
• Stateless Web API controllers, scale horizontally if needed
• Single-page interactions orchestrated by JS modules, but pages are not a SPA (each page a separate HTML + script)
Technologies and frameworks
• Frontend: HTML5, CSS/Bootstrap 5, vanilla JS modules
• Backend: .NET 7+ (or .NET Core 3.1+), ASP.NET Core MVC, Entity Framework Core
• Database: Microsoft SQL Server
• External: SMTP (configurable via appsettings.json)
Detail but avoid over-modularizing
• Related controllers together under “API Controllers.”
• Essential data-flow paths (user login, community join, task CRUD, email verification, notifications).