Blog

Custom Record Sharing Component

Custom Record Sharing Component

Sharing:

Sharing enables record-level access control for all custom objects, as well as many standard objects (such as Account, Contact, Opportunity and Case).
Administrators first set an object’s organization-wide default sharing access level, and then grant additional access based on record ownership,
the role hierarchy, sharing rules, and manual sharing.Developers can then use Apex managed sharing to grant additional access programmatically with Apex.

Features of Sharing:

  • Most sharing for a record is maintained in a related sharing object, similar to an access control list (ACL) found in other platforms.
  • You can easily remove this access after it’s no longer needed.
  • When the button is available on the page layout, administrators see the button on all records.
  • Non-administrators see this button on records that only they own.

Advantages of Custom Sharing Component:

  1. The custom lightning component provides the existing functionality and also provides some additional functionality.
  2. Other than the record owner, anyone is able to provide access to the records.
  3. Visibility of the Sharing Button is not based on any criteria. We can also be shown based on Customer needs. (Eg: Show button based on a user profile).
  4. This component also works as a stand-alone and able to work on the needs of the customer.
  5. Functionality to remove and add sharing records to users and roles.
  6. This can be used in any object and can be incorporated with any component.
  7. The standard sharing button can only be viewed by the Administrator but a custom component can be shown based on Customer requirements.
  8. User can able to view existing sharing permission of the record and able to add new Sharing permission to the record.

Images shows Existing Permission on record:

Custom Record Sharing Component
 
Custom Record Sharing Component

Note :

1.Disabled button in the image denotes the access level to the user on a record.

We are Innovalleyworks , We are a passionate team of developers, best thinkers and consultants who can solve anything and everything.
With our highly engaging team, you can easily bring the vision to all your business ventures come true.
We have team, put your problem, get your solution