Approval Comments Available In Workflows

A new workflow custom function called P2K_CF_GET_DAPR_COMMENT was created for use in the workflow products such as WF_AAL, WF_SPA, etc. to look for any approval records that are tied to the subject record being changed and return the comment column.

Currently of the 23 approval areas only 12 have workflow products available. See chart below.
Approval Areas and Workflow Product Cross Reference

ValueDisplayedWF ProductWF Product Description
01Disabled
02Pay Trans BatchesWF_PBTWorkflow – Batches
03Pay Header BatchesWF_PBTWorkflow – Batches
04Performance ReviewsWF_SRVWorkflow – Reviews
05Personnel ActionsWF_SPAWorkflow – Personnel Actions
07Job RequisitionsWF_RPOWorkflow – Postings
08Applicant HiresWF_RAPWorkflow – Applications
09Development Programs
10Development Activity
11Courses
12Class Schedules
13Training Resources
14Benefit ElectionsWF_BELWorkflow – BE Elections
15Assessments
16Class RegistrationWF_CRSEWorkflow – Class Registrations
17Time SheetsWF_PTSWorkflow – Time Sheets
19Leave LinesWF_AALWorkflow – Leave Lines
20Clock Entries ((Authorize)WF_TCEWorkflow – Clock Entries
21Education
22References
23Work History
24Open Enrollment EEsWF_BOEEWorkflow – Open Enrollment EE
25Positions
26Time Sheet Entries (Authorize)



There could be multiple approval records out there for a subject record at any point in time, so records with the following approval statuses will be bypassed:

From there we will sort the records by the change date descending to ensure that the most recent change will be the one that triggered this.

Implementation#

1. To use this custom function an entry needs to be made to the X_UC_FUNCTIONS lexicon as below

2. When using this custom function the value needs to be returned to a character variable like:

3. A sample Workflow Action may look like this:

4. A sample Workflow Usercalc may look like this:

In the example above, there is a check to see if the PA status has changed before anything is done.

Then in this example, we are only dealing with Declined/Not Approved PA’s so we want to ensure that the status is for that.

The actual custom function is called and the value of the found comment field is returned into the variable dapr_comment created.

If the comment is left blank, an email is not sent. In this case, you may want to have one action line (email content) for when a comment is supplied and a different one for when a comment is not supplied.


Notes #

Click to create a new notes page