Hello,
Im having problems with creating a filter on stock.picking object. Just recently i build a simple "privilege relay" - in each stock location you can define "Assigned User Group", thanks to that users that are in particular group can or cannot confirm moves for or out of the location.
Stock.picking:location_id -> assigned_user_group -> users
Now I would like to create a filter (later to be set default) on stock picking tree view that will show only the moves which locations (source location and destination location; i use them in stock.picking object) can be managed by a viewing user.
By far I wrote a filter that looks like that, :
<filter icon="terp-check" name="locgroup" string="Location Group" domain="[(uid,'in',[user.id for user in location_id.user_group.users])]" context="{'group_by':'date'}"/>
I also added field location_id to the tree view.
But Im still getting an error (after choosing the filter) that even google doesnt know anything about:
TypeError: results.group_by is undefined
My questions are:
1. By looking on domain in filter field - what am i doing wrong?
2. Is something like that even possible?
I will gladly welcome any help.