mirror of https://github.com/OCA/social.git
[IMP] mail_activity_team: Force team on schedule
If you schedule an activity and you don't force the team as False, errors might araise. For example, on holidays.pull/1321/head
parent
f607b4f406
commit
efe180a67d
|
@ -72,9 +72,7 @@ class MailActivityMixin(models.AbstractModel):
|
||||||
.with_context(default_res_model=self._name,)
|
.with_context(default_res_model=self._name,)
|
||||||
._get_default_team_id(user_id=user_id)
|
._get_default_team_id(user_id=user_id)
|
||||||
)
|
)
|
||||||
# Even if it comes empty, we don't want to mismatch the user's team
|
act_values.update({"team_id": team.id})
|
||||||
if team:
|
|
||||||
act_values.update({"team_id": team.id})
|
|
||||||
return super().activity_schedule(
|
return super().activity_schedule(
|
||||||
act_type_xmlid=act_type_xmlid,
|
act_type_xmlid=act_type_xmlid,
|
||||||
date_deadline=date_deadline,
|
date_deadline=date_deadline,
|
||||||
|
|
Loading…
Reference in New Issue