Skip to content

Commit

Permalink
[FIX] resource_booking: Force to send calendar event author notification
Browse files Browse the repository at this point in the history
  • Loading branch information
victoralmau authored and pedrobaeza committed Apr 1, 2023
1 parent 7771b0c commit 575d2aa
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion resource_booking/models/calendar_event.py
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,8 @@ def create(self, vals_list):
"""Transfer resource booking to _attendees_values by context.
We need to serialize the creation in that case.
mail_notify_author key from context is necessary to force the notification
to be sent to author.
"""
vals_list2 = []
records = self.env["calendar.event"]
Expand All @@ -65,7 +67,8 @@ def create(self, vals_list):
records += super(
CalendarEvent,
self.with_context(
resource_booking_ids=vals["resource_booking_ids"]
resource_booking_ids=vals["resource_booking_ids"],
mail_notify_author=True,
),
).create(vals)
else:
Expand Down

0 comments on commit 575d2aa

Please sign in to comment.