Announcing the Saviynt Knowledge Exchange unifying the Saviynt forums, documentation, training,
and more in a single search tool across platforms. Read the announcement here.

Email Templte 'To' recipe logic

CR
Regular Contributor III
Regular Contributor III

Hi Team,

I Have requirement based on customer value need to send mail , as of now secondarymanager email id saving in cp7 value. i need include exiting logic. could help on this issue please?

secondarymanager=cp7

vendormanager=cp59

Current working synatax: <% if (null!=user.customproperty59 && user.customproperty59!='') print"${user.customproperty59}" else print "${user.vendorManager.email}"%>

i need include based on customer = 15 need to secondary manager (cp7 we have value mail id)

tried :

working alone 1 :

<% if (null!=user.customproperty7 && user.customproperty7!='') print"${user.customproperty7}" else print "${user.secondaryManager.email}"%>

Have 2 cases :

1. Secondarymanager,VendorManager combination also it sholud trigger both

2..only vendorManager will pass

3. only Secondarymanager will pass

tried below not working used user.customer=15 and without comma print stement , above 2 and 3 separately tried but not working

<%
if(null!=user.customproperty59 && user.customproperty59!='' && user.customer.customerkey!='' && user.customer.customerkey==15) print"${user.customproperty59}" "${user.customproperty7} else print "${user.vendorManager.email},"${user.secondaryManager.email}" || (user.customer.customerkey!='' && user.customer.customerkey==15) print "${user.customproperty7} || (null!=user.customproperty59 && user.customproperty59!='') print"${user.customproperty59}" else print "${user.vendorManager.email} || (null!=user.customer.customerkey && user.customer.customerkey==15) print "${user.customproperty7}" else print "${user.secondaryManager.email}"
%>

 

 

 


Thanks,
Raghu
If this reply answered your question, Please Accept As Solution and hit Kudos.
3 REPLIES 3

rushikeshvartak
All-Star
All-Star

<%
if (null != user.customproperty59 && user.customproperty59 != '') {
if (user.customer == 15) {
print "${user.customproperty7}" 
} else {
print "${user.customproperty59}" 
}
} else {
print "${user.vendorManager.email}"
}
%>


Regards,
Rushikesh Vartak
If you find the response useful, kindly consider selecting Accept As Solution and clicking on the kudos button.

CR
Regular Contributor III
Regular Contributor III

thanks @rushikeshvartak

Not working , mail not going to cp7 and it printing empty.

CR_0-1709185224279.png

 

and we tried same type of scenario when customer object passing email not getting cp7 person

 


Thanks,
Raghu
If this reply answered your question, Please Accept As Solution and hit Kudos.

share variable list


Regards,
Rushikesh Vartak
If you find the response useful, kindly consider selecting Accept As Solution and clicking on the kudos button.