<?xml version="1.0"?>
<form string="Event Registration">
                <field name="active" invisible="1"/>
                <header>
                    <button name="action_send_badge_email" string="Send by Email" type="object" class="oe_highlight" invisible="not active or state != 'open' and state != 'done'"/>
                    <button name="action_confirm" string="Registered" type="object" class="oe_highlight" invisible="not active or state != 'draft'"/>
                    <button name="action_set_done" string="Attended" type="object" class="oe_highlight" invisible="not active or state != 'open'"/>
                    <button name="action_cancel" string="Cancel Registration" type="object" invisible="not active or state == 'cancel'"/>
                    <field name="state" nolabel="1" colspan="2" widget="statusbar" statusbar_visible="open,done" readonly="False" options="{'clickable': '1'}"/>
                </header>
                <sheet string="Registration">
                    <div class="oe_button_box" name="button_box"/>
                    <widget name="web_ribbon" text="Archived" bg_color="text-bg-danger" invisible="active"/>
                    <group>
                        <group string="Attendee" name="attendee">
                            <field class="o_text_overflow" name="name"/>
                            <field name="email"/>
                            <field name="phone" class="o_force_ltr" widget="phone" options="{'enable_sms': true}"/>
                            <field name="company_name" placeholder="e.g. &quot;Azure Interior&quot;"/>
                        </group>
                        <group string="Event Information" name="event">
                            <field class="text-break" name="event_id" context="{'name_with_seats_availability': True}" options="{'no_create': True}"/>
                            <field name="event_slot_id" invisible="not is_multi_slots" required="is_multi_slots" context="{'name_with_seats_availability': True}" options="{'no_open': True, 'no_create': True}" domain="[('event_id', '=', event_id)]"/>
                            <field name="event_ticket_id" invisible="not event_id" context="{'name_with_seats_availability': True, 'is_event_multi_slots': is_multi_slots}" options="{'no_open': True, 'no_create': True}" domain="[('event_id', '=', event_id)]"/>
                            <field name="barcode" groups="base.group_no_one"/>
                            <field name="partner_id"/>
                            <field name="create_date" string="Registration Date" groups="base.group_no_one"/>
                            <field name="date_closed" groups="base.group_no_one"/>
                        </group>
                        <group string="Marketing" name="utm_link" groups="base.group_no_one">
                            <field name="utm_campaign_id"/>
                            <field name="utm_medium_id"/>
                            <field name="utm_source_id"/>
                        </group>
                    </group>
                    <field name="registration_properties" columns="2"/>
                    <notebook>
                        <page string="Questions" name="questions">
                            <field name="registration_answer_ids" widget="one2many">
                                <list editable="bottom">
                                    <field name="event_id" column_invisible="True"/>
                                    <field name="question_id" domain="[('event_id', '=', event_id)]" options="{'no_create': True}"/>
                                    <field name="question_type" string="Type"/>
                                    <field name="value_answer_id" invisible="question_type != 'simple_choice'" domain="[('question_id', '=', question_id)]" options="{'no_create': True}"/>
                                    <field name="value_text_box" invisible="question_type == 'simple_choice'"/>
                                </list>
                                <kanban class="o_kanban_mobile" create="false" delete="false">
                                    <field name="event_id"/>
                                    <field name="question_type"/>
                                    <templates>
                                        <t t-name="card" class="justify-content-between">
                                            <field class="fw-bold fs-5" name="question_id" domain="[('event_id', '=', event_id)]"/>
                                            <field name="value_answer_id" invisible="question_type != 'simple_choice'" domain="[('question_id', '=', question_id)]" options="{'no_create': True}"/>
                                            <field name="value_text_box" invisible="question_type == 'simple_choice'"/>
                                        </t>
                                    </templates>
                                </kanban>
                            </field>
                        </page>
                    </notebook>
                </sheet>
                <chatter reload_on_post="True"/>
            </form>
        