콘텐츠로 건너뛰기
메뉴
커뮤니티에 참여하려면 회원 가입을 하시기 바랍니다.
신고된 질문입니다
3148 화면

I had set my outgoing mail server and also tested the connection all was fine but the mail is not reflecting in the inbox can someone help me on this earlier in v9 it was working fine but in v11 its now working.

Since my program is not showing any error just didn't reflect in the mail.

Thanks in Advance

#py

@api.multi

def action_send_mail(self):

    template_id = self.env['ir.model.data'].get_object_reference('automat','mail_automat_sales_inquiry')[1]

    email_template_obj = self.env['mail.template'].browse(template_id)

    print (email_template_obj)

return {}

#xml

<?xml version="1.0" ?>

<openerp>

<data>

<!--Email template -->

<record id="mail_automat_sales_inquiry" model="mail.template">

<field name="name">Sales Quotation</field>

<field name="email_from">any_mail@something.com</field> 

<field name="email_to">any_mail@something.com</field>

<field name="model_id" ref="automat.model_automat_sales_inquiry"/>

<field name="auto_delete" eval="True"/>

<field name="subject">

<![CDATA[

Testing Mail in Version 11

]]></field>

<field name="body_html">

<![CDATA[

<div style="font-family: 'Lucica Grande', Ubuntu, Arial, Verdana, sans-serif; font-size: 12px; color: rgb(34, 34, 34); background-color: #FFF; ">

<p>Welcome</p>

</div>

]]></field>

</record>

</data>

</openerp>

아바타
취소
관련 게시물 답글 화면 활동
3
9월 25
1822
2
9월 25
333
1
8월 25
1781
1
5월 25
1451
0
4월 25
1288