Skip to content

Commit bce96ed

Browse files
committed
[IMP] estate: add kanban view for estate_property
1 parent 5510c98 commit bce96ed

1 file changed

Lines changed: 27 additions & 1 deletion

File tree

estate/views/estate_property_views.xml

Lines changed: 27 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
<record id="estate_property_action" model="ir.actions.act_window">
55
<field name="name">Properties</field>
66
<field name="res_model">estate.property</field>
7-
<field name="view_mode">list,form</field>
7+
<field name="view_mode">list,form,kanban</field>
88
<field name="context">{'search_default_available': True, 'search_default_current': True}</field>
99
</record>
1010
<record id="estate_property_view_tree" model="ir.ui.view">
@@ -99,4 +99,30 @@
9999
</search>
100100
</field>
101101
</record>
102+
<record id="estate_property_view_kanban" model="ir.ui.view">
103+
<field name="name">estate.property.view.kanban</field>
104+
<field name="model">estate.property</field>
105+
<field name="arch" type="xml">
106+
<kanban default_group_by="property_type_id" records_draggable="False">
107+
<field name="state"/>
108+
<templates>
109+
<t t-name="card">
110+
<strong class="o_kanban_record_title">
111+
<field name="name"/>
112+
</strong>
113+
<div>
114+
Expected Price:<field name="expected_price"/>
115+
</div>
116+
<div t-if="record.state.raw_value == 'offer_received'">
117+
Best Offer:<field name="best_offer"/>
118+
</div>
119+
<div t-if="record.state.raw_value == 'sold'">
120+
Selling Price:<field name="selling_price"/>
121+
</div>
122+
<field name="property_tag_ids" widget="many2many_tags" options="{'color_field': 'color'}"/>
123+
</t>
124+
</templates>
125+
</kanban>
126+
</field>
127+
</record>
102128
</odoo>

0 commit comments

Comments
 (0)