Auto-Approve a Flexi Task and update the Workflow Task

  • 24 October 2019
  • 4 replies
  • 3 views

Badge +11

 

Scenario


There is an approval process e.g. manager approves an amount up to £500.00
If the manager submits an request, it would then send the approval to him-self to approve the request but this is not ideal and not prefered by the management.

 

Also, when it gets auto-approved, the task gets updated and the workflow task to show a record.

 

Solution (not fully working)


To add a 'Set a Condition' function in the workflow to check the following:
If the requester is equal to the Manager ... as seen below.

 

5059i7B1DA60999B670D6.jpg

If the workflow runs without the two actions: Update Workflow Task and Complete workflow task, then all it does it updates the item list with the manager's name but there is no record in the workflow task to state it has been auto-approved etc.

 

Problems


I am not using 'Parallel' actions because ... I think it's not required.

Furthermore, when I try to update the 'Workflow Task' list via the 'Create Item' function, I do not get the field for 'Related Content' so that the reference number is updated - instead it shows Related Items. As well as, the link binded behind the 'Title' does not resolve as it does not exist.

 

5060iAB345F93BCF0C940.jpg

 

 

What I want to achieve?


I like to add the records in the workflow task list to show that the relevant task has been auto-approved by the manager, which partly works but not fully.  However, the Complete Workflow Task action seems to be able to do that work but it needs the Action ID, which I am not able to get from a Flexi Task (because it has the reminders and deligation in one unit).

 

Maybe adding a 'Set variable' may store the action ID ?
However the option I selected is Workflow Instance ID and doubt it is the same!

 

5063iD5735C18352706F3.jpg

 

Question


How to get the Action ID stored in a variable?

How do update the Workflow Task to have all the relevant information: Related Content and Outcome ??
5065i338A2D15D9D83B80.jpg

 

 

 


4 replies

Badge +12

@bimi82 .....why don't you use query user profile action and get the manager's name for created by field? This way if the requestor is the manager then it will go to his manager for approval and so on.

 

Also, try to use flexi task action if possible.

Badge +11

Hello,

 

I use a custom list where I pull the information from.

In this case, the manager can approve £500 and therefore does not need an approval because he is a manager himself :) and that is so defined, set as rule.

 

Furthermore, as you can see the FlexiTask does not run as it gets bypassed by the "condition". To do what you suggested, would require to implement the 'parallel action'.

Question is, how to directly update Workflow Task including the Outcome and Related Content fields?

 

 

 

Badge +12

@bimi82 .....If manager doesn't need to approve then why to assign task in the first place? Create task only if Requestor is not the Manager.

Badge +11

@kunalpatel 

 

You fail to understand the concept of "would like to have a record of the manager's auto approve".

 

Anyway, I simply added another Flexi Task to the other route and set Complete Task in the Escalation tab, which then enters a record in the workflow task.

 

5077i7EA90EB117E0C87D.jpg

 

Reply