Bỏ qua để đến Nội dung
Menu
Câu hỏi này đã bị gắn cờ
1 Trả lời
3346 Lượt xem

Hello, I have created a custom module in my Odoo instance and have implemented a new user group within it. My objective is to assign this group to users by default upon their creation. Could you please provide guidance on how to achieve this?

Ảnh đại diện
Huỷ bỏ
Câu trả lời hay nhất

Hi,
If you need to assign it for all the users from code, you can do it by overriding the create method of the res.users model.

But the cleaner solution, will be updating the Default user template with this user group.

* Navigate to general settings and click "Default User Template"
* Add your group for this user
* Now on creating new user, this group will be automatically added






Thanks

Ảnh đại diện
Huỷ bỏ
Bài viết liên quan Trả lời Lượt xem Hoạt động
4
thg 10 24
1503
0
thg 4 24
1776
3
thg 4 24
3180
0
thg 3 24
2003
1
thg 8 25
1630