GlideSysAttachment Business rule not adding attachment
Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎04-02-2024 07:27 AM
I have an inbound action which creates a request and child RITM. The inbound action runs on the sc_request table so by default the attachments get added to the request. I have created a BR which runs After insert on the sc_req_item table however I cannot get the attachment to add on insert at all
--BR Code--
var att = new GlideSysAttachment();
var copiedAtt = att.copy('sc_request', current.request, 'sc_req_item', current.sys_id);
Any help is appreciated!
Thanks
1 REPLY 1

Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎04-02-2024 08:04 AM
@Kearney Could you please update the script as follows and check it it works.
var att = new GlideSysAttachment();
var copiedAtt = att.copy('sc_request', current.getValue('request'), 'sc_req_item', current.getValue('sys_id'));
Hope this works.