Sale auto remove zero quantity lines
Upon confirming a sales order remove any sales order lines that have zero quantities.
auto_awesome What this module does
AI-generated from the code · Odoo 18.0Adds a company-level setting that automatically deletes sales order lines with zero quantity (and empty note lines) when a sales order is confirmed, leaving a message in the order's chatter.
This module gives you a new option in the Sales settings: "Automatic Removal of Zero Quantity Lines". When it is turned on for a company, confirming a sales order will automatically delete any order line whose product quantity is zero, as well as any empty note lines (lines with no text).
- The setting is company-dependent, so each company can decide separately whether to use it.
- The option appears in the Sales settings screen, right after the online signature setting.
- When lines are removed, a message is posted in the order's chatter saying that some lines with zero quantities or empty notes were removed upon confirmation.
- The removal happens before the normal confirmation process continues, so the order is confirmed without those lines.
The module touches the sales order model (sale.order), the company model (res.company) and the configuration settings model (res.config.settings). It does not add new menus or reports; it only adds one checkbox in the existing Sales configuration screen and changes the behaviour of the Confirm button on sales orders.
Depends on
Models and fields (3)
- sale.order · extends an existing model
- res.company · extends an existing modelsale_auto_remove_zero_quantity_lines
- res.config.settings · extends an existing modelsale_auto_remove_zero_quantity_lines (Automatic Removal of Zero Quantity Lines)
Text generated by AI (DeepSeek) from reading the Odoo 18.0 code on GitHub; it may contain mistakes, so check the code before deciding. View the code on GitHub
Availability by version
Reviewed: 2026-11-03Confirmation status: 3 confirmed, 6 with no information of 9 versions.
Sources · Odoo 17.0
Confirmed on 2026-11-03 in branch 17.0 of OCA/sale-workflow.
terminal Installation and usage
OCA documentation · Odoo 18.0Configuration
Source · Odoo 18.0To enable this feature you need to:
- Go to Sale \> Settings \> Quotation & Orders.
- Check Automatic Removal of Zero Quantity Lines
No verified information in OCA: Installation, Usage.
Installation instructions, the distribution package, dependencies and configuration steps are not shown because they have not yet been verified in the module documentation for any version.
Data imported from GitHub: this sheet reflects the latest catalog review, not a live lookup. Always check the module documentation and staging before installing in production.