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,
Odoo is the world's easiest all-in-one management software.
It includes hundreds of business apps:
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)
أنشئ حساباً اليوم لتستمتع بالخصائص الحصرية، وتفاعل مع مجتمعنا الرائع!
تسجيلالمنشورات ذات الصلة | الردود | أدوات العرض | النشاط | |
---|---|---|---|---|
|
1
ديسمبر 24
|
4058 | ||
|
1
فبراير 16
|
3665 | ||
|
1
مارس 15
|
5101 | ||
|
0
مارس 15
|
3034 | ||
|
1
مارس 15
|
5601 |