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

How to derive certifier's email in Revoke Task Email

hirenp
New Contributor III
New Contributor III

Hi,

I am trying to determine the binding variable for the certifier's email address in the Revoke Task email. 

Also when the task is created to Remove child entitlement ${users?.email} is a null value so I would like to add a conditional logic check not to send an email if ${users?.email} value is null. Any suggestion on how to do it?

10 REPLIES 10

Saathvik
All-Star
All-Star

Try ${Certification?.certifier?.email} for certifier email.

If didn't work try ${this.binding.variables.each {k,v -> println "$k = $v" + "<" + "br" + ">"}} parameter in body of revoke email template and share the output 

Also for if else condition use below

<% if (null==users?.email || users?.email == '') print "<logic here>" else print "logic here" %>


Regards,
Saathvik
If this reply answered your question, please Accept As Solution and give Kudos to help others facing similar issue.

hirenp
New Contributor III
New Contributor III

Here is the output of all the binding variables. Don't see certification?certifier?.email

 

task = com.saviynt.ecm.task.ArsTasks : 
manager = null
campaign = com.saviynt.ecm.campaign.domain.Campaign : 
baseUrlForEmail = https://release-n-plus-one.saviyntcloud.com/ECM
campaignOwnerAndTheirDelegateEmailList = 
user = admin
secondarycertifier =
requestor = admin
tasks = com.saviynt.ecm.task.ArsTasks : 
users = admin
Certification = com.saviynt.ecm.campaign.domain.Certification : 
out = java.io.PrintWriter@3bff52d2
This is Revoke by email address - 

[task:com.saviynt.ecm.task.ArsTasks : , manager:null, campaign:com.saviynt.ecm.campaign.domain.Campaign : , baseUrlForEmail:https://release-n-plus-one.saviyntcloud.com/ECM, campaignOwnerAndTheirDelegateEmailList:, user:admin, secondarycertifier:, requestor:admin, tasks:com.saviynt.ecm.task.ArsTasks : , users:admin, Certification:com.saviynt.ecm.campaign.domain.Certification : , out:java.io.PrintWriter@3bff52d2]

I don't see parameter exposed related certifier. You need to use certification parameter.

Try the one I suggested ${Certification?.certifier?.email}  and see if that works


Regards,
Saathvik
If this reply answered your question, please Accept As Solution and give Kudos to help others facing similar issue.

hirenp
New Contributor III
New Contributor III

What do you mean to use the certification parameter?

I tried the one you suggested but it does not work

Can you put this in body and let me know if it is giving any output

${Certification?.certifier}


Regards,
Saathvik
If this reply answered your question, please Accept As Solution and give Kudos to help others facing similar issue.

hirenp
New Contributor III
New Contributor III

It gives certifier key which is userkey

Okay cool then ${Certification?.certifier?.email} this should work to get certifier email. If you can share the error logs we can see what's going wrong.

otherwise you can try this

${com.saviynt.ecm.identitywarehouse.domain.Users.get(Certification?.certifier)?.email}


Regards,
Saathvik
If this reply answered your question, please Accept As Solution and give Kudos to help others facing similar issue.

hirenp
New Contributor III
New Contributor III

Could you also suggest what is the issue in the below statement

Hi <%if(null!=task?.accountName || task?.accountName!='') print "${users?.firstname}" else print"XYZ"%>

Even though task?accountName  value is null it is not evaluating it correctly

What is the behaviour you are seeing with above statement? Are you seeing any error or invalid ouput?

Can you please share the task?.accountName output


Regards,
Saathvik
If this reply answered your question, please Accept As Solution and give Kudos to help others facing similar issue.

hirenp
New Contributor III
New Contributor III

Thanks again i was able to resolve this issue. Instead of null!= I used null== and it worked