<?xml version="1.0"?>
<t t-name="event.event_registration_report_template_badge">
    <t t-call="web.basic_layout">
        <t t-foreach="docs.grouped('event_id').items()" t-as="attendees_per_event">
            <t t-set="event" t-value="attendees_per_event[0]._set_tz_context()"/>
            <t t-set="attendees" t-value="attendees_per_event[1]"/>
            <t t-if="event.badge_format != 'four_per_sheet'" t-foreach="attendees" t-as="attendee">
                <t t-if="event.badge_format == 'A4_french_fold'" t-call="event.event_report_template_foldable_badge" t-lang="event.lang or attendee.env.lang"/>
                <t t-else="" t-call="event.event_report_template_a6_badge" t-lang="event.lang or attendee.env.lang"/>
            </t>
            <t t-if="event.badge_format == 'four_per_sheet'" t-call="event.event_report_template_four_per_sheet_badge" t-lang="event.lang or event.env.lang"/>
        </t>
    </t>
</t>

