I want to attachment(s) copy from demand to enhancement, is it possible ?

Ramanjaneyulu C
Tera Contributor

I want to attachment(s) copy from demand to enhancement, is it possible ? [when demand is turned into a project, attachments do carry over].

5 REPLIES 5

Eshwar Reddy
Kilo Sage

Hi @Ramanjaneyulu C 
yes it is possible 

Refer to the below link
example code

var copy = new GlideRecord('problem');
    copy.addQuery('parent', current.getUniqueValue());
    copy.query();
    if (copy.next()) {
        GlideSysAttachment.copy('incident', current.getUniqueValue(), 'problem', copy.getUniqueValue());
    }