Package de.xima.fc.gui.bean.user
Class ClientAuthorizationBean
- java.lang.Object
-
- de.xima.fc.gui.common.bean.ABooleanExpressionBean
-
- de.xima.fc.gui.bean.user.ClientAuthorizationBean
-
- All Implemented Interfaces:
Serializable
@Named @ViewScoped public class ClientAuthorizationBean extends ABooleanExpressionBean implements Serializable
Bean for handling ofIEntityClientAuthorization
in theauthorizations.xhtml
- Since:
- 8.0.0
- Author:
- XIMA Media GmbH
- See Also:
- Serialized Form
-
-
Field Summary
-
Fields inherited from class de.xima.fc.gui.common.bean.ABooleanExpressionBean
localeBean
-
-
Constructor Summary
Constructors Constructor Description ClientAuthorizationBean()
-
Method Summary
-
Methods inherited from class de.xima.fc.gui.common.bean.ABooleanExpressionBean
completeCustomExpression, findNewVariableName, getOrderedCombinationTypes, getOrderedMatchConditions, lintCustomExpression
-
-
-
-
Method Detail
-
getModel
public IEntityListModelSelectByView<IEntityClientAuthorization> getModel()
-
updateModel
public void updateModel()
-
canBeDeleted
public boolean canBeDeleted(IEntityClientAuthorization authorization)
-
canBeEdited
public boolean canBeEdited(IEntityClientAuthorization authorization)
-
canPermissionDetailsBeEdited
public boolean canPermissionDetailsBeEdited(IEntityClientAuthorization authorization)
-
canRoleBeEdited
public boolean canRoleBeEdited(Rolle role, IEntityClientAuthorization authorization)
-
isCanMarkedBeDeleted
public boolean isCanMarkedBeDeleted()
-
isShowSaveAndSendButton
public boolean isShowSaveAndSendButton()
-
isShowResendInvitationButton
public boolean isShowResendInvitationButton()
-
isShowRoleSelection
public boolean isShowRoleSelection()
-
isShowNoBackendAccessWarning
public boolean isShowNoBackendAccessWarning()
-
isShowBackendAccessWithoutFilterWarning
public boolean isShowBackendAccessWithoutFilterWarning()
-
isShowBackendAccessWithoutFilterWarning
public boolean isShowBackendAccessWithoutFilterWarning(IEntityClientAuthorization authorization)
-
isShowTestUserRedirectClientButton
public boolean isShowTestUserRedirectClientButton()
-
isShowTestUserInputClientButton
public boolean isShowTestUserInputClientButton()
-
getNoBackendAccessMessage
public String getNoBackendAccessMessage()
-
getDisplayEmailAddress
public String getDisplayEmailAddress(IEntityClientAuthorization authorization)
-
isChooseType
public boolean isChooseType()
-
setChooseType
public void setChooseType(boolean chooseType)
-
isShowResetLoginsBtn
public boolean isShowResetLoginsBtn()
-
isLoginLocked
public boolean isLoginLocked()
-
getAuthenticatorOptions
public List<javax.faces.model.SelectItem> getAuthenticatorOptions()
-
getLdapGroups
public List<GenericStringModel> getLdapGroups()
-
isUserDiscoveryEnabled
public boolean isUserDiscoveryEnabled()
-
resetLoginAttemptsForSelected
public void resetLoginAttemptsForSelected()
-
createNewAuthorization
public void createNewAuthorization()
Since the exact implementation of a newIEntityClientAuthorization
has to be chosen first, this function replaces the casual model.addNew() call from clientAuthorizationListToolbar.xhtml
-
addNewDirect
public void addNewDirect()
Method evoked after createNewAuthorization got called and a implementation is chosen, to add a newDirectClientAuthorization
to this model here and fulfilling its specific conditions i.e.UserProfile
+UserEmail
-
addNewIndirect
public void addNewIndirect()
Method evoked after createNewAuthorization got called and a implementation is chosen, to add a newIndirectClientAuthorization
to this model here
-
deleteAuthorization
public void deleteAuthorization(IEntityClientAuthorization authorization)
Method to call model.deleteEntity, since else there is a ELResolverException (maybe because of interface parameter)- Parameters:
authorization
- to be deleted
-
getInitials
public String getInitials(IEntityClientAuthorization authorization)
Method to extract first one or two letters of the display name, if its direct its fore- and surename letters are used- Parameters:
authorization
- the currently selectedIEntityClientAuthorization
- Returns:
- a String consisting of one to two letters or ? if display name is empty
-
getImageFile
public IFileEntity<?,?> getImageFile(IEntityClientAuthorization authorization)
-
getAvailableInboxNames
public List<String> getAvailableInboxNames(IEntityClientAuthorization authorization)
-
getClass
public Class<?> getClass(IEntityClientAuthorization authorization)
Method needed for clientAuthorizationList.xhtml groupBy- Parameters:
authorization
- currently handled entity inside p:dataTable- Returns:
- either
IndirectClientAuthorization
orDirectClientAuthorization
-
getUserIdentities
public List<UserIdentity> getUserIdentities(IEntityClientAuthorization authorization)
-
getRolesList
public List<Rolle> getRolesList()
Method to return list of allRolle
of a selectedIEntityClientAuthorization
- Returns:
- null if none found or client is system
-
getUserGroupsList
public List<BenutzerGruppe> getUserGroupsList()
Method to return list of allBenutzerGruppe
of the current client.- Returns:
- null if none found or client is system
-
getFilterType
public String getFilterType(IEntityClientAuthorization auth)
Finds the selected filter type of the given authorizer. Attempts to read the type from theIndirectClientAuthorization.getCustomPropertiesModel()
. Checks whether that type is a valid filter type, and, if not, returns one of the valid filter types, if any.- Parameters:
auth
- Authorizer to process.- Returns:
- The selected filter type, or any valid filter type if the selected filter type is not valid.
-
getFilterType
public String getFilterType()
Finds the selected filter type of the current authorizer. Attempts to read the type from theIndirectClientAuthorization.getCustomPropertiesModel()
. Checks whether that type is a valid filter type, and, if not, returns one of the valid filter types, if any.- Returns:
- The selected filter type, or any valid filter type if the selected filter type is not valid.
-
setFilterType
public void setFilterType(String type)
-
getFilterTypeOptions
public List<EAuthorizationFilterType> getFilterTypeOptions()
Finds all valid filter type options for the currently selected authorizer.- Returns:
- All valid filter types allowed for the given authorizer.
-
getFilterTypeOptions
public List<EAuthorizationFilterType> getFilterTypeOptions(IEntityClientAuthorization auth)
Finds all valid filter type options for the given authorizer.- Parameters:
auth
- Authorizer to process.- Returns:
- All valid filter types allowed for the given authorizer.
-
getClientDescriptor
public IClientDescriptor getClientDescriptor()
-
setClientDescriptor
public void setClientDescriptor(IClientDescriptor clientDescriptor)
-
save
public void save()
-
setMarkedAndSelected
public void setMarkedAndSelected(IEntityClientAuthorization entity)
Method to help with clicks on avatar + gravatar- Parameters:
entity
- the selected/marked entity
-
setAuthorization
public void setAuthorization(IEntityClientAuthorization authorization)
-
saveAndSendInvitation
public void saveAndSendInvitation(DirectClientAuthorization authorization)
-
sendInvitation
public void sendInvitation(DirectClientAuthorization authorization)
-
addCondition
public void addCondition()
Called when the user clicks on the add button to add a new condition.
-
removeCondition
public void removeCondition(int index)
Called when the user clicks on the remove button on a condition.- Parameters:
index
- Index of the condition to remove.
-
searchLdapGroups
public void searchLdapGroups()
-
findUsers
public List<UserEmailQueryResult> findUsers(String query)
-
getFoundUserProfile
public UserProfile getFoundUserProfile()
-
isHasFilterExtensions
public boolean isHasFilterExtensions()
-
findAttributes
public List<PluginProfileFilterAttribute> findAttributes(String query)
-
onAttributeSelect
public void onAttributeSelect(org.primefaces.event.SelectEvent<ProfileAttributeDescriptor> event)
-
findValueOptions
public List<IPluginProfileFilterValue> findValueOptions(String query)
-
getAttributeIcon
public IGuiIcon getAttributeIcon(ProfileAttributeDescriptor attribute)
-
getAttributeIconTitle
public String getAttributeIconTitle(ProfileAttributeDescriptor attribute)
-
getOrderedMatchConditions
public List<EMatchCondition> getOrderedMatchConditions(IProfileAttributeDescriptor attribute)
-
getRowKey
public String getRowKey(IEntityClientAuthorization auth)
-
getValueDisplayName
public String getValueDisplayName(IProfileAttributeDescriptor attribute, Object value)
-
getValueDescription
public String getValueDescription(IProfileAttributeDescriptor attribute, Object value)
-
getValueIcon
public IGuiIcon getValueIcon(ProfileAttributeDescriptor attribute, String value)
-
getValueIconTitle
public String getValueIconTitle(ProfileAttributeDescriptor attribute, String value)
-
getAttribute
public ProfileAttributeDescriptor getAttribute(Object obj)
-
getAllVariables
protected Set<String> getAllVariables()
- Specified by:
getAllVariables
in classABooleanExpressionBean
-
-