تخطي للذهاب إلى المحتوى
القائمة
لقد تم الإبلاغ عن هذا السؤال
3 الردود
21815 أدوات العرض

How can i Grant the superuser rights for another, not admin user?

الصورة الرمزية
إهمال
أفضل إجابة

Hi Yves,

If you're talking about calling superuser rights for another user through Python:

 self.sudo(user.id)
self.sudo()   # This will use the SUPERUSER_ID by default
# or
self.env['res.partner'].sudo().create(vals)

There is some documentation about this, which you can find here: http://odoo-new-api-guide-line.readthedocs.org/en/latest/environment.html 
If you're talking about creating a new user, from the view, you should simply create a new user and grant it all rights under settings > users.

Yenthe

الصورة الرمزية
إهمال
الكاتب

Thank you Yenthe

الكاتب أفضل إجابة

answer: I think that superuser user rights are granted when user_id = 1

الصورة الرمزية
إهمال

If you're talking about the absolute admin account you're correct. It has user_id 1 and a lot is based on this.

أفضل إجابة

in Settings-->Users

There is a drop down against Administration set that drop down to Settings

Following change will set user to superuser

الصورة الرمزية
إهمال
المنشورات ذات الصلة الردود أدوات العرض النشاط
1
يناير 17
3326
1
يوليو 16
7894
1
أبريل 23
3460
0
يونيو 25
427
0
يناير 25
1565