Announcing the SAVIYNT KNOWLEDGE EXCHANGE unifying the Saviynt forums, documentation, training, and more in a single search tool across platforms. Click HERE to read the Announcement.

Multiple attribute values are not updated in AD Account Description

rajeshg
New Contributor
New Contributor
Hi Team,
We are testing LOA scenario and require to send the LOA value details from saviynt to AD account description. But its not passing and getting an an error.
 
Requirement:
 
User is on LOA, we want the description to add this to the end of the existing description. “ ** LOA YYYYMMDD Saviynt” where YYYYMMDD is the current date (20230503)
 
Requirement:
Description before user goes on LOA ( the below value is combination of cost center name and employee ID)
ERS R & D Operations 704127
 
Description when user is on LOA
ERS R & D Operations 704127 ** LOA 20230503 Saviynt
 
Description when user is no longer on LOA
ERS R & D Operations 704127
 
JSON Syntax:
 
"description": "${if(user.customproperty7?.equals ('On Leave')){'value' user.customproperty12 'value' user.employeeid}
 
Getting error:
No signature of method: SimpleTemplateScript420.value() is applicable for argument types: (java.lang.String) values: [Costcenter Center] Possible solutions: evaluate(java.lang.String), evaluate(java.io.File), wait(), run(), run(), any()
7 REPLIES 7

dgandhi
All-Star
All-Star

It seems to be syntax issue. Can you try below?

"description": "${if(user.customproperty7.equals('On Leave')){'value'+' '+user?.customproperty12} else {'value'+' '+user?.employeeid}}"

Thanks

Thanks,
Devang Gandhi
If this reply answered your question, please Accept As Solution and give Kudos to help others who may have a similar problem.

rajeshg
New Contributor
New Contributor

Hi @dgandhi 

Thanks for your response.

Our requirement is to combine multiple attribute values and need to send to AD account description and also with else condition. Refer below.

"description": "${if(user.customproperty7.equals ('On Leave')){'user.customproperty12''user.employeeid''user.customproperty7'} else if(user?.customproperty12.equals('Active')) {'user.customproperty12''user.employeeid'}} ",

Regards,
Rajesh

SB
Saviynt Employee
Saviynt Employee

You can use the below format to setup the description value when CP7 is On Leave.

I am checking on how to trim the value we added once user is no longer On Leave and will update you.

"description": "${if(user?.customproperty7.equals('On Leave')){String str = user.customproperty12;return str.concat('** LOA').concat(Calendar.getInstance().getTime().format('yyyyMMddHHmmss')).concat('Saviynt');} else {user.customproperty12}}"


Regards,
Sahil

rajeshg
New Contributor
New Contributor

Hi @SB 

Thanks for your reply. 

The requirement is the below. I can pass single attribute value but when start combine mor ethan one then its passing the attribute keys (cp12, cp13) instead of the value.

The requirement is as below.

"description": "${if(user?.customproperty12.equals('On leave')) ${user.customproperty12} ${user.employeeid} ** ${user.customproperty7} ${user.customproperty13} Saviynt else if(user?.customproperty12.equals('Active')) ${user.customproperty12} ${user.employeeid}}

Regards,
Rajesh

 

You can use concat string function


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

rajeshg
New Contributor
New Contributor

Thanks you all issue resolved with some customizations.

SB
Saviynt Employee
Saviynt Employee

Can you share the final format you used which solved the issue.


Regards,
Sahil