1

We have the below scenario for the partner users:

1) They should be able to view their own data. (they are not the owners of the record, but it is explicitly shared to them).

2) The should be able to view other partners data only if it has crossed certain status, but they shouldn't be able to report on it or view it on their list views..

We also do not have the global search enabled.

We had 2 approaches for the same:

Approach 1:

1) The object's OWD will be set to private

2) Create a custom search view (lightning component) where the users will be able to search without any restriction (their data or other partner's record which have crossed certain status.

3) When they click on certain record they will be routed to a custom detail page which will mimic the standard detail page, but if they have access to the record then they will taken to the standard details page.

4) This approach will result in discrepancy in the view because there will always be mis-match between the custom and the standard view.

Approach 2

1) The object's OWD will be set to private

2) Create a custom search view (lightning component) where the users will be able to search without any restriction (their data or other partner's record which have crossed certain status).

3) When they click on certain record the user will be given the access (incase they do not have access) to the record, by inserting the data into the appropriate sharing object, and then redirecting the user to the standard details page.

4) We will maintain another table where we capture the access given to a particular user.

5) After a pre-defined time, we will delete the record from the sharing table which will ultimately remove the access for a particular record for that user.

6) This approach will have a problem i.e., the user will suddenly lose access if he refreshes the detail page after the sharing has been deleted.

7) We might also need to show some kind of timer on the detail page which will indicate the user that he will lose access to the record after so many minutes.

It would really help to understand

1) What challenges we could face with the above approaches?

2) And also what are the other approaches that we can look at?

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.