Markup rate on product and sales

sale_markup
REPOSITORY
REPOSITORYOCA/sale-financial
GIT
GIThttps://github.com/OCA/sale-financial.git
GIT FOLDER
GIT FOLDERhttps://github.com/OCA/sale-financial/tree/10.0/sale_markup
VERSION
VERSION 5.1
CATEGORY
CATEGORYversion
LICENSE
LICENSEAGPL-3
APPLICATION
APPLICATIONYes
AUTO-INSTALLABLE
AUTO-INSTALLABLENo
AUTHORS
AUTHORSOdoo Community Association (OCA), Camptocamp
MAINTAINERS
MAINTAINERSCamptocamp
COMMITTERS
COMMITTERSPedro M. Baeza
WEBSITE
WEBSITEhttp://www.camptocamp.com/
LAST TRACKING UPDATE
LAST TRACKING UPDATE2026-07-06 00:19:54
ODOO DEPENDENCIES
ODOO DEPENDENCIES OCA/sale-financial:
    - sale_floor_price
    - sale_line_watcher
odoo/odoo:
    - base
    - mrp
    - product
    - decimal_precision
    - mail
    - base_setup
    - web_kanban
    - web
    - bus
    - web_tour
    - report
    - stock
    - procurement
    - barcodes
    - web_planner
    - resource
    - sale
    - sales_team
    - account
    - analytic
PYTHON DEPENDENCIES
PYTHON DEPENDENCIES Not have
SYSTEM DEPENDENCIES
SYSTEM DEPENDENCIES Not have
DESCRIPTION
DESCRIPTION
display the product and sale markup in the appropriate views

Code Analysis

Views touched (7)
XML IDNameModelTypeStatus
sale_markup_product_form product.markup.view.form product.product field Inherits product.product_normal_form_view
sale_markup_product_tree product.markup.view.tree product.product field Inherits product.product_product_tree_view
sale_markup_sale_order_form_line_form sale.order.markup.view.form2 sale.order xpath Inherits sale.view_order_form
sale_markup_sale_order_form_line_tree sale.order.markup.view.form sale.order xpath Inherits sale.view_order_form
sale_markup_sale_order_line_tree sale.order.line.markup.view.tree sale.order.line field Inherits sale.view_order_line_tree
sale_markup_sale_order_tree sale.order.markup.view.tree sale.order field Inherits sale.view_order_tree
sale_markup_sale_order_view sale.order.markup.view.form sale.order xpath Inherits sale.view_order_form
Models touched (3)

New fields (0)

No new fields.

Public methods (1)
  • compute_markup(self, cursor, user, ids, product_uom=None, pricelist=None, sale_price=None, properties=None, context=None)
    compute markup If properties, pricelist and sale_price arguments are set, it will be used to compute all results

New fields (0)

No new fields.

Public methods (0)

No public methods.

New fields (0)

No new fields.

Public methods (5)
  • onchange_commercial_margin(self, cursor, uid, ids, margin, cost_price, price_unit, context=None)
    If markup rate change compute the discount
  • onchange_discount(self, cursor, uid, ids, price_unit, product_id, discount, product_uom, pricelist, **kwargs)
    If discount change, compute the new markup rate
  • onchange_markup_rate(self, cursor, uid, ids, markup, cost_price, price_unit, context=None)
    If markup rate change compute the discount
  • onchange_price_unit(self, cursor, uid, ids, price_unit, product_id, discount, product_uom, pricelist, **kwargs)
    If price unit change, compute the new markup rate.
  • product_id_change(self, cursor, uid, ids, pricelist, product, qty=0, uom=False, qty_uos=0, uos=False, name='', partner_id=False, lang=False, update_tax=True, date_order=False, packaging=False, fiscal_position=False, flag=False, discount=None, price_unit=None, context=None)
    Overload method If product change, compute the new markup. Added params : - price_unit, - discount - properties
REPOSITORY
REPOSITORYOCA/sale-financial
GIT
GIThttps://github.com/OCA/sale-financial.git
GIT FOLDER
GIT FOLDERhttps://github.com/OCA/sale-financial/tree/9.0/sale_markup
VERSION
VERSION 5.1
CATEGORY
CATEGORYversion
LICENSE
LICENSEAGPL-3
APPLICATION
APPLICATIONYes
AUTO-INSTALLABLE
AUTO-INSTALLABLENo
AUTHORS
AUTHORSOdoo Community Association (OCA), Camptocamp
MAINTAINERS
MAINTAINERSCamptocamp
COMMITTERS
COMMITTERS
WEBSITE
WEBSITEhttp://www.camptocamp.com/
LAST TRACKING UPDATE
LAST TRACKING UPDATE2026-07-06 00:15:19
ODOO DEPENDENCIES
ODOO DEPENDENCIES OCA/sale-financial:
    - sale_floor_price
    - sale_line_watcher
odoo/odoo:
    - base
    - mrp
    - product
    - decimal_precision
    - mail
    - base_setup
    - web_kanban
    - web
    - bus
    - report
    - procurement
    - stock_account
    - stock
    - barcodes
    - web_planner
    - account
    - analytic
    - web_tip
    - resource
    - sale
    - sales_team
PYTHON DEPENDENCIES
PYTHON DEPENDENCIES Not have
SYSTEM DEPENDENCIES
SYSTEM DEPENDENCIES Not have
DESCRIPTION
DESCRIPTION
display the product and sale markup in the appropriate views

Code Analysis

Views touched (7)
XML IDNameModelTypeStatus
sale_markup_product_form product.markup.view.form product.product field Inherits product.product_normal_form_view
sale_markup_product_tree product.markup.view.tree product.product field Inherits product.product_product_tree_view
sale_markup_sale_order_form_line_form sale.order.markup.view.form2 sale.order xpath Inherits sale.view_order_form
sale_markup_sale_order_form_line_tree sale.order.markup.view.form sale.order xpath Inherits sale.view_order_form
sale_markup_sale_order_line_tree sale.order.line.markup.view.tree sale.order.line field Inherits sale.view_order_line_tree
sale_markup_sale_order_tree sale.order.markup.view.tree sale.order field Inherits sale.view_order_tree
sale_markup_sale_order_view sale.order.markup.view.form sale.order xpath Inherits sale.view_order_form
Models touched (3)

New fields (0)

No new fields.

Public methods (1)
  • compute_markup(self, cursor, user, ids, product_uom=None, pricelist=None, sale_price=None, properties=None, context=None)
    compute markup If properties, pricelist and sale_price arguments are set, it will be used to compute all results

New fields (0)

No new fields.

Public methods (0)

No public methods.

New fields (0)

No new fields.

Public methods (5)
  • onchange_commercial_margin(self, cursor, uid, ids, margin, cost_price, price_unit, context=None)
    If markup rate change compute the discount
  • onchange_discount(self, cursor, uid, ids, price_unit, product_id, discount, product_uom, pricelist, **kwargs)
    If discount change, compute the new markup rate
  • onchange_markup_rate(self, cursor, uid, ids, markup, cost_price, price_unit, context=None)
    If markup rate change compute the discount
  • onchange_price_unit(self, cursor, uid, ids, price_unit, product_id, discount, product_uom, pricelist, **kwargs)
    If price unit change, compute the new markup rate.
  • product_id_change(self, cursor, uid, ids, pricelist, product, qty=0, uom=False, qty_uos=0, uos=False, name='', partner_id=False, lang=False, update_tax=True, date_order=False, packaging=False, fiscal_position=False, flag=False, discount=None, price_unit=None, context=None)
    Overload method If product change, compute the new markup. Added params : - price_unit, - discount - properties
REPOSITORY
REPOSITORYOCA/sale-financial
GIT
GIThttps://github.com/OCA/sale-financial.git
GIT FOLDER
GIT FOLDERhttps://github.com/OCA/sale-financial/tree/8.0/sale_markup
VERSION
VERSION 5.1
CATEGORY
CATEGORYversion
LICENSE
LICENSEAGPL-3
APPLICATION
APPLICATIONYes
AUTO-INSTALLABLE
AUTO-INSTALLABLENo
AUTHORS
AUTHORSOdoo Community Association (OCA), Camptocamp
MAINTAINERS
MAINTAINERSCamptocamp
COMMITTERS
COMMITTERSStéphane Bidoul, Alexandre Fayolle
WEBSITE
WEBSITEhttp://www.camptocamp.com/
LAST TRACKING UPDATE
LAST TRACKING UPDATE2026-07-06 00:11:20
ODOO DEPENDENCIES
ODOO DEPENDENCIES OCA/sale-financial:
    - sale_floor_price
    - sale_line_watcher
odoo/odoo:
    - base
    - mrp
    - product
    - decimal_precision
    - mail
    - base_setup
    - web_kanban
    - web
    - report
    - procurement
    - stock_account
    - stock
    - board
    - web_kanban_gauge
    - web_kanban_sparkline
    - account
    - analytic
    - edi
    - email_template
    - resource
    - sale
    - sales_team
    - account_voucher
PYTHON DEPENDENCIES
PYTHON DEPENDENCIES Not have
SYSTEM DEPENDENCIES
SYSTEM DEPENDENCIES Not have
DESCRIPTION
DESCRIPTION
display the product and sale markup in the appropriate views

Code Analysis

Views touched (7)
XML IDNameModelTypeStatus
sale_markup_product_form product.markup.view.form product.product field Inherits product.product_normal_form_view
sale_markup_product_tree product.markup.view.tree product.product field Inherits product.product_product_tree_view
sale_markup_sale_order_form_line_form sale.order.markup.view.form2 sale.order xpath Inherits sale.view_order_form
sale_markup_sale_order_form_line_tree sale.order.markup.view.form sale.order xpath Inherits sale.view_order_form
sale_markup_sale_order_line_tree sale.order.line.markup.view.tree sale.order.line field Inherits sale.view_order_line_tree
sale_markup_sale_order_tree sale.order.markup.view.tree sale.order field Inherits sale.view_order_tree
sale_markup_sale_order_view sale.order.markup.view.form sale.order xpath Inherits sale.view_order_form
Models touched (3)

New fields (0)

No new fields.

Public methods (1)
  • compute_markup(self, cursor, user, ids, product_uom=None, pricelist=None, sale_price=None, properties=None, context=None)
    compute markup If properties, pricelist and sale_price arguments are set, it will be used to compute all results

New fields (0)

No new fields.

Public methods (0)

No public methods.

New fields (0)

No new fields.

Public methods (5)
  • onchange_commercial_margin(self, cursor, uid, ids, margin, cost_price, price_unit, context=None)
    If markup rate change compute the discount
  • onchange_discount(self, cursor, uid, ids, price_unit, product_id, discount, product_uom, pricelist, **kwargs)
    If discount change, compute the new markup rate
  • onchange_markup_rate(self, cursor, uid, ids, markup, cost_price, price_unit, context=None)
    If markup rate change compute the discount
  • onchange_price_unit(self, cursor, uid, ids, price_unit, product_id, discount, product_uom, pricelist, **kwargs)
    If price unit change, compute the new markup rate.
  • product_id_change(self, cursor, uid, ids, pricelist, product, qty=0, uom=False, qty_uos=0, uos=False, name='', partner_id=False, lang=False, update_tax=True, date_order=False, packaging=False, fiscal_position=False, flag=False, discount=None, price_unit=None, context=None)
    Overload method If product change, compute the new markup. Added params : - price_unit, - discount - properties
REPOSITORY
REPOSITORYOCA/sale-financial
GIT
GIThttps://github.com/OCA/sale-financial.git
GIT FOLDER
GIT FOLDERhttps://github.com/OCA/sale-financial/tree/7.0/sale_markup
VERSION
VERSION 5.1
CATEGORY
CATEGORYversion
LICENSE
LICENSEAGPL-3
APPLICATION
APPLICATIONYes
AUTO-INSTALLABLE
AUTO-INSTALLABLENo
AUTHORS
AUTHORSOdoo Community Association (OCA), Camptocamp
MAINTAINERS
MAINTAINERSCamptocamp
COMMITTERS
COMMITTERSYannick Vaucher, Alexandre Fayolle, Joel Grand-Guillaume, Leonardo Pistone
WEBSITE
WEBSITEhttp://www.camptocamp.com/
LAST TRACKING UPDATE
LAST TRACKING UPDATE2026-07-06 00:07:13
ODOO DEPENDENCIES
ODOO DEPENDENCIES OCA/margin-analysis:
    - product_get_cost_field
OCA/sale-financial:
    - sale_line_watcher
OCA/server-tools:
    - web_context_tunnel
odoo/odoo:
    - base
    - product
    - process
    - web
    - decimal_precision
    - mail
    - base_setup
    - web_kanban
    - mrp
    - procurement
    - stock
    - account
    - analytic
    - board
    - edi
    - email_template
    - resource
    - purchase
    - sale
    - account_voucher
PYTHON DEPENDENCIES
PYTHON DEPENDENCIES Not have
SYSTEM DEPENDENCIES
SYSTEM DEPENDENCIES Not have
DESCRIPTION
DESCRIPTION
Markup rate on product and sales
================================

Display the product and sale markup in the appropriate views

Code Analysis

Views touched (7)
XML IDNameModelTypeStatus
sale_markup_product_form product.markup.view.form product.product field Inherits product.product_normal_form_view
sale_markup_product_tree product.markup.view.tree product.product field Inherits product.product_product_tree_view
sale_markup_sale_order_form_line_form sale.order.markup.view.form2 sale.order xpath Inherits sale.view_order_form
sale_markup_sale_order_form_line_tree sale.order.markup.view.form sale.order xpath Inherits sale.view_order_form
sale_markup_sale_order_line_tree sale.order.line.markup.view.tree sale.order.line field Inherits sale.view_order_line_tree
sale_markup_sale_order_tree sale.order.markup.view.tree sale.order field Inherits sale.view_order_tree
sale_markup_sale_order_view sale.order.markup.view.form sale.order xpath Inherits sale.view_order_form
Models touched (3)

New fields (0)

No new fields.

Public methods (1)
  • compute_markup(self, cr, uid, ids, product_uom=None, pricelist=None, sale_price=None, properties=None, context=None)
    compute markup If properties, pricelist and sale_price arguments are set, it will be used to compute all results

New fields (0)

No new fields.

Public methods (0)

No public methods.

New fields (0)

No new fields.

Public methods (5)
  • onchange_commercial_margin(self, cr, uid, ids, context=None)
    If commercial margin changes compute the discount context arguments: commercial_margin markup_rate discount cost_price price_unit break_onchange Will change: discount markup_rate
  • onchange_discount(self, cr, uid, ids, context=None, **kwargs)
    If discount changes, compute the new markup rate and commercial margin. context arguments: product_id price_unit discount product_uom pricelist markup_rate commercial_margin break_onchange Will change: markup_rate commercial_margin
  • onchange_markup_rate(self, cr, uid, ids, context=None)
    If markup rate changes compute the discount context arguments: markup_rate commercial_margin cost_price price_unit break_onchange Will change: discount commercial_margin
  • onchange_price_unit(self, cr, uid, ids, context=None, **kwargs)
    If price unit changes, compute the new markup rate and commercial margin context arguments: price_unit product_id discount product_uom pricelist markup_rate commercial_margin Will change: markup_rate commercial_margin
  • product_id_change(self, cr, uid, ids, pricelist, product, qty=0, uom=False, qty_uos=0, uos=False, name='', partner_id=False, lang=False, update_tax=True, date_order=False, packaging=False, fiscal_position=False, flag=False, context=None)
    Overload method If product changes, compute the new markup, cost_price and commercial_margin. Added params : - price_unit - discount - markup_rate - commercial_margin Will change: markup_rate commercial_margin
REPOSITORY
REPOSITORYOCA/sale-financial
GIT
GIThttps://github.com/OCA/sale-financial.git
GIT FOLDER
GIT FOLDERhttps://github.com/OCA/sale-financial/tree/6.1/sale_markup
VERSION
VERSION 5.1
CATEGORY
CATEGORYversion
LICENSE
LICENSEAGPL-3
APPLICATION
APPLICATIONYes
AUTO-INSTALLABLE
AUTO-INSTALLABLENo
AUTHORS
AUTHORSOdoo Community Association (OCA), Camptocamp
MAINTAINERS
MAINTAINERSCamptocamp
COMMITTERS
COMMITTERSYannick Vaucher, Guewen Baconnier, Alexandre Fayolle, Joël Grand-Guillaume, unknown, Alexandre Fayolle @ camptocamp, Guewen Baconnier @ Camptocamp
WEBSITE
WEBSITEhttp://www.camptocamp.com/
LAST TRACKING UPDATE
LAST TRACKING UPDATE2026-07-06 00:04:05
ODOO DEPENDENCIES
ODOO DEPENDENCIES OCA/margin-analysis:
    - product_get_cost_field
OCA/sale-financial:
    - sale_floor_price
    - sale_line_watcher
odoo/odoo:
    - base
    - product
    - process
    - decimal_precision
    - mrp
    - procurement
    - stock
    - account
    - base_setup
    - analytic
    - board
    - edi
    - email_template
    - mail
    - base_tools
    - resource
    - purchase
    - sale
PYTHON DEPENDENCIES
PYTHON DEPENDENCIES Not have
SYSTEM DEPENDENCIES
SYSTEM DEPENDENCIES Not have
DESCRIPTION
DESCRIPTION
display the product and sale markup in the appropriate views

Code Analysis

Views touched (7)
XML IDNameModelTypeStatus
sale_markup_product_form product.markup.view.form product.product field Inherits product.product_normal_form_view
sale_markup_product_tree product.markup.view.tree product.product field Inherits product.product_product_tree_view
sale_markup_sale_order_form_line_form sale.order.markup.view.form2 sale.order xpath Inherits sale.view_order_form
sale_markup_sale_order_form_line_tree sale.order.markup.view.form sale.order xpath Inherits sale.view_order_form
sale_markup_sale_order_line_tree sale.order.line.markup.view.tree sale.order.line field Inherits sale.view_order_line_tree
sale_markup_sale_order_tree sale.order.markup.view.tree sale.order field Inherits sale.view_order_tree
sale_markup_sale_order_view sale.order.markup.view.form sale.order xpath Inherits sale.view_order_form
Models touched (3)

New fields (0)

No new fields.

Public methods (1)
  • compute_markup(self, cursor, user, ids, product_uom=None, pricelist=None, sale_price=None, properties=None, context=None)
    compute markup If properties, pricelist and sale_price arguments are set, it will be used to compute all results

New fields (0)

No new fields.

Public methods (0)

No public methods.

New fields (0)

No new fields.

Public methods (5)
  • onchange_commercial_margin(self, cursor, uid, ids, margin, cost_price, price_unit, context=None)
    If markup rate change compute the discount
  • onchange_discount(self, cursor, uid, ids, price_unit, product_id, discount, product_uom, pricelist, **kwargs)
    If discount change, compute the new markup rate
  • onchange_markup_rate(self, cursor, uid, ids, markup, cost_price, price_unit, context=None)
    If markup rate change compute the discount
  • onchange_price_unit(self, cursor, uid, ids, price_unit, product_id, discount, product_uom, pricelist, **kwargs)
    If price unit change, compute the new markup rate.
  • product_id_change(self, cursor, uid, ids, pricelist, product, qty=0, uom=False, qty_uos=0, uos=False, name='', partner_id=False, lang=False, update_tax=True, date_order=False, packaging=False, fiscal_position=False, flag=False, discount=None, price_unit=None, context=None)
    Overload method If product change, compute the new markup. Added params : - price_unit, - discount - properties