Hello,
Is it a way to use domain on many2many field on openerp v6.1?
Here is my object : Code:
class user(osv.osv):
_columns={
'group_ids':fields.many2many('custom_module.group', 'custom_module_group_user_rel', 'user_id', 'group_id', 'Groups'),
}
user()
class group(osv.osv):
_columns={
'user_ids':fields.many2many('custom_module.group', 'custom_module_group_user_rel', 'group_id', 'user_id', 'Users'),
}
group()
I have added these fields on the views and it works fine. My problem is that I'd like to select only users who are in a specific group but I can't find the correct domain to apply.
Here is my view : Code:
<record ..>
...
<field name="name"/>
<field name="group_id"/>
<field name="user_id" domain="[('id','in', [group_id.user_ids]])]"/>
...
</record>
I would like that by selecting a group, the user could only select a user in this group.
Does somebody know what is wrong with my domain ? Or is it possible ?
Hi vivek, you found any solution? even i'm facing the same problem please help me out
Domain on many2many field: http://bit.ly/2DarOfB