A full-stack Inventory Management System built with Angular and .NET Core APIs, featuring comprehensive book inventory tracking, sales and purchase management, supplier management, and user authentication.
- β¨ Features
- π οΈ Tech Stack
- π Project History
- π Quick Start with Docker
- π» Development Setup
- π§ Entity Framework Migrations
- πΈ Screenshots
- π€ Contributing
- π License
- β Show Your Support
- π Book Management: Add, edit, delete, and search books with detailed information
- π Inventory Tracking: Real-time inventory monitoring and stock level management
- π° Sales Management: Record and track sales transactions with PDF report generation
- π Purchase Management: Manage purchase orders and supplier transactions with PDF export
- π’ Supplier Management: Maintain supplier information and relationships
- π€ User Authentication: Secure login system with role-based access control
- π PDF Reports: Generate detailed PDF reports for sales and purchase records
- π¨ Modern UI: Clean and responsive interface built with Angular Material
- π Advanced Search: Filter and search across all entities
- π± Responsive Design: Works seamlessly on desktop and mobile devices
- Backend: ASP.NET Core Web API 10.0
- Database: PostgreSQL 16 (migrated from SQL Server 2022)
- ORM: Dapper (primary) + Entity Framework Core (for migrations)
- Frontend: Angular 20
- UI Library: Angular Material
- State Management: NgRx Component Store & Signals
- Containerization: Docker & Docker Compose
This project has evolved significantly since its inception:
Early 2024 - Initial Development
- Started with
.NET 8andAngular 17 - Originally maintained as two separate repositories (frontend & backend)
- Used SQL Server 2022 with stored procedures
Major Upgrades & Migrations
- β
Upgraded to
.NET 10andAngular 20 - β
Migrated from SQL Server to
PostgreSQL- A challenging but rewarding experience that deepened my understanding of database migrations without relying solely on Entity Framework - β Consolidated into a single monorepo for better maintainability
Feature Additions
- β Supplier management system
- β User authentication and authorization
- β PDF report generation for sales and purchases
- β Enhanced UI with Angular Material
Technical Improvements
- β Added Entity Framework Core for database migrations (maintaining dual databases across machines was challenging!)
- β Implemented NgRx Component Store for state management
- β Adopted Angular Signals for newer features
- β Docker support for easy deployment
The easiest way to get started is using Docker:
- Navigate to the
srcdirectory:cd src - Start the containers:
docker compose up -d
- Open your browser and visit:
http://localhost:3001/
That's it! The application should be running with all dependencies configured.
Prerequisites:
- .NET 10.0 SDK
- Node.js (latest LTS version)
- Angular CLI
- PostgreSQL 16
Installation Steps:
-
Clone the repository:
git clone https://github.com/rd003/InventoryMgt.git
-
Navigate to the project directory:
cd InventoryMgt -
Open in VS Code (optional):
code .
You'll need to set up both the backend and frontend separately:
-
Navigate to the backend API directory:
cd backend/InventoryMgt.Api -
Update the connection string in
appsettings.json:"ConnectionStrings": { "DefaultConnection": "Host=localhost;Database=InventoryMgtDb;Username=your_user;Password=your_password" }
-
Run the application:
dotnet run
The database will be automatically created and seeded with initial data on first run.
-
Open a new terminal and navigate to the frontend directory:
cd frontend/InventoryMgt.Client(Keep the backend terminal running)
-
Install dependencies:
npm install
-
Start the development server:
ng serve --open
-
The application will open in your browser. Use these credentials to log in:
Username: admin Password: Admin@123
If you encounter issues running migrations with the .NET CLI (due to multiple projects), use these commands:
Common Error:
Unable to create a 'DbContext' of type 'RuntimeType'...Solution:
Navigate to the backend directory first:
cd backendCreating a Migration:
dotnet ef migrations add YourMigrationName --project InventoryMgt.Data --startup-project InventoryMgt.ApiReplace YourMigrationName with a descriptive name (e.g., AddSupplierTable)
Updating the Database:
dotnet ef database update --project InventoryMgt.Data --startup-project InventoryMgt.ApiNote: Migrations are automatically applied when you run the application, but you can manually execute them using the command above.
Tip: If using Visual Studio, you can use the Package Manager Console instead, which handles multi-project solutions more gracefully.
Contributions are welcome! If you'd like to contribute:
- Fork the repository
- Create a feature branch (
git checkout -b feature/AmazingFeature) - Commit your changes (
git commit -m 'Add some AmazingFeature') - Push to the branch (
git push origin feature/AmazingFeature) - Open a Pull Request
This project is licensed under the MIT License - see the LICENSE file for details.
If you found this project helpful, please consider giving it a star on GitHub! β
Built with β€οΈ by rd003










