Created
July 3, 2014 15:27
-
-
Save zachelrath/7e956c5693528d3734b2 to your computer and use it in GitHub Desktop.
Skuid Page that shows Pending Approval Items for the User or for any Groups that the user is a part of, either directly or indirectly
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<skuidpage showsidebar="true" showheader="true" tabtooverride="User"> | |
<models> | |
<model id="UserGroups" limit="20" query="true" createrowifnonefound="false" sobject="Group"> | |
<fields> | |
<field id="Name"/> | |
<field id="DeveloperName"/> | |
<field id="Type"/> | |
</fields> | |
<conditions> | |
<condition type="join" value="" field="Id" operator="in" enclosevalueinquotes="true" joinobject="GroupMember" joinfield="GroupId" logic=""> | |
<conditions> | |
<condition type="userinfo" value="" field="UserOrGroupId" operator="=" enclosevalueinquotes="true" userinfotype="userid"/> | |
</conditions> | |
</condition> | |
</conditions> | |
</model> | |
<model id="UserRoleGroups" limit="20" query="true" createrowifnonefound="false" sobject="Group"> | |
<fields> | |
<field id="DeveloperName"/> | |
<field id="Type"/> | |
<field id="Name"/> | |
</fields> | |
<conditions> | |
<condition type="userinfo" value="" field="RelatedId" operator="=" enclosevalueinquotes="true" userinfotype="userroleid"/> | |
</conditions> | |
</model> | |
<model id="GroupsContainingTheUsersGroups" limit="20" query="true" createrowifnonefound="false" sobject="Group"> | |
<fields> | |
<field id="Id"/> | |
<field id="Name"/> | |
<field id="DeveloperName"/> | |
<field id="Type"/> | |
</fields> | |
<conditions> | |
<condition type="join" value="" field="Id" operator="in" enclosevalueinquotes="true" joinobject="GroupMember" joinfield="GroupId" logic=""> | |
<conditions> | |
<condition type="modelmerge" value="" field="UserOrGroupId" operator="in" model="UserGroups" enclosevalueinquotes="true" mergefield="Id" novaluebehavior="noquery"/> | |
</conditions> | |
</condition> | |
</conditions> | |
</model> | |
<model id="GroupsContainingTheUserRoleGroups" limit="20" query="true" createrowifnonefound="false" sobject="Group"> | |
<fields> | |
<field id="Id"/> | |
<field id="Name"/> | |
<field id="DeveloperName"/> | |
<field id="Type"/> | |
</fields> | |
<conditions> | |
<condition type="join" value="" field="Id" operator="in" enclosevalueinquotes="true" joinobject="GroupMember" joinfield="GroupId" logic=""> | |
<conditions> | |
<condition type="modelmerge" value="" field="UserOrGroupId" operator="in" model="UserRoleGroups" enclosevalueinquotes="true" mergefield="Id" novaluebehavior="noquery"/> | |
</conditions> | |
</condition> | |
</conditions> | |
</model> | |
<model id="PendingApprovalItems" limit="20" query="true" createrowifnonefound="false" sobject="ProcessInstanceStep"> | |
<fields> | |
<field id="ActorId"/> | |
<field id="Actor.Name"/> | |
<field id="Comments"/> | |
<field id="ProcessInstanceId"/> | |
<field id="StepStatus"/> | |
<field id="OriginalActorId"/> | |
<field id="OriginalActor.Name"/> | |
<field id="ProcessInstance.TargetObjectId"/> | |
<field id="ProcessInstance.TargetObject.Name"/> | |
</fields> | |
<conditions logic="1 AND (2 OR 3 OR 4 OR 5 OR 6)"> | |
<condition type="fieldvalue" value="Pending" enclosevalueinquotes="true" field="ProcessInstance.Status"/> | |
<condition type="userinfo" value="" field="ActorId" operator="=" enclosevalueinquotes="true" userinfotype="userid"/> | |
<condition type="modelmerge" value="" field="ActorId" operator="in" model="UserGroups" enclosevalueinquotes="true" mergefield="Id" novaluebehavior="deactivate"/> | |
<condition type="modelmerge" value="" field="ActorId" operator="in" model="UserRoleGroups" enclosevalueinquotes="true" mergefield="Id" novaluebehavior="deactivate"/> | |
<condition type="modelmerge" value="" field="ActorId" operator="in" model="GroupsContainingTheUsersGroups" enclosevalueinquotes="true" mergefield="Id" novaluebehavior="deactivate"/> | |
<condition type="modelmerge" value="" field="ActorId" operator="in" model="GroupsContainingTheUserRoleGroups" enclosevalueinquotes="true" mergefield="Id" novaluebehavior="deactivate"/> | |
</conditions> | |
</model> | |
</models> | |
<components> | |
<tabset rememberlastusertab="true" defertabrendering="true"> | |
<tabs> | |
<tab name="Pending Approval Items" loadlazypanels="true"> | |
<components> | |
<skootable showconditions="true" showsavecancel="false" searchmethod="server" searchbox="true" showexportbuttons="false" pagesize="10" createrecords="false" model="PendingApprovalItems" buttonposition="" mode="readonly"> | |
<fields> | |
<field id="ActorId"> | |
<label>Actor</label> | |
</field> | |
<field id="StepStatus"/> | |
<field id="ProcessInstance.TargetObjectId"> | |
<label>Target Object</label> | |
</field> | |
<field id="OriginalActorId"> | |
<label>Original Actor</label> | |
</field> | |
<field id="Comments"/> | |
</fields> | |
<rowactions/> | |
<massactions usefirstitemasdefault="true"/> | |
<views> | |
<view type="standard"/> | |
</views> | |
</skootable> | |
</components> | |
</tab> | |
<tab name="User Groups"> | |
<components> | |
<skootable showconditions="true" showsavecancel="true" searchmethod="server" searchbox="true" showexportbuttons="false" pagesize="10" createrecords="true" model="UserGroups" buttonposition="" mode="read"> | |
<fields> | |
<field id="Name"/> | |
<field id="DeveloperName"/> | |
<field id="Type"/> | |
</fields> | |
<rowactions> | |
<action type="edit"/> | |
<action type="delete"/> | |
</rowactions> | |
<massactions usefirstitemasdefault="true"> | |
<action type="massupdate"/> | |
<action type="massdelete"/> | |
</massactions> | |
<views> | |
<view type="standard"/> | |
</views> | |
</skootable> | |
</components> | |
</tab> | |
<tab name="Groups containing the Users' Groups" loadlazypanels="true"> | |
<components> | |
<skootable showconditions="true" showsavecancel="true" searchmethod="server" searchbox="true" showexportbuttons="false" pagesize="10" createrecords="true" buttonposition="" mode="read" model="GroupsContainingTheUsersGroups"> | |
<fields> | |
<field id="Name"/> | |
<field id="DeveloperName"/> | |
<field id="Type"/> | |
</fields> | |
<rowactions> | |
<action type="edit"/> | |
<action type="delete"/> | |
</rowactions> | |
<massactions usefirstitemasdefault="true"> | |
<action type="massupdate"/> | |
<action type="massdelete"/> | |
</massactions> | |
<views> | |
<view type="standard"/> | |
</views> | |
</skootable> | |
</components> | |
</tab> | |
<tab name="User Role Groups" loadlazypanels="true"> | |
<components> | |
<skootable showconditions="true" showsavecancel="true" searchmethod="server" searchbox="true" showexportbuttons="false" pagesize="10" createrecords="true" buttonposition="" mode="read" model="UserRoleGroups"> | |
<fields> | |
<field id="Name"/> | |
<field id="DeveloperName"/> | |
<field id="Type"/> | |
</fields> | |
<rowactions> | |
<action type="edit"/> | |
<action type="delete"/> | |
</rowactions> | |
<massactions usefirstitemasdefault="true"> | |
<action type="massupdate"/> | |
<action type="massdelete"/> | |
</massactions> | |
<views> | |
<view type="standard"/> | |
</views> | |
</skootable> | |
<basicfieldeditor showheader="true" showsavecancel="true" model="UserRoleGroups" buttonposition="" mode="read"> | |
<columns> | |
<column width="50%"> | |
<sections> | |
<section title="Section A"> | |
<fields> | |
<field id="DeveloperName"/> | |
<field id="Type"/> | |
</fields> | |
</section> | |
</sections> | |
</column> | |
<column width="50%"> | |
<sections> | |
<section title="Section B"> | |
<fields> | |
<field type="COMBO"> | |
<label>Template Field</label> | |
<template>{{{RelatedId}}}</template> | |
</field> | |
</fields> | |
</section> | |
</sections> | |
</column> | |
</columns> | |
</basicfieldeditor> | |
</components> | |
</tab> | |
<tab name="Groups containing the User's Role Groups" loadlazypanels="true"> | |
<components> | |
<skootable showconditions="true" showsavecancel="true" searchmethod="server" searchbox="true" showexportbuttons="false" pagesize="10" createrecords="true" model="GroupsContainingTheUserRoleGroups" buttonposition="" mode="read"> | |
<fields> | |
<field id="Name"/> | |
<field id="DeveloperName"/> | |
<field id="Type"/> | |
</fields> | |
<rowactions> | |
<action type="edit"/> | |
<action type="delete"/> | |
</rowactions> | |
<massactions usefirstitemasdefault="true"> | |
<action type="massupdate"/> | |
<action type="massdelete"/> | |
</massactions> | |
<views> | |
<view type="standard"/> | |
</views> | |
</skootable> | |
</components> | |
</tab> | |
</tabs> | |
</tabset> | |
</components> | |
<resources> | |
<labels/> | |
<css/> | |
<javascript/> | |
</resources> | |
</skuidpage> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Hi Zach,
Do you have examples of displaying Approval History on a skuid page? Same data that is displayed on a Standard Salesforce page. Thanks.