跳至內容
選單
此問題已被標幟
1458 瀏覽次數

comment envoyer des email from button submit in odoo 14

頭像
捨棄
作者

def action_validate(self):
if len(self.loan_line_ids)<=0:
raise ValidationError(
_("Rien a Validé"))
self.env['extra.loan.approver'].create({
'loan_id': self.id,
'user_id': self.env.uid, 'date_approved': fields.Datetime.now(), 'state': 'approved'})
mail_template = self.env.ref('extra_rh.extra_loan_valid')
mail_template.send_mail(self.id, force_send=True)
self.write({'state':'approve'})

相關帖文 回覆 瀏覽次數 活動
2
6月 24
3896
2
11月 23
3109
2
2月 21
2376
1
7月 25
2281
2
7月 25
7755