cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
AliciaDG
Helper III
Helper III

gallery selected text in text input data

Hi,

 

I hope i can explain this problem well. 

 

I am building an app where user's are inputting data which then get's pulled to a another page that only the manager can see. So each user can only see their data. all that is fine. 

where my problem is. i then want the manager to edit the notes they have created but save it seperately to be sent out as a final report. what i dont want is for the user's to see the edits and changes the manager has made. 

i have coded manager's report column to be what the user has entered. When i click the save button it saves the data in the column but it reverts back to the orignal text in the managers section.

 

AliciaDG_0-1616657135934.png

 

1 ACCEPTED SOLUTION

Accepted Solutions

Hi @AliciaDG ,

 

I think I may understood your scenario.

 

Please try set the Default of the Manager Report data card value to:

If(IsBlank(ThisItem.ManagerReport, ThisItem.UserReport, ThisItem.ManagerReport)

This means if manager hasn't filled manager report, it will display user report by default.

 

Hope it helps.

 

Best regards,

Community Support Team _ Jeffer Ni
If this post helps, then please consider Accept it as the solution to help the other members find it.

 

View solution in original post

3 REPLIES 3
v-jefferni
Community Support
Community Support

Hi @AliciaDG ,

 

Would you like to show manager report only to managers but hide it from users?

 

If so, firstly you could create a collection OnStart of the App which would include all manager accounts:

 

ForAll(Office365Users.SearchUserV2().value,Collect(colManager,Office365Users.ManagerV2(ThisRecord.Id).userPrincipalName));
Set(varUser, Office365Users.UserProfileV2(User().Email).userPrincipalName)

 

 

Then in View Form, set Visible of the Manager Report Data Card to:

 

If(varUser in colManager.Value,false,true)

 

This will hide the Manager Report Data Card if current user is not one of the managers in the collection.

 

Next step, set Default of the Manager Report Data Card to

ThisItem.ManagerReport

and Default of User Report Data Card to

ThisItem.UserReport

This means NOT to set manager's report column to be what the user has entered, but to display the actual value in the corresponding column.

 

In the end, make sure Update of the Manager Report Data Card of the Edit Form has been set to 

ManagerReportDataCardValue.Text

 

Hope this helps.

 

Best regards,

Community Support Team _ Jeffer Ni
If this post helps, then please consider Accept it as the solution to help the other members find it.

Hi

 

thanks for the response love the coding, however i dont think it will work in this scenario for me. BUT am going to keep it for future projects i do. 

i will try explain a bit more what our outcome would like to be. 

our users enter data a summary report in  a gallery. they can only see what they have input. 

i have created another page and gallery (pic in original question) that is the managers view. 
they can click on each line and see what the user has inputted. 

What i would like to do is for the manager to edit directly on that page (through a different text box which is linked to a different sharepoint column called (finalreport) BUT instead of them copying and pasting i want a copy of the user text to appear in the manager box which once it is edited feeds back to the (finalreport) but keeps the users details the same.

 

does that make sense?

Hi @AliciaDG ,

 

I think I may understood your scenario.

 

Please try set the Default of the Manager Report data card value to:

If(IsBlank(ThisItem.ManagerReport, ThisItem.UserReport, ThisItem.ManagerReport)

This means if manager hasn't filled manager report, it will display user report by default.

 

Hope it helps.

 

Best regards,

Community Support Team _ Jeffer Ni
If this post helps, then please consider Accept it as the solution to help the other members find it.

 

View solution in original post

Helpful resources

Announcements
PA User Group

Welcome to the User Group Public Preview

Check out new user group experience and if you are a leader please create your group

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

V3_PVA CAmpaign Carousel.png

Community Challenge - Giveaways!

Participate in the Power Virtual Agents Community Challenge

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.

Top Solution Authors
Top Kudoed Authors
Users online (2,342)