Skip ke Konten
Menu
Pertanyaan ini telah diberikan tanda
1 Balas
2229 Tampilan

I am creating a user in the archived state using python code. But after creating the user, the system sends invitations and other emails to this user. How is it happening even if the user is disabled?

Avatar
Buang
Jawaban Terbai

Hi,

Archiving the user will not stop sending emails to the user. By default when we create a user the selection field notification_type in res.users will be set to emails. You can update this field value to inbox in order to handle the acknowledgments within odoo.

Try the below code, 

self.env['res.users'].create({
'name': 'test user',
'login'
: 'test',
'email'
: 'p.p@example.com',
'notification_type'
: 'inbox',})

Thanks

Avatar
Buang
Post Terkait Replies Tampilan Aktivitas
2
Des 24
4187
1
Nov 24
2931
2
Apr 23
17790
4
Agu 24
23849
0
Des 21
2387