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

Where can I change in code, so that email_from is changed when I send mail from chatter?

아바타
취소
베스트 답변

Hi,

You can customize the sender email (email_from) for chatter messages by overriding the message_post method. For example:

class MailThread(models.AbstractModel):

    _inherit = 'mail.thread'


    @api.model

    def message_post(self, **kwargs):

        if not kwargs.get('email_from'):

            kwargs['email_from'] = 'custom_email@example.com'  # Set your custom email address

        return super().message_post(**kwargs)

This will set a custom sender email if one is not provided when posting a message.


Hope it helps

아바타
취소
베스트 답변

Any update?

아바타
취소

Is this problem solved? More information here: https://101games.io/solar-smash

관련 게시물 답글 화면 활동
1
8월 25
2040
2
8월 25
639
2
3월 25
1578
1
2월 25
2033
1
12월 24
2534