Is it possible to change the sender address for all emails sent via chatter of a certain model? If so, how can I do it?
Odoo is the world's easiest all-in-one management software.
It includes hundreds of business apps:
- CRM
- e-Commerce
- Contabilidad
- Inventario
- PoS
- Project
- MRP
Se marcó esta pregunta
Fixed:
class TheModel(models.Model):
...
_inherit = ['mail.thread', 'mail.activity.mixin']
...
@api.multi
@api.returns('self', lambda value: value.id)
def message_post(self, body='', subject=None, message_type='notification', **kwargs):
kwargs['email_from'] = "REALMAIL <realmail@domain.com>"
return super(TheModel, self).message_post(body, subject, message_type, **kwargs)
¿Le interesa esta conversación? ¡Participe en ella!
Cree una cuenta para poder utilizar funciones exclusivas e interactuar con la comunidad.
InscribirsePublicaciones relacionadas | Respuestas | Vistas | Actividad | |
---|---|---|---|---|
|
3
jul 21
|
9484 | ||
|
0
abr 21
|
1905 | ||
|
1
jun 19
|
3949 | ||
|
1
ago 25
|
3252 | ||
|
1
mar 25
|
1916 |