Bỏ qua để đến Nội dung
Menu
Câu hỏi này đã bị gắn cờ
3 Trả lời
3045 Lượt xem

Hello,

I have configure email in odoo 11 and working fine, but now i want to create a function in my code to sent email after request has been submitted to recipient.

Any Help?



Ảnh đại diện
Huỷ bỏ
Tác giả

Ok, thanks i will try this code

Tác giả

Hello Sudhir thanks a lot but how do i sent email from template as well?

Câu trả lời hay nhất

Do you want to send an email from button click? If yes, use following code:

mail_template = self.env.ref('my_module.my_email_template') // Get Email Template by XML ID
mail_template.send_mail(record.id, force_send=True) // Send Email


Ảnh đại diện
Huỷ bỏ
Bài viết liên quan Trả lời Lượt xem Hoạt động
1
thg 12 23
9178
1
thg 1 21
10009
1
thg 10 20
7827
1
thg 5 19
3173
0
thg 12 16
3931