Limit (Tree Views)
As standard, Odoo will display 40 lines in List (Tree) views, but this can be changed in the XML.
Here’s an example of adding a list of BOMs to a product (note: there’s already a “smart button” for this, so it may not be the most useful example). The steps to add this are described here: adding a one2many
This is the XML generated by Odoo Studio
This is the line in the XML that we need to change:
<tree string="Bill of Materials" limit = "5" default_order="product_tmpl_id">
This is the result:
As you will see, 5 records are displayed.