<?xml version="1.0" encoding="utf-8"?>
<odoo>
    <data>
        <record id="base_consent_tree" model="ir.ui.view">
            <field name="name">Consents</field>
            <field name="model">base.consent</field>
            <field name="arch" type="xml">
                <list>
                    <field name="name"/>
                    <field name="partner_id"/>
                    <field name="employee_id"/>
                    <field name="date_from"/>
                    <field name="date_to"/>
                </list>
            </field>
        </record>

        <record id="base_consent_form" model="ir.ui.view">
            <field name="name">consent.form</field>
            <field name="model">base.consent</field>
            <field name="arch" type="xml">
                <form>
                    <header></header>
                    <sheet>
                        <group>
                            <group>
                                <field name="name" placeholder="Для автонумерации оставьте пустым"/>
                                <field name="partner_id"/>
                                <field name="employee_id"/>
                            </group>
                            <group>
                                <field name="date_from"/>
                                <field name="date_to"/>
                                <field name="purchaseorder_id"/>
                                <field name="company_id"/>
                            </group>
                        </group>
                    </sheet>
                    <chatter/>
                </form>
            </field>
        </record>

        <record id="l10n_ru_attorney.action_consent" model="ir.actions.act_window">
            <field name="name">Доверенности</field>
            <field name="res_model">base.consent</field>
            <field name="view_mode">list,form</field>
        </record>

        <menuitem id="l10n_ru_attorney.menu_1" name="Доверенности" parent="purchase.menu_purchase_root"
                  action="l10n_ru_attorney.action_consent"/>

        <record id="seq_consent" model="ir.sequence">
            <field name="name">Consents</field>
            <field name="code">base.consent</field>
            <field name="prefix">CON</field>
            <field name="padding">5</field>
            <field name="company_id" eval="False"/>
        </record>

    </data>
</odoo>
