Boolean canEditAllFields = (Boolean) configuration.get(BaseSecurityModule.CONFIG_USERMANAGER_CAN_EDIT_ALL_PROFILE_FIELDS);
if (ManagerFactory.getManager().isIdentityPermittedOnResourceable(identity, Constants.PERMISSION_HASROLE, Constants.ORESOURCE_ADMIN)) {
canEditAllFields = Boolean.TRUE;
}
userProfileCtr = new ProfileAndHomePageEditController(ureq, getWindowControl(), identity, canEditAllFields.booleanValue());
listenTo(userProfileCtr);
userTabP.addTab(translate(NLS_EDIT_UPROFILE), userProfileCtr.getInitialComponent());
prefsCtr = new ChangePrefsController(ureq, getWindowControl(), identity);
userTabP.addTab(translate(NLS_EDIT_UPREFS), prefsCtr.getInitialComponent());