cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
HadilH
Helper I
Helper I

Gallery Customization

Hi there!

 

I am developing a Event organizing application.

 

The gallery page -contains a gallery with all event requests- will be accessed by 3 types of users (Requester, Manager, Approver) see below:

HadilH_0-1659865081317.png

 

 

If the user is Requester, view the events created by him only.

If the user is Manager, view event requests created by all users.

If the user is Approver, view the events that his email was added for (Explanation in the below screenshot)

HadilH_1-1659865081321.png

 

The Manager should choose the Approver name from the highlighted dropdown.

 

Please not that I have a list with every user type, expect the Requester, will be taken from Created by Column.

 

Any advises on what are the functions to perform this?

 

Thanks a lot in advance.

1 ACCEPTED SOLUTION

Accepted Solutions
v-qiaqi-msft
Community Support
Community Support

Hi @HadilH,

Have you solved your problem?

Do you want to filter the Gallery based on current user?

 

Set the Items property of the Gallery as below:

If(!IsBlank(LookUp(UserTypeList,UserType=Manager).UserName=User().Email),List,If(!IsBlank(LookUp(UserTypeList,UserType=Approver).UserName=User().Email),Filter(List,UserColumn=User().Email)),Filter(List, CreatedBy.Email=User().Email))

Not sure how you configure the list that you populate the Gallery with, I just assume there is a UserColumn saving all the user with different user types.

Best Regards,
Qi

View solution in original post

2 REPLIES 2
Akash17
Responsive Resident
Responsive Resident

Hi

If you want to show the records in the gallery based on user type like requester ,manager etc

then on Gallery you can filter the data

Filter('Table', CreatedBy.Email=User().Email)

please refer

https://www.matthewdevaney.com/3-ways-to-filter-a-power-apps-gallery-by-the-current-user/#:~:text=Go....

v-qiaqi-msft
Community Support
Community Support

Hi @HadilH,

Have you solved your problem?

Do you want to filter the Gallery based on current user?

 

Set the Items property of the Gallery as below:

If(!IsBlank(LookUp(UserTypeList,UserType=Manager).UserName=User().Email),List,If(!IsBlank(LookUp(UserTypeList,UserType=Approver).UserName=User().Email),Filter(List,UserColumn=User().Email)),Filter(List, CreatedBy.Email=User().Email))

Not sure how you configure the list that you populate the Gallery with, I just assume there is a UserColumn saving all the user with different user types.

Best Regards,
Qi

Helpful resources

Announcements
October Events

Mark Your Calendars

So many events that are happening this month - don't miss out!

Ignite 2022

WHAT’S NEXT AT MICROSOFT IGNITE 2022

Explore the latest innovations, learn from product experts and partners, level up your skillset, and create connections from around the world.

Power Apps Africa Challenge 2022

Power Apps Africa Challenge

Your chance to join an engaging competition of Power Platform enthusiasts.

Top Solution Authors
Top Kudoed Authors
Users online (1,791)