Hello,
I have a situation were I want to filter a Category based on a group. So I have the following domain added to the Category field
<fields name="categ_id" domain="[('group_id', '=', group_id)]"/>
This works perfect, but now I want to make it that when the group is not selected. That all the lines of the Category fields are shown. I already tried a couple of things, but I can't get it to work.
my last idea is to create an extra boolean field on categ_id that is default False and will always be False. (or can you actually set a constant-field?) and then set the domain to:
['|', ('group_id', '=', group_id), ('false_field','=',group_id)]
But this feels like bad programming, does anybody knows a better way?
Thanks
In the mean time i used the last idea I had with the false_field. It works, but I am still thinking if there couldn't be a better way to do this.