Hi @miguelits ,
Do you make this template app as your own app (click "Make my own app" button)?
For your first question, have you made this template app as your own app? Do you want to save your new Leave Request into the LeaveCollection?
On your side, you should make this template app as your own app firstly via clicking "Make my own app" button. Actually, when you submit a new leave request, the new submitted request would be saved into the LeaveCollection collection (same as BalanceCollection and HolidayCollection). The LeaveCollection collection (same as BalanceCollection and HolidayCollection) is initialized within the OnStart property of the App control as below:
If you want to save the new submitted leave request into your SP list, you must add same columns as that in the LeaveCollection within your SP list. The data structure should be as below:
then add your SP list as a data source within your app instead of LeaveCollection collection. If you want to save your new leave request into your SP list, please modify the formula within the OnVisible property of the ConfirmationScreen to following:
If(_submittingRequest,
Concurrent(
Set(_navMenuSelect, ""),
//if editing a request, revise the record that is being edited, otherwise create a new one
Patch("YourSPList", If(_editingRequest, LookUp("YourSPList", LeaveID = GalleryRequests.Selected.LeaveID), Defaults("YourSPList")), /* <-- Please replace LeaveCollection with your SP List data source here */
{
Title: TextInput1.Text,
Detail: TextInput1_1.Text,
StartDate: LeaveStartDatePicker.SelectedDate,
EndDate: LeaveEndDatePicker.SelectedDate,
LeaveType: _selectedLeaveType.type,
Approver: _selectedApprover.UserPrincipalName,
Status: "Pending",
Requester: _myProfile.UserPrincipalName,
LeaveID: If(_editingRequest, GalleryRequests.Selected.LeaveID, Text(Now(), DateTimeFormat.LongDateTime24) & _myProfile.UserPrincipalName)
}
),
//create email template data specific to the request
...
...
...
For your second question, do you want the request the user made to be approved by two managers? Based on the needs that, I think you need to custom your app.
I think you need to add another column (Approver2) within your SP list to store the second Approver email. Then when the second approver approve the request, the user would be notified.
Best regards,