Created
February 17, 2020 06:16
-
-
Save sehrishnaz/a6e89074e58e173272c50881127bd3ef to your computer and use it in GitHub Desktop.
How can i select only the users belongs to a particular group in a many2many field
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
user_ids = fields.Many2many('res.users', string='Recipients', | |
domain=lambda self: [("groups_id", "=", | |
self.env.ref("base.group_erp_manager").id)]) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
For details: Domain on many2many