cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
SoB
Level: Powered On

Re: Leave Request App - Manager not able to view my Requests

image.png

 

@Pstork1  Correct email ID is displayed in Approver - Any other collection to look into ?

Also getting the emails.

Dual Super User
Dual Super User

Re: Leave Request App - Manager not able to view my Requests

Then you'll have to start digging into the logic of the screen that displays the requests. If its correct in the collection then it should show on the page.



-------------------------------------------------------------------------
If I have answered your question, please mark your post as Solved.
If you like my response, please give it a Thumbs Up.
Highlighted
hh01
Level: Powered On

Re: Leave Request App - Manager not able to view my Requests

Hi@SoB ,

Did you found a solution for this?

 

thank you

SoB
Level: Powered On

Re: Leave Request App - Manager not able to view my Requests

@hh01 

Hi, Yes i kinda worked out a solution.

Tried many things:

1. Made the LeaveCollection as a excel sheet table (dont forget to name the Table inside excel sheet as LeaveCollection) - But problem withthis is that it should be in a common repository with all the users have read/WRITE access.

2. So, Made a Sharepoint list instead of excel table with all the colounm names required in the LeaveCollection and connect to powerapp as new connection (this will overwrite your existing LeaveCollection collection in powerapp)

 

Changes in the code:

1. Commented this section in OnAppStart

/*ClearCollect(LeaveCollection,
{Title: "Vacation", Detail: "Example vacation request", StartDate: Today(), EndDate: DateAdd(Today(), 6, Days), LeaveType: "Vacation", Requester: _myProfile.UserPrincipalName, Approver: _selectedApprover.userPrincipalName,
Status: "Pending", LeaveID: _myProfile.UserPrincipalName&Text(Now(), "[$-en-US]mm-dd-yyyy-hh-mm-ss-fff")});
*/

 

2. (JUST a test - delete this once confirmed) Copy GalleryRequest in the Home page itself and in its ITEM property write -  LeaveCollection

This will show you all the leaves present in the table- You should have some records in the table for that.

Check this from your login and then from your manager's Login if its visible.

 

3. Create another copy of GalleryRequest and write this code in it's Item property- Just to test

If(_managerView,

If( _requestTypeFilter="All",
LeaveCollection,
Filter(LeaveCollection, Status= _requestTypeFilter))
,

If( _requestTypeFilter="All",
Filter(LeaveCollection,Requester=_myProfile.UserPrincipalName),
Filter(LeaveCollection,Status= _requestTypeFilter && Requester=_myProfile.UserPrincipalName)
)
)
Test this from your Manager's Login

 

3. Importantly, Check on Confirmation Page's OnVisible property for Approver:

 

4. Check the sharepoint list or excel table or LeaveCollection within Powerapp (whichever you are using) and confirm that all the columns are poplulated expecially Approver

 

ALSO, you can replace

_selectedApprover.UserPrincipalName whereever manager has to be used after you have declared Manger on the Login screen

 

These are few debugging steps. Let me know

Dual Super User
Dual Super User

Re: Leave Request App - Manager not able to view my Requests

You could do this for a group of people using Excel as long as you store the Excel file in OneDrive and share it with the other users.  I think SharePoint is the better solution, but Excel would work as long as you share the file.



-------------------------------------------------------------------------
If I have answered your question, please mark your post as Solved.
If you like my response, please give it a Thumbs Up.
SoB
Level: Powered On

Re: Leave Request App - Manager not able to view my Requests

Yes, its true but we need to 'Share' the excel to users which exposes the excel explicitly and they can 'edit' manually - Since its Leave application 😉

we can make Sharepoint list as Not visible unless someone goes to Site Contents in SHarepoint


@Pstork1 wrote:

You could do this for a group of people using Excel as long as you store the Excel file in OneDrive and share it with the other users.  I think SharePoint is the better solution, but Excel would work as long as you share the file.


 

Dual Super User
Dual Super User

Re: Leave Request App - Manager not able to view my Requests

True, but hiding the list from display doesn't really keep anyone from editing it manually as well.  Security by obscurity is never very secure.  Much better to make it a policy to only edit the backend data through the app and then enforce it by auditing changes.  Telling people not to do something with an explanation of why is usually better than depending on ignorance.

 

As I said, I would use SharePoint because its a more robust data source.  But your comment was that it couldn't be shared if Excel was used.  I just wanted to correct that misconception.



-------------------------------------------------------------------------
If I have answered your question, please mark your post as Solved.
If you like my response, please give it a Thumbs Up.
Ioan1
Level: Powered On

Re: Leave Request App - Manager not able to view my Requests

I have the same problem, did you found any solution ?

 

Thank you,

Helpful resources

Announcements
thirdimage

Power Platform 24

Check it out!

thirdimage

New Badges

Check it out!

thirdimage

Power Apps Community User Group Member Badge

Fill out a quick form to claim your user group badge now!

sixthImage

Power Platform World Tour

Find out where you can attend!

Power Platform 2019 release wave 2 plan

Power Platform 2019 release wave 2 plan

Features releasing from October 2019 through March 2020

Top Solution Authors
Top Kudoed Authors
Users online (5,047)