Version 1.7.0 – Inventory Module Now Live!
We’re excited to announce Version 1.7.0, introducing a powerful new Inventory Management Module designed for real-time tracking, operational efficiency, and seamless POS integration. This release lays the foundation for complete restaurant stock control and waste optimization.
v1.7.0 (08-May-2025)
- Inventory Stock Management – Add, update, or delete stock items, manage quantities and units with full control.
- Inventory Movements – Log and track all stock-ins, stock-outs, and wastage with full traceability.
- Low Stock Alerts – Receive real-time alerts directly in the POS when stock levels fall below the defined threshold.
- Inventory Dashboard – Get a unified view of cummulative stock movements and track Usage VS Current stock along with status.
- Recipe Creation – Define raw material requirements and quantities for each menu item using recipes.
- Recipe-Based Stock Tracking – Automatically deduct raw materials based on the recipes when orders are placed.
- Wastage Tracking – Inventory changes due to wastage are managed through controlled manual entry.
Update Guide
Step 1: Update DB
1.1 Create the inventory_items
table
This table tracks all inventory items, including quantity, unit, and stock thresholds.
CREATE TABLE `inventory_items` (
`id` int NOT NULL AUTO_INCREMENT,
`title` varchar(255) NOT NULL,
`quantity` decimal(10,4) DEFAULT '0.0000',
`unit` enum('pc','kg','g','l','ml') NOT NULL,
`min_quantity_threshold` decimal(10,4) NOT NULL,
`status` enum('low','in','out') DEFAULT NULL,
`created_at` timestamp NULL DEFAULT CURRENT_TIMESTAMP,
`updated_at` timestamp NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP,
`tenant_id` int DEFAULT NULL,
PRIMARY KEY (`id`),
KEY `fk_tenant_id_idx` (`tenant_id`),
CONSTRAINT `fk_tenant_id` FOREIGN KEY (`tenant_id`) REFERENCES `tenants` (`id`) ON DELETE CASCADE ON UPDATE CASCADE
);
1.2 Create the inventory_logs
table
This table logs all inventory movements (IN, OUT, WASTAGE), including quantity changes.
CREATE TABLE `inventory_logs` (
`id` int NOT NULL AUTO_INCREMENT,
`tenant_id` int NOT NULL,
`inventory_item_id` int NOT NULL,
`type` enum('IN','OUT','WASTAGE') NOT NULL,
`quantity_change` decimal(10,4) NOT NULL,
`previous_quantity` decimal(10,4) DEFAULT NULL,
`new_quantity` decimal(10,4) DEFAULT NULL,
`note` varchar(255) DEFAULT NULL,
`created_by` varchar(255) DEFAULT NULL,
`created_at` timestamp NULL DEFAULT CURRENT_TIMESTAMP,
PRIMARY KEY (`id`),
KEY `tenant_id` (`tenant_id`),
KEY `inventory_item_id` (`inventory_item_id`),
KEY `inventory_logs_ibfk_3` (`created_by`),
CONSTRAINT `inventory_logs_ibfk_1` FOREIGN KEY (`tenant_id`) REFERENCES `tenants` (`id`) ON DELETE CASCADE,
CONSTRAINT `inventory_logs_ibfk_2` FOREIGN KEY (`inventory_item_id`) REFERENCES `inventory_items` (`id`) ON DELETE CASCADE,
CONSTRAINT `inventory_logs_ibfk_3` FOREIGN KEY (`created_by`) REFERENCES `users` (`username`) ON DELETE SET NULL
);
1.3 Create the menu_item_recipes
table
This table tracks the raw material requirements for menu items and allows for recipe-based stock tracking.
CREATE TABLE `menu_item_recipes` (
`id` int NOT NULL AUTO_INCREMENT,
`menu_item_id` int DEFAULT NULL,
`variant_id` int NOT NULL DEFAULT '0',
`addon_id` int NOT NULL DEFAULT '0',
`inventory_item_id` int NOT NULL,
`quantity` decimal(10,4) NOT NULL,
`tenant_id` int DEFAULT NULL,
`created_at` timestamp NULL DEFAULT CURRENT_TIMESTAMP,
`updated_at` timestamp NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP,
PRIMARY KEY (`id`),
UNIQUE KEY `uniq_recipe_combo` (`menu_item_id`,`inventory_item_id`,`variant_id`,`addon_id`),
KEY `inventory_item_id` (`inventory_item_id`),
KEY `tenant_id` (`tenant_id`),
CONSTRAINT `menu_item_recipes_ibfk_1` FOREIGN KEY (`menu_item_id`) REFERENCES `menu_items` (`id`) ON DELETE CASCADE,
CONSTRAINT `menu_item_recipes_ibfk_2` FOREIGN KEY (`inventory_item_id`) REFERENCES `inventory_items` (`id`) ON DELETE CASCADE,
CONSTRAINT `menu_item_recipes_ibfk_3` FOREIGN KEY (`tenant_id`) REFERENCES `tenants` (`id`) ON DELETE CASCADE
);
Step 2: Update Backend Code
- Replace the existing backend files with the latest version from the v1.7.0 release.
- Run any required migrations or seeders to initialize inventory-related tables.
- Follow the original RestroPRO setup guide for any new
.env
or configuration updates.
Step 3: Update Frontend Code
- Replace existing frontend code with the updated files from the v1.7.0 branch.
- Clear local storage/cache and rebuild the frontend for the changes to reflect.
- Confirm visibility of the new Inventory, Movements, and Recipe sections in the admin panel.
Feature Usage Notes
- Inventory Setup: Before tracking live orders, initialize your inventory with all ingredients, units, and stock levels.
- Recipe Linking: Link each menu item with its recipe to ensure auto-deduction works accurately.
- Wastage Logs: Use the wastage module regularly to account for discrepancies and avoid inflated stock reports.
- Low Stock Alerts: Configure minimum threshold levels to enable real-time alerts during high traffic hours.
📦 Upgrade now to start managing your kitchen inventory like a pro!