Update project_task.py
This commit is contained in:
parent
2d778c4b33
commit
ffc4316289
|
|
@ -56,8 +56,7 @@ class ProjectTask(models.Model):
|
|||
_("Total planned hours for all tasks in stage %s must not exceed Total stage hours %s") % (
|
||||
record.phase_id.display_name, record.phase_hours))
|
||||
|
||||
@api.onchange('stage_id', 'stage_id.is_closed')
|
||||
def _compute_stage(self):
|
||||
def _send_state_change_notification(self):
|
||||
manager_users = self.env.ref('project.group_project_manager').users
|
||||
department_manager_users = self.env.ref('project_base.group_project_department_manager').users
|
||||
# Combine both user sets
|
||||
|
|
@ -75,3 +74,7 @@ class ProjectTask(models.Model):
|
|||
'author_id': self.env.user.partner_id and self.env.user.partner_id.id
|
||||
})
|
||||
|
||||
@api.onchange('stage_id', 'stage_id.is_closed')
|
||||
def _compute_stage(self):
|
||||
self._send_state_change_notification()
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue