Skip to content
Health
80/100
good
  • Security25/25
    No findings
  • Activity25/25
    Last human commit 1 month ago
  • Required by5/25
    0 modules depend on it
  • Maturity25/25
    In 9 Odoo series since 11.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.09 MB
Module directory on disk
Code analysis 0 migration notes 5 models 6 views 0 HTTP endpoints

Description

This module extends the functionality of purchase orders to allow buy products in secondary unit of distinct category.

Users can enter quantities and prices in secondary units on purchase order lines. Vendor pricelist records are also extended to support secondary unit pricing.

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 6

XML IDNameModelTypeStatus
product_supplierinfo_form_view product.supplierinfo.form.view product.supplierinfo form Inherits product.product_supplierinfo_form_view
product_supplierinfo_tree_view product.supplierinfo.list.view product.supplierinfo list Inherits product.product_supplierinfo_tree_view
product_template_form_view Product template Secondary Unit product.template form Inherits product.product_template_form_view
purchase_order_form Purchase Order Secondary Unit purchase.order form Inherits purchase.purchase_order_form
report_purchaseorder_document report_purchaseorder_document ir.ui.view qweb Inherits purchase.report_purchaseorder_document
report_purchasequotation_document report_purchasequotation_document ir.ui.view qweb Inherits purchase.report_purchasequotation_document

HTTP endpoints 0

No HTTP endpoints found for this module.

Models touched 5

New fields (1)
  • purchase_secondary_uom_id Many2one → product.secondary.unit
    comodel_name='product.secondary.unit' domain="['|', ('product_id', '=', id),'&', ('product_tmpl_id', '=', product_tmpl_id), ('product_id', '=', False)]" help="In order to set a value, please first add at least one record in 'Secondary Unit of Measure'" string='Default secondary unit for purchases'
Public methods (0)

No public methods.

New fields (2)
  • secondary_uom_id Many2one → product.secondary.unit
    comodel_name='product.secondary.unit' domain="[('product_tmpl_id', '=', product_tmpl_id)]" string='Secondary Unit'
  • secondary_uom_price Float
    compute='_compute_secondary_uom_price' inverse='_inverse_secondary_uom_price' min_display_digits='Product Price' store=True string='Secondary Price'
Public methods (0)

No public methods.

New fields (1)
  • purchase_secondary_uom_id Many2one → product.secondary.unit
    comodel_name='product.secondary.unit' domain="[('product_tmpl_id', '=', id), ('product_id', '=', False)]" string='Default secondary unit for purchases'
Public methods (0)

No public methods.

New fields (0)

No new fields.

Public methods (0)

No public methods.

New fields (2)
  • product_qty Float
    compute='_compute_product_qty' copy=True precompute=True readonly=False store=True
  • secondary_uom_price Float
    aggregator='avg' compute='_compute_secondary_uom_price' digits='Product Price' inverse='_inverse_secondary_uom_price' store=True string='Secondary Price'
Public methods (1)
  • onchange_product_id(self)
    @api.onchange('product_id')
    If default purchases secondary unit set on product, put on secondary quantity 1 for being the default quantity. We override this method, that is the one that sets by default 1 on the other quantity with that purpose.

Loading…

Loading…

Loading…

Loading…

Loading…

Loading…

Loading…

Loading…

Loading…