Cédric Krier pushed to branch branch/default at Tryton / Tryton


Commits:
27bd4c93 by Cédric Krier at 2025-05-23T17:07:57+02:00
Set email content with maintype when needed and correctly set Content-Language 
header

When the content is not a string, EmailMessage.set_content requires a maintype
argument but not when it is a string. The maintype is then deduced using the
mimetypes module.
The Content-Language of content or alternate must be set using the headers
parameter instead of params which is for the Content-Type.
And finally the Content-Language must be set on the main message only if it
contains multiparts otherwise it is set twice.

Closes #14028
- - - - -
181be514 by Cédric Krier at 2025-05-23T17:13:37+02:00
Document preferred languages order for get_email
- - - - -


4 changed files:

- trytond/doc/ref/report.rst
- trytond/setup.py
- trytond/trytond/report/report.py
- trytond/trytond/tests/test_report.py


View it on Heptapod: 
https://foss.heptapod.net/tryton/tryton/-/compare/f2734a16eb1d28f654ffc3ae6cd45b9d2af8726e...181be514a757e2d93f7da4b4753bcb91767155b8

-- 
View it on Heptapod: 
https://foss.heptapod.net/tryton/tryton/-/compare/f2734a16eb1d28f654ffc3ae6cd45b9d2af8726e...181be514a757e2d93f7da4b4753bcb91767155b8
You're receiving this email because of your account on foss.heptapod.net.

Reply via email to