Odoo Mindscape. Understand Odoo faster. Explore modules, fields, dependencies and version differences in one place instead of digging through the source code.
Module: Purchase
Entity: product.template
Compute Method: _compute_purchase_method
| Inputs | Method | Outputs |
|---|---|---|
|
- default_purchase_method = self.env['product.template'].default_get(['purchase_method']).get('purchase_method') + default_purchase_method = self.env['product.template'].default_get(['purchase_method']).get('purchase_method', 'receive') for product in self: - if product.detailed_type == 'service': + if product.type == 'service': product.purchase_method = 'purchase' else: product.purchase_method = default_purchase_method |
|
