- Author Massaoud Bouzenad
- Module version 1.0.0
- Release date 09/23/2025
- Access to updates and downloads 365 days
|
- How to contact support products@dzprod.net
- Compatibility Dolibarr
V12 - V22
- PHP>= 7.4
- Last update 09/24/2025 03:02 PM
|
More info
Smart Kit Stock Management for Dolibarr
Compostock optimizes the management of your virtual products (kits) by providing real-time visibility into your actual available stock. No more guesswork, get precise calculations that combine physical kit stock with assemblable quantities.
Key Features
- Automatic Calculation - Real-time stock updates via intelligent triggers
- Multi-Level Kits - Support for nested kits up to 2 levels deep
- Limiting Component Detection - Instantly identify bottleneck components
- Performance Optimized - Built for high-volume environments with smart caching
- Configurable Behavior - Choose between automatic or manual recalculation
- Non-Intrusive Design - Uses extrafields, no core table modifications
How It Works
The magic formula: Compostock = Physical_Stock + MIN(component_stock / required_quantity)
Example: Kit ABC (2×A + 3×B + 1×C)
- Physical kit stock: 5 units
- Components: A=10, B=8, C=12
- Assemblable: MIN(10/2, 8/3, 12/1) = MIN(5, 2, 12) = 2
- Total Compostock = 5 + 2 = 7 available kits
🔄 Automatic Stock Recalculation
Compostock automatically updates kit availability whenever stock movements occur:
- Component Stock Changes - When components are received, shipped, or consumed, all impacted kits are instantly recalculated
- Kit Stock Movements - Direct kit entries/exits automatically update the physical stock portion
- Smart Cascade Updates - Multi-level kits are recalculated recursively when sub-components change
- Real-time Visibility - Sales teams always see current assemblable quantities without manual intervention
Example: When component A stock drops from 10 to 6, Kit ABC availability instantly updates from 7 to 6 units (5 physical + 1 assemblable)
Business Benefits
- Accurate Sales Forecasting - Know exactly what you can sell
- Optimized Purchasing - Identify which components to reorder
- Reduced Waste - Prevent overproduction and obsolete inventory
- Improved Planning - Make informed decisions based on real data
Technical Excellence
- ✅ Compatible with Dolibarr 12.0+
- ✅ Multi-entity support
- ✅ Trigger-based automation
- ✅ Manual recalculation tools
- ✅ Performance monitoring
- ✅ Comprehensive diagnostics
Perfect For
- Manufacturing companies with assembly processes
- Distributors managing product kits
- Retailers with bundle products
- Any business combining components into finished products
Future Evolution & Extensions
Compostock lays the foundation for advanced industrial management features:
📦 Cannibalization & Component Recovery
- Extended Recomposable Stock - Calculation including recoverable components from other products in stock
- Dismountable Parts Management - Automatic identification of recoverable components through disassembly
- Multi-Source Optimization - Suggest the best assembly/recovery combination to maximize availability
🔧 Simplified Assembly/Disassembly
- Lightweight BOM Alternative - For simple assemblies without complex manufacturing processes
- Manual Operations - Ideal for screwdriver assembly, clipping, simple screwing
- Instant Actions - No planning or heavy resources required
- Logistics Focus - Optimized for stock management, not industrial production
Example: Click "Disassemble Kit ABC" → Kit stock -1, Stock A +2, Stock B +3, Stock C +1 automatically
Installation: Simply install and activate - works out of the box with intelligent defaults!
🔧 Required Setup: Configure your kits with incdec=0 to avoid double-counting between kit and component stocks.