I have 3 class of users superadmin, admin, Authenticated. How can I lock some textfield in a form from Authenticated class? Currently I am using following code but it locks textfield for all classes.
TBH, putting things like this clientside is not a good method to enforce access control. At least have a check in your model if the current user should be able to alter the accountID field by setting a custom validator in place. An even better solution were to facilitate scenarios to protect certain fields.