A lightweight ERP-style Employee & Department Management System built with ASP.NET Core 8 MVC, Entity Framework Core, and Microsoft SQL Server.
- Authentication – Cookie-based login with BCrypt password hashing
- Employee CRUD – Add, view, edit, delete employees with validation
- Department CRUD – Manage departments; prevents deletion if employees exist
- Search & Filter – Filter employees by name, email, department, or status
- Salary Report – Department-wise report powered by a SQL Server stored procedure
- Dashboard – Live stats: headcount, salary bill, recent joiners
- Data Validation – Server-side validation with duplicate email/name detection
| Layer | Technology |
|---|---|
| Backend | ASP.NET Core 8 MVC (C#) |
| ORM | Entity Framework Core 8 |
| Database | Microsoft SQL Server |
| Frontend | Bootstrap 5, Bootstrap Icons |
| Auth | Cookie Authentication + BCrypt |
| CI/DevOps | GitHub / Git |
- .NET 8 SDK
- SQL Server (Express edition is fine)
- SQL Server Management Studio (optional)
-
Clone the repository
git clone https://github.com/yourusername/ERPLite.git cd ERPLite -
Update connection string in
appsettings.json:"DefaultConnection": "Server=YOUR_SERVER;Database=ERPLiteDB;Trusted_Connection=True;TrustServerCertificate=True;"
-
Restore packages and run
dotnet restore dotnet run
The app will auto-create the database and seed default departments + admin user on first launch.
-
Create stored procedures (for the Salary Report feature) Open
SQL/StoredProcedures.sqlin SSMS and execute againstERPLiteDB. -
Login
Username: admin Password: Admin@123
ERPLite/
├── Controllers/
│ ├── AccountController.cs # Login / Logout
│ ├── HomeController.cs # Dashboard
│ ├── EmployeeController.cs # Employee CRUD + Report
│ └── DepartmentController.cs
├── Models/
│ ├── Employee.cs
│ ├── Department.cs
│ ├── AppUser.cs
│ └── ApplicationDbContext.cs # EF Core DbContext + Seeder
├── Views/
│ ├── Shared/_Layout.cshtml # Sidebar layout
│ ├── Account/Login.cshtml
│ ├── Home/Index.cshtml # Dashboard
│ ├── Employee/ # Index, Create, Edit, Details, Delete, Report
│ └── Department/ # Index, Create, Edit, Delete
├── SQL/
│ └── StoredProcedures.sql # 4 stored procedures
├── appsettings.json
└── Program.cs
| Procedure | Description |
|---|---|
usp_GetDepartmentSalaryReport |
Salary stats per department (used in Report page) |
usp_SearchEmployees |
Parameterised employee search |
usp_DeactivateEmployee |
Soft-delete (sets IsActive = 0) |
usp_GetHeadcount |
Active employee count per department |
Need to add screenshots here.
Divyansh Chaurasia
MCA Student – IET Lucknow
GitHub | LinkedIn