[FIX] purchase: fixed onchange of product that wasn't setting the supplier taxes

This commit is contained in:
qdp-odoo
2015-10-16 09:53:25 +02:00
parent af0f33a475
commit c1920951ec
+1 -13
View File
@@ -582,20 +582,8 @@ class PurchaseOrderLine(models.Model):
if product_lang.description_purchase:
self.name += '\n' + product_lang.description_purchase
taxes = self.product_id.supplier_taxes_id
fpos = self.order_id.fiscal_position_id
if fpos:
self.taxes_id = fpos.map_tax(taxes)
result['value'] = {
'name': self.name,
'product_uom': self.product_uom.id,
'product_qty': self.product_qty,
'date_planned': self.date_planned,
'taxes_id': self.taxes_id.ids,
}
return result
self.taxes_id = fpos.map_tax(self.product_id.supplier_taxes_id)
class ProcurementRule(models.Model):