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
Lena ChristyLena Christy 

VF page in community

Hi everyone !
I want to create a customer community for the contacts for who I already enable for them “the customer user” and I give them “Customer Community” as User Licence and “Customer Community User” as Profile.
What I need is a vf page where each contact can see its own account and opportunities in a vf page in the community.
Something like that: (this one doesn't work!)
<apex:page standardController="Contact" recordSetVar="contacts"  sidebar="false">
    <apex:pageBlock >
          <apex:repeat value="{!contacts}" var="con">
<apex:pageBlockSection title="{!con.Name}"></apex:pageBlockSection>
<apex:relatedList list="Account" subject="{!con.Id}"/>
<apex:relatedList list="Opportunities" subject="{!con.Id}" />
</apex:repeat>      
     </apex:pageBlock>
</apex:page>
I read that we can not display Opportunities when we enable the “Community User” for contacts, what should I change?
If you can help me with this I would be grateful..
Thanks in advance.
 
AnuragGautamAnuragGautam
Hi Lena,

Please check Opportunity Object Permission for that profile. 
You should be able to only when that profile have read permission on opportunity object.

Please mark as a best answer if it resolve your problem.

Thanks,
Anurag
Lena ChristyLena Christy
Hi Anurag,
Thank you so much for your reply!
How can I check Permission for the profile ? Should I edit it for each contact manually, is there a method that the contact could have it automatically ?

Thanks.
AnuragGautamAnuragGautam
Nope, you don't have to edit each contact.

Please open contact then click on view comminity user and then click on user's profile now you are at profile page.

There you can edit object setting.
Lena ChristyLena Christy
Hi!
I did what you told me but  in Permission Set Overview> Object Settings, I don't find the 'Opportunity' Object !
That's the issue....
 
AnuragGautamAnuragGautam
You have to check profile not permission set.
Lena ChristyLena Christy
I check in Customer Community User profile and I don't find Opportunity object in it to edit it....
User-added image