<?xml version='1.0' encoding='utf-8'?>
<odoo>
    <record id="asset_group_form_view_inherit_loan" model="ir.ui.view">
        <field name="name">account.asset.group.form</field>
        <field name="model">account.asset.group</field>
        <field name="inherit_id" ref="odex30_account_asset.asset_group_form_view"/>
        <field name="arch" type="xml">
            <xpath expr="//div[@name='button_box']" position="inside">
                <button name="action_open_linked_loans"
                    type="object"
                    class="oe_stat_button"
                    icon="fa-bars"
                    invisible="count_linked_loans == 0">
                    <field string="Loan(s)" name="count_linked_loans" widget="statinfo"/>
                </button>
            </xpath>
        </field>
    </record>

</odoo>
