<?xml version="1.0"?>
<odoo>
    <record id="estate_property_type_action" model="ir.actions.act_window">
        <field name="name">Property Types</field>
        <field name="res_model">estate.property.type</field>
        <field name="view_mode">tree,form</field>
    </record>

    <record id="estate_property_type_view_form" model="ir.ui.view">
        <field name="name">estate.property.type.form</field>
        <field name="model">estate.property.type</field>
        <field name="arch" type="xml">
            <form>
                <sheet>
                    <div name="button_box" position="inside">
                        <button class="oe_stat_button" type="action" name="%(estate_property_offer_from_type_action)d" icon="fa-money">
                            <field name="offer_count" string="Offers" widget="statinfo" />
                        </button>
                    </div>                
                    <h1>
                        <field name="name" />
                    </h1>
                    <notebook>
                        <page string="Properties">
                            <field name="property_ids">
                                <tree create="False" edit="False" delete="False" open_form_view="False">
                                    <field name="name" string="Title" />
                                    <field name="expected_price" />
                                    <field name="state" string="Status" />
                                </tree>
                            </field>
                        </page>
                    </notebook>
                </sheet>
            </form>
        </field>
    </record>
</odoo>