OdooWiki OCA HUB

Sale Discount Invoicing

sale_order_discount_invoicing folder_open OCA/sale-workflow open_in_new
Sales License: AGPL-3

This module allows configuring a specific account for the accounting of discounts, which can be required by some localizations or by some accountants, especially in the e-commerce sector.

auto_awesome What this module does

AI-generated from the code · Odoo 15.0

Lets you post the discount on a sale line to a dedicated discount account by splitting the invoice line in two: one line at the original price and one line for the discount.

When enabled, this module changes how discounted sales are turned into customer invoices. Instead of a single invoice line carrying a discount percentage, the invoice is generated with two lines: one for the product at its original (undiscounted) price and a second line for the discount amount, posted to a dedicated discount account.

Where it appears in Odoo: - In Sales settings, a new option "Split Discount Lines" can be turned on. - On product categories and on products, a new "Discount Account" field lets you choose which account receives the discount. - On sale order lines, an "origin price unit" field is shown next to the unit price.

Business rules and automatic behaviour: - The split only happens when the company option is enabled and the original price is higher than the current price. - The discount line is posted to the discount account taken from the product, or from its product category if the product has none. - The two lines are linked to the same sale order line, and Odoo checks that they stay together: if you add, remove or change one of them, an error asks you to do the same on the other. - Invoiced quantities on the sale order line ignore the discount line, so quantities stay correct.

It touches sale orders, customer invoices and their lines, products, product categories and company settings.

Depends on

accountsale
Models and fields (7)
  • res.company · extends an existing modelaccount_split_discount_line (Split Discount Lines)
  • account.move · extends an existing model
  • sale.order.line · extends an existing modelorigin_price_unit
  • product.category · extends an existing modelproperty_account_discount_categ_id (Discount Account)
  • product.template · extends an existing modelproperty_account_discount_id (Discount Account)
  • account.move.line · extends an existing modelis_split_line, is_split_discount_line, discount_split_by_sale_line_id
  • res.config.settings · extends an existing modelaccount_split_discount_line (Split Discount Lines)

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-03
Confirmed (verified in repository and branch) Estimated (unverified) No information

Confirmation status: 1 confirmed, 8 with no information of 9 versions.

Sources · Odoo 15.0

Confirmed on 2026-11-03 in branch 15.0 of OCA/sale-workflow.

terminal Installation and usage

OCA documentation · Odoo 15.0

To use the module you need to:

  • allow sale lines splitting (if discounted) in the sales configuration
  • configure a discount account on the product category or product template (according to you needs)

On a sale order, set the origin price unit.

When an invoice is created, the unit price is accounted for in the income account, and the discount is accounted in the discount account of the product.

No verified information in OCA: Installation.

info

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.