
Hello Team,
I am stuck at creating a flow which needs to look at successors and dependency while executing the task. Any help with this is greatly appreciated.
I have a list of tasks as a SharePoint list. The PA flow should run in a way that it should look at a task, and check if the status is 'Awaiting', if yes, then it should look for any dependency, if none then it should sent the user an adaptive card with an option "Done". Once the user receive the card, and user presses the button the status of the card is changed to Done. The flow should look at the task and see if there is any successor. If yes, the flow should go to that task and execute it.
If there is a dependency then the flow should look at the dependency task and see if its in 'Done' Status. If Yes, then the flow should proceed with the current task. If No, then the flow should inform the dependent task owner that the current task is pending and need to be actioned.
Note:
| Task ID | Task Name | Dependency | Successor | Status |
| 1 | AAA | 2 | Awaiting | |
| 2 | BBB | 1 | 3 | Awaiting |
| 3 | DDD | 2 | 5 | Awaiting |
| 4 | EEE | 5 | Awaiting | |
| 5 | FFF | 4 | 6,7 | Awaiting |
| 6 | Awaiting | |||
| 7 | Awaiting |