Small notice. Mine patch is incompatible with this issue: https://www.drupal.org/project/commerce_email/issues/3314082 π Mail "to" replaceTokens Fixed . Anyway the metioned issue is resolved also.
I have updated the patch for the latest dev branch changes. There is the same feature request that is not dependent on the commerce core patch ( https://www.drupal.org/project/commerce_email/issues/3282118 β ). Definitely, there is demand for this feature.
- π§πͺBelgium weseze
I also need this functionality, didn't expect that it would not be standard...
Attached is a revised patch that works against latest stable release. (8.x-1.5)
I've added 2 changes:
1/ passing the langcode also to the the $params array
2/ reset the active language to what it was after the mail processing; this would prevent any other processes from using the wrong languageAlso fixed som typos in variable names. (but that might be because of changes to dev?)
I als think this still needs work since the behaviour should be optional/configurable.
You do not always want to send mails in the customers language. For example when sending mails to administrators, they prefer fixed language.