<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>question Re: Service Portal Approver can see attachments in Developer forum</title>
    <link>https://www.servicenow.com/community/developer-forum/service-portal-approver-can-see-attachments/m-p/2141693#M798619</link>
    <description>&lt;P&gt;For what its worth, its possible to update the approval record widget to display the attachments.&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;Widget HTML Template:&lt;/P&gt;&lt;BR /&gt;&lt;PRE __default_attr="java" __jive_macro_name="code" class="jive_macro_code _jivemacro_uid_15175269231479298 jive_text_macro" data-renderedposition="58_8_1175_816" jivemacro_uid="_15175269231479298"&gt;&lt;P&gt;&amp;lt;div ng-if="!data.isValid"&amp;gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;${Record not found}&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;&amp;lt;/div&amp;gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;&amp;lt;div ng-if="data.isValid"&amp;gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;&amp;lt;div class="panel panel-{{::options.color}} b"&amp;gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt; &amp;nbsp; &amp;lt;div class="panel-heading"&amp;gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;lt;h4 class="panel-title"&amp;gt;${Approval request for {{::task.table}} {{::task.number.display_value}}}&amp;lt;/h4&amp;gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt; &amp;nbsp; &amp;lt;/div&amp;gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt; &amp;nbsp; &amp;lt;div class="panel-body"&amp;gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;lt;div ng-if="task.attachments.length &amp;gt; 0"&amp;gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;lt;label&amp;gt;${Attachments}:&amp;lt;/label&amp;gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;lt;ul&amp;gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;lt;div ng-repeat="attachment in task.attachments"&amp;gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;lt;a target="_blank" href="/sys_attachment.do?view=true&amp;amp;sys_id={{attachment.sys_id}}"&amp;gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;lt;img ng-if="attachment.thumbnail_path" alt="" ng-src="/{{attachment.path}}?t=medium" class="img-responsive"/&amp;gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;lt;/a&amp;gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;lt;div&amp;gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;lt;li&amp;gt;&amp;lt;a href="/sys_attachment.do?sys_id={{attachment.sys_id}}" target="_blank"&amp;gt;&amp;lt;strong&amp;gt;{{attachment.file_name}}&amp;lt;/strong&amp;gt;&amp;lt;/a&amp;gt; {{attachment.size}}&amp;lt;/li&amp;gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;lt;/div&amp;gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;lt;/div&amp;gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;lt;/ul&amp;gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;lt;/div&amp;gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &lt;/P&gt;&lt;BR /&gt;&lt;P&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &lt;/P&gt;&lt;BR /&gt;&lt;P&gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;lt;div ng-if="data.items.length &amp;gt; 0"&amp;gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;lt;h3&amp;gt;&amp;lt;u&amp;gt;${Items in this Request}&amp;lt;/u&amp;gt;&amp;lt;/h3&amp;gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;lt;div ng-repeat="item in data.items"&amp;gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;lt;h4&amp;gt;&amp;lt;a ng-href="?id=ticket&amp;amp;table=sc_req_item&amp;amp;sys_id={{::item.sys_id}}&amp;amp;view=sp"&amp;gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; {{::item.short_description}}&lt;/P&gt;&lt;BR /&gt;&lt;P&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;lt;/a&amp;gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;lt;/h4&amp;gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;lt;div ng-if="item.attachments.length &amp;gt; 0"&amp;gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;lt;label&amp;gt;${Attachments}:&amp;lt;/label&amp;gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;lt;ul&amp;gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;lt;div ng-repeat="attachment in item.attachments"&amp;gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;lt;a target="_blank" href="/sys_attachment.do?view=true&amp;amp;sys_id={{attachment.sys_id}}"&amp;gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;lt;img ng-if="attachment.thumbnail_path" alt="" ng-src="/{{attachment.path}}?t=medium" class="img-responsive"/&amp;gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;lt;/a&amp;gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;lt;div&amp;gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;lt;li&amp;gt;&amp;lt;a href="/sys_attachment.do?sys_id={{attachment.sys_id}}" target="_blank"&amp;gt;&amp;lt;strong&amp;gt;{{attachment.file_name}}&amp;lt;/strong&amp;gt;&amp;lt;/a&amp;gt; {{attachment.size}}&amp;lt;/li&amp;gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;lt;/div&amp;gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;lt;/div&amp;gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;lt;/ul&amp;gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;lt;/div&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &lt;/P&gt;&lt;BR /&gt;&lt;P&gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;lt;/div&amp;gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;lt;/div&amp;gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt; &amp;nbsp; &amp;nbsp; &lt;/P&gt;&lt;BR /&gt;&lt;P&gt; &amp;nbsp; &amp;lt;/div&amp;gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;&amp;lt;/div&amp;gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt; &amp;nbsp; &amp;lt;sp-widget widget="data.ticketConversation" /&amp;gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;&amp;lt;/div&amp;gt;&lt;/P&gt;&lt;BR /&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;Server Script:&lt;/P&gt;&lt;BR /&gt;&lt;PRE __default_attr="javascript" __jive_macro_name="code" class="jive_macro_code _jivemacro_uid_15175266419605971 jive_text_macro" data-renderedposition="916_8_1175_976" jivemacro_uid="_15175266419605971"&gt;&lt;P&gt;// g_approval_form_request is for approval summarizer ACLs&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;// that let user read a record they need to approve. This global&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;// variable is then deleted at the bottom of the script&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;g_approval_form_request = true;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;var gr = $sp.getRecord();&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;if (gr == null || !gr.isValid()) {&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;data.isValid = false;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;//return;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;}&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;if (gr.getValue("approver") != gs.getUserID())&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;data.approver = gr.approver.getDisplayValue();&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;data.isValid = true;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;var task = getRecordBeingApproved(gr);&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;var t = {};&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;t = $sp.getFieldsObject(task, 'number,short_description,opened_by,requested_by,start_date,end_date,price,recurring_price,recurring_frequency,requested_for,sys_class_name,request,quantity,cat_item,special_instructions,sys_id,request');&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;t.table = task.getLabel();&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;........&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;//Get attachments for current record being approved&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;t.attachments = getAttachments(t.sys_class_name.value, t.sys_id.value);&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;var items = [];&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;var idx = 0;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;var itemsGR = new GlideRecord("sc_req_item");&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;itemsGR.addQuery("request", task.sys_id);&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;itemsGR.query();&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;while (itemsGR.next()) {&lt;/P&gt;&lt;BR /&gt;&lt;P&gt; &amp;nbsp; var item = {};&lt;/P&gt;&lt;BR /&gt;&lt;P&gt; &amp;nbsp; //Get attachments for requested items within parent request&lt;/P&gt;&lt;BR /&gt;&lt;P&gt; &amp;nbsp; item.attachments = getAttachments("sc_req_item", itemsGR.getValue("sys_id"));&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;..............&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;function getAttachments(tablename, sysid) {&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;var attachments = [];&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;var stream = $sp.getStream(tablename, sysid);&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;for(var i = 0; i &amp;lt; stream.entries.length; i++){&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;var curEntry = stream.entries[i];&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;if(curEntry.element == 'attachment'){&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;attachments.push(curEntry.attachment);&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;}&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;}&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;return attachments;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;}&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;..........&lt;/P&gt;&lt;BR /&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper" image-alt="sample.jpg"&gt;&lt;img src="https://www.servicenow.com/community/image/serverpage/image-id/68473i4A29EB2D899126C2/image-size/large?v=v2&amp;amp;px=999" role="button" title="sample.jpg" alt="sample.jpg" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;BR /&gt;</description>
    <pubDate>Thu, 01 Feb 2018 23:13:58 GMT</pubDate>
    <dc:creator>jamesmcwhinney</dc:creator>
    <dc:date>2018-02-01T23:13:58Z</dc:date>
    <item>
      <title>Service Portal Approver can see attachments</title>
      <link>https://www.servicenow.com/community/developer-forum/service-portal-approver-can-see-attachments/m-p/2141683#M798609</link>
      <description>&lt;P&gt;We have several requests where users must attach an excel or word document before submitting the item. &amp;nbsp; I tied to add the ticket attachment widget to the Approval form but it does not show any attachments. &amp;nbsp; I'm guessing this had to do with the approval form being on the sys_approval table and the attachment is on the sc_req_item table. &amp;nbsp; What code would need to be updated to if I were to clone the attachment widget to pull the attachment associated with the approval for from the sys_approval table?&lt;/P&gt;</description>
      <pubDate>Wed, 23 Aug 2017 13:40:54 GMT</pubDate>
      <guid>https://www.servicenow.com/community/developer-forum/service-portal-approver-can-see-attachments/m-p/2141683#M798609</guid>
      <dc:creator>brianlan25</dc:creator>
      <dc:date>2017-08-23T13:40:54Z</dc:date>
    </item>
    <item>
      <title>Re: Service Portal Approver can see attachments</title>
      <link>https://www.servicenow.com/community/developer-forum/service-portal-approver-can-see-attachments/m-p/2141684#M798610</link>
      <description>&lt;P&gt;Brian,&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;You can check this : &lt;A href="http://wiki.servicenow.com/index.php?title=Copy_Attachments_from_Record_to_Record#gsc.tab=0" title="http://wiki.servicenow.com/index.php?title=Copy_Attachments_from_Record_to_Record#gsc.tab=0"&gt;http://wiki.servicenow.com/index.php?title=Copy_Attachments_from_Record_to_Record#gsc.tab=0&lt;/A&gt;&lt;/P&gt;&lt;BR /&gt;</description>
      <pubDate>Wed, 23 Aug 2017 13:50:31 GMT</pubDate>
      <guid>https://www.servicenow.com/community/developer-forum/service-portal-approver-can-see-attachments/m-p/2141684#M798610</guid>
      <dc:creator>manikorada</dc:creator>
      <dc:date>2017-08-23T13:50:31Z</dc:date>
    </item>
    <item>
      <title>Re: Service Portal Approver can see attachments</title>
      <link>https://www.servicenow.com/community/developer-forum/service-portal-approver-can-see-attachments/m-p/2141685#M798611</link>
      <description>&lt;P&gt;So you want me to copy the attachment from the sc_req_item table to the sys_approval table for the specific request?&lt;/P&gt;&lt;BR /&gt;</description>
      <pubDate>Wed, 23 Aug 2017 14:02:29 GMT</pubDate>
      <guid>https://www.servicenow.com/community/developer-forum/service-portal-approver-can-see-attachments/m-p/2141685#M798611</guid>
      <dc:creator>brianlan25</dc:creator>
      <dc:date>2017-08-23T14:02:29Z</dc:date>
    </item>
    <item>
      <title>Re: Service Portal Approver can see attachments</title>
      <link>https://www.servicenow.com/community/developer-forum/service-portal-approver-can-see-attachments/m-p/2141686#M798612</link>
      <description>&lt;P&gt;I am doing the same thing for all sc_tasks to inherit from their parent RITM. I am sure you can create a clone of the attachment and assign it to the Approval record but if possible it seems like the best option would to add these to a defined related list. &lt;/P&gt;&lt;BR /&gt;&lt;P&gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;&lt;A href="https://www.servicenowguru.com/system-definition/relationships/defined-related-lists/" title="https://www.servicenowguru.com/system-definition/relationships/defined-related-lists/"&gt;https://www.servicenowguru.com/system-definition/relationships/defined-related-lists/&lt;/A&gt; &lt;/P&gt;&lt;BR /&gt;</description>
      <pubDate>Wed, 23 Aug 2017 14:22:22 GMT</pubDate>
      <guid>https://www.servicenow.com/community/developer-forum/service-portal-approver-can-see-attachments/m-p/2141686#M798612</guid>
      <dc:creator>johansec</dc:creator>
      <dc:date>2017-08-23T14:22:22Z</dc:date>
    </item>
    <item>
      <title>Re: Service Portal Approver can see attachments</title>
      <link>https://www.servicenow.com/community/developer-forum/service-portal-approver-can-see-attachments/m-p/2141687#M798613</link>
      <description>&lt;P&gt;would this even work in the service portal. &amp;nbsp; it does not have related lists.&lt;/P&gt;&lt;BR /&gt;</description>
      <pubDate>Wed, 23 Aug 2017 14:32:01 GMT</pubDate>
      <guid>https://www.servicenow.com/community/developer-forum/service-portal-approver-can-see-attachments/m-p/2141687#M798613</guid>
      <dc:creator>brianlan25</dc:creator>
      <dc:date>2017-08-23T14:32:01Z</dc:date>
    </item>
    <item>
      <title>Re: Service Portal Approver can see attachments</title>
      <link>https://www.servicenow.com/community/developer-forum/service-portal-approver-can-see-attachments/m-p/2141688#M798614</link>
      <description>&lt;P&gt;Nope sorry. &lt;/P&gt;&lt;BR /&gt;</description>
      <pubDate>Wed, 23 Aug 2017 14:34:05 GMT</pubDate>
      <guid>https://www.servicenow.com/community/developer-forum/service-portal-approver-can-see-attachments/m-p/2141688#M798614</guid>
      <dc:creator>johansec</dc:creator>
      <dc:date>2017-08-23T14:34:05Z</dc:date>
    </item>
    <item>
      <title>Re: Service Portal Approver can see attachments</title>
      <link>https://www.servicenow.com/community/developer-forum/service-portal-approver-can-see-attachments/m-p/2141689#M798615</link>
      <description>&lt;P&gt;Can you send me a screenshot of the widget you are wanting to edit? &lt;/P&gt;&lt;BR /&gt;</description>
      <pubDate>Wed, 23 Aug 2017 14:36:28 GMT</pubDate>
      <guid>https://www.servicenow.com/community/developer-forum/service-portal-approver-can-see-attachments/m-p/2141689#M798615</guid>
      <dc:creator>johansec</dc:creator>
      <dc:date>2017-08-23T14:36:28Z</dc:date>
    </item>
    <item>
      <title>Re: Service Portal Approver can see attachments</title>
      <link>https://www.servicenow.com/community/developer-forum/service-portal-approver-can-see-attachments/m-p/2141690#M798616</link>
      <description>&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper" image-alt="find_real_file.png"&gt;&lt;img src="https://www.servicenow.com/community/image/serverpage/image-id/68477i9071C7C219DE3AAC/image-size/large?v=v2&amp;amp;px=999" role="button" title="find_real_file.png" alt="find_real_file.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;It does not have any options so I think it is pulling parameters from the URL. &amp;nbsp; This is the same widget that is on the ticket form page that comes OOB and if there is an attachment on the RITM or Incident it is displayed here. &amp;nbsp; However since I am on the approval form there is not attachment there because it is not looking at the sys_id of the correct table.&lt;/P&gt;&lt;BR /&gt;</description>
      <pubDate>Wed, 23 Aug 2017 14:42:17 GMT</pubDate>
      <guid>https://www.servicenow.com/community/developer-forum/service-portal-approver-can-see-attachments/m-p/2141690#M798616</guid>
      <dc:creator>brianlan25</dc:creator>
      <dc:date>2017-08-23T14:42:17Z</dc:date>
    </item>
    <item>
      <title>Re: Service Portal Approver can see attachments</title>
      <link>https://www.servicenow.com/community/developer-forum/service-portal-approver-can-see-attachments/m-p/2141691#M798617</link>
      <description>&lt;P&gt;Hello Mani,&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;So I created a business rule to copy the attachment to the approval record. &amp;nbsp; Do you know if there is a way in the Service Portal to make it so they cannot delete or edit the attachment?&lt;/P&gt;&lt;BR /&gt;</description>
      <pubDate>Tue, 19 Sep 2017 14:41:27 GMT</pubDate>
      <guid>https://www.servicenow.com/community/developer-forum/service-portal-approver-can-see-attachments/m-p/2141691#M798617</guid>
      <dc:creator>brianlan25</dc:creator>
      <dc:date>2017-09-19T14:41:27Z</dc:date>
    </item>
    <item>
      <title>Re: Service Portal Approver can see attachments</title>
      <link>https://www.servicenow.com/community/developer-forum/service-portal-approver-can-see-attachments/m-p/2141692#M798618</link>
      <description>&lt;P&gt;This doesn't seem like the best solution.&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;Is there no way to just show the RITM attachments on the approval page?&lt;/P&gt;&lt;BR /&gt;</description>
      <pubDate>Thu, 01 Feb 2018 18:27:55 GMT</pubDate>
      <guid>https://www.servicenow.com/community/developer-forum/service-portal-approver-can-see-attachments/m-p/2141692#M798618</guid>
      <dc:creator>jamesmcwhinney</dc:creator>
      <dc:date>2018-02-01T18:27:55Z</dc:date>
    </item>
    <item>
      <title>Re: Service Portal Approver can see attachments</title>
      <link>https://www.servicenow.com/community/developer-forum/service-portal-approver-can-see-attachments/m-p/2141693#M798619</link>
      <description>&lt;P&gt;For what its worth, its possible to update the approval record widget to display the attachments.&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;Widget HTML Template:&lt;/P&gt;&lt;BR /&gt;&lt;PRE __default_attr="java" __jive_macro_name="code" class="jive_macro_code _jivemacro_uid_15175269231479298 jive_text_macro" data-renderedposition="58_8_1175_816" jivemacro_uid="_15175269231479298"&gt;&lt;P&gt;&amp;lt;div ng-if="!data.isValid"&amp;gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;${Record not found}&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;&amp;lt;/div&amp;gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;&amp;lt;div ng-if="data.isValid"&amp;gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;&amp;lt;div class="panel panel-{{::options.color}} b"&amp;gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt; &amp;nbsp; &amp;lt;div class="panel-heading"&amp;gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;lt;h4 class="panel-title"&amp;gt;${Approval request for {{::task.table}} {{::task.number.display_value}}}&amp;lt;/h4&amp;gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt; &amp;nbsp; &amp;lt;/div&amp;gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt; &amp;nbsp; &amp;lt;div class="panel-body"&amp;gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;lt;div ng-if="task.attachments.length &amp;gt; 0"&amp;gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;lt;label&amp;gt;${Attachments}:&amp;lt;/label&amp;gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;lt;ul&amp;gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;lt;div ng-repeat="attachment in task.attachments"&amp;gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;lt;a target="_blank" href="/sys_attachment.do?view=true&amp;amp;sys_id={{attachment.sys_id}}"&amp;gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;lt;img ng-if="attachment.thumbnail_path" alt="" ng-src="/{{attachment.path}}?t=medium" class="img-responsive"/&amp;gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;lt;/a&amp;gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;lt;div&amp;gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;lt;li&amp;gt;&amp;lt;a href="/sys_attachment.do?sys_id={{attachment.sys_id}}" target="_blank"&amp;gt;&amp;lt;strong&amp;gt;{{attachment.file_name}}&amp;lt;/strong&amp;gt;&amp;lt;/a&amp;gt; {{attachment.size}}&amp;lt;/li&amp;gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;lt;/div&amp;gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;lt;/div&amp;gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;lt;/ul&amp;gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;lt;/div&amp;gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &lt;/P&gt;&lt;BR /&gt;&lt;P&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &lt;/P&gt;&lt;BR /&gt;&lt;P&gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;lt;div ng-if="data.items.length &amp;gt; 0"&amp;gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;lt;h3&amp;gt;&amp;lt;u&amp;gt;${Items in this Request}&amp;lt;/u&amp;gt;&amp;lt;/h3&amp;gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;lt;div ng-repeat="item in data.items"&amp;gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;lt;h4&amp;gt;&amp;lt;a ng-href="?id=ticket&amp;amp;table=sc_req_item&amp;amp;sys_id={{::item.sys_id}}&amp;amp;view=sp"&amp;gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; {{::item.short_description}}&lt;/P&gt;&lt;BR /&gt;&lt;P&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;lt;/a&amp;gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;lt;/h4&amp;gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;lt;div ng-if="item.attachments.length &amp;gt; 0"&amp;gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;lt;label&amp;gt;${Attachments}:&amp;lt;/label&amp;gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;lt;ul&amp;gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;lt;div ng-repeat="attachment in item.attachments"&amp;gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;lt;a target="_blank" href="/sys_attachment.do?view=true&amp;amp;sys_id={{attachment.sys_id}}"&amp;gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;lt;img ng-if="attachment.thumbnail_path" alt="" ng-src="/{{attachment.path}}?t=medium" class="img-responsive"/&amp;gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;lt;/a&amp;gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;lt;div&amp;gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;lt;li&amp;gt;&amp;lt;a href="/sys_attachment.do?sys_id={{attachment.sys_id}}" target="_blank"&amp;gt;&amp;lt;strong&amp;gt;{{attachment.file_name}}&amp;lt;/strong&amp;gt;&amp;lt;/a&amp;gt; {{attachment.size}}&amp;lt;/li&amp;gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;lt;/div&amp;gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;lt;/div&amp;gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;lt;/ul&amp;gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;lt;/div&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &lt;/P&gt;&lt;BR /&gt;&lt;P&gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;lt;/div&amp;gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;lt;/div&amp;gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt; &amp;nbsp; &amp;nbsp; &lt;/P&gt;&lt;BR /&gt;&lt;P&gt; &amp;nbsp; &amp;lt;/div&amp;gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;&amp;lt;/div&amp;gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt; &amp;nbsp; &amp;lt;sp-widget widget="data.ticketConversation" /&amp;gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;&amp;lt;/div&amp;gt;&lt;/P&gt;&lt;BR /&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;Server Script:&lt;/P&gt;&lt;BR /&gt;&lt;PRE __default_attr="javascript" __jive_macro_name="code" class="jive_macro_code _jivemacro_uid_15175266419605971 jive_text_macro" data-renderedposition="916_8_1175_976" jivemacro_uid="_15175266419605971"&gt;&lt;P&gt;// g_approval_form_request is for approval summarizer ACLs&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;// that let user read a record they need to approve. This global&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;// variable is then deleted at the bottom of the script&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;g_approval_form_request = true;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;var gr = $sp.getRecord();&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;if (gr == null || !gr.isValid()) {&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;data.isValid = false;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;//return;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;}&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;if (gr.getValue("approver") != gs.getUserID())&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;data.approver = gr.approver.getDisplayValue();&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;data.isValid = true;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;var task = getRecordBeingApproved(gr);&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;var t = {};&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;t = $sp.getFieldsObject(task, 'number,short_description,opened_by,requested_by,start_date,end_date,price,recurring_price,recurring_frequency,requested_for,sys_class_name,request,quantity,cat_item,special_instructions,sys_id,request');&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;t.table = task.getLabel();&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;........&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;//Get attachments for current record being approved&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;t.attachments = getAttachments(t.sys_class_name.value, t.sys_id.value);&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;var items = [];&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;var idx = 0;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;var itemsGR = new GlideRecord("sc_req_item");&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;itemsGR.addQuery("request", task.sys_id);&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;itemsGR.query();&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;while (itemsGR.next()) {&lt;/P&gt;&lt;BR /&gt;&lt;P&gt; &amp;nbsp; var item = {};&lt;/P&gt;&lt;BR /&gt;&lt;P&gt; &amp;nbsp; //Get attachments for requested items within parent request&lt;/P&gt;&lt;BR /&gt;&lt;P&gt; &amp;nbsp; item.attachments = getAttachments("sc_req_item", itemsGR.getValue("sys_id"));&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;..............&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;function getAttachments(tablename, sysid) {&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;var attachments = [];&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;var stream = $sp.getStream(tablename, sysid);&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;for(var i = 0; i &amp;lt; stream.entries.length; i++){&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;var curEntry = stream.entries[i];&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;if(curEntry.element == 'attachment'){&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;attachments.push(curEntry.attachment);&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;}&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;}&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;return attachments;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;}&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;..........&lt;/P&gt;&lt;BR /&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;BR /&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper" image-alt="sample.jpg"&gt;&lt;img src="https://www.servicenow.com/community/image/serverpage/image-id/68473i4A29EB2D899126C2/image-size/large?v=v2&amp;amp;px=999" role="button" title="sample.jpg" alt="sample.jpg" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;BR /&gt;</description>
      <pubDate>Thu, 01 Feb 2018 23:13:58 GMT</pubDate>
      <guid>https://www.servicenow.com/community/developer-forum/service-portal-approver-can-see-attachments/m-p/2141693#M798619</guid>
      <dc:creator>jamesmcwhinney</dc:creator>
      <dc:date>2018-02-01T23:13:58Z</dc:date>
    </item>
    <item>
      <title>Re: Service Portal Approver can see attachments</title>
      <link>https://www.servicenow.com/community/developer-forum/service-portal-approver-can-see-attachments/m-p/2141694#M798620</link>
      <description>&lt;P&gt;This is great and exactly what i was looking for, however it is very difficult to know where in the Server Script you are inserting or overwriting.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;The ....... is a bit vague.&lt;/P&gt;
&lt;P&gt;Any way to clearify?&lt;/P&gt;</description>
      <pubDate>Thu, 01 Mar 2018 21:24:48 GMT</pubDate>
      <guid>https://www.servicenow.com/community/developer-forum/service-portal-approver-can-see-attachments/m-p/2141694#M798620</guid>
      <dc:creator>kevinray</dc:creator>
      <dc:date>2018-03-01T21:24:48Z</dc:date>
    </item>
    <item>
      <title>Re: Service Portal Approver can see attachments</title>
      <link>https://www.servicenow.com/community/developer-forum/service-portal-approver-can-see-attachments/m-p/2141695#M798621</link>
      <description>&lt;P&gt;Hi &lt;SN-MENTION class="sn-mention" table="live_profile" sysid="1a129625dbd81fc09c9ffb651f9619ea"&gt;@manikorada&lt;/SN-MENTION&gt;&amp;nbsp;,&lt;/P&gt;
&lt;P&gt;Could you please update the link?&amp;nbsp; I have the same question and the link is no longer valid.&lt;/P&gt;</description>
      <pubDate>Thu, 08 Jul 2021 16:59:48 GMT</pubDate>
      <guid>https://www.servicenow.com/community/developer-forum/service-portal-approver-can-see-attachments/m-p/2141695#M798621</guid>
      <dc:creator>Community Alums</dc:creator>
      <dc:date>2021-07-08T16:59:48Z</dc:date>
    </item>
    <item>
      <title>Re: Service Portal Approver can see attachments</title>
      <link>https://www.servicenow.com/community/developer-forum/service-portal-approver-can-see-attachments/m-p/2141696#M798622</link>
      <description>&lt;P&gt;Its been awhile and I no longer work for the company I set this up at but I believe the wiki article was for &lt;A href="https://developer.servicenow.com/dev.do#!/reference/api/quebec/server/no-namespace/c_GlideSysAttachmentScopedAPI#r_SGSA-copy_S_S_S_S" target="_blank"&gt;GlideSysAttachment&lt;/A&gt;.&lt;/P&gt;</description>
      <pubDate>Fri, 09 Jul 2021 16:56:02 GMT</pubDate>
      <guid>https://www.servicenow.com/community/developer-forum/service-portal-approver-can-see-attachments/m-p/2141696#M798622</guid>
      <dc:creator>brianlan25</dc:creator>
      <dc:date>2021-07-09T16:56:02Z</dc:date>
    </item>
  </channel>
</rss>

