Package org.openxava.actions
Class RemoveSelectedInElementCollectionAction
- java.lang.Object
-
- org.openxava.actions.BaseAction
-
- org.openxava.actions.ViewBaseAction
-
- org.openxava.actions.CollectionElementViewBaseAction
-
- org.openxava.actions.CollectionBaseAction
-
- org.openxava.actions.DeleteSelectedInCollectionBaseAction
-
- org.openxava.actions.RemoveSelectedInCollectionAction
-
- org.openxava.actions.RemoveSelectedInElementCollectionAction
-
- All Implemented Interfaces:
IAction
,IChangeModeAction
,IModuleContextAction
,IRequestAction
public class RemoveSelectedInElementCollectionAction extends RemoveSelectedInCollectionAction
Remove an element in an @ElementCollection. This action is not used by default, because OpenXava uses JavaScript to remove a row in an element collection directly in the browser. However, you can use @RemoveSelectedAction to call this action and it works. The goal of this action is to be refined, so the developer could add Java code to the row removal.- Since:
- 5.3.2
- Author:
- Javier Paniza
-
-
Field Summary
-
Fields inherited from interface org.openxava.actions.IChangeModeAction
DETAIL, LIST, PREVIOUS_MODE, SPLIT
-
-
Constructor Summary
Constructors Constructor Description RemoveSelectedInElementCollectionAction()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected void
addMessage()
protected void
commit()
Commit the current transaction.protected View
getCollectionElementView()
protected boolean
isEntityReferencesCollection()
protected void
removeElement(java.util.Map values)
Is called for each selected row with the values that includes the key values.-
Methods inherited from class org.openxava.actions.DeleteSelectedInCollectionBaseAction
execute
-
Methods inherited from class org.openxava.actions.CollectionBaseAction
getMapsSelectedValues, getMapValues, getObjects, getRow, getSelectedKeys, getSelectedObjects, setRow
-
Methods inherited from class org.openxava.actions.CollectionElementViewBaseAction
closeDialog, getMetaCollection, getParentView, getView, getViewObject, isCloseDialogDisallowed, isEntityReferencesCollection, mustRefreshCollection, setCloseDialogDisallowed, setViewObject, showDialog, validateMaximum, validateMinimum
-
Methods inherited from class org.openxava.actions.ViewBaseAction
changeThisPropertyByViewValue, getModelName, getPreviousView, getPreviousViews, resetDescriptionsCache, returnToPreviousView, setControllers, setPreviousViews, setView, showDialog, showNewView, showView, validateViewValues
-
Methods inherited from class org.openxava.actions.BaseAction
addActions, addError, addErrors, addInfo, addMessage, addMessages, addWarning, clearActions, executeAction, executeAfter, executeBefore, getContext, getEnvironment, getErrors, getLocale, getManager, getMessages, getNextMode, getQualifiedActionIfAvailable, getRequest, removeActions, returnToPreviousControllers, rollback, setContext, setDefaultControllers, setEnvironment, setErrors, setMessages, setNextMode, setRequest
-
-
-
-
Method Detail
-
commit
protected void commit()
Description copied from class:BaseAction
Commit the current transaction.- Overrides:
commit
in classBaseAction
-
removeElement
protected void removeElement(java.util.Map values) throws java.lang.Exception
Is called for each selected row with the values that includes the key values.- Overrides:
removeElement
in classRemoveSelectedInCollectionAction
- Throws:
java.lang.Exception
-
getCollectionElementView
protected View getCollectionElementView() throws XavaException
- Overrides:
getCollectionElementView
in classCollectionElementViewBaseAction
- Throws:
XavaException
-
isEntityReferencesCollection
protected boolean isEntityReferencesCollection() throws XavaException
- Overrides:
isEntityReferencesCollection
in classCollectionElementViewBaseAction
- Throws:
XavaException
-
addMessage
protected void addMessage()
- Overrides:
addMessage
in classRemoveSelectedInCollectionAction
-
-