Odoo Help


This community is for beginners and experts willing to share their Odoo knowledge. It's not a forum to discuss ideas, but a knowledge base of questions and their answers.


How to set search view filter behavior?

on 4/16/13, 4:23 AM 2,303 views

I have defined a search view for my model:

<search string="Fields">
    <group expand="1" string="Group By...">
        <filter name="groupby_month" string="Month" domain="[]" context="{'group_by':'until'}"/>

Now when I view my tree view of the model, groups are never expanded (even with expand="1"), and search filter is always on when tree is accessed through menu.

How could I achieve tree to be expanded by default, and filter to be not on at first by default?

On 4/16/13, 10:09 AM

Looks like there actually is no problem at all, the behavior described in question is normal.


René Schuster

--René Schuster--
| 5 5 8
Weinheim, Germany
--René Schuster--

Challenge Everything!

René Schuster
On 1/9/14, 9:11 AM

The default filters for a search view can be set via the context of the related window action:

<field name="context">{'search_default_groupby_month': 1}</field>

I don't know, why your groups are not expanded. Facing a similar issue... :/

Your Answer

Please try to give a substantial answer. If you wanted to comment on the question or answer, just use the commenting tool. Please remember that you can always revise your answers - no need to answer the same question twice. Also, please don't forget to vote - it really helps to select the best questions and answers!

About This Community

This community is for professionals and enthusiasts of our products and services. Read Guidelines

Question tools

0 follower(s)


Asked: 4/16/13, 4:23 AM
Seen: 2303 times
Last updated: 3/16/15, 8:10 AM