TIP: You can type at any time to perform a new search.
Purchase Order Secondary Unit
purchase_order_secondary_unit · OCA/purchase-workflow
- Repository
- OCA/purchase-workflow · module folder · Try on Runboat
- Module version
- 1.2.3
- Category
- Purchase
- Folder size
- 0.09 MB
- License
- AGPL-3
- Application
- No
- Auto-installable
- Yes
- Website
- https://github.com/OCA/purchase-workflow
- Last tracking update
- 2026-08-07 08:42:58
- Authors
- Odoo Community Association (OCA), Tecnativa
- Maintainers
- Odoo Community Association (OCA), Tecnativa
- Committers
- sergio-teruel, pilarvargas-tecnativa, Aungkokolin1997, Weblate, OCA-git-bot, oca-ci, yostashiro, rjaraspearhead
- Odoo dependencies
- Python dependencies
- None
- System dependencies
- None
- Required by
- purchase_order_product_recommendation_secondary_unit, purchase_stock_secondary_unit
- 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. Purchase reports and the Purchase Order portal are adjusted to display quantities and prices in secondary units based on company configuration.
Code Analysis ⓘ
Views touched (6)
| XML ID | Name | Model | Type | Status |
|---|---|---|---|---|
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_idMany2one → product.secondary.unitcomodel_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'
No public methods.
New fields (2)
-
secondary_uom_idMany2one → product.secondary.unitcomodel_name='product.secondary.unit'domain="[('product_tmpl_id', '=', product_tmpl_id)]"string='Secondary Unit' -
secondary_uom_priceFloatcompute='_compute_secondary_uom_price'digits='Product Price'inverse='_inverse_secondary_uom_price'store=Truestring='Secondary Price'
No public methods.
New fields (1)
-
purchase_secondary_uom_idMany2one → product.secondary.unitcomodel_name='product.secondary.unit'domain="[('product_tmpl_id', '=', id), ('product_id', '=', False)]"string='Default secondary unit for purchases'
No public methods.
New fields (0)
No new fields.
Public methods (0)No public methods.
New fields (4)
-
product_packaging_idMany2onecompute='_compute_product_packaging_id'precompute=Truestore=True -
product_packaging_qtyFloatcompute='_compute_product_packaging_qty'precompute=Truestore=True -
product_qtyFloatcompute='_compute_product_qty'copy=Trueprecompute=Truereadonly=Falsestore=True -
secondary_uom_priceFloataggregator='avg'compute='_compute_secondary_uom_price'digits='Product Price'inverse='_inverse_secondary_uom_price'store=Truestring='Secondary Price'
-
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. -
onchange_product_uom_for_secondary(self)@api.onchange('product_uom')
Loading…
Loading…
Loading…
Loading…
Loading…
Loading…
Loading…
- Status
- Open migration PR — not merged yet for this version
- CI status
- green — ready to merge
- Open since
- 0 days ago
- Last activity
- 0 days ago
- Repository
- OCA/purchase-workflow
- Pull request
- [19.0][MIG] purchase_order_secondary_unit: Migration to version 19.0 (#3155)