├── LICENSE ├── Task3.py └── README.md /LICENSE: -------------------------------------------------------------------------------- 1 | MIT License 2 | 3 | Copyright (c) 2024 Deepak L 4 | 5 | Permission is hereby granted, free of charge, to any person obtaining a copy 6 | of this software and associated documentation files (the "Software"), to deal 7 | in the Software without restriction, including without limitation the rights 8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 9 | copies of the Software, and to permit persons to whom the Software is 10 | furnished to do so, subject to the following conditions: 11 | 12 | The above copyright notice and this permission notice shall be included in all 13 | copies or substantial portions of the Software. 14 | 15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 21 | SOFTWARE. 22 | -------------------------------------------------------------------------------- /Task3.py: -------------------------------------------------------------------------------- 1 | class Product: 2 | def __init__(self, name, quantity, price): 3 | self.name = name 4 | self.quantity = quantity 5 | self.price = price 6 | class Inventory: 7 | def __init__(self): 8 | self.products = [] 9 | 10 | def add_product(self, product): 11 | self.products.append(product) 12 | 13 | def remove_product(self, name): 14 | for product in self.products: 15 | if product.name == name: 16 | self.products.remove(product) 17 | print(f"Product '{name}' removed from inventory") 18 | return 19 | print(f"Product '{name}' not found in inventory") 20 | 21 | def update_quantity(self, name, quantity): 22 | for product in self.products: 23 | if product.name == name: 24 | product.quantity = quantity 25 | print(f"Quantity of '{name}' updated to {quantity}") 26 | return 27 | print(f"Product '{name}' not found in inventory") 28 | 29 | def display_products(self): 30 | print("Inventory:") 31 | for product in self.products: 32 | print(f"Name: {product.name}, Quantity: {product.quantity}, Price: {product.price}") 33 | 34 | def search_product(self, name): 35 | for product in self.products: 36 | if product.name == name: 37 | return product 38 | return None 39 | 40 | # Create an instance of the inventory 41 | inventory = Inventory() 42 | 43 | # Add some products 44 | inventory.add_product(Product("Apple", 10, 1.00)) 45 | inventory.add_product(Product("Banana", 20, 0.50)) 46 | inventory.add_product(Product("Orange", 30, 1.50)) 47 | 48 | inventory.display_products() 49 | 50 | inventory.update_quantity("Apple", 15) 51 | 52 | inventory.remove_product("Banana") 53 | 54 | product = inventory.search_product("Orange") 55 | if product: 56 | print(f"Product found: {product.name}, {product.quantity}, {product.price}") 57 | else: 58 | print("Product not found") 59 | 60 | # Display products again 61 | inventory.display_products() -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # ViLearnx Task 3: Inventory Management System 2 | 3 | ## Overview 4 | The Inventory Management System is a software solution designed to help businesses efficiently manage their inventory levels, track orders, sales, and deliveries. With a user-friendly interface, this system enables real-time inventory management, reducing errors and optimizing stock levels to meet demand. 5 | 6 | ## Features 7 | - **Real-time Inventory Tracking**: Monitor stock levels in real-time and receive notifications when inventory is low. 8 | - **Order Management**: Manage purchase orders and sales orders, including order status, delivery schedules, and order history. 9 | - **Reporting and Analytics**: Generate detailed reports and analytics on inventory levels, sales, and purchase history to aid informed business decisions. 10 | - **Supplier Management**: Maintain a database of suppliers, including contact details, order history, and performance metrics. 11 | - **User Roles and Permissions**: Define different user roles and permissions to manage access to various features and data within the system. 12 | - **Integration with Other Systems**: Seamlessly integrate with other business systems such as accounting software, e-commerce platforms, and ERP solutions. 13 | 14 | ## Technology Stack 15 | - **Backend**: Python (Flask, Django) 16 | 17 | ## Installation 18 | 1. Clone the repository: 19 | ```bash 20 | git clone https://github.com/Deepak-L-coder/ViLearnx-Task-3.git 21 | ``` 22 | 2. Navigate to the project directory: 23 | ```bash 24 | cd ViLearnx-Task-3 25 | ``` 26 | 3. Install the required dependencies: 27 | ```bash 28 | pip install -r requirements.txt 29 | ``` 30 | 31 | ## Usage 32 | To run the application, execute: 33 | ```bash 34 | python app.py 35 | ``` 36 | Visit `http://localhost:5000` in your web browser to access the Inventory Management System. 37 | 38 | ## License 39 | This project is licensed under the MIT License. See the [LICENSE](LICENSE) file for more details. 40 | 41 | ## Contributing 42 | Contributions are welcome! Please fork the repository and submit a pull request for any improvements or bug fixes. 43 | 44 | 45 | --------------------------------------------------------------------------------