Prepopulate the fields while creating child case
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
3 hours ago
Hi All,
We have a requirement to prepopulate the opened for with parent Assigned to field while trying to create a child HR case from HR Agent Workspace.
Tried creating a Business rule before insert, but it is happening after creating the case not while creating or while loading.
Can someone provide your expertise over here?
Thanks in Advance!!!
Manisha
- Labels:
-
Human Resources Service Delivery
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
3 hours ago
you can use onLoad client script, grab the sysId of parent
Then use GlideAjax to check the parent assigned to and set in Child HR Case
💡 If my response helped, please mark it as correct ✅ and close the thread 🔒— this helps future readers find the solution faster! 🙏
Ankur
✨ Certified Technical Architect || ✨ 9x ServiceNow MVP || ✨ ServiceNow Community Leader
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
2 hours ago - last edited 2 hours ago
Hi @Ankur Bawiskar ,
Thanks for the quick response.
I did try with onchange client script as our requirement is specific to HR Service, when trying to create child case and hr service selected is "A", then the opened for should be prepopulated with Assigned to of Parent case, but no luck.
Thanks,
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
2 hours ago
you want it while loading then why onchange script is required?
share your script and did you follow the approach I shared?
Ankur
✨ Certified Technical Architect || ✨ 9x ServiceNow MVP || ✨ ServiceNow Community Leader
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
40m ago - last edited 39m ago
@Ankur Bawiskar Apologies, i have tried using onload client script but no luck, its not pre-populating the field value of opened for with assigend to of parent.
Client script:
Script include:
