Skip to Content
Meniu
Trebuie să fiți înregistrat pentru a interacționa cu comunitatea.
Această întrebare a fost marcată
1 Răspunde
6838 Vizualizări

How can I add grouping by category for employers in the standard employers view ?

Update

Right now I change the Search view adding this:

<filter string="Category" icon="terp-personal+" domain="[]" context="{'group_by':'category_ids'}"/>

And on clicking the button in the view I get this error:

File "/opt/openerp/openerp-server-6.0.4/bin/osv/orm.py", line 2170, in read_group
    assert not groupby or groupby in fields, "Fields in 'groupby' must appear in the list of fields to read (perhaps it's missing in the list view?)"
AssertionError: Fields in 'groupby' must appear in the list of fields to read (perhaps it's missing in the list view?)
Imagine profil
Abandonează
Cel mai bun răspuns

category_ids must be displayed in the view for you to add it as a filter. That is what the error says.

You must edit the view to add category_ids you can add the invisible tag if you don't want users to see it.

Imagine profil
Abandonează
Autor

No it won't even this way. I think it is not possible by design to group by a many2many field in a view.

Autor

Like this Q stated: http://help.openerp.com/question/22335/group-by-a-many2many-field/

Related Posts Răspunsuri Vizualizări Activitate
1
aug. 25
234
1
iul. 25
622
1
iul. 25
968
2
mai 25
1557
1
iul. 25
1284