- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎05-08-2018 12:42 PM
Hi,
I'm trying to create a widget for my approvals in a simple list. The "My Approvals" widget has Approve/Reject buttons for each pending approval and it takes up a lot of real estate on the homepage(where I plan to position it). If anyone was able to create a simple list widget for approvals I would really like to how you solved this problem. I hoped I could find a widget developed but I could not find one in the community.
Thank you in advance.
Solved! Go to Solution.
- Labels:
-
Service Portal

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎05-11-2018 09:43 AM
Yes, Make a clone of Approval widget, Remove below code and add to homepage.
<div ng-if="options.portal && approval.state == 'requested'" class="col-xs-6">
<button name="reject" class="btn btn-default btn-block" ng-click="reject(approval.sys_id);">${Reject}</button>
</div>
<div ng-if="options.portal && approval.state == 'requested'" class="col-xs-6">
<button name="approve" class="btn btn-primary btn-block" ng-click="approve(approval.sys_id);">${Approve}</button>
</div>

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎05-08-2018 05:28 PM
Why you are not using OOTB widget called Approvals
If you want your own than copy and make changes to code.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎05-09-2018 05:29 PM
Hi Mike,
I didn't want the approve/reject buttons to show up on the right hand side of the approvals since this took up alot of space. Is there a way to get rid of the buttons and also still allow the approver to click on the item and take them to the approval?

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎05-11-2018 09:43 AM
Yes, Make a clone of Approval widget, Remove below code and add to homepage.
<div ng-if="options.portal && approval.state == 'requested'" class="col-xs-6">
<button name="reject" class="btn btn-default btn-block" ng-click="reject(approval.sys_id);">${Reject}</button>
</div>
<div ng-if="options.portal && approval.state == 'requested'" class="col-xs-6">
<button name="approve" class="btn btn-primary btn-block" ng-click="approve(approval.sys_id);">${Approve}</button>
</div>