How phantrang2002/worknest works
Main Components
• Frontend: Built using Next.js (React) with TailwindCSS. This includes pages, layouts, components, and API service clients that the user interacts with.
• Backend API: Developed in ASP.NET Core Web API. This layer contains Controllers (for handling HTTP requests), Data (using ApplicationDBContext, migrations for database schema), Dtos (data transfer objects for request/response), Models (domain entities), and Services (business logic such as token generation).
• Database: A MSSQL database that is set up using the provided WorkNest-db-script.sql. This holds all user accounts, job postings, applications, policies, and more.
• Static Assets: Under the API’s wwwroot folder, which includes images and sample CV templates (PDFs and DOCs) that are served as static files.
Relationships and Data Flow
• API Server to Database: Illustrate the connection where the ASP.NET Core backend accesses data using Entity Framework (ApplicationDBContext) and applies migrations.
• API Server Static Assets: Demonstrate that the API also serves static files (sample CV templates/images) through its wwwroot folder.
• Internal Services: Within the API, represent how Controllers use Services (e.g., TokenService) and work with Dtos and Models for business logic and data transformation.
Architectural Patterns and Principles
• Separation of Concerns: Frontend and backend are clearly separated. Within the backend, the code is modularized into Controllers, Dtos, Models, and Services.
• RESTful API Design: Highlight how the controllers (e.g., AccountController, JobPostingController) expose endpoints corresponding to the features detailed in the README (user registration, job posting, feedback submission, etc.).
• Layered Architecture: Indicate how the system layers (Presentation → Business Logic → Data Access) are implemented through separate directories/files.
Technologies and Frameworks
• Frontend: Next.js (React), TailwindCSS.
• Backend: ASP.NET Core Web API (version 8), Entity Framework Core (for database operations), MSSQL Server.
• Additional: The API also uses token-based authentication via the TokenService and likely employs DTOs for data sanitization and communication.