User Rule Manager
Define the User Rule
Setup a rule based on a standard or custom field on the User object that will add or revoke the related setup entity record(s).
Relate Permission Sets, Public Groups, Queues and Permission Set Groups to a Rule
Able to include multiple Public Groups, Queues, Permission Sets, and Permission Set Groups to the user rule to grant these entities to the users your rule applies to. Quickly add / remove / review which users are part of these Salesforce Setup objects to help control the visibility and access to your organization's data.
Why control permission access from the User object?
Salesforce distinguishes every object as setup vs non setup objects. Setup objects include Users, Group Members, and Permission Set Assignments are not allowed to be in the same transaction with updates to Non Setup objects which are defined as any custom object and standard objects like Account and Contact.
What if I have a permission on a Contact or Account field that I want to use to control access?
Asycronchous Update to a field on the User record
Leveraging either a Future or Queueable interface you can (with a small delay ) have real time updates pushed from the source object to the user object which will then kick of the user rules that would
Implementing a Batch that executes on a scheduled basis to copy the info from the source object to the user. Ensure to not try to update the user and non setup object within the batch execute.
Formula Fields
Can create a new formula field that pulls in the reference of the field onto the user object. However with this option, the permissions will not be updated at near real time. When you change the value on the source field, it will not trigger an update on the user object which is where our logic runs off of.
What if I have a permission that is based off of many rules and conditions?
Leverage a Formula Field
You can create a text or checkbox formula field that does the complex conditions and does the output as your are expecting
Why User Rule Manager over the free apps on App Exchange
Visibility
Instantly view all active users affected by your rule and their association with relevant entities.
Update all users with one click
With a single click, adjust permissions and group associations effortlessly, eliminating the need to update each user record individually.
Permission Sets, Public Groups, Queues and Permission Set Groups
This solution provides the necessary visibility and automation to effectively manage all four components alongside rule management. Each of these elements is essential for proficiently handling record and object access within Salesforce.