The Inventory Management System is a robust and flexible application designed to streamline the tracking and management of inventory. This system supports both MySQL and SQLite databases, offering versatility for different deployment environments. It is built using Python, leveraging its powerful libraries to ensure a reliable and efficient application.
- Multi-Database Support: Easily switch between MySQL and SQLite for backend storage.
- User-Friendly Interface: Simplified command-line interface for easy navigation and operation.
- CRUD Operations: Full create, read, update, and delete functionality for inventory items.
- Report Generation: Generate reports on inventory levels, transactions, and more.
- Transaction Logging: Maintain an audit trail of all changes made to the inventory.
- Python 3.8+
- MySQL 8.0+ (optional for MySQL support)
- SQLite 3.0+ (included with Python)
- Python Libraries:
mysql-connector-pythonsqlite3(built-in with Python)SQLAlchemy(optional, for ORM support)pandas(for data manipulation and reporting)
-
Clone the Repository
git clone https://github.com/hollali/Inventory-System.git cd inventory-system -
Set Up Virtual Environment
python3 -m venv env source env/bin/activate # On Windows use `env\Scripts\activate`
-
Install Dependencies
pip install -r requirements.txt
-
Database Configuration
- MySQL: Create a database and update the
config.inifile with your MySQL credentials. - SQLite: No additional setup needed, the SQLite database will be created automatically.
- MySQL: Create a database and update the
Update the config.ini file to specify the database settings.
[database]
engine = mysql # Change to 'sqlite' for SQLite database
host = localhost
user = yourusername
password = yourpassword
database = inventory_db-
Run the Application
python dashboard.py
-
Basic Commands
add: Add a new item to the inventory.list: List all items in the inventory.update: Update details of an existing item.delete: Remove an item from the inventory.report: Generate a report of current inventory levels.
-
Database Migration
- For MySQL:
python manage.py migrate --db mysql
- For SQLite:
python manage.py migrate --db sqlite
- For MySQL:
-
Testing
- Run tests using
unittestorpytestframeworks.
python -m unittest discover tests
- Run tests using
-
Code Style
- Follow PEP 8 standards. Use tools like
flake8for linting.
- Follow PEP 8 standards. Use tools like
Contributions are welcome! Please read the CONTRIBUTING.md file for more information on how to contribute to this project.
This project is licensed under the MIT License. See the LICENSE file for more details.
- Python
- MySQL
- SQLite
- Community contributors
This `README.md` provides a comprehensive guide for users and contributors, covering setup, usage, and contribution details. Adjust the sections to fit the specifics of your project.