You need to sign in to do that
Don't have an account?
Visualforce not displaying properly for any Profile but System Administrator
A consultant built some Visualforce pages for us and upon adding them to our Contact page layouts, I'm finding that they do not display properly for any Profile but the System Administrator profile. Even if I clone the system admin profile and assign it as a test to a different user, it continues to not display properly.
For the system admins, the Contact record displays normally, with the below VF page inline about halfway down the page when field
contact.Legacy_RecordType__c == 'Fellow/Alum'
For any other profile, upon loading a Contact record it:
1) Jumps down the page to this VF page
2) Renders the page regardless of the Legacy Record Type
3) Leaves open for editing the lookup field
!contact.EG_Finalist_Fellow_Org__c
Does anyone have any idea what might be going on? The consultant also installed the InlineVFExpander (https://appexchange.salesforce.com/listingDetail?listingId=a0N30000004cEEyEAM) which all profiles also have access to.
Things I've checked in my attempts to fix this:
-The fellowext class has profile access for all profiles
-The profiles all have access to all fields referenced here
<apex:page standardController="Contact" extensions="fellowext" sidebar="false" rendered="{!contact.Legacy_RecordType__c == 'Fellow/Alum'}" showHeader="false"> <script> function doRedirect() { window.parent.location.href = 'https://na14.salesforce.com/apex/FellowAlum_Edit?id={!contact.Id}'; } </script> <apex:form > <apex:pageBlock title="Fellow/Alum Details" id="thePageBlock" mode="detail" rendered="{!contact.Legacy_RecordType__c == 'Fellow/Alum'}"> <apex:pageMessages /> <apex:pageBlockButtons > <apex:commandButton value="Edit Fellow/Alum Fields" action="{!go}" onComplete="doRedirect()"/> </apex:pageBlockButtons> <apex:pageBlockSection title="FELLOW/ALUM" columns="2"> <apex:outputField value="{!contact.EG_Finalist_Fellow_Org__c}" /> <apex:outputField value="{!contact.Fellow_Type__c}"/> <apex:outputField value="{!contact.Fellowship_Year__c}"/> <apex:outputField value="{!contact.Finalist_Year__c}"/> <apex:outputField value="{!contact.EG_Funded_Org_Structure__c}"/> </apex:pageBlockSection> <apex:pageBlockSection title="Fellow/Alumni Specifics" columns="2"> <apex:outputField value="{!contact.Program_Area__c}"/> <apex:outputField value="{!contact.Facebook_Profile__c}"/> <apex:outputField value="{!contact.Population_Expertise__c}"/> <apex:outputField value="{!contact.Twitter_Handle__c}"/> <apex:outputField value="{!contact.Geographic_Expertise__c}"/> <apex:outputField value="{!contact.YouTube_Vimeo__c}"/> <apex:outputField value="{!contact.Geographic_Reach_EG_Fellowship__c}"/> <apex:outputField value="{!contact.Blog__c}"/> <apex:pageBlockSectionItem ></apex:pageBlockSectionItem> <apex:outputField value="{!contact.Flickr__c}"/> <apex:pageBlockSectionItem ></apex:pageBlockSectionItem> <apex:outputField value="{!contact.LinkedIn__c}"/> <apex:pageBlockSectionItem ></apex:pageBlockSectionItem> <apex:outputField value="{!contact.Tumblr__c}"/> <apex:pageBlockSectionItem ></apex:pageBlockSectionItem> <apex:outputField value="{!contact.Product_Link__c}"/> </apex:pageBlockSection> <apex:pageBlockSection title="Fellow/Alumni Specifics(Text)" columns="1"> <apex:outputField value="{!contact.Bold_Idea__c}"/> <apex:outputField value="{!contact.Professional_Expertise__c}"/> <apex:outputField value="{!contact.Website_Metadata__c}"/> <apex:outputField value="{!contact.Bio__c}"/> <apex:outputField value="{!contact.Moment_of_Obligation__c}"/> <apex:outputField value="{!contact.Product_Description__c}"/> <apex:outputField value="{!contact.EG_Funded_Org_Overview__c}"/> </apex:pageBlockSection> </apex:pageBlock> </apex:form> </apex:page>
Hi LizaMu,
You've mentioned that all users / profiles have access to this class. Have You checked also the VF page as well?
Best regards
Along with visualforce page, check for Field Level security of those fields.
Thanks,
Devendra
Yes, all profiles have access to that VF Page
So the JavaScript that seems to be running when a non-admin goes to the page is as follows (all populated fields values redacted). I can see where the VF is populating, but can anyone make sense of where this is going wrong? It was so long that I also had to redact what came over as the below value
and a lot of datepicker code.
What you have currently pasted above is the HTML source code returned with HTML post call.
So, We could help you further if you could provide some details about JavaScript error.
The Inline VisualForce Expander (https://appexchange.salesforce.com/listingDetail?listingId=a0N30000004cEEyEAM&tab=r&revId=a0S3000000DMcGxEAL) package contains it's own VF page that it uses to resize your custom VF pages (which you've already correctly set permissions for.
That VF page is called InlineVFExpander, and needs to be explicitly allowed for profiles that need to see resized pages (default is system admin, which is why everything looks normal for admin). This step does NOT appear to be included in the installation instructions: https://appexchange.salesforce.com/servlet/servlet.FileDownload?file=00P30000007KcasEAC
Your consultant dun goofed. :)