Please come at least 30 minutes before the beginning of the event.
+
Tickets can be printed or scanned directly from your phone.
+
If you don't have this ticket, you will not be allowed entry!
+
+ Free
diff --git a/addons/event/data/event_registration_demo.xml b/addons/event/data/event_registration_demo.xml
index 632702c1a26..e4197572a04 100644
--- a/addons/event/data/event_registration_demo.xml
+++ b/addons/event/data/event_registration_demo.xml
@@ -149,6 +149,7 @@
- badge_of_${(object.event_id.name or '').replace('/','_')}
+
+ Foldable Badge - ${(object.event_id.name or 'Event').replace('/','')}${object.partner_id.lang}
@@ -248,6 +248,8 @@
+
+ Full Page Ticket - ${(object.event_id.name or 'Event').replace('/','')}${object.partner_id.lang}
diff --git a/addons/event/models/event_event.py b/addons/event/models/event_event.py
index 332c132e6b1..1ad89563585 100644
--- a/addons/event/models/event_event.py
+++ b/addons/event/models/event_event.py
@@ -44,6 +44,9 @@ class EventType(models.Model):
_tz_get, string='Timezone', default=lambda self: self.env.user.tz or 'UTC')
# communication
event_type_mail_ids = fields.One2many('event.type.mail', 'event_type_id', string='Mail Schedule')
+ # ticket reports
+ ticket_instructions = fields.Html('Ticket Instructions', translate=True,
+ help="This information will be printed on your tickets.")
@api.depends('has_seats_limitation')
def _compute_default_registration(self):
@@ -162,12 +165,10 @@ class EventEvent(models.Model):
tracking=True, domain="['|', ('company_id', '=', False), ('company_id', '=', company_id)]")
country_id = fields.Many2one(
'res.country', 'Country', related='address_id.country_id', readonly=False, store=True)
- # badge fields
- badge_front = fields.Html(string='Badge Front')
- badge_back = fields.Html(string='Badge Back')
- badge_innerleft = fields.Html(string='Badge Inner Left')
- badge_innerright = fields.Html(string='Badge Inner Right')
- event_logo = fields.Html(string='Event Logo')
+ # ticket reports
+ ticket_instructions = fields.Html('Ticket Instructions', translate=True,
+ compute='_compute_ticket_instructions', store=True, readonly=False,
+ help="This information will be printed on your tickets.")
@api.depends('stage_id', 'kanban_state')
def _compute_kanban_state_label(self):
@@ -434,6 +435,13 @@ class EventEvent(models.Model):
if event.event_type_id and not is_html_empty(event.event_type_id.note):
event.note = event.event_type_id.note
+ @api.depends('event_type_id')
+ def _compute_ticket_instructions(self):
+ for event in self:
+ if is_html_empty(event.ticket_instructions) and not \
+ is_html_empty(event.event_type_id.ticket_instructions):
+ event.ticket_instructions = event.event_type_id.ticket_instructions
+
@api.constrains('seats_max', 'seats_available', 'seats_limited')
def _check_seats_limit(self):
if any(event.seats_limited and event.seats_max and event.seats_available < 0 for event in self):
diff --git a/addons/event/models/event_mail.py b/addons/event/models/event_mail.py
index 9bdfa4cd7a8..ed1f396221f 100644
--- a/addons/event/models/event_mail.py
+++ b/addons/event/models/event_mail.py
@@ -235,9 +235,8 @@ You receive this email because you are:
for scheduler in schedulers:
try:
- with self.env.cr.savepoint():
- # Prevent a mega prefetch of the registration ids of all the events of all the schedulers
- self.browse(scheduler.id).execute()
+ # Prevent a mega prefetch of the registration ids of all the events of all the schedulers
+ self.browse(scheduler.id).execute()
except Exception as e:
_logger.exception(e)
self.invalidate_cache()
diff --git a/addons/event/models/event_registration.py b/addons/event/models/event_registration.py
index 7a9429e3e1e..27da716a968 100644
--- a/addons/event/models/event_registration.py
+++ b/addons/event/models/event_registration.py
@@ -155,7 +155,11 @@ class EventRegistration(models.Model):
# some were created already open
if registrations._check_auto_confirmation():
registrations.sudo().action_confirm()
- else:
+ elif not self.env.context.get('install_mode', False):
+ # running the scheduler for demo data can cause an issue where wkhtmltopdf runs during
+ # server start and hangs indefinitely, leading to serious crashes
+ # we currently avoid this by not running the scheduler, would be best to find the actual
+ # reason for this issue and fix it so we can remove this check
registrations._update_mail_schedulers()
return registrations
@@ -167,7 +171,11 @@ class EventRegistration(models.Model):
ret = super(EventRegistration, self).write(vals)
- if vals.get('state') == 'open':
+ if vals.get('state') == 'open' and not self.env.context.get('install_mode', False):
+ # running the scheduler for demo data can cause an issue where wkhtmltopdf runs during
+ # server start and hangs indefinitely, leading to serious crashes
+ # we currently avoid this by not running the scheduler, would be best to find the actual
+ # reason for this issue and fix it so we can remove this check
pre_draft._update_mail_schedulers()
return ret
diff --git a/addons/event/report/event_event_reports.xml b/addons/event/report/event_event_reports.xml
index 0bbe4a924bd..2e48403e551 100644
--- a/addons/event/report/event_event_reports.xml
+++ b/addons/event/report/event_event_reports.xml
@@ -1,41 +1,89 @@
-
- European A4 low margin
-
+
+ Custom Paperformat for the Event Foldable Badge report
+
+ A400Portrait
- 5
- 5
- 5
- 5
-
- 0
- 80
+ 0
+ 0
+ 0
+ 0
+ 96
-
- Registration Badge
+
+ Custom Paperformat for the Event Full Page Ticket report
+
+
+ A4
+ 0
+ 0
+ Portrait
+ 0
+ 8
+ 0
+ 0
+ 96
+
+
+
+
+ Full Page Ticketevent.registrationqweb-pdf
- event.event_registration_report_template_badge
- event.event_registration_report_template_badge
- 'Registration Event - %s' % (object.name or 'Attendee').replace('/','')
-
+ event.event_registration_report_template_full_page_ticket
+ event.event_registration_report_template_full_page_ticket
+ 'Full Page Ticket - %s - %s' % ((object.event_id.name or 'Event').replace('/',''), object.name.replace('/',''))report
+
-
- Event Badge
- event.event
- qweb-html
- event.event_event_report_template_badge
- event.event_event_report_template_badge
-
-
+
+ Full Page Ticket Example
+ event.event
+ qweb-pdf
+ event.event_event_report_template_full_page_ticket
+ event.event_event_report_template_full_page_ticket
+ 'Full Page Ticket - %s' % (object.name or 'Event').replace('/','')
+
+ report
+
+
+
+
+ Foldable Badge
+ event.registration
+ qweb-pdf
+ event.event_registration_report_template_foldable_badge
+ event.event_registration_report_template_foldable_badge
+ 'Foldable Badge - %s - %s' % ((object.event_id.name or 'Event').replace('/',''), object.name.replace('/',''))
+
+ report
+
+
+
+
+ Foldable Badge Example
+ event.event
+ qweb-pdf
+ event.event_event_report_template_foldable_badge
+ event.event_event_report_template_foldable_badge
+ 'Foldable Badge - %s' % (object.name or 'Event').replace('/','')
+
+ report
+
+
diff --git a/addons/event/report/event_event_templates.xml b/addons/event/report/event_event_templates.xml
index 5bad64a8e18..4aabb2dc0b2 100644
--- a/addons/event/report/event_event_templates.xml
+++ b/addons/event/report/event_event_templates.xml
@@ -1,104 +1,243 @@
-
-
-
-
-