How to inherit fields when we spilt a story

Harshitha SR1
Tera Contributor

Hi All,

My requirement is to inherit the fields when we are spilting a story such as:

When a story is split, it should inherit the following additional information from the original story

  • Application Owners
  • State
  • Priority
  • Enhancement
  • Defect
  • Enhancement
  • HR Case
  • Incident
  • Requested for

Change the current inheritance as follows

  • Do not inherit Release
  • Change the Split from field to show STRY # instead of name

Could anyone provide solution to achieve it.

Thanks,

Harshitha SR

 

4 REPLIES 4

Mohith Devatte
Tera Sage
Tera Sage

Hello, 

You can create a after insert BR on story table and query with the parent story 

then you can start mapping the corresponding fields to the child story.

Please accept my answer if it gave you an idea

Hi Mohit,

Can you please provide code for this requirement.

 

Thanks,

Harshitha SR

Hi Harshita, 

Here is what you need to do -

When a story is split, it should inherit the following additional information from the original story and should not include the release field

Update this script include - 'SplitStoryUtil' on line 10 with the fields that you want to copy and the ones you don't want to because this drives the story split. Note this is OOTB script so consider the impact on upgrades if you are changing this.  

 

find_real_file.png

Change the Split from field to show STRY # instead of a name

Wouldn't recommend you to do that as it required a change to the display value of the overall table since all reference fields to the story table would show the short description, but if you still have this as a requirement then the required changes are available on the link below - 

https://community.servicenow.com/community?id=community_question&sys_id=6535afb9dbf567005d782183ca96...


If the above answer has helped you to close your issue, then please mark the answer as helpful and correct to close the thread. 

Thanks, Harneet

Hi @Harshitha SR @Harshitha SR 

Request you to please mark the answer correct if this has fixed your query so others can refer to the same answer and we get the query marked closed.

 

If the answer has helped you, please mark the answer correct/helpful. Thank you.
-Harneet
ServiceNow Certified Technical Architect