<?xml version="1.0" ?>
<odoo>
    <!--FORM view-->
    <record id="contract_contract_form_view" model="ir.ui.view">
        <field name="name">contract.contract form view (in contract_mandate)</field>
        <field name="model">contract.contract</field>
        <field
            name="inherit_id"
            ref="contract_payment_mode.contract_contract_form_view"
        />
        <field name="arch" type="xml">
            <field name="payment_mode_id" position="after">
                <field name="company_id" invisible="1" />
                <field
                    name="mandate_id"
                    domain="[('partner_id', '=', commercial_partner_id), ('state', '=', 'valid'), ('company_id', '=', company_id)]"
                    attrs="{'invisible': [('mandate_required', '=', False)]}"
                />
                <field name="commercial_partner_id" invisible="1" />
                <field name="mandate_required" invisible="1" />
            </field>
        </field>
    </record>
</odoo>
