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

How can i overwrite the value of "self._uid" based on special condition

Eg:- self._uid = int(my_userid) gives an error "AttributeError: can't set attribute"

Any thought on this is appreciated !..

頭像
捨棄
最佳答案

 use self.sudo(my_userid), it will set the uid value in the self .

self.sudo(my_userid)
頭像
捨棄
作者

Hi Prakash , Thanks for your answer , but this is not compatible with version 7 . Am actually trying to implement this small fix in version 7 . Is there any alternatives or for this .. Thanks ..

相關帖文 回覆 瀏覽次數 活動
0
9月 19
98
1
7月 17
4097
4
8月 16
8275
1
3月 16
4946
2
3月 16
7206