Usage of the script answer = (function transformEntry(source) { if (target.install_status!= 7) { target.install_status=1; } // Add your code here return ""; // return the value to be put into the target field })(source);

Nirupama Reddy
Tera Contributor

Can anyone explain the use of this script and also how to check the backend value of 7 and 1?

find_real_file.png

1 REPLY 1

Sean Walters
Tera Expert

Hi Nirupama, 

So the source script is checking if the target record_ install status is not Retired then make the install status Installed. 

You can check the field values at the dictionary level of the table. 

Go to the Computer table (cmdb_ci_computer)
Right click between the headers and go to dictionary 
Search for the field install_status
and scroll down to see the choices. 


The link should take your right there just replace the instance within the URL below.  
https://dev.service-now.com/nav_to.do?uri=sys_dictionary.do?sys_id=cc82e73f753011108c8b143dd0c59f9c

find_real_file.png

 

Hope that helps.

Please mark my answer correct and helpful if this resolves your issue.