Package org.apache.ofbiz.widget.model
Class ModelForm
java.lang.Object
org.apache.ofbiz.widget.model.ModelWidget
org.apache.ofbiz.widget.model.ModelForm
- All Implemented Interfaces:
Serializable
- Direct Known Subclasses:
ModelGrid
,ModelSingleForm
Abstract base class for the <form> and <grid> elements.
- See Also:
-
widget-form.xsd
- Serialized Form
-
Nested Class Summary
Modifier and TypeClassDescriptionstatic class
static class
static class
static class
static class
static class
static interface
static class
static class
The UpdateArea class implements the<on-event-update-area>
elements used in form widgets.Nested classes/interfaces inherited from class org.apache.ofbiz.widget.model.ModelWidget
ModelWidget.NamedBorderType
-
Field Summary
Modifier and TypeFieldDescriptionstatic final String
static final String
static final String
static final String
static final String
static final String
static final String
static final String
static final int
Pagination settings and defaults.static final String
static final String
static final String
Sort field default styles.static final int
Fields inherited from class org.apache.ofbiz.widget.model.ModelWidget
ENABLE_BOUNDARY_COMMENTS_PARAM
-
Constructor Summary
ModifierConstructorDescriptionprotected
ModelForm
(Element formElement, String formLocation, ModelReader entityModelReader, VisualTheme visualTheme, DispatchContext dispatchContext, String defaultType) XML Constructor -
Method Summary
Modifier and TypeMethodDescriptionGets actions.Gets alt row styles.Gets alt targets.Gets auto fields entities.Gets auto fields services.Returns the widget's name to be used in boundary comments.boolean
Gets client autocomplete fields.Gets container id.Gets container style.Gets default entity name.Gets default field group.getDefaultMap
(Map<String, ? extends Object> context) Gets default map.Gets default map name.Gets default required field style.Gets default service name.Gets default sort field asc style.Gets default sort field desc style.Gets default sort field style.Gets default table style.Gets default title area style.Gets default title style.Gets default tooltip style.int
Gets default view size.Gets default widget area style.Gets default widget style.getEmptyFormDataMessage
(Map<String, Object> context) Gets empty form data message.Gets even row style.Gets field group list.Gets field group map.Gets field list.Gets focus field name.Gets form location.Gets form title area style.Gets form widget area style.boolean
Gets group columns.Gets header row style.boolean
Gets hide header.Gets item index separator.Gets last order fields.Gets list entry name.Gets list name.getMultiPaginateIndexField
(Map<String, Object> context) Gets multi paginate index field.getMultiPaginateSizeField
(Map<String, Object> context) Gets multi paginate size field.Gets multi submit fields.Gets odd row style.Gets on paginate update areas.Gets on sort column update areas.Returns the list of ModelForm.UpdateArea objects.Gets override list size.int
getOverrideListSize
(Map<String, Object> context) Gets override list size.Gets paginate.boolean
getPaginate
(Map<String, Object> context) Gets paginate.Gets paginate first label.getPaginateFirstLabel
(Map<String, Object> context) Gets paginate first label.Gets paginate first style.Gets paginate index field.getPaginateIndexField
(Map<String, Object> context) Gets paginate index field.Gets paginate last label.getPaginateLastLabel
(Map<String, Object> context) Gets paginate last label.Gets paginate last style.Gets paginate next label.getPaginateNextLabel
(Map<String, Object> context) Gets paginate next label.Gets paginate next style.Gets paginate previous label.getPaginatePreviousLabel
(Map<String, Object> context) Gets paginate previous label.Gets paginate previous style.Gets paginate size field.getPaginateSizeField
(Map<String, Object> context) Gets paginate size field.Gets paginate style.Gets paginate target.getPaginateTarget
(Map<String, Object> context) Gets paginate target.Gets paginate target anchor.Gets paginate view size label.getPaginateViewSizeLabel
(Map<String, Object> context) Gets paginate view size label.Gets parent form location.Gets parent form name.protected abstract ModelForm
getParentModel
(Element formElement, ModelReader entityModelReader, VisualTheme visualTheme, DispatchContext dispatchContext) Gets parent model form.getPassedRowCount
(Map<String, Object> context) Gets passed row count.Gets row actions.Gets row count.boolean
Gets separate columns.boolean
Gets skip end.boolean
Gets skip start.getSortField
(Map<String, Object> context) Gets sort field.Gets sort field parameter name.Gets sort order fields.getStyleAltRowStyle
(Map<String, Object> context) iterate through alt-row-styles list to see if should be used, then add styleGets target.iterate through altTargets list to see if any should be used, if not return original targetGets target type.Gets target window.getTargetWindow
(Map<String, Object> context) Gets target window.getTitle()
Gets title.Gets tooltip.getType()
Gets type.boolean
Gets use row submit.Gets use when fields.boolean
Is overriden list size boolean.void
runFormActions
(Map<String, Object> context) Run form actions.Methods inherited from class org.apache.ofbiz.widget.model.ModelWidget
accept, getName, getStartColumn, getStartLine, getSystemId, toString, widgetBoundaryCommentsEnabled, widgetNamedBorderType
-
Field Details
-
DEFAULT_FORM_RESULT_LIST_NAME
- See Also:
-
DEFAULT_PAGE_SIZE
public static final int DEFAULT_PAGE_SIZEPagination settings and defaults.- See Also:
-
MAX_PAGE_SIZE
public static final int MAX_PAGE_SIZE- See Also:
-
DEFAULT_PAG_INDEX_FIELD
- See Also:
-
DEFAULT_PAG_SIZE_FIELD
- See Also:
-
DEFAULT_PAG_STYLE
- See Also:
-
DEFAULT_PAG_FIRST_STYLE
- See Also:
-
DEFAULT_PAG_PREV_STYLE
- See Also:
-
DEFAULT_PAG_NEXT_STYLE
- See Also:
-
DEFAULT_PAG_LAST_STYLE
- See Also:
-
DEFAULT_SORT_FIELD_STYLE
Sort field default styles.- See Also:
-
DEFAULT_SORT_FIELD_ASC_STYLE
- See Also:
-
DEFAULT_SORT_FIELD_DESC_STYLE
- See Also:
-
-
Constructor Details
-
ModelForm
protected ModelForm(Element formElement, String formLocation, ModelReader entityModelReader, VisualTheme visualTheme, DispatchContext dispatchContext, String defaultType) XML Constructor
-
-
Method Details
-
getActions
Gets actions.- Returns:
- the actions
-
getAltRowStyles
Gets alt row styles.- Returns:
- the alt row styles
-
getAltTargets
Gets alt targets.- Returns:
- the alt targets
-
getAutoFieldsEntities
Gets auto fields entities.- Returns:
- the auto fields entities
-
getAutoFieldsServices
Gets auto fields services.- Returns:
- the auto fields services
-
getBoundaryCommentName
Description copied from class:ModelWidget
Returns the widget's name to be used in boundary comments. The default action is to return the widget's name. Derived classes can override this method to return a customized name.- Overrides:
getBoundaryCommentName
in classModelWidget
- Returns:
- Name to be used in boundary comments
-
getClientAutocompleteFields
public boolean getClientAutocompleteFields()Gets client autocomplete fields.- Returns:
- the client autocomplete fields
-
getContainerId
Gets container id.- Returns:
- the container id
-
getContainerStyle
Gets container style.- Returns:
- the container style
-
getDefaultEntityName
Gets default entity name.- Returns:
- the default entity name
-
getDefaultFieldGroup
Gets default field group.- Returns:
- the default field group
-
getDefaultMap
Gets default map.- Parameters:
context
- the context- Returns:
- the default map
-
getDefaultMapName
Gets default map name.- Returns:
- the default map name
-
getDefaultRequiredFieldStyle
Gets default required field style.- Returns:
- the default required field style
-
getDefaultServiceName
Gets default service name.- Returns:
- the default service name
-
getDefaultSortFieldAscStyle
Gets default sort field asc style.- Returns:
- the default sort field asc style
-
getDefaultSortFieldDescStyle
Gets default sort field desc style.- Returns:
- the default sort field desc style
-
getDefaultSortFieldStyle
Gets default sort field style.- Returns:
- the default sort field style
-
getDefaultTableStyle
Gets default table style.- Returns:
- the default table style
-
getDefaultTitleAreaStyle
Gets default title area style.- Returns:
- the default title area style
-
getDefaultTitleStyle
Gets default title style.- Returns:
- the default title style
-
getDefaultTooltipStyle
Gets default tooltip style.- Returns:
- the default tooltip style
-
getDefaultViewSize
public int getDefaultViewSize()Gets default view size.- Returns:
- the default view size
-
getDefaultWidgetAreaStyle
Gets default widget area style.- Returns:
- the default widget area style
-
getDefaultWidgetStyle
Gets default widget style.- Returns:
- the default widget style
-
getEvenRowStyle
Gets even row style.- Returns:
- the even row style
-
getFieldGroupList
Gets field group list.- Returns:
- the field group list
-
getFieldGroupMap
Gets field group map.- Returns:
- the field group map
-
getFieldList
Gets field list.- Returns:
- the field list
-
getFocusFieldName
Gets focus field name.- Returns:
- the focus field name
-
getFormLocation
Gets form location.- Returns:
- the form location
-
getFormTitleAreaStyle
Gets form title area style.- Returns:
- the form title area style
-
getFormWidgetAreaStyle
Gets form widget area style.- Returns:
- the form widget area style
-
getHeaderRowStyle
Gets header row style.- Returns:
- the header row style
-
getHideHeader
public boolean getHideHeader()Gets hide header.- Returns:
- the hide header
-
getItemIndexSeparator
Gets item index separator.- Returns:
- the item index separator
-
getLastOrderFields
Gets last order fields.- Returns:
- the last order fields
-
getListEntryName
Gets list entry name.- Returns:
- the list entry name
-
getListName
Gets list name.- Returns:
- the list name
-
getMultiPaginateIndexField
Gets multi paginate index field.- Parameters:
context
- the context- Returns:
- the multi paginate index field
-
getMultiPaginateSizeField
Gets multi paginate size field.- Parameters:
context
- the context- Returns:
- the multi paginate size field
-
getMultiSubmitFields
Gets multi submit fields.- Returns:
- the multi submit fields
-
getOddRowStyle
Gets odd row style.- Returns:
- the odd row style
-
getOnPaginateUpdateAreas
Gets on paginate update areas.- Returns:
- the on paginate update areas
-
getOnSortColumnUpdateAreas
Gets on sort column update areas.- Returns:
- the on sort column update areas
-
getOnSubmitUpdateAreas
Returns the list of ModelForm.UpdateArea objects. -
getOverrideListSize
Gets override list size.- Returns:
- the override list size
-
getOverrideListSize
Gets override list size.- Parameters:
context
- the context- Returns:
- the override list size
-
getPaginate
Gets paginate.- Returns:
- the paginate
-
getPaginate
Gets paginate.- Parameters:
context
- the context- Returns:
- the paginate
-
getPaginateFirstLabel
Gets paginate first label.- Returns:
- the paginate first label
-
getPaginateFirstLabel
Gets paginate first label.- Parameters:
context
- the context- Returns:
- the paginate first label
-
getPaginateFirstStyle
Gets paginate first style.- Returns:
- the paginate first style
-
getPaginateIndexField
Gets paginate index field.- Returns:
- the paginate index field
-
getPaginateIndexField
Gets paginate index field.- Parameters:
context
- the context- Returns:
- the paginate index field
-
getPaginateLastLabel
Gets paginate last label.- Returns:
- the paginate last label
-
getPaginateLastLabel
Gets paginate last label.- Parameters:
context
- the context- Returns:
- the paginate last label
-
getPaginateLastStyle
Gets paginate last style.- Returns:
- the paginate last style
-
getPaginateNextLabel
Gets paginate next label.- Returns:
- the paginate next label
-
getPaginateNextLabel
Gets paginate next label.- Parameters:
context
- the context- Returns:
- the paginate next label
-
getPaginateNextStyle
Gets paginate next style.- Returns:
- the paginate next style
-
getPaginatePreviousLabel
Gets paginate previous label.- Returns:
- the paginate previous label
-
getPaginatePreviousLabel
Gets paginate previous label.- Parameters:
context
- the context- Returns:
- the paginate previous label
-
getPaginatePreviousStyle
Gets paginate previous style.- Returns:
- the paginate previous style
-
getPaginateSizeField
Gets paginate size field.- Returns:
- the paginate size field
-
getPaginateSizeField
Gets paginate size field.- Parameters:
context
- the context- Returns:
- the paginate size field
-
getPaginateStyle
Gets paginate style.- Returns:
- the paginate style
-
getPaginateTarget
Gets paginate target.- Returns:
- the paginate target
-
getPaginateTarget
Gets paginate target.- Parameters:
context
- the context- Returns:
- the paginate target
-
getPaginateTargetAnchor
Gets paginate target anchor.- Returns:
- the paginate target anchor
-
getPaginateViewSizeLabel
Gets paginate view size label.- Returns:
- the paginate view size label
-
getPaginateViewSizeLabel
Gets paginate view size label.- Parameters:
context
- the context- Returns:
- the paginate view size label
-
getParentModel
protected abstract ModelForm getParentModel(Element formElement, ModelReader entityModelReader, VisualTheme visualTheme, DispatchContext dispatchContext) -
getParentFormLocation
Gets parent form location.- Returns:
- the parent form location
-
getParentFormName
Gets parent form name.- Returns:
- the parent form name
-
getParentModelForm
Gets parent model form.- Returns:
- the parent model form
-
getPassedRowCount
Gets passed row count.- Parameters:
context
- the context- Returns:
- the passed row count
-
getRowActions
Gets row actions.- Returns:
- the row actions
-
getRowCount
Gets row count.- Returns:
- the row count
-
getSeparateColumns
public boolean getSeparateColumns()Gets separate columns.- Returns:
- the separate columns
-
getSkipEnd
public boolean getSkipEnd()Gets skip end.- Returns:
- the skip end
-
getSkipStart
public boolean getSkipStart()Gets skip start.- Returns:
- the skip start
-
getSortField
Gets sort field.- Parameters:
context
- the context- Returns:
- the sort field
-
getSortFieldParameterName
Gets sort field parameter name.- Returns:
- the sort field parameter name
-
getSortOrderFields
Gets sort order fields.- Returns:
- the sort order fields
-
getStyleAltRowStyle
iterate through alt-row-styles list to see if should be used, then add style- Returns:
- The style for item row
-
getTarget
Gets target.- Returns:
- the target
-
getTarget
iterate through altTargets list to see if any should be used, if not return original target- Returns:
- The target for this Form
-
getTargetType
Gets target type.- Returns:
- the target type
-
getTargetWindow
Gets target window.- Returns:
- the target window
-
getTargetWindow
Gets target window.- Parameters:
context
- the context- Returns:
- the target window
-
getTitle
Gets title.- Returns:
- the title
-
getEmptyFormDataMessage
Gets empty form data message.- Parameters:
context
- the context- Returns:
- the empty form data message
-
getTooltip
Gets tooltip.- Returns:
- the tooltip
-
getType
Gets type.- Returns:
- the type
-
getUseRowSubmit
public boolean getUseRowSubmit()Gets use row submit.- Returns:
- the use row submit
-
getUseWhenFields
Gets use when fields.- Returns:
- the use when fields
-
getGroupColumns
public boolean getGroupColumns()Gets group columns.- Returns:
- the group columns
-
isOverridenListSize
public boolean isOverridenListSize()Is overriden list size boolean.- Returns:
- the boolean
-
runFormActions
Run form actions.- Parameters:
context
- the context
-