Guest User

Untitled

a guest
Jan 22nd, 2019
81
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.35 KB | None | 0 0
  1. function onChange(control, oldValue, newValue, isLoading) {
  2. if (isLoading || newValue == '') {
  3. return;
  4. }
  5.  
  6. var user = new GlideRecord("sys_user");
  7. user.addQuery("sys_id", newValue);
  8. user.setLimit(1);
  9.  
  10. user.query(function(record) {
  11. if(record.next()) {
  12. var managerSysid = record.manager;
  13. g_form.setValue("u_manager", managerSysid);
  14. }
  15. });
  16. }
Add Comment
Please, Sign In to add comment