This module allows to auto apply the programs without the need of the user intervention.
auto_awesome What this module does
AI-generated from the code · Odoo 15.0Automatically re-applies promotion programs marked as auto-apply on sales orders whenever the order or its lines change, without the user having to click anything.
This module makes Odoo keep promotions up to date on quotations and sales orders by itself. A new company-level setting, "Auto Refresh Coupons", appears in the Sales settings next to the discount option; when enabled, Odoo recalculates the auto-apply promotion programs each time a relevant change happens on an order.
- The refresh happens when a sales order is created or edited, and when its order lines are added, changed or deleted. Changes to the customer, product, quantity, unit price, unit of measure, taxes or discount are the triggers.
- Only orders in draft or sent state are refreshed, so confirmed orders are left untouched.
- The recalculation is skipped when the change comes from the website or when the system itself is already processing a coupon, to avoid loops and unwanted side effects.
- The coupon application wizard is also protected so a coupon is not discarded in the middle of the process.
Administrators can extend the list of fields that trigger a refresh through a system parameter, without changing the code. The setting is company-specific, so different companies can behave differently.
Depends on
Required by other modules
Models and fields (6)
- sale.order · new modelauto_refresh_coupon
- res.company · extends an existing modelauto_refresh_coupon (Auto Refresh Coupons)
- sale.order.line · new model
- res.config.settings · extends an existing modelauto_refresh_coupon
- sale.coupon.apply.code · extends an existing model
- sale.coupon.refresh.mixin · new modelauto_refresh_coupon_triggers_data
Text generated by AI (DeepSeek) from reading the Odoo 15.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 14.0
Confirmed on 2026-11-03 in branch 14.0 of OCA/sale-promotion.
terminal Installation and usage
OCA documentation · Odoo 15.0Configuration
Source · Odoo 15.0You can set this feature on or off in every company. To do so:
- Go to Sales > Configuration > Settings
- In the Pricing section you'll find the option Auto refresh promotions.
The auto-refresh in the backend is triggered over a minimum set of fields changes. If you want to extend the list of that fields:
- Go to Settings > Technical > Config parameters
- Add or update the key:
- For
sale.order:sale_coupon_auto_refresh.sale_order_triggers - For
sale.order.line:sale_coupon_auto_refresh.sale_order_line_triggers - In every add the fields seperated by commas that you want to add to the recomputation triggers.
⚠️ After configuring or removiming a trigger a restart of Odoo is recommended so the depends are reloaded properly. Anyway it isn't mandatory and the module detects the new triggers so the auto-refresh works as expected as soon as they are set.
Usage
Source · Odoo 15.0You need to configure a Promotion program with the option Promo Code Usage set to Automatically applied. This can be done in Sales > Products > Promotion programs.
Now, make a quotation that fulfill the promotion condition and the promotion will be automatically applied.
No verified information in OCA: Installation.
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.