Anyone have any examples of how to create a CRUD page in Visualforce salesforce1?

I have doubts on how to create an optimized page for mobile devices using Visualforce. I utilize Rest Api? RemoteAction?

Thank you

1 Answer 1


CRUD/FLS is always enforced server side.

  1. Within Apex Code (custom controller or controller extension) you can explicitly call the isAccessible(), isDeletable(), methods. If you are only using standard controllers then this check is performed for you by the standard controller and you don't need to do anything.

  2. You can (in some cases) automatically force isAccessible/isUpdateable checks to occur by using outputField, inputField apex components within visualforce, or by using the visualforce renderif tag. e.g. renderif="{!ObjectType.Account.Accessible}". For more complex operations (e.g. knowing whether you can perform a SOQL query against certain fields in the WHERE clause), you need to do the check in the Apex class.

Therefore in a Salesforce1 app, you would still do the check in your apex class that handles your remoting call. The same principle applies for Lightning apps.

In other words, the only difference between using visualforce components and using a client side library to render your data is that in the former case you can make simple CRUD checks in the visualforce components (option 2) but in the latter case you cannot. You must use option 1 only. This is because CRUD is enforced server-side.

Your Answer

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

Not the answer you're looking for? Browse other questions tagged or ask your own question.