You need to sign in to do that
Don't have an account?
ValueText SMS
with sharing not enforcing on FLS
My controler :
public with sharing class sharingtest1{
public string datax{get;set;}
public void runquery(){
contact c=[select id,name,rsplus__DateTime_Field__c from contact where id='sfid'];
datax=json.serialize(c);
system.debug(c+'KKKK');
}
}
My page:
<apex:page controller="sharingtest1">
<apex:form >
<apex:outputText value="{!datax}"></apex:outputText>
<apex:commandButton value="call" action="{!runquery}"/>
</apex:form>
</apex:page>
Rsult for button click "call":
Id:,Name:Lauren Boyle,rsplus__DateTime_Field__c:2016-05-08T05:26:00.000+0000
My FLS (notmal salesforce licenec profile , where view all and modefy all is false)
Can any one help me why with sharing keyword is not enforcing on SOQL, I can see "dattime field" data in json. I am need to do manual sharing checking my using describe class?
public with sharing class sharingtest1{
public string datax{get;set;}
public void runquery(){
contact c=[select id,name,rsplus__DateTime_Field__c from contact where id='sfid'];
datax=json.serialize(c);
system.debug(c+'KKKK');
}
}
My page:
<apex:page controller="sharingtest1">
<apex:form >
<apex:outputText value="{!datax}"></apex:outputText>
<apex:commandButton value="call" action="{!runquery}"/>
</apex:form>
</apex:page>
Rsult for button click "call":
Id:,Name:Lauren Boyle,rsplus__DateTime_Field__c:2016-05-08T05:26:00.000+0000
My FLS (notmal salesforce licenec profile , where view all and modefy all is false)
Can any one help me why with sharing keyword is not enforcing on SOQL, I can see "dattime field" data in json. I am need to do manual sharing checking my using describe class?
I tried this scenario in my personal DE account its working properly.Please cors-check your steps with the below steps.
Go to Setup--->Administer--->Manage Users--->Users--->System Administrator---->Field-Level Security--->Contact object.
Please check the below screenshot
Visualforce Page
Controller
In DE account ,we have 2 salesforce licenses.
Hope this helps you!
Regards,
Jyothsna