How can I set a default user as the current user in new API,
in the V7 :
'user_id': lambda obj, cr, uid, context: uid,
How can I set a default user as the current user in new API,
in the V7 :
'user_id': lambda obj, cr, uid, context: uid,
Hello,
You can try this one
user_id = fields.Many2one('res.users', string='My User',default=lambda self: self.env.user)
| 관련 게시물 | 답글 | 화면 | 활동 | |
|---|---|---|---|---|
|
0
4월 26
|
20 | |||
|
1
12월 24
|
6084 | |||
|
1
2월 16
|
5642 | |||
|
1
3월 15
|
7320 | |||
|
0
3월 15
|
4859 |
1. Use the live chat to ask your questions.
2. The operator answers within a few minutes.