
- Subscribe to RSS Feed
- Mark as New
- Mark as Read
- Bookmark
- Subscribe
- Printer Friendly Page
- Report Inappropriate Content
When you are submitting a service request, you can add attachments using the icon located on the form header. But, if you want to enhance the form with a customized Add Attachment button, there's a simple way to create this to make the functionality that much easier.
You'll just need to create a UI page with some basic scripting. The script will actually include the button and fires when the button is clicked. You'll also need to add a UI page variable to your catalog item to reference the UI page.
How to add a customized attachment button in your service catalog:
First, create the UI page:
- Go to System UI > UI Pages.
- Click New.
- Create a name such as Add_Attachment_UI.
- In the Category field, select General.
- In the HTML field, copy the script from below. Label the button whatever makes sense for your catalog page (see bold text below):
<?xml version="1.0" encoding="utf-8" ?>
<j:jelly trim="false" xmlns:j="jelly:core" xmlns:g="glide" xmlns:j2="null" xmlns:g2="null">
<button type="button" onclick="saveCatAttachment(gel('sysparm_item_guid').value, 'sc_cart_item')">Add Attachment</button>
</j:jelly>
- Click Submit.
Then, add a UI page variable:
- From your catalog item, add a New Variable.
- In the Type field, select UI Page.
- In Type Specifications, enter Add_Attachment_UI in the UI page field.
- Set the rest of the fields as normal.
You'll now be able to view your button on your catalog item:
And when you click it, your standard attachment browser will automatically display:
Having Service Catalog UI issues? See:
Redirecting the Back to Catalog button
Get the Continue Shopping button working in your Service Catalog
- 14,415 Views
- « Previous
-
- 1
- 2
- Next »
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.