The 'Short Description' field from the release parent is not populating the 'Project Name' field

CarolMa6
Tera Expert

Hi, 

 

I'm trying to configure the 'Short Description' field from the release parent to populate the 'Project Name' field in related tasks. However, the current business rule is incorrectly updating the related tasks using the 'Description' field from the related phase task instead of the release parent.

 

table: rm_task

when: display

script: 

(function executeRule(current, previous /*null when async*/ ) {

    current.u_project_name = current.parent.short_description;

})(current, previous);

 

Regards 

CarolMa

 

 

14 REPLIES 14

@CarolMa6 

 

Did you get a chance to review this ?

 

If my responses helped to answer your query, please mark it helpful & accept the solution. As per community guidelines, you can accept more than one answer as accepted solution.

 

Thanks,

Bhuvan

@CarolMa6 

so what did logs say?

If my response helped please mark it correct and close the thread so that it benefits future readers.

Regards,
Ankur
Certified Technical Architect  ||  9x ServiceNow MVP  ||  ServiceNow Community Leader

@Ankur Bawiskar 

The logs show that the Project Name field in the Release Task record is being populated. However, instead of pulling the correct value from the Parent Release record, it appears to be populated with the Short Description from the Release Phase Task record.

 

not sure how this is happening, help. 

 

Regards

CarolMa

@CarolMa6 

it means it's not picking the correct field.

Regards,
Ankur
Certified Technical Architect  ||  9x ServiceNow MVP  ||  ServiceNow Community Leader

@Ankur Bawiskar 

 

How can I ensure that updates are strictly happening between only two tables — rm_task and its parent table rm_release . The logs show that the project_name value is correctly captured on the parent (rm_release) table, but nothing is being populated on the child (rm_task) table. This suggests that the script isn't successfully retrieving the value from the parent and applying it to the corresponding field on the task form.

I’ve hit a wall and would really appreciate your help.

 

Regards

CarolMa