Skip to content
Health
60/100
fair
  • Security25/25
    No findings
  • Activity25/25
    Human commit this month
  • Required by5/25
    0 modules depend on it
  • Maturity5/25
    In 1 Odoo series since 19.0

Heuristic over the facts below, not an audit · How it's computed

Security findings
Grave / minor (static analysis)
Required by
0
Modules depending on it
External deps
0 pip · 0 bin
Python packages / system binaries
License
AGPL-3
No conflicts with its dependencies
Folder size
0.07 MB
Module directory on disk
Code analysis 0 migration notes 3 models 5 views 0 HTTP endpoints

Description

This module allows to trace the usage of stock move valuation. That is, makes it possible to identify which stock moves were used as sources for a given outgoing stock move, and how much quantity and value was taken from each source move.

Note: In Odoo 19.0, stock valuation layer model was removed and valuation is now tracked directly on stock moves through the 'value' field.

This kind of traceability is important in case that at some point you want to conduct a revaluation (for example, in case that the purchase order price changes after the products have been received into stock).

Also, it changes the way the outgoing move values are calculated in order to respect the MTO case. When creating the outgoing move valuation, Odoo uses FIFO to consume from the first available incoming moves with value. The module stock_move_valuation_usage improves this process. For standard FIFO, it always uses the oldest move. However, for MTO cases, when there is a fixed link between the incoming move and the outgoing move, the system should use the specific incoming move not just the oldest one. Also, when the case is not MTO, the system should avoid using moves that are "reserved".

Dependencies

Odoo dependencies
Python dependencies
None
System dependencies
None
Required by
None

Code analysis

Extracted from the source by best-effort static analysis (no code is executed); details may be incomplete.

Views touched 5

XML IDNameModelTypeStatus
stock_move_valuation_usage_form stock.move.valuation.usage.form stock.move.valuation.usage form New
stock_move_valuation_usage_list stock.move.valuation.usage.list stock.move.valuation.usage list New
stock_move_valuation_usage_pivot stock.move.valuation.usage.pivot stock.move.valuation.usage pivot New
stock_move_valuation_usage_search stock.move.valuation.usage.search stock.move.valuation.usage search New
view_move_form_inherit stock.move.form.inherit stock.move form Inherits stock.view_move_form

HTTP endpoints 0

No HTTP endpoints found for this module.

Models touched 3

New fields (0)

No new fields.

Public methods (0)

No public methods.

New fields (6)
  • incoming_usage_ids One2many → stock.move.valuation.usage
    comodel_name='stock.move.valuation.usage' help="Trace in what stock moves has this move's valuation been used, including the quantities and values taken." inverse_name='dest_stock_move_id' string='Incoming Valuation Usage'
  • incoming_usage_quantity Float
    compute='_compute_incoming_usages' store=True string='Incoming Usage quantity'
  • incoming_usage_value Float
    compute='_compute_incoming_usages' store=True string='Incoming Usage value'
  • usage_ids One2many → stock.move.valuation.usage
    comodel_name='stock.move.valuation.usage' help="Trace in what stock moves has this move's valuation been used, including the quantities and values taken." inverse_name='src_stock_move_id' string='Valuation Usage'
  • usage_quantity Float
    compute='_compute_usage_values' store=True
  • usage_value Float
    compute='_compute_usage_values' store=True
Public methods (0)

No public methods.

New fields (6)
  • company_id Many2one → res.company
    readonly=True required=True args: 'res.company'
  • dest_stock_move_id Many2one → stock.move
    comodel_name='stock.move' help='Outgoing stock move that consumed from the source move' required=False string='Destination Stock Move'
  • product_id Many2one → product.product
    comodel_name='product.product' related='dest_stock_move_id.product_id' store=True
  • quantity Float
    string='Taken Quantity'
  • src_stock_move_id Many2one → stock.move
    comodel_name='stock.move' help='Incoming stock move that was used as a source for valuation' string='Source Stock Move'
  • value Float
    string='Taken Value'
Public methods (1)
  • init(self)

Loading…