Check for Attachments on Service Portal
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
12-11-2017 09:18 AM
We have a onsubmit script for CMS that worked fine but this is not working on Service Portal.
function onSubmit() {
//Type appropriate comment here, and begin script below
var sys_id=gel('sysparm_item_guid').value;
var gr = new GlideRecord("sys_attachment");
gr.addQuery("table_name","sc_cart_item");
gr.addQuery("table_sys_id",sys_id);
gr.query();
if (!gr.next()) {
alert("Please attach the 'Desktop Software Security Review' filled out form before submitting this request");
return false;
}
}
Am i missing something that can cause it not to work on Service Portal
- Labels:
-
Service Catalog

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-28-2019 04:39 AM
Ahh!! good to know that Mark. Will be looking forward to making use of this once we're on Madrid. Thanks for sharing this knowledge.