跳至內容
選單
此問題已被標幟
3 回覆
21806 瀏覽次數

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
1月 17
3324
1
7月 16
7894
1
4月 23
3459
0
6月 25
426
0
1月 25
1563