- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-20-2022 09:14 PM
Change task planned start/end date should be same as Change request , also when Change Request planned dates are updated , Change Task planned date should be updated as well
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-20-2022 09:59 PM
Hi,
Please write a After Insert and Update Business Rule on Change request table and use the script as below:
(function executeRule(current, previous /*null when async*/) {
// Add your code here
var gr = new GlideRecord('change_task');
gr.addQuery('change_request',current.sys_id);
gr.query();
while(gr.next()){
gr.planned_start_date = current.start_date.getDisplayValue();
gr.planned_end_date = current.end_date.getDisplayValue();
gr.update();
}
})(current, previous);
Regards,
Shloke
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-20-2022 10:02 PM
Also for reference, I am attaching the BR screenshot . Also make sure the condition of BR should be as below:
Planned Start Date Changes
OR
Planned End Date Changes
I have tested this and it is working in my PDI.
Hope this helps. Please mark the answer as correct/helpful based on impact.
Regards,
Shloke
Regards,
Shloke