Files
clementthomas a94e819f8c [IMP] event_track_calendar_event:
copy calendar events on event_track copy
2024-07-11 09:36:40 +02:00

15 lines
448 B
Python

# License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl).
from odoo import fields, models, api, Command
import logging
_logger = logging.getLogger(__name__)
class EventEvent(models.Model):
_inherit = "event.event"
def write(self, vals):
res = super().write(vals)
for event in self:
for track in event.track_ids:
track.sync_calendar_event()
return res