[3.3] Nop.Services.Messages.WorkflowMessageService

This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.
8 years ago
I am using nop 3.3.


In Nop.Services.Messages.WorkflowMessageService, there is a method called GetEmailAccountOfMessageTemplate() which has a line like this.

var emailAccounId = messageTemplate.GetLocalized(mt => mt.EmailAccountId, languageId);

Any reason why we do not just grab the id like this?

var emailAccountId = messageTemplate.EmailAccountId;


What was the purpose of getting a localized value on an ID? Just trying to understand the code, but it is picking up the wrong id every single time when we have multiple accounts in our multi tenant multi country environments.


Any help would be appreciated.
8 years ago
EmailAccount is set by each language on message template as well.

so depend on language it getting the proper email account.

if you check the message template / Edit the email account is set for each language tab

I Hope it help.
8 years ago
vipul.dumaniya wrote:
EmailAccount is set by each language on message template as well.

so depend on language it getting the proper email account.

if you check the message template / Edit the email account is set for each language tab

I Hope it help.


The multi countries that we support are New Zealand and Australia. They speak the same language, so it doesn't solve the problem that our NZ templates still picking up AU address. It seems risky to our business to pick up email address base on the language but not base on what we chose.
8 years ago
if you want to use different email account depend on country then may be you need to use multi store for each country and use and restrict the email account by the store.
This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.