Block Manufacturing Order
by Odoo DevHouse https://apps.odoo.com/apps/modules/browse?author=Odoo%20DevHouse$ 30.01
| Availability |
Odoo Online
Odoo.sh
On Premise
|
| Odoo Apps Dependencies |
•
Manufacturing (mrp)
• Inventory (stock) • Discuss (mail) |
| Lines of code | 27 |
| Technical Name |
dh_block_mrp |
| License | OPL-1 |
| Website | https://apps.odoo.com/apps/modules/browse?author=Odoo%20DevHouse |
| Versions | 18.0 19.0 |
| Availability |
Odoo Online
Odoo.sh
On Premise
|
| Odoo Apps Dependencies |
•
Manufacturing (mrp)
• Inventory (stock) • Discuss (mail) |
| Lines of code | 27 |
| Technical Name |
dh_block_mrp |
| License | OPL-1 |
| Website | https://apps.odoo.com/apps/modules/browse?author=Odoo%20DevHouse |
| Versions | 18.0 19.0 |
Block Manufacturing Order
Prevent manufacturing order confirmation when components are not fully available. Get a precise error listing every missing component with required and available quantities.
In standard Odoo, nothing stops a production manager from confirming a manufacturing order even when the required raw materials are not available in stock. The order moves to Confirmed or In Progress, the work centre is scheduled, and workers begin setup - only to discover mid-production that a key ingredient or component is missing.
- Manufacturing orders confirmed with zero or partial component stock
- Production halted mid-run when workers discover missing materials
- Machine downtime and labour costs wasted on setup for orders that cannot proceed
- No visibility into which components are short and by how much before confirmation
- Inventory planners unaware of the shortfall until it is too late to reorder in time
This module intercepts the Confirm button on every manufacturing order and checks each component's on-hand quantity against the required quantity before allowing the order to proceed. If any component falls short, the system raises a clear User Error that lists every insufficient component by name alongside its required quantity and available quantity - so planners can act immediately. No components missing? Confirmation proceeds normally with zero friction.
- Confirmation Gate: Blocks the Confirm action if any component is below the required quantity
- Full Component Report: All insufficient components listed in one error - not just the first one found
- Required vs Available: Each blocked component shows its required quantity and its current on-hand quantity
- UoM-Aware: Quantities are compared and displayed in the component's move unit of measure
- Zero Configuration: Works out of the box on install - no settings, rules, or mapping required
- Non-Intrusive: If all components are available, confirmation proceeds exactly as in standard Odoo
- Multi-Order Safe: Works correctly when confirming multiple manufacturing orders at once
- Lightweight: Pure Python override - no new database tables, menus, or views added
Create a Manufacturing Order
Go to Manufacturing → Manufacturing Orders → New. Select the finished product, the Bill of Materials, and the quantity to produce. The Components tab is automatically populated from the BoM with the required quantities per component.
Click Confirm
Click the Confirm button. The module instantly checks every component line against the current on-hand quantity in stock, converting quantities to the correct unit of measure for an accurate comparison.
Blocked - Component Shortage Detected
If one or more components are insufficient, a User Error dialog is raised listing every short component with its Required Quantity and Available Quantity. The manufacturing order stays in Draft - no move is confirmed, no stock reserved.
Resolve the Shortage
Use the error details to take corrective action: receive a purchase order, trigger an internal transfer, adjust the manufactured quantity to match available stock, or wait for replenishment - the exact shortfall figures are in the error message.
Confirm Succeeds - Production Starts
Once all components are available, clicking Confirm passes the check and the order moves to Confirmed state exactly as in standard Odoo - stock moves are confirmed, the work centre is scheduled, and production can begin.
Manufacturing Order - Components Tab
The standard MRP form shows the components and quantities to consume. The module checks every line when Confirm is clicked.
User Error - Component Shortage Report
When components are insufficient the system raises a clear error listing every short component with its Required Quantity and Available Quantity.
When one or more components are insufficient, the error dialog shows:
Component: Raw Material A
Required Quantity: 60.76
Available Quantity: 12.00
Component: Raw Material B
Required Quantity: 759.50
Available Quantity: 0.0
All short components appear in a single dialog - no need to click through multiple warnings to discover the full picture.
Discrete Manufacturing
Prevent assembly lines from starting when mechanical or electronic components are out of stock - avoid costly machine setup with no parts to process.
Food & Beverage
Block batch production orders when ingredients are short - critical for recipes where partial-batch production creates waste or compliance issues.
Pharmaceuticals
Ensure that every active ingredient and excipient is available before a production batch is confirmed - supporting GMP compliance and batch traceability.
Cosmetics & Chemicals
Prevent mixing orders from being confirmed when raw chemicals or packaging materials are below the minimum required batch quantity.
Print & Packaging
Block print runs when paper stock, ink, or packaging material quantities fall below what the job requires - avoiding partial or aborted print jobs.
Restaurants & Catering
Use manufacturing orders for recipe-based production and prevent production start when any ingredient is below the required amount for the batch.
Installation & Configuration
- Prerequisites: Requires Odoo 18 with the
mrpmodule installed - Install: Copy
dh_block_mrpto your addons path and install via Apps → Update App List → Search "Block Manufacturing Order" - No configuration needed: The component check is active immediately after installation - no settings to configure
- Test: Create a manufacturing order for a product whose components have insufficient on-hand stock, then click Confirm to see the error
Note: The check uses the product's current on-hand quantity (qty_available) at the time the Confirm button is clicked. It does not consider incoming purchase orders or scheduled receipts - only stock that is physically in the warehouse counts.
Does the check use forecasted quantity or on-hand quantity?
On-hand quantity only. The check compares the component's qty_available (physical stock currently in the warehouse) against what the manufacturing order needs. Forecasted incoming quantities (from purchase orders or transfers) are not counted - only what is actually on the shelf right now.
What if a component is a consumable (service type product)?
Consumable (service-type) products in Odoo always have qty_available = 0 but are never really "out of stock" in the stockable sense. If your BoM uses such components, they will always appear as available = 0 and could trigger a false block. In that case, remove service-type components from BoMs or use storable products instead.
Can I still confirm if I want to override the check?
Not by default - that is by design. The module is intentionally strict to prevent incomplete production runs. If your workflow sometimes requires confirming with partial stock (e.g. for planning purposes), the check can be removed or made optional by a developer with a one-line change in the module.
Does it work when confirming multiple manufacturing orders at once?
Yes. When multiple orders are confirmed in batch (e.g. from the list view), each order is checked independently. If any order in the batch has a shortage, that specific order's error is raised. Note: because checks are per-order, two orders competing for the same component stock may each pass individually even though together they exceed available stock.
Does this module affect any other manufacturing workflow steps?
No. Only the Confirm action is intercepted. Drafting, scheduling, producing, backorders, scrap, and all other MRP actions behave exactly as in standard Odoo 18.
Prevent Production Stoppages
Stop mid-production halts caused by missing components - the shortage is surfaced before any machine is set up or worker assigned.
Reduce Labour & Machine Waste
Avoid costly setup time spent preparing for a production run that cannot be completed - resources are only committed when all materials are confirmed in stock.
Instant Shortfall Visibility
The error message quantifies every gap precisely - planners know exactly how much more stock to source before retrying the order.
Protect Inventory Integrity
Only manufacturing orders that can actually be fulfilled reach the Confirmed state - keeping your production schedule realistic and your inventory data accurate.
Need Help or Have a Feature Request?
Odoo Proprietary License v1.0 This software and associated files (the "Software") may only be used (executed, modified, executed after modifications) if you have purchased a valid license from the authors, typically via Odoo Apps, or if you have received a written agreement from the authors of the Software (see the COPYRIGHT file). You may develop Odoo modules that use the Software as a library (typically by depending on it, importing it and using its resources), but without copying any source code or material from the Software. You may distribute those modules under the license of your choice, provided that this license is compatible with the terms of the Odoo Proprietary License (For example: LGPL, MIT, or proprietary licenses similar to this one). It is forbidden to publish, distribute, sublicense, or sell copies of the Software or modified copies of the Software. The above copyright notice and this permission notice must be included in all copies or substantial portions of the Software. THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
Please log in to comment on this module