Odoo Help

Welcome!

This community is for beginners and experts willing to share their Odoo knowledge. It's not a forum to discuss ideas, but a knowledge base of questions and their answers.

0

how to push mail into pool in odoo framework using python code

By
chirra
on 7/7/15, 9:01 AM 540 views

how to push mail into mailspool in odoo framework using python code  and how can pool send the mail

1
Andre de Kock
On 7/9/15, 3:50 PM

You can try the following:

template = self.env['email.template'].search[('name', '=', 'Name of email template'))
if not template:
    raise exceptions.Warning("Email template not found!")
template.send_mail(record.id, force_send=True)

Setting force_send to True will immediately send the email, whereas if you set force_send to False, the mail will push to the mail queue and be sent later (30min intervals) by a cron job.

0
chirra
On 7/10/15, 4:53 AM

HI Andre de Kock Thanks for response,

I Implemented another way,it's working fine .

i will try this approach also

 thank you once agian



Glad I could help

Limitless Virtual Enterprise, Andre de Kock
on 7/14/15, 3:04 AM

Your Answer

Please try to give a substantial answer. If you wanted to comment on the question or answer, just use the commenting tool. Please remember that you can always revise your answers - no need to answer the same question twice. Also, please don't forget to vote - it really helps to select the best questions and answers!

About This Community

This community is for professionals and enthusiasts of our products and services. Read Guidelines

Question tools

1 follower(s)

Stats

Asked: 7/7/15, 9:01 AM
Seen: 540 times
Last updated: 7/10/15, 4:53 AM