Skip to main content

Notifications

Announcements

No record found.

Customer experience | Sales, Customer Insights,...
Answered

View for specific Users

Posted on by 20

Hi,

I have a requirement like, show the custom views for specific roles in specific region. say. I have three regions US, UK, Aus. and each region have 1 Manager role.

Create 3 views for each region and show only to Manager of those regions like - All open Accounts for US, UK and Aus.

I can do everything by creating custom views and share with specific people, but that will create too many views and its straight forward and simple. Is there any other optimized way to achieve this.

  • WheelsShar Profile Picture
    WheelsShar 20 on at
    RE: View for specific Users

    Thanks for this.

  • Verified answer
    mobeenmohsin Profile Picture
    mobeenmohsin on at
    RE: View for specific Users

    Hi,

    We can write plugin for retrieveMultiple and modify the filter attributes for savedquery(view) in order to get the required results, this approach will avoid the need to create multiple views instead it will filter the view query at runtime according to user security role. Please find more information at following:

    https://docs.microsoft.com/en-us/powerapps/developer/data-platform/org-service/samples/modify-query-preoperation-stage

    https://docs.microsoft.com/en-us/powerapps/developer/data-platform/best-practices/business-logic/implement-all-types-of-queries-when-filtering-preoperation-retrievemultiple

    https://hachecrm2011.wordpress.com/2013/07/19/filtering-views-by-intercepting-retrieve-multiple-queries-with-a-plugin/

    Thanks.

    Mobeen 

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

December Spotlight Star - Muhammad Affan

Congratulations to a top community star!

Top 10 leaders for November!

Congratulations to our November super stars!

Tips for Writing Effective Suggested Answers

Best practices for providing successful forum answers ✍️

Leaderboard

#1
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 291,269 Super User 2024 Season 2

#2
Martin Dráb Profile Picture

Martin Dráb 230,198 Most Valuable Professional

#3
nmaenpaa Profile Picture

nmaenpaa 101,156

Leaderboard

Featured topics

Product updates

Dynamics 365 release plans