OdooWiki OCA HUB

Price recalculation in purchases orders

purchase_order_price_recalculation folder_open OCA/purchase-workflow open_in_new
Purchase Management License: AGPL-3

This module adds one button on purchase orders (below the lines) that:

  • Recalculates the prices of the order lines that contain a product in them.

It is launched manually as a button to get the user to decide if he/she wants to recalculate prices when vendor is changed or after duplicating a purchase order to update or not purchase information.

auto_awesome What this module does

AI-generated from the code · Odoo 18.0

Adds an 'Update lines info' button on draft and sent purchase orders that recalculates the prices of all order lines based on the currently selected vendor.

This module adds a single button to the purchase order form, placed next to the existing unlock button. The button is labelled 'Update lines info' and shows a refresh icon.

  • It is only visible while the purchase order is in Draft or Sent status, so it cannot be used on confirmed or locked orders.
  • When clicked, a confirmation message appears: 'This will update all the line prices based on the vendor currently set. Do you want to continue?' This gives the user the choice to recalculate or cancel.
  • If confirmed, every order line is recalculated using the current vendor's product information, updating the unit price, the planned date and the line description.

This is useful after changing the vendor on a purchase order or after duplicating one, because Odoo does not automatically refresh line prices in those situations. The module only touches the purchase.order model and its form view; it does not add menus, reports, scheduled jobs or automatic rules.

Depends on

purchase
Models and fields (1)
  • purchase.order · extends an existing model

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

Confirmation status: 4 confirmed, 5 with no information of 9 versions.

Sources · Odoo 18.0

Confirmed on 2026-11-03 in branch 18.0 of OCA/purchase-workflow.

terminal Installation and usage

OCA documentation · Odoo 18.0
  • Go to Purchase -\> Products \> Products and create some record and set differente prices to vendors in Purchase tab, for example: Vendor 1: 10 and Vendor 2: 20.
  • Go to Purchase -\> Orders \> Requests for Quotation and create some record and set Vendor 1.
  • Add a line with the previously created product.
  • The unit price of the product is 10.
  • Change vendor to Vendor 2.
  • Click on the "Update lines info" button.
  • The unit price of the product is 20.

No verified information in OCA: Installation, Configuration.

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.