on 07-08-2015 9:23 AM
Hello All,
In general we will be using NotificationUtil class for sending custom mail notifications.
Below is the method which we use most frequently.
NotificationUtil.sendNotification(java.lang.String[] recipients, IapiAccountIfc sender, MailTypeEnum notificationType, java.util.Properties notificationParameters, java.lang.String attachmentDisplayName, java.io.InputStream attachment)
;
If you see the sender parameter in above method, we have to use IapiAccountIfc which can be fetched below.
sender = session.getAccount();
Lets say sender is user "USERSCN" and the respective
user mail id is "user.scn@sap.com" and
user's company mail id is "noreply.scn@sap.com"
In the mail notification which is sent out what would be the sender email in the notification as per above data?
In our Sourcing Application i.e, Sourcing 9 SP14 mail is getting triggered such that sender mail id is getting fetched from company
But after upgrading to Sourcing 10 SP4 mail is getting triggered such that sender mail id is user email itself.
Why its not behaving the same way as it was before upgrading?
Please clarify
Regards,
Raj
Hi Raj,
I remember this issue when transitioning from V9 to V10. The behaviour changed as a result of a (presumed) bug-fix.
In general, the email notification will override the 'sender' address with the value from the email template config (hardcoded config). For custom email templates, the Sender field is BLANK. Question is ... "what should be the sender address in the case of BLANK setup?"
In V9 it was defaulting to 'company address', but in V10 the code is picking up the selected user account address.
In our case, we were sending these emails from a ProcessOwner user, so we changed the email address to the company address to 'fix' this problem.
If you are sending the emails from a buyer user account, there's no standard way you could change the behaviour for onlythis email type.
Bogdan
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.