Přejít na obsah
Menu
You need to be registered to interact with the community.
This question has been flagged
1 Odpovědět
6534 Zobrazení

I am trying to inherit one group's access rights to another group in odoo using python code.

Example :-

i have a hr_manager group and restrict_user group.

i want to inherit hr_manager group to restrict_user group during creation of a new user.

Please suggest..

Avatar
Zrušit
Nejlepší odpověď

If you have a group A, then you can create/write a group B that inherit the access rights of A. 

self.env['res.groups'].create({'name': 'B', 'implied_ids': [(6, 0, A.ids)]})

implied_ids is a many2many field that does exactly what you need

Avatar
Zrušit
Related Posts Odpovědi Zobrazení Aktivita
7
čvn 24
24734
0
zář 20
2258
1
čvn 20
11610
0
srp 19
3783
0
čvc 23
2