
Announcements
hello
i want make flow to sub 2 numbers when employee leave request in Leave Request sharepoint list
i make static number 21 days in Request Sharepoint List
if Day less or = Days Start Approve
My Question
i want when Leave Request is Approved in sharepoint Leave Request Flow Sub 21 Days in Request sharepoint List and update item in Request Sharepoint List To the new value
if employee need 2 days sub 2 days from 21 days and update to 19 days
how i make this by Microsoft Flow
Hi @mohamed,
What is the type of the Day, Days, and Email column in your sharepoint list?
I have made a test on my side to create the lists as yours, and the Day, Days column is of type number, the Email column is of type Person or Group don't allow multiple selections.
And I couldn't create a "Name" column in the lists, so I create a "Name " column in the lists.
The Request list as screenshot below:
I have created a flow as below:
The expression in the Days column as below:
sub(items('Apply_to_each')?['Days'],triggerBody()?['Day'])
When an item is created in the Leave request column as below:
If the Request is approved, the flow would run successfully as below:
The Request list would be updated as below:
Best regards,
Community Support Team _ Alice Zhang
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.