تخطي للذهاب إلى المحتوى
القائمة
لقد تم الإبلاغ عن هذا السؤال
1 الرد
5795 أدوات العرض

I'm creating cron method for auto scheduling for passport expiry date. My concept is when expire date is over, that employee name and expire date will send to administrator's mail id. I got employee name and expiry date and I updated in mail.mail form, values all are come there. But I can't click automatically send button to Send a Mail.

Thanks and regards Sridharan G

الصورة الرمزية
إهمال
أفضل إجابة

I am sending mail via a scheduler job.

Create a scheduler definition xml file. Look for "ir_cron_scheduler_action" in the code for an example.

In the model definition py file create a function "run_scheduler" def run_scheduler(self, cr, uid, automatic=False, use_new_cursor=False, context=None): # Create mail body etc. Then call: mail_obj.schedule_with_attach(params)

Hope this helps

الصورة الرمزية
إهمال
الكاتب

Thanks for Reply, tried another method it is working fine, now i able to send automatic mail, when date is expire.

المنشورات ذات الصلة الردود أدوات العرض النشاط
2
أبريل 23
2781
0
مارس 15
5498
0
مايو 21
3520
2
أبريل 20
15628
4
مارس 19
16202