HR Profile Java Script

mustafaia1
Tera Contributor

In the HRSD, we have variables in our Record Producers that are refencing the Sys User Table. When a user is selected from that, we want other variables on the Record Producer to populate information from the users HR Profile. I created this Catalog Client Script below but when I test the form out, nothing populates. What am I doing incorrectly?

 

 
2 REPLIES 2

Sandeep Rajput
Tera Patron
Tera Patron

@mustafaia1 Are you facing this issue on Service Portal or the platform view. If it is on the Service Portal then you need to change the UI Type to Mobile/Service Portal.

 

Another issue I observed in your script is that it is an onChange client script which runs on change of emp_barg_union field and inside the script you are again trying to set the value of emp_barg_union field on line number 16. This will cause a recursion of onChange script and either the form would hang or the method call would end abruptly. 

 

Hope this helps.

Rampriya-S
Tera Guru
Tera Guru

Hi @mustafaia1,

You have written onChange Catalog client script on the field 'emp_barg_union' and clearing the same field and setting the bargaining unit in the line number 16? It will run recursive.

and In the line number 16 you are setting bargaining unit to the union.

 

 

Mark helpful if the solution is accepted.

Best,
Rampriya S