01-31-2022 07:27 AM - last edited 02-02-2022 05:46 AM
Create a SP list with the following name: Leave Request
Column Name |
Column Type |
Comments |
Title |
Single line of Text |
This will be the default column that gets created in a SharePoint list |
Detail |
Multiple Lines of Text |
|
From |
Date and Time |
|
To |
Date and Time |
|
Leave Type |
Choice |
Choice values: ⛱️ Vacation 🤒 Sick Leave 🎈 Floating Holiday ⚖️ Jury Duty 💔 Bereavement |
Status |
Choice |
Choice values: Declined Approved Pending Manager Approval Pending HR Approval |
Manager |
Person or Group |
|
HR |
Person or Group |
|
Approval Comments |
Multiple Lines of Text |
|
Approval Link |
Single Line of Text |
|
Import App zip file in Power Apps.
Imported zip file will contain both the App & the flow.
Edit the App.
On App OnStart function, Set the HR Admin details as follows: Set(HRManagerEmail, "place email of HR Admin here")
Remove the SharePoint data source from the App & add a new SharePoint data source connection with your newly created “Leave Request” list.
Go to flow.microsoft.com
Turn on the “Leave Request Approval Process flow”
Edit the flow and update the SiteURL action to point to your SharePoint site where the new “Leave Request” list has been created.
Thanks,
Reza Dorrani, MVP
YouTube
Twitter
watch?v=0U5jax-zMIc
Thank you for yours explain.
@RezaDorrani Thank you for this app. Please help as i'm almost there with this app in our organization.
I'm getting a error when Submitting from App - list records are written but Flow does not run. Error: WorkflowTriggerIsNotEnabled... I have manually turned on Flow but still receive error. When i manually run flow I get inputs....if I put in a known list record ID, the flow runs then fails on "the passed in field "approval link" could not be found.
Manually trigger flow:
Manually trigger flow
When app triggers flow:
Can you help? And thank you!
Hi there,
Do you know if there is a way that it will detect the direct supervisor in the org taxonomy and email that person based on the requestor?
Thank you!
CW
Hello to everyone.
Thank you Reza to share this template.
I am facing two issues regarding the PowerApp part.
First Issue : The App can´t retrieve the manager of the user
It says "UserManager" is unknown. So I guess that I need to see with the IT admin of my company (I don´t have the rights to access to the Active Advisory) how to link employees to their manager right ?
Or I guess I need to modify the way the code is writing to make it match with the current organization.
Second Issue : HR and Manager are not updated in my SharePoint List
I put my own mail adress as HRManagerEmail as suggested in the tutorial. But my "HR" field is still empty when I create a leave request.
I guess that when Submitting the form, it should update this field in SharePoint right?
My Sharepoint list :
Same issue for Managers : but maybe because of the first issue...
Can I find a way to ALWAYS fill HR field with the same e-mail adress ? (it will never change)
Last issue (But not that big) :
I dont´t know why when I submit the form, the title will go within "delete" column randomly.
I was not able to find the link between where each field of the form should populate which column.
Thank you for your precious help! I don´t usually code, so I hope that my questions won´t be too obvious.
Christophe from France
Great video but I have one issue. I modified the Flow and changed the HR and SharePoint site.
I created a new request that came to me as the manager and HR. The flow worked perfectly. The issue is that after Submitting the request. The request does not show up in my user account nor does it show up in the manager screen as if the request was never made. I know the flow worked as I got the notification in Teams about a pending request and SharePoint was updated accordingly?
Is there another change with in Power Apps for it to display there?