<?xml version="1.0" encoding="utf-8" ?>
<odoo>
    <record model="ir.ui.view" id="validate_attendance_sheet_form">
        <field name="name">Validate Attendance Sheet</field>
        <field name="model">shift.sheet.validate</field>
        <field name="arch" type="xml">
            <form>
                <sheet>
                    <separator string="Validation" />
                    <field name="card_support" invisible="1" />
                    <field name="active_sheet" invisible="1" />
                    <field name="_barcode_scanned" widget="barcode_handler" />
                    <label for="notes" />
                    <field name="notes" />
                    <label for="feedback" />
                    <field name="feedback" />
                    <group>
                        <field name="worker_nb_feedback" />
                    </group>
                    <group
                        string="Login"
                        attrs="{'invisible': [('card_support', '=', True)]}"
                    >
                        <field name="login" />
                        <field name="password" password="True" />
                    </group>
                    <group
                        string="Scan your card"
                        attrs="{'invisible': [('card_support', '=', False)]}"
                    >
                        <field name="barcode" />
                    </group>
                    <field
                        name="warning_regular_workers"
                        readonly="1"
                        attrs="{'invisible': [('warning_regular_workers', '=', False)]}"
                    />
                </sheet>
                <footer>
                    <button
                        type="object"
                        name="validate_sheet"
                        string="Validate"
                        class="oe_highlight"
                    />
                    <button type="object" name="save" string="Save" />
                    <button special="cancel" string="Cancel" />
                </footer>
            </form>
        </field>
    </record>
</odoo>
