<?xml version="1.0"?>
<form string="Contract History" create="false" edit="false" delete="false" duplicate="false" import="false">
                <header>
                    <button name="hr_contract_view_form_new_action" string="Create" type="object" groups="hr_contract.group_hr_contract_manager" class="btn-primary"/>
                </header>
                <sheet>
                    <div class="oe_button_box" name="button_box"/>
                    <h1>
                        <div class="d-flex justify-content-start">
                            <div>
                                <field name="display_name"/>
                            </div>
                            <div class="ps-3">
                                <field name="under_contract_state" widget="state_selection" readonly="1"/>
                            </div>
                        </div>
                    </h1>
                    <h2>
                        <field name="employee_id"/>
                    </h2>
                    <group>
                        <group>
                            <field name="contract_id" invisible="1"/>
                            <field name="company_country_id" invisible="1"/>
                            <field name="country_code" invisible="1"/>
                            <field name="structure_type_id"/>
                            <field name="resource_calendar_id"/>
                            <field name="currency_id" invisible="1"/>
                            <field name="wage" invisible="1"/>
                        </group>
                        <group>
                            <field name="department_id"/>
                            <field name="job_id"/>
                        </group>
                    </group>
                    <notebook>
                        <page string="Contract History" name="contract_history">
                            <field name="contract_ids" widget="one2many" readonly="0">
                                <tree string="Current Contracts" decoration-primary="state == 'open'" decoration-muted="state == 'close'" decoration-bf="id == parent.contract_id" default_order="date_start desc, state desc" editable="bottom" no_open="1" create="0" delete="0">
                                    <button name="action_open_contract_form" type="object" icon="fa-external-link" title="Open Contract"/>
                                    <field name="id" invisible="1"/>
                                    <field name="name" string="Contract Name"/>
                                    <field name="date_start"/>
                                    <field name="date_end"/>
                                    <field name="resource_calendar_id"/>
                                    <field name="currency_id" invisible="1"/>
                                    <field name="wage" string="Monthly Wage"/>
                                    <field name="state" widget="badge" decoration-info="state == 'draft'" decoration-warning="state == 'close'" decoration-success="state == 'open'"/>
                                </tree>
                            </field>
                        </page>
                        <page string="Employee Information" name="contract_others">
                            <group>
                                <field name="date_hired"/>
                                <field name="hr_responsible_id"/>
                                <field name="company_id"/>
                            </group>
                        </page>
                    </notebook>
                </sheet>
            </form>
        