Tree
This type of view is the common way to display a list of records
<tree string="This is a list"> <field name="name" /> <field name="email" /></tree>
Changing the color of the text
<tree string="This is a list" colors="red:status=='unpaid';orange:status=='checking'"> <field name="name" /> <field name="email" /> <field name="status" /></tree>
Adding a status dot
<tree string="This is a list" status="green:unpaid_amount==0;red:unpaid_amount>0"> <field name="name" /> <field name="email" /> <field name="status" /> <field name="unpaid_amount" /></tree>
Infinite scroll
<tree string="This is a list" infinite="1"> <field name="name" /> <field name="email" /></tree>
API
Property | Description | Type | Default | Version |
---|---|---|---|---|
string | The title of the tree | string | - | - |
colors | Color of the row's text when match the condition. See conditions | string | - | - |
status | Add a status dot in the row when the match the condition. See conditions | string | - | - |
infinite | Whether to load more records when scrolling | 1 | 0 | 0 | - |