- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-20-2018 08:25 AM
I'd like to build a Template to allow the auto-fill of Assignment Group from the User record, using a field called 'u_main_group' (similar to using javascript: gs.getUserID()). I've used Script Includes to limit options before, but never to populate a field like that.
How would I do that? Is that even the right approach?
Solved! Go to Solution.
- Labels:
-
Scripting and Coding

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-20-2018 08:36 AM
Please mark this response as correct or helpful if it assisted you with your question.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-20-2018 08:54 AM
With a minor typo fix, this does work:
javascript:var u = new GlideRecord('sys_user'); u.get(gs.getUserID());u.u_main_group;

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-20-2018 08:55 AM
small update: just to change the JavaScript to javascript