and more in a single search tool across platforms. Read the announcement here. |
09/28/2022 10:38 AM
Hi Team,
we have request approval configured for 2 levels for New Account+Entitlmemnt request, we are using below variable to show requested items in email.
<tr><th>Application</th><th> Entitlement Name(s) </th> <th> Description </th> <th> Glossary </th> </tr> ${entitlementshtmltablerows}
the above table populates only when user request for Entitlmements , if request for new Account this is showing as blank.
How to populate above table with application name ( in case of only New Account request) ?
09/28/2022 11:29 AM
This table will only get populated if the request contains any entitlements. Else it will be blank as shown in your snip.
If you would like to show your application name / the request type in the email, Use the below binding variables.
${endpoint} - Obtains the name of the endpoint for which request is submitted.
${requesttype} - Obtains the request type such as new account, add access, or remove access.
If you want to hide this blank table if no entitlements are requested (Just new account request), you can use the below logic in your email template.
${entitlementshtmltablerows.equals('') ? '' : ('<p><b>Entitlement(s) Requested:</b> <br><br /><table border="1" cellpadding="2" cellspacing="0"><tr><th>Application</th><th> Role </th> <th> Description </th> <th> Glossary </th> </tr>') + (entitlementshtmltablerows) + ('</table></p>')}
You can refer this freshdesk documentation for variables exposed in email templates - https://saviynt.freshdesk.com/support/solutions/articles/43000622153-managing-email-templates
Hope this helps!
-Siva
09/28/2022 11:47 AM
${requesttype} is variable used to check Request Type
to check all variable available in email template use below code in email body
${this.binding.variables.each {k,v -> println "$k = $v" + "<" + "br" + ">"}}
09/28/2022 11:57 AM
Thank you Guys for the responses.
I have tried below - its same behaviour :
existing one :
<tr><th>Application</th><th> Entitlement Name(s) </th> <th> Description </th> <th> Glossary </th> </tr> ${entitlementshtmltablerows}
new one :
${entitlementshtmltablerows.equals('') ? '' : ('<p><b>Entitlement(s) Requested:</b> <br><br /><table border="1" cellpadding="2" cellspacing="0"><tr><th>Application</th><th> Role </th> <th> Description </th> <th> Glossary </th> </tr>') + (entitlementshtmltablerows) + ('</table></p>')}
Can we try this - Do you have sample syntax for this ?
<% ${requesttype} == 'NEw account' %>
09/28/2022 12:09 PM
<% if(requesttype.equalsIgnoreCase('New Request')) print "" else print "${entitlementshtmltablerows}" %>