function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
nsbnsb 

Partner Role

Hi All,

 

I have an scenario where i want to restrict Account Partner Role for certain users. Can we do this? We are not allowed to have trigger on "Partner" object.

 

Any suggestion please. Quite urgent.

 

Thanks

nsb

lukaz1010lukaz1010
Hi I'd add custom checkbox field to the User object naming it for instance "AccountPartnerRoleViewer" then modify "privileged users" with setting this option set to. Consequently I'd modify related SOQL queries to join User DB object with filtering the ones that has User.AccountPartnerRoleViewer=True So if the user has a flag "AccountPartnerRoleViewer" set to True then the Partner Account Role will fetch the ones he is allowed to view.
lukaz1010lukaz1010
:) I am sorry I couldn't edit already posted Reply. So please take this one as my answer to your question. Hi, I'd add a custom checkbox field to the User object naming it for instance "AccountPartnerRoleViewer" then modify "privileged users" with setting this option set to TRUE. Consequently I'd modify related SOQL queries to join User DB object with filtering the ones only with User.AccountPartnerRoleViewer=True
nsbnsb

Hi,

 

Thanks for replying, however could you please how to modify user previledges? I mean, are you suggesting to have a trigger? However trigger here will not help as it is not allowed on partner object.

Could you please elaborate more?

 

Many thanks

 

lukaz1010lukaz1010
Please forget it... I have happend to found nicer way of 'Creating Custom List Views' and 'Account Teams' in the most convenient way available though. Please check further at: https://na1.salesforce.com/help/doc/en/accountteam_def.htm https://na1.salesforce.com/help/doc/en/customviews.htm
nsbnsb

Hi,

 

New View creation will not help in my case,

 

Following the solution that i have come accross..

 

Wrote a inline vf on Account where i override the save button (with me condition for specific users).

The solution works like a charm for Admin, however for other users it gives "Insufficint priviledges on Partner sobject"

 

Folling is my security setting

OWD:Public R/W

Account: R/W/C/D

Manage Partner=Checked

 

Added corresponding controller and pages to user profile...

 

Please let me know what am i missing???

its quite urgent...

 

Thanks

 

lukaz1010lukaz1010
Hi So you want to prevent certain users from saving Partner Account with hiding a Save button? This wasnt quite obvious according to your original question I am afraid. Never mind. I would use then 'Account Validation Rules'. Check this http://mysalesforcecode.blogspot.com/2008/12/how-to-create-validation-rule-in.html first and take a look into this one http://www.salesforce.com/community/assets/docs/salesforce_useful_validation_formulas.pdf Good luck nsb!