[FIX] hr_expense: set company of expense

When an expense is received by email, make sure to set the expense in
the emloyee's company.

opw-688671
This commit is contained in:
Nicolas Martinelli
2016-10-11 19:01:59 +02:00
parent 54ebe31f51
commit 42797ebfbb
+2 -1
View File
@@ -338,7 +338,8 @@ class HrExpense(models.Model):
'product_id': product.id,
'product_uom_id': product.uom_id.id,
'quantity': 1,
'unit_amount': price
'unit_amount': price,
'company_id': employee.company_id.id,
})
return super(HrExpense, self).message_new(msg_dict, custom_values)