diff --git a/event_mail_attachment/models/mail_template.py b/event_mail_attachment/models/mail_template.py index 9fd648a..f437104 100644 --- a/event_mail_attachment/models/mail_template.py +++ b/event_mail_attachment/models/mail_template.py @@ -6,7 +6,10 @@ class MailTemplate(models.Model): event_attachment_name_prefix = fields.Char( "Attachment name prefix", - help="If there is an attachment in event registration, or in event, with a name that starts with this name, it will be attached to the mail.", + help=""" + If there is an attachment in event registration, or in event, + with a name that starts with this name, it will be attached to the mail. + """, ) def generate_email(self, res_ids, fields): @@ -18,10 +21,9 @@ class MailTemplate(models.Model): res_ids = [res_ids] multi_mode = False - for lang, (template, template_res_ids) in self._classify_per_lang( - res_ids - ).items(): - # add reports attached to event.registration or event.event from attachment name + for _, (template, template_res_ids) in self._classify_per_lang(res_ids).items(): + # add reports attached to event.registration or event.event from + # attachment name if template.event_attachment_name_prefix: for res_id in template_res_ids: event_registration = self.env["event.registration"].browse(res_id) diff --git a/event_mail_manual/models/event_mail.py b/event_mail_manual/models/event_mail.py index 1696a0d..9afb8a5 100644 --- a/event_mail_manual/models/event_mail.py +++ b/event_mail_manual/models/event_mail.py @@ -79,7 +79,10 @@ class EventMailRegistration(models.Model): if not template: _logger.warning( - "Cannot process ticket %s, because Mail Scheduler %s has reference to non-existent template", + """ + Cannot process ticket %s, because Mail Scheduler %s has + reference to non-existent template + """, reg_mail.registration_id, reg_mail.scheduler_id, ) diff --git a/event_sequence/i18n/fr.po b/event_sequence/i18n/fr.po index dc297d3..c78b158 100644 --- a/event_sequence/i18n/fr.po +++ b/event_sequence/i18n/fr.po @@ -18,6 +18,7 @@ msgstr "" #. module: event_sequence #: model:ir.model.fields,field_description:event_sequence.field_event_event__current_sequence_id +#: model_terms:ir.ui.view,arch_db:event_sequence.view_event_form_event_sequence msgid "Current sequence" msgstr "Séquence en cours" @@ -45,12 +46,6 @@ msgstr "Séquence" msgid "Sequences" msgstr "Séquences" -#. module: event_sequence -#: model_terms:ir.ui.view,arch_db:event_sequence.view_event_form_event_sequence -msgid "Current sequence" -msgstr "Séquence en cours" - - #. module: event_sequence #: model_terms:ir.ui.view,arch_db:event_sequence.view_event_track_by_sequence_kanban msgid "hours" diff --git a/event_track_calendar_event/models/event_track.py b/event_track_calendar_event/models/event_track.py index 33fb12b..1395616 100644 --- a/event_track_calendar_event/models/event_track.py +++ b/event_track_calendar_event/models/event_track.py @@ -31,7 +31,8 @@ class EventTrack(models.Model): Return default values of calendar events. """ return { - # due to google calendar unexpected notifications, for the moment we disable attendees of calendar event + # due to google calendar unexpected notifications, for the moment we + # disable attendees of calendar event # uncomment following line to re-enable #'partner_ids':[Command.set(self.get_calendar_event_partner_value())], "partner_ids": [Command.set([])], diff --git a/event_track_calendar_event_event_track_location/__manifest__.py b/event_track_calendar_event_event_track_location/__manifest__.py index fa544f3..af4f465 100644 --- a/event_track_calendar_event_event_track_location/__manifest__.py +++ b/event_track_calendar_event_event_track_location/__manifest__.py @@ -15,7 +15,8 @@ Link event tracks locations to calendar event ---------------------------------------------------- * Add Partner field on event track location * Add partner "location" to calendar event -* Update calendar event if event track location change (or partner in event track location) +* Update calendar event if event track location change +(or partner in event track location) * Alert if location is used diff --git a/event_track_calendar_event_event_track_location/models/event_track.py b/event_track_calendar_event_event_track_location/models/event_track.py index 5423c07..9f1b5fe 100644 --- a/event_track_calendar_event_event_track_location/models/event_track.py +++ b/event_track_calendar_event_event_track_location/models/event_track.py @@ -6,8 +6,12 @@ from odoo.tools import format_date class EventTrack(models.Model): _inherit = "event.track" - location_already_in_use = fields.Boolean("Location already in use", compute="_compute_location_already_in_use") - location_already_in_use_message = fields.Text(compute="_compute_location_already_in_use") + location_already_in_use = fields.Boolean( + "Location already in use", compute="_compute_location_already_in_use" + ) + location_already_in_use_message = fields.Text( + compute="_compute_location_already_in_use" + ) @api.depends("date", "duration", "location_id") def _compute_location_already_in_use(self): @@ -19,7 +23,8 @@ class EventTrack(models.Model): for calendar_event in track.calendar_event_ids: if track.location_id and calendar_event.start: - # search if other calendar event exists for same day on same location + # search if other calendar event exists for same day on + # same location search_other_calendar_events = [ ("event_track_id.location_id", "=", track.location_id.id), ("start", ">=", calendar_event.start.replace(hour=0, minute=0)), @@ -32,14 +37,22 @@ class EventTrack(models.Model): # search only on other event tracks if track.id or track.id.origin: - search_other_calendar_events.append(("event_track_id", "!=", track.id or track.id.origin)) + search_other_calendar_events.append( + ("event_track_id", "!=", track.id or track.id.origin) + ) # search calendar events not already founded if already_found_other_calendar_event_ids: - search_other_calendar_events.append(("id", "not in", already_found_other_calendar_event_ids)) + search_other_calendar_events.append( + ("id", "not in", already_found_other_calendar_event_ids) + ) - other_calendar_events = self.env["calendar.event"].search(search_other_calendar_events) - already_found_other_calendar_event_ids.extend(other_calendar_events.ids) + other_calendar_events = self.env["calendar.event"].search( + search_other_calendar_events + ) + already_found_other_calendar_event_ids.extend( + other_calendar_events.ids + ) if other_calendar_events: location_already_in_use = True