|
@@ -13,7 +13,7 @@ class account_invoice(models.Model):
|
|
|
if product:
|
|
|
template = self.env['product.template'].browse(product.product_tmpl_id.id)
|
|
|
if(template.price_change == 'purchase'):
|
|
|
- template.write({'standard_price': item.price_unit, 'last_purchase_date': date.today()})
|
|
|
+ product.write({'standard_price': item.price_unit, 'last_purchase_date': date.today()})
|
|
|
else:
|
|
|
- template.write({'last_purchase_date': date.today()})
|
|
|
+ product.write({'last_purchase_date': date.today()})
|
|
|
return res
|