[FIX] sale_timesheet: created task company depends on its project
When confirming a SO creates a task, the task is in a project. The company from the task should be the one from the project, as we will (in the next commit) restrict the company of a task: it will only allow a project to have task in the same company as its. Task-1999686
This commit is contained in:
@@ -270,7 +270,7 @@ class SaleOrderLine(models.Model):
|
||||
'description': description,
|
||||
'project_id': project.id,
|
||||
'sale_line_id': self.id,
|
||||
'company_id': self.company_id.id,
|
||||
'company_id': project.company_id.id,
|
||||
'user_id': False, # force non assigned task, as created as sudo()
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user