UI Action - Create Story modification on enhancement form

Pramod Pandey2
Tera Contributor

Hello Community,

 

I have requirement to modify create story ui action which is available in enhancement form.

UI action copy short des, description assigned to from enhancement form to story dialog form. But i also need to add attachment and worknote code as well so when we create story from enhancement it should copy attachment and worknote.

 

Below is code where i need to modify 

--------------------------------------------

 

 var gModalForm = new GlideModalForm('Create Story', 'rm_story');
    gModalForm.setPreference('sysparm_view', 'scrum');
    gModalForm.addParm('sysparm_query', 'short_description=' +
        g_form.getValue('short_description').replace(/\^/g, '^^') +
        '^description=' + g_form.getValue('short_description').replace(/\^/g, '^^') +
        '^acceptance_criteria=' + g_form.getValue('description').replace(/\^/g, '^^') +
        '^assigned_to=' + g_form.getValue('assigned_to') +
        '^work_notes=' + g_form.getValue('work_notes') +
        '^classification=Feature' +
        '^enhancement=' + sysId +
        '^sys_class_name=rm_story'
    );
------------------------------------------------------------------------------
Ui Action screen shot
 
PramodPandey2_0-1729169390369.png

 

Please suggest me what changes i can do to copy  attachment and work note from enhancement to story dialog window.

 

@John Dewhurst

 @GS3 @Ankur Bawiskar @Abhishek Gardad 

Thanks

Pramod Pandey

1 REPLY 1

Abbas_5
Tera Sage
Tera Sage

Hello @Pramod Pandey2,

Please refer to the link below:
https://www.servicenow.com/community/developer-forum/create-story-from-using-ui-action/m-p/2775865

 

If it is helpful, please mark it as helpful and accept the correct solution, In future by refer to the solution it will helpful to them.

Thanks & Regards,

Abbas Shaik