-
- Downloads
[FIX] purchase: correct product cost in reporting
product.product inheritS from product.template, and they both define the 'standard_price' field, but implement it differently; - product: the field is a company dependent one (so non stored) - template: the field is a computed one based on tis variants For the first case, since the field is not stored in database, when doing SQL query, we have to get the value from the table ir_property. That is what purchase report does, but instead of searching on resource 'product.product', it does it on 'product.template'. There are obviously no entries in ir_property table for 'standard_price' field on product template. As consequence, the "product value" (cost) is always null in purchase reporting. This commit fixes that by modifying SQL query to get the good value from ir_property table.
Loading
Please register or sign in to comment