cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
asmedic85
Regular Visitor

Set the Person or Group field to mutiple SharePoint Groups

Hello,

 

I have SharePoint list that I customized in Power App. I have run in to a slight permissions issue. 

 

Product: A list where employees can submit a leave request or the request can be submitted on behalf of the employee.

 

Permission Goal: I do not want all employees to be able to see all SharePoint list items. Only the following people should be able to see what is on the SharePoint list.

  1. The Employee
  2. The Requestor
  3. All members of 3 specific SharePoint groups.

 

Plan: I will filter out all items unless the user is listed in one of the 3 following fields:

  1.      Column Type: Person or Group, allow single selection, editable, Column Name: Employee Name 
  2.      Column Type: Person or Group, allow single selection,  editable, Column Name: Requestor Name 
  3.      Column Type: Person or Group, allow multiple selections, not-editable and hidden, Column Name: Controllers

 

Considerations:

  1.  I have considered setting the SharePoint list advanced setting to read, create and edit items only created by user but that causes an issue since I need supervisors or be able to submit the request on behalf of the employee also. 
  2. I have considered using a Microsoft Flow that starts when a new item is created. It would stop sharing an item or file as shown by Vikram_Samal's post filting/restricting list items on the basis of user group in sharepoint online classic - Microsoft T... Not sure if that would accomplish the goal.

 

Question and Problem: Trying to set the value in the Controllers column to multiple SharePoint groups.  As stated the Controllers column is hidden on the SharePoint list and in the Power App but I want the value to be automatically set to 3 SharePoint Permissions groups (group names would be Leave Request Managers, Leave Request Admins, Leave Request Auditors) The SharePoint Groups use Web Enabled Security Group Emails.

 

How can I accomplish this?

 

 

 

5 REPLIES 5
BCLS776
Community Champion
Community Champion

Unfortunately, Sharepoint lists must be shared with anyone using your app, and there isn't column-level access restrictions. You can make it a bit difficult for people to see, but you won't keep them out of the data completely. If security is a big concern here, you should choose a different back end.

Thanks for the reply. Understanding I can't completely restrict things, is there a way to set the value of a person or group field to those three SharePoint groups either in Power App or using flow?

BCLS776
Community Champion
Community Champion

There are two primary ways to manage some roles with Sharepoint lists:

  1. Make another list with all your users and flags/descriptors of their roles. In the app, use their role to control functionality and filters.
  2. Use 365 Groups and the Office365Groups and Office365Users connectors to handle the same logic

I like method #2 because if a person is savvy enough to find the list used in method #1 then they are also capable of modifying the contents to their liking. Method #2 requires a level of admin access to alter the 365 Groups.

asmedic85
Regular Visitor

Ok let me ask a different question. 

 

How do set the value of a person or group field to a specific SharePoint group in Power App instead of a specific user?

BCLS776
Community Champion
Community Champion

I am unsure if you can do that. I know you can set a People and Groups column to a 365 Group or individual users, but those are different entities than a Sharepoint Group.

Helpful resources

Announcements
PA_User Group Leader_768x460.jpg

Manage your user group events

Check out the News & Announcements to learn more.

Power Query PA Forum 768x460.png

Check it out!

Did you know that you can visit the Power Query Forum in Power BI and now Power Apps

Carousel 2021 Release Wave 2 Plan 768x460.jpg

2021 Release Wave 2 Plan

Power Platform release plan for the 2021 release wave 2 describes all new features releasing from October 2021 through March 2022.

R2 (Green) 768 x 460px.png

Microsoft Dynamics 365 & Power Platform User Professionals

DynamicsCon is a FREE, 4 half-day virtual learning experience for 11,000+ Microsoft Business Application users and professionals.

Users online (1,216)