OdooWiki OCA HUB

Purchase order line price history

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

This module extends the functionality of Purchase to allow you to see the price history of a product from a purchase order line and set one of these old prices in the purchase order line.

auto_awesome What this module does

AI-generated from the code · Odoo 15.0

Adds a clock button on each purchase order line that opens a pop-up showing the last prices paid to the supplier for that product, and lets you apply one of those old prices to the current line.

When you are filling in a purchase order, each line in the order lines list now shows a small clock icon. Clicking it opens a pop-up window called "Price history per supplier" for that line.

The pop-up shows the product and the supplier, plus two options: - "Include RFQ": also show prices from requests for quotation that are still in draft, sent or to-approve status (by default only confirmed and completed purchases are shown). - "Include commercial entity": also include the supplier's parent company and its contacts (this is on by default).

Changing the supplier or either option refreshes the list. The list shows up to 20 earlier purchase order lines for the same product and supplier, with the order, supplier, order date, quantity and unit price. The current line is excluded.

Opening a history line shows a "Set price" button that copies that old unit price onto the purchase order line you started from. A "Close" button closes the window without changing anything.

The module only adds these two pop-up screens and the button; it does not change how purchase orders are otherwise created or confirmed. It works on purchase.order.line and purchase.order and is available to all internal users in read-only mode.

Depends on

purchase
Models and fields (2)
  • purchase.order.line.price.history · new modelline_ids (History lines), partner_id (Supplier), product_id, include_rfq (Include RFQ), purchase_order_line_id (Purchase order line), include_commercial_partner (Include commercial entity)
  • purchase.order.line.price.history.line · new modelorder_id, history_id (History), partner_id, price_unit, product_qty, product_uom, purchase_order_line_id (Purchase order line), purchase_order_date_order

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: 4 confirmed, 5 with no information of 9 versions.

Sources · Odoo 15.0

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

terminal Installation and usage

OCA documentation · Odoo 15.0

To use this module, you need to:

  • Go to Purchase -> Orders -> Requests for Quotation and select a Requests for Quotation or create a new one.
  • Click on the new clock button in one of the order lines.
  • A pop-up will open and you will see the price history for the product of the order line and for the supplier of the selected or created Requests for Quotation.
  • You can select another supplier or leave it empty to see the price history for all suppliers.
  • You can also set the price of one of the price history lines to the order line. To do that, you have to open the price history line desired and click the smart button named Set price.

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.