Class InputFieldBase
- All Implemented Interfaces:
Serializable,Cloneable,Copyable,DictionaryBean,UifDictionaryBean,CaseConstrainable,Constrainable,MustOccurConstrainable,PrerequisiteConstrainable,SimpleConstrainable,ValidCharactersConstrainable,Component,DataBinding,Ordered,ScriptEventSupport,DataField,Field,InputField,LifecycleElement,Helpable,org.springframework.core.Ordered
- Direct Known Subclasses:
LookupInputField
The InputField provides the majority of the data input/output
for the screen. Through these fields the model can be displayed and updated.
For data input, the field contains a Control instance will
render an HTML control element(s). The input field also contains a
Label, summary, and widgets such as a quickfinder (for
looking up values) and inquiry (for getting more information on the value).
InputField instances can have associated messages (errors)
due to invalid input or business rule failures. Security can also be
configured to restrict who may view the fields valnue.
- Author:
- Kuali Rice Team (rice.collab@kuali.org)
- See Also:
-
Field Summary
Fields inherited from class org.kuali.rice.krad.uif.field.DataFieldBase
readOnlyDisplayReplacementPropertyName, readOnlyDisplaySuffixPropertyNameFields inherited from class org.kuali.rice.krad.uif.component.ComponentBase
templateOptionsFields inherited from class org.kuali.rice.krad.datadictionary.DictionaryBeanBase
componentCode, namespaceCodeFields inherited from interface org.kuali.rice.krad.uif.component.Ordered
INITIAL_ORDER_VALUEFields inherited from interface org.springframework.core.Ordered
HIGHEST_PRECEDENCE, LOWEST_PRECEDENCE -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected voidInvoked during the finalize phase to capture state of the component needs to support post operations.voidaddPostInputAddon(Component addOn) Adds a component to the list of post input addon components.protected voidadjustMustOccurConstraintBinding(List<MustOccurConstraint> mustOccurConstraints) Adjust paths on the must occur constrain bindingsprotected voidadjustPrerequisiteConstraintBinding(List<PrerequisiteConstraint> prerequisiteConstraints) Adjust paths on the prerequisite constraint bindingsvoidNo-op implementation.voidcompleteValidation(ValidationTrace tracer) Validates different requirements of component compiling a series of reports detailing information on errors found in the component.voidcopyFromAttributeDefinition(AttributeDefinition attributeDefinition) Defaults the properties of theDataFieldto the corresponding properties of itsAttributeDefinitionretrieved from the dictionary (if such an entry exists).Attribute query instance configured for this field to dynamically pull information back for updates other fields or providing messagesMessage field that displays constraint textText that display a restriction on the value a field can holdControlinstance that should be used to input data for the fieldGets the DataType of this InputField, note that DataType set to be date when this field is using a date picker with a TextControl and has not otherwise been explicitly set.List ofPrerequisiteConstraintthat apply to thisInputFieldThe exclusive minimum value for numeric or date field.Help text that displays under the control and is disclosed on focus.The inclusive maximum value for numeric or date field.Message field that displays instructional textInstructional text that display an explanation of the field usageMaximum number of characters the input field value is allowed to haveMinimum number of characters the input field value needs to beInstance ofKeyValuesFinderthat should be invoked to provide a List of values the field can have.Class<? extends KeyValuesFinder> Get the class of the optionsFinder being used by this InputFieldList of components that will be grouped with the input field control to form an input group.List of CSS classes that will be applied to the span that wraps the post input components.Returns the list of post input css classes as a string formed by joining the classes with a space.Lookup finder widget for the fieldIndicates whether the component is requiredSuggest box widget for the input fieldField that contains the messages (errors) for the input field.protected booleanDetermines wheter or not to create an automatic quickfinder widget for this field within the current lifecycle.booleanWhen ajaxInlineEdit is enabled, the field will appear as text, and when clicked, the input version of that field is retrieved from the server; the user will be able to edit that field's value and save that new value.booleanIndicates whether the browser autocomplete functionality should be disabled for the input field (adds autocomplete="off")booleanIndicates whether direct inquiries should be automatically set when a relationship for the field's property is foundbooleanIndicates whether quickfinders should be automatically set when a relationship for the field's property is foundbooleanWhen inlineEdit is enabled, the field will appear as text, and when clicked the user will be able to edit that field's value and save that new value.booleanIndicates whether the data field instance allows input, subclasses should override and set to true if input is allowedbooleanbooleanForces rendering of the input group div around the control.booleanPerform uppercase flag for this field to force input to uppercase.booleanIndicates indicates whether the field can only be updated through a widget widgetInputOnly behaves similar to ReadOnly with the exception that the value of the input field can be changed via the associated widget (e.g. spinner, date picker, quickfinder, etc).voidperformApplyModel(Object model, LifecycleElement parent) The following finalization is performed: Make sure that a label is defined for any data fields.voidperformFinalize(Object model, LifecycleElement parent) The following finalization is performed: Set the labelForComponentId to this component id Set the label text on the label field from the field's label property Set the render property on the label's required message field if this field is marked as required The following finalization is done here: progressiveRender and conditionalRefresh variables are processed if set If any of the style properties were given, sets the style string on the style property Set the skipInTabOrder flag for nested components The last phase before the view is renderedvoidperformInitialization(Object model) The following updates are done here: Invoke performInitialize on component modifiers Initializes the componentprotected voidprocessReadOnlyListDisplay(Object model, List<?> originalList) Overrides processReadOnlyListDisplay to handle MultiValueControls by creating the list of values from values instead of the keys of the options selected (makes the list "human-readable").voidsetAjaxInlineEdit(boolean ajaxInlineEdit) protected voidsetAlternateAndAdditionalDisplayValue(View view, Object model) Overriding to check quickfinder when masked is being applied.voidsetAttributeQuery(AttributeQuery attributeQuery) Setter for this field's attribute queryvoidsetCaseConstraint(CaseConstraint caseConstraint) Setter forcaseConstraintvoidsetConstraintMessage(Message constraintMessage) Setter for the constraint text message fieldvoidsetConstraintText(String constraintText) Setter for the constraint message textvoidsetControl(Control control) Setter for the field's controlvoidsetDataType(String dataType) voidsetDataType(DataType dataType) This does not have to be set, represents the DataType constraint of this field.voidsetDependencyConstraints(List<PrerequisiteConstraint> dependencyConstraints) Setter fordependencyConstraintsvoidsetDisableNativeAutocomplete(boolean disableNativeAutocomplete) Setter to disable browser autocomplete for the input fieldvoidsetEnableAutoDirectInquiry(boolean enableAutoDirectInquiry) Setter for enabling automatic direct inquiriesvoidsetEnableAutoQuickfinder(boolean enableAutoQuickfinder) Setter for enabling automatic quickfindersvoidsetExclusiveMin(String exclusiveMin) Setter for the field's exclusive minimum valuevoidsetHelperText(String helperText) voidsetInclusiveMax(String inclusiveMax) Setter for the field's inclusive maximum valuevoidsetInlineEdit(boolean inlineEdit) voidsetInstructionalMessage(Message instructionalMessage) Setter for the instructional text message fieldvoidsetInstructionalText(String instructionalText) Setter for the instructional messagevoidsetMaxLength(Integer maxLength) Setter for input field max lengthvoidsetMinLength(Integer minLength) Setter for input field minimum lengthvoidsetMustOccurConstraints(List<MustOccurConstraint> mustOccurConstraints) Setter formustOccurConstraintsvoidsetOptionsFinder(KeyValuesFinder optionsFinder) Setter for the field's KeyValuesFinder instancevoidsetOptionsFinderClass(Class<? extends KeyValuesFinder> optionsFinderClass) Setter that takes in the class name for the options finder and creates a new instance to use as the finder for the input fieldvoidsetPostInputAddons(List<Component> postInputAddons) voidsetPostInputCssClasses(List<String> postInputCssClasses) voidsetQuickfinder(QuickFinder quickfinder) Setter for the lookup widgetvoidsetRenderInputAddonGroup(boolean renderInputAddonGroup) voidsetRequired(Boolean required) Setter for the required indicatorvoidsetSimpleConstraint(SimpleConstraint simpleConstraint) Setter for simple constraintvoidsetSuggest(Suggest suggest) Setter for the fields suggest widgetprotected voidsetupFieldQuery(View view) Performs setup of the field attribute query and informational display properties.protected voidsetupIds()Sets the ids on all components the input field uses so they will all contain this input field's id in their ids.voidsetUppercaseValue(boolean uppercaseValue) Setter for this field's performUppercase flagvoidsetValidationMessages(FieldValidationMessages validationMessages) Setter for the input field's errors fieldvoidsetValidCharactersConstraint(ValidCharactersConstraint validCharactersConstraint) Setter forvalidCharacterConstraintvoidsetWidgetInputOnly(boolean widgetInputOnly) Setter for the widget input only indicatorMethods inherited from class org.kuali.rice.krad.uif.field.DataFieldBase
generateReadOnlyListDisplayReplacement, getAdditionalHiddenPropertyNames, getBindingInfo, getDataFieldSecurity, getDefaultValue, getDefaultValueFinderClass, getDefaultValues, getDictionaryAttributeName, getDictionaryObjectEntry, getForcedValue, getHelp, getHelpSummary, getHelpTitle, getInquiry, getMaskFormatter, getName, getPropertyEditor, getPropertyName, getPropertyNamesForAdditionalDisplay, getReadOnlyDisplayReplacement, getReadOnlyDisplayReplacementPropertyName, getReadOnlyDisplaySuffix, getReadOnlyDisplaySuffixPropertyName, getReadOnlyListDelimiter, getReadOnlyListDisplayType, getSortAs, hasAutoInquiryRelationship, hasSecureValue, initializeComponentSecurity, isAddHiddenWhenReadOnly, isApplyMask, isEnableAutoInquiry, isEscapeHtmlInPropertyValue, isMultiLineReadOnlyDisplay, isRenderInfoMessageSpan, isRenderMarkerIconSpan, setAddHiddenWhenReadOnly, setAdditionalHiddenPropertyNames, setApplyMask, setBindingInfo, setComponentSecurity, setDefaultValue, setDefaultValueFinderClass, setDefaultValues, setDictionaryAttributeName, setDictionaryObjectEntry, setEnableAutoInquiry, setEscapeHtmlInPropertyValue, setForcedValue, setHelp, setHelpSummary, setInquiry, setMaskFormatter, setMultiLineReadOnlyDisplay, setPropertyEditor, setPropertyEditorClass, setPropertyName, setPropertyNamesForAdditionalDisplay, setReadOnlyDisplayReplacement, setReadOnlyDisplayReplacementPropertyName, setReadOnlyDisplaySuffix, setReadOnlyDisplaySuffixPropertyName, setReadOnlyListDelimiter, setReadOnlyListDisplayType, setRenderInfoMessageSpan, setRenderMarkerIconSpan, setSortAs, setTooltipOfComponentMethods inherited from class org.kuali.rice.krad.uif.field.FieldBase
getComponentTypeName, getFieldLabel, getFieldSecurity, getLabel, getLabelColSpan, getLabelStyleClasses, getShortLabel, isEditInLineAuthz, isLabelLeft, isLabelRendered, isViewInLineAuthz, setEditInLineAuthz, setFieldLabel, setLabel, setLabelColSpan, setLabelLeft, setLabelRendered, setLabelStyleClasses, setNestedComponentIdAndSuffix, setShortLabel, setShowLabel, setViewInLineAuthzMethods inherited from class org.kuali.rice.krad.uif.component.ComponentBase
addAriaAttribute, addDataAttribute, addScriptDataAttribute, addStyleClass, addWrapperCssClass, appendToStyle, checkMutable, clone, getAdditionalComponentsToRefresh, getAdditionalComponentsToRefreshJs, getAdditionalCssClasses, getAdditionalTemplates, getAlign, getAriaAttributes, getAriaAttributesAsString, getCanCopyOnReadOnly, getCellWidth, getColSpan, getComponentModifiers, getComponentSecurity, getConditionalRefresh, getConditionalRefreshConditionJs, getConditionalRefreshControlNames, getContainerIdSuffix, getContext, getCssClasses, getCssGridSizes, getDataAttributes, getEventHandlerScript, getExcludeIf, getExcludeUnless, getFieldsToSendOnRefresh, getFinalizeMethodAdditionalArguments, getFinalizeMethodInvoker, getFinalizeMethodToCall, getId, getLibraryCssClasses, getMethodToCallOnRefresh, getOnBlurScript, getOnChangeScript, getOnClickScript, getOnCloseScript, getOnDblClickScript, getOnDocumentReadyScript, getOnFocusScript, getOnInputScript, getOnKeyDownScript, getOnKeyPressScript, getOnKeyUpScript, getOnLoadScript, getOnMouseDownScript, getOnMouseMoveScript, getOnMouseOutScript, getOnMouseOverScript, getOnMouseUpScript, getOnSubmitScript, getOnUnloadScript, getOrder, getPhasePathMapping, getPostRenderContent, getPreRenderContent, getProgressiveDisclosureConditionJs, getProgressiveDisclosureControlNames, getProgressiveRender, getPropertyReplacerComponents, getPropertyReplacers, getReadOnly, getRefreshTimer, getRefreshWhenChangedPropertyNames, getRenderedHtmlOutput, getRole, getRowSpan, getScriptDataAttributes, getScriptDataAttributesJs, getSimpleDataAttributes, getStyle, getStyleClassesAsString, getTemplate, getTemplateName, getTemplateOptions, getTemplateOptionsJSString, getTitle, getToolTip, getValign, getViewPath, getViewStatus, getWidth, getWrapperCssClasses, getWrapperCssClassesAsString, getWrapperStyle, isDisableSessionPersistence, isDisclosedByAction, isEditAuthz, isFinal, isForceSessionPersistence, isHidden, isInitialized, isModelApplied, isMutable, isOmitFromFormPost, isProgressiveRenderAndRefresh, isProgressiveRenderViaAJAX, isRefreshedByAction, isRender, isRendered, isResetDataOnRefresh, isRetrieveViaAjax, isSelfRendered, isSkipInTabOrder, isViewAuthz, notifyCompleted, pushAllToContext, pushObjectToContext, pushToPropertyReplacerContext, setAdditionalComponentsToRefresh, setAdditionalCssClasses, setAlign, setAriaAttributes, setCanCopyOnReadOnly, setCellWidth, setColSpan, setComponentModifiers, setConditionalRefresh, setContainerIdSuffix, setContext, setCssClasses, setCssGridSizes, setDataAttributes, setDisableSessionPersistence, setDisclosedByAction, setEditAuthz, setExcludeIf, setExcludeUnless, setFieldsToSendOnRefresh, setFinalizeMethodAdditionalArguments, setFinalizeMethodInvoker, setFinalizeMethodToCall, setForceSessionPersistence, setHidden, setId, setLibraryCssClasses, setMethodToCallOnRefresh, setOmitFromFormPost, setOnBlurScript, setOnChangeScript, setOnClickScript, setOnCloseScript, setOnDblClickScript, setOnDocumentReadyScript, setOnFocusScript, setOnInputScript, setOnKeyDownScript, setOnKeyPressScript, setOnKeyUpScript, setOnLoadScript, setOnMouseDownScript, setOnMouseMoveScript, setOnMouseOutScript, setOnMouseOverScript, setOnMouseUpScript, setOnSubmitScript, setOnUnloadScript, setOrder, setPhasePathMapping, setPostRenderContent, setPreRenderContent, setProgressiveRender, setProgressiveRenderAndRefresh, setProgressiveRenderViaAJAX, setPropertyReplacers, setReadOnly, setRefreshedByAction, setRefreshTimer, setRefreshWhenChangedPropertyNames, setRender, setRenderedHtmlOutput, setResetDataOnRefresh, setRetrieveViaAjax, setRole, setRowSpan, setScriptDataAttributes, setSelfRendered, setSkipInTabOrder, setStyle, setTemplate, setTemplateName, setTemplateOptions, setTemplateOptionsJSString, setTitle, setToolTip, setValign, setViewAuthz, setViewPath, setViewStatus, setWidth, setWrapperCssClasses, setWrapperStyle, skipLifecycleMethods inherited from class org.kuali.rice.krad.datadictionary.uif.UifDictionaryBeanBase
getExpressionGraph, getPropertyExpression, getPropertyExpressions, setExpressionGraph, setPropertyExpressionsMethods inherited from class org.kuali.rice.krad.datadictionary.DictionaryBeanBase
copy, dataDictionaryPostProcessing, getComponentCode, getNamespaceCode, setComponentCode, setNamespaceCodeMethods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.kuali.rice.krad.uif.component.Component
addAriaAttribute, addDataAttribute, addScriptDataAttribute, addStyleClass, addWrapperCssClass, appendToStyle, getAdditionalComponentsToRefresh, getAdditionalComponentsToRefreshJs, getAdditionalCssClasses, getAdditionalTemplates, getAlign, getAriaAttributes, getAriaAttributesAsString, getCanCopyOnReadOnly, getCellWidth, getColSpan, getComponentModifiers, getComponentSecurity, getComponentTypeName, getConditionalRefresh, getConditionalRefreshConditionJs, getConditionalRefreshControlNames, getContext, getCssClasses, getCssGridSizes, getDataAttributes, getEventHandlerScript, getExcludeIf, getExcludeUnless, getFieldsToSendOnRefresh, getFinalizeMethodAdditionalArguments, getFinalizeMethodInvoker, getFinalizeMethodToCall, getLibraryCssClasses, getMethodToCallOnRefresh, getOrder, getPostRenderContent, getPreRenderContent, getProgressiveDisclosureConditionJs, getProgressiveDisclosureControlNames, getProgressiveRender, getPropertyReplacerComponents, getPropertyReplacers, getReadOnly, getRefreshTimer, getRefreshWhenChangedPropertyNames, getRenderedHtmlOutput, getRole, getRowSpan, getScriptDataAttributes, getScriptDataAttributesJs, getSimpleDataAttributes, getStyle, getStyleClassesAsString, getTemplate, getTemplateName, getTemplateOptions, getTemplateOptionsJSString, getTitle, getToolTip, getValign, getWidth, getWrapperCssClasses, getWrapperStyle, isDisableSessionPersistence, isDisclosedByAction, isForceSessionPersistence, isHidden, isOmitFromFormPost, isProgressiveRenderAndRefresh, isProgressiveRenderViaAJAX, isRefreshedByAction, isRendered, isResetDataOnRefresh, isRetrieveViaAjax, isSelfRendered, setAdditionalComponentsToRefresh, setAdditionalCssClasses, setAlign, setAriaAttributes, setCanCopyOnReadOnly, setCellWidth, setColSpan, setComponentModifiers, setConditionalRefresh, setContext, setCssClasses, setCssGridSizes, setDataAttributes, setDisableSessionPersistence, setDisclosedByAction, setFieldsToSendOnRefresh, setForceSessionPersistence, setHidden, setLibraryCssClasses, setOmitFromFormPost, setOrder, setPostRenderContent, setPreRenderContent, setProgressiveRender, setProgressiveRenderAndRefresh, setProgressiveRenderViaAJAX, setPropertyReplacers, setReadOnly, setRefreshedByAction, setRefreshTimer, setRefreshWhenChangedPropertyNames, setRenderedHtmlOutput, setResetDataOnRefresh, setRetrieveViaAjax, setRole, setRowSpan, setScriptDataAttributes, setSelfRendered, setStyle, setTemplate, setTemplateName, setTemplateOptions, setTemplateOptionsJSString, setTitle, setToolTip, setValign, setViewStatus, setWidth, setWrapperCssClasses, setWrapperStyleMethods inherited from interface org.kuali.rice.krad.datadictionary.validation.capability.Constrainable
getNameMethods inherited from interface org.kuali.rice.krad.uif.component.DataBinding
getBindingInfo, getPropertyName, setBindingInfoMethods inherited from interface org.kuali.rice.krad.uif.field.DataField
getAdditionalHiddenPropertyNames, getDataFieldSecurity, getDefaultValue, getDefaultValueFinderClass, getDefaultValues, getDictionaryAttributeName, getDictionaryObjectEntry, getForcedValue, getHelpSummary, getInquiry, getMaskFormatter, getName, getPropertyEditor, getPropertyNamesForAdditionalDisplay, getReadOnlyDisplayReplacement, getReadOnlyDisplayReplacementPropertyName, getReadOnlyDisplaySuffix, getReadOnlyDisplaySuffixPropertyName, getReadOnlyListDelimiter, getReadOnlyListDisplayType, getSortAs, hasSecureValue, isAddHiddenWhenReadOnly, isApplyMask, isEnableAutoInquiry, isEscapeHtmlInPropertyValue, isMultiLineReadOnlyDisplay, isRenderInfoMessageSpan, isRenderMarkerIconSpan, setAddHiddenWhenReadOnly, setAdditionalHiddenPropertyNames, setApplyMask, setComponentSecurity, setDefaultValue, setDefaultValueFinderClass, setDefaultValues, setDictionaryAttributeName, setDictionaryObjectEntry, setEnableAutoInquiry, setEscapeHtmlInPropertyValue, setForcedValue, setHelpSummary, setInquiry, setMaskFormatter, setMultiLineReadOnlyDisplay, setPropertyEditor, setPropertyEditorClass, setPropertyName, setPropertyNamesForAdditionalDisplay, setReadOnlyDisplayReplacement, setReadOnlyDisplayReplacementPropertyName, setReadOnlyDisplaySuffix, setReadOnlyDisplaySuffixPropertyName, setReadOnlyListDelimiter, setReadOnlyListDisplayType, setRenderInfoMessageSpan, setRenderMarkerIconSpan, setSortAsMethods inherited from interface org.kuali.rice.krad.datadictionary.DictionaryBean
dataDictionaryPostProcessing, getComponentCode, getNamespaceCodeMethods inherited from interface org.kuali.rice.krad.uif.field.Field
getFieldLabel, getFieldSecurity, getLabel, getLabelColSpan, getLabelStyleClasses, getShortLabel, isLabelLeft, isLabelRendered, setFieldLabel, setLabel, setLabelColSpan, setLabelLeft, setLabelRendered, setLabelStyleClasses, setShortLabelMethods inherited from interface org.kuali.rice.krad.uif.widget.Helpable
getHelp, getHelpTitle, setHelp, setTooltipOfComponentMethods inherited from interface org.kuali.rice.krad.uif.util.LifecycleElement
checkMutable, getContainerIdSuffix, getId, getPhasePathMapping, getViewPath, getViewStatus, isFinal, isInitialized, isModelApplied, isMutable, isRender, notifyCompleted, pushAllToContext, pushObjectToContext, setContainerIdSuffix, setId, setPhasePathMapping, setRender, setViewPath, skipLifecycleMethods inherited from interface org.kuali.rice.krad.uif.component.ScriptEventSupport
getOnBlurScript, getOnChangeScript, getOnClickScript, getOnCloseScript, getOnDblClickScript, getOnDocumentReadyScript, getOnFocusScript, getOnInputScript, getOnKeyDownScript, getOnKeyPressScript, getOnKeyUpScript, getOnLoadScript, getOnMouseDownScript, getOnMouseMoveScript, getOnMouseOutScript, getOnMouseOverScript, getOnMouseUpScript, getOnSubmitScript, getOnUnloadScript, setOnBlurScript, setOnChangeScript, setOnClickScript, setOnCloseScript, setOnDblClickScript, setOnDocumentReadyScript, setOnFocusScript, setOnInputScript, setOnKeyDownScript, setOnKeyPressScript, setOnKeyUpScript, setOnLoadScript, setOnMouseDownScript, setOnMouseMoveScript, setOnMouseOutScript, setOnMouseOverScript, setOnMouseUpScript, setOnSubmitScript, setOnUnloadScriptMethods inherited from interface org.kuali.rice.krad.datadictionary.uif.UifDictionaryBean
getExpressionGraph, getPropertyExpression, getPropertyExpressions, setExpressionGraph, setPropertyExpressions
-
Constructor Details
-
InputFieldBase
public InputFieldBase()
-
-
Method Details
-
performInitialization
The following updates are done here:- Invoke performInitialize on component modifiers
Where components can set defaults and setup other necessary state. The initialize method should only be called once per component lifecycle and is invoked within the initialize phase of the view lifecylce.
- Specified by:
performInitializationin interfaceLifecycleElement- Overrides:
performInitializationin classDataFieldBase- Parameters:
model- - object instance containing the view data- See Also:
-
afterEvaluateExpression
public void afterEvaluateExpression()No-op implementation. Override for custom behavior in subclasses. Invoked by the view lifecycle after expressions are evaluated at the apply model phase.In general, this method is preferred to
LifecycleElement.performApplyModel(Object, LifecycleElement)for populating model data via code, since it is called before client-side state is synchronize.- Specified by:
afterEvaluateExpressionin interfaceComponent- Overrides:
afterEvaluateExpressionin classDataFieldBase
-
performApplyModel
The following finalization is performed:- Make sure that a label is defined for any data fields. If not then create hidden label using property name.
- If no label for a non data field then just log a warning.
- Evaluate the progressive render condition (if set) and combine with the current render status to set the render status
Where components can perform conditional logic such as dynamically generating new fields or setting field state based on the given data
- Specified by:
performApplyModelin interfaceLifecycleElement- Overrides:
performApplyModelin classDataFieldBase- Parameters:
model- - Top level object containing the data (could be the form or a top level business object, dto)parent- parent lifecycle element
-
performFinalize
The following finalization is performed:- Set the labelForComponentId to this component id
- Set the label text on the label field from the field's label property
- Set the render property on the label's required message field if this field is marked as required
- progressiveRender and conditionalRefresh variables are processed if set
- If any of the style properties were given, sets the style string on the style property
- Set the skipInTabOrder flag for nested components
Here final preparations can be made based on the updated view state.
- Specified by:
performFinalizein interfaceLifecycleElement- Overrides:
performFinalizein classDataFieldBase- Parameters:
model- - top level object containing the dataparent- - parent component
-
addComponentPostMetadata
protected void addComponentPostMetadata()Invoked during the finalize phase to capture state of the component needs to support post operations. -
processReadOnlyListDisplay
Overrides processReadOnlyListDisplay to handle MultiValueControls by creating the list of values from values instead of the keys of the options selected (makes the list "human-readable"). Otherwise it just passes the list ahead as normal if this InputField does not use a MultiValueControl.- Overrides:
processReadOnlyListDisplayin classDataFieldBase- Parameters:
model- the modeloriginalList- originalList of values
-
setAlternateAndAdditionalDisplayValue
Overriding to check quickfinder when masked is being applied. If quickfinder is configured set the component to widgetInputOnly, else set to readOnly Sets alternate and additional property value for this field.If
AttributeSecuritypresent in this field, make sure the current user has permission to view the field value. If user doesn't have permission to view the value, mask the value as configured and set it as alternate value for display. If security doesn't exists for this field butalternateDisplayPropertyNamepresent, get its value and format it based on that fields formatting and set for display.For additional display value, if
AttributeSecuritynot present, sets the value ifadditionalDisplayPropertyNamepresent. If not present, check whether this field is aKualiCodeand get the relationship configured in the datadictionary file and set the name additional display value which will be displayed along with the code. If additional display property not present, check whether this field is hasMultiValueControlBase. If yes, get the Label for the value and set it as additional display value.- Overrides:
setAlternateAndAdditionalDisplayValuein classDataFieldBase- Parameters:
view- the current view instancemodel- model instance
-
adjustMustOccurConstraintBinding
Adjust paths on the must occur constrain bindings- Parameters:
mustOccurConstraints-
-
adjustPrerequisiteConstraintBinding
protected void adjustPrerequisiteConstraintBinding(List<PrerequisiteConstraint> prerequisiteConstraints) Adjust paths on the prerequisite constraint bindings- Parameters:
prerequisiteConstraints-
-
setupFieldQuery
Performs setup of the field attribute query and informational display properties.Paths are adjusted to match the binding for the this field, and the necessary onblur script for triggering the query client side is constructed
- Parameters:
view- view instance the input field is associated with
-
setupIds
protected void setupIds()Sets the ids on all components the input field uses so they will all contain this input field's id in their ids. This is useful for jQuery manipulation. -
copyFromAttributeDefinition
Defaults the properties of theDataFieldto the corresponding properties of itsAttributeDefinitionretrieved from the dictionary (if such an entry exists). If the field already contains a value for a property, the definitions value is not used.- Specified by:
copyFromAttributeDefinitionin interfaceDataField- Overrides:
copyFromAttributeDefinitionin classDataFieldBase- Parameters:
attributeDefinition- AttributeDefinition instance the property values should be copied from
-
isInputAllowed
public boolean isInputAllowed()Indicates whether the data field instance allows input, subclasses should override and set to true if input is allowed- Specified by:
isInputAllowedin interfaceDataField- Specified by:
isInputAllowedin interfaceInputField- Overrides:
isInputAllowedin classDataFieldBase- Returns:
- true if input is allowed, false if read only
- See Also:
-
getControl
Controlinstance that should be used to input data for the fieldWhen the field is editable, the control will be rendered so the user can input a value(s). Controls typically are part of a Form and render standard HTML control elements such as text input, select, and checkbox
- Specified by:
getControlin interfaceInputField- Returns:
- Control instance
-
setControl
Setter for the field's control- Specified by:
setControlin interfaceInputField- Parameters:
control-
-
isInlineEdit
public boolean isInlineEdit()When inlineEdit is enabled, the field will appear as text, and when clicked the user will be able to edit that field's value and save that new value.The method that is called by inlineEdit is saveField.
- Specified by:
isInlineEditin interfaceInputField- Returns:
- inlineEdit if set to true the field will have the ability to be edited inline
-
setInlineEdit
public void setInlineEdit(boolean inlineEdit) - Specified by:
setInlineEditin interfaceInputField- See Also:
-
isAjaxInlineEdit
public boolean isAjaxInlineEdit()When ajaxInlineEdit is enabled, the field will appear as text, and when clicked, the input version of that field is retrieved from the server; the user will be able to edit that field's value and save that new value.- Specified by:
isAjaxInlineEditin interfaceInputField- Returns:
- ajaxInlneEdit if true the field will have the ability to be edited inline via ajax call
-
setAjaxInlineEdit
public void setAjaxInlineEdit(boolean ajaxInlineEdit) - Specified by:
setAjaxInlineEditin interfaceInputField- See Also:
-
getValidationMessages
Field that contains the messages (errors) for the input field. TheValidationMessagesholds configuration on associated messages along with information on rendering the messages in the user interface- Specified by:
getValidationMessagesin interfaceInputField- Returns:
- ValidationMessages instance
-
setValidationMessages
Setter for the input field's errors field- Specified by:
setValidationMessagesin interfaceInputField- Parameters:
validationMessages-
-
getOptionsFinder
Instance ofKeyValuesFinderthat should be invoked to provide a List of values the field can have. Generally used to provide the options for a multi-value control or to validate the submitted field value- Specified by:
getOptionsFinderin interfaceInputField- Returns:
- KeyValuesFinder instance
-
setOptionsFinder
Setter for the field's KeyValuesFinder instance- Specified by:
setOptionsFinderin interfaceInputField- Parameters:
optionsFinder-
-
getOptionsFinderClass
Get the class of the optionsFinder being used by this InputField- Specified by:
getOptionsFinderClassin interfaceInputField- Returns:
- the class of the set optionsFinder, if not set or not applicable, returns null
-
setOptionsFinderClass
Setter that takes in the class name for the options finder and creates a new instance to use as the finder for the input field- Specified by:
setOptionsFinderClassin interfaceInputField- Parameters:
optionsFinderClass- the options finder class to set
-
isEnableAutoDirectInquiry
public boolean isEnableAutoDirectInquiry()Indicates whether direct inquiries should be automatically set when a relationship for the field's property is foundNote this only applies when the
DataField.getInquiry()widget has not been configured (is null) and is set to true by default- Specified by:
isEnableAutoDirectInquiryin interfaceInputField- Returns:
- true if auto direct inquiries are enabled, false if not
-
setEnableAutoDirectInquiry
public void setEnableAutoDirectInquiry(boolean enableAutoDirectInquiry) Setter for enabling automatic direct inquiries- Specified by:
setEnableAutoDirectInquiryin interfaceInputField- Parameters:
enableAutoDirectInquiry-
-
getQuickfinder
Lookup finder widget for the fieldThe quickfinder widget places a small icon next to the field that allows the user to bring up a search screen for finding valid field values. The
Widgetinstance can be configured to point to a certainLookupView, or the framework will attempt to associate the field with a lookup based on its metadata (in particular its relationships in the model)- Specified by:
getQuickfinderin interfaceInputField- Returns:
- QuickFinder lookup widget
-
setQuickfinder
Setter for the lookup widget- Specified by:
setQuickfinderin interfaceInputField- Parameters:
quickfinder- the field lookup widget to set
-
isEnableAutoQuickfinder
public boolean isEnableAutoQuickfinder()Indicates whether quickfinders should be automatically set when a relationship for the field's property is foundNote this only applies when the
InputField.getQuickfinder()widget has not been configured (is null) and is set to true by default- Specified by:
isEnableAutoQuickfinderin interfaceInputField- Returns:
- true if auto quickfinders are enabled, false if not
-
setEnableAutoQuickfinder
public void setEnableAutoQuickfinder(boolean enableAutoQuickfinder) Setter for enabling automatic quickfinders- Specified by:
setEnableAutoQuickfinderin interfaceInputField- Parameters:
enableAutoQuickfinder-
-
getSuggest
Suggest box widget for the input fieldIf enabled (by render flag), as the user inputs data into the fields control a dynamic query is performed to provide the user suggestions on values which they can then select
Note the Suggest widget is only valid when using a standard TextControl
- Specified by:
getSuggestin interfaceInputField- Returns:
- Suggest instance
-
setSuggest
Setter for the fields suggest widget- Specified by:
setSuggestin interfaceInputField- Parameters:
suggest- the field suggest widget to set
-
isWidgetInputOnly
public boolean isWidgetInputOnly()Indicates indicates whether the field can only be updated through a widget widgetInputOnly behaves similar to ReadOnly with the exception that the value of the input field can be changed via the associated widget (e.g. spinner, date picker, quickfinder, etc).- Specified by:
isWidgetInputOnlyin interfaceInputField- Returns:
- true if only widget input is allowed, false otherwise
-
setWidgetInputOnly
public void setWidgetInputOnly(boolean widgetInputOnly) Setter for the widget input only indicator- Specified by:
setWidgetInputOnlyin interfaceInputField- Parameters:
widgetInputOnly-
-
isRenderInputAddonGroup
public boolean isRenderInputAddonGroup()Forces rendering of the input group div around the control.If other components add content through script that should be grouped with the control, this flag can be set to true to generate the input group, even though
InputField.getPostInputAddons()may be empty- Specified by:
isRenderInputAddonGroupin interfaceInputField- Returns:
- boolean true to force rendering of the input group, false if not
-
setRenderInputAddonGroup
public void setRenderInputAddonGroup(boolean renderInputAddonGroup) - Specified by:
setRenderInputAddonGroupin interfaceInputField- See Also:
-
getPostInputCssClasses
List of CSS classes that will be applied to the span that wraps the post input components. TODO: revisist this, possibly getting the classes from component wrapper css classes once created- Specified by:
getPostInputCssClassesin interfaceInputField- Returns:
- List of CSS classes
-
getPostInputCssClassesAsString
Returns the list of post input css classes as a string formed by joining the classes with a space.- Specified by:
getPostInputCssClassesAsStringin interfaceInputField- Returns:
- post input css classes string
-
setPostInputCssClasses
- Specified by:
setPostInputCssClassesin interfaceInputField- See Also:
-
getPostInputAddons
List of components that will be grouped with the input field control to form an input group.Generally these are icon, link, or button components that should be rendered with the control.
- Specified by:
getPostInputAddonsin interfaceInputField- Returns:
- List of post input components
-
setPostInputAddons
- Specified by:
setPostInputAddonsin interfaceInputField- See Also:
-
addPostInputAddon
Adds a component to the list of post input addon components.- Specified by:
addPostInputAddonin interfaceInputField- Parameters:
addOn- component to add- See Also:
-
getInstructionalText
Instructional text that display an explanation of the field usageText explaining how to use the field, including things like what values should be selected in certain cases and so on (instructions)
- Specified by:
getInstructionalTextin interfaceInputField- Returns:
- instructional message
-
setInstructionalText
Setter for the instructional message- Specified by:
setInstructionalTextin interfaceInputField- Parameters:
instructionalText- the instructional text to set
-
getInstructionalMessage
Message field that displays instructional textThis message field can be configured to for adjusting how the instructional text will display. Generally the styleClasses property will be of most interest
- Specified by:
getInstructionalMessagein interfaceInputField- Returns:
- instructional message field
-
setInstructionalMessage
Setter for the instructional text message fieldNote this is the setter for the field that will render the instructional text. The actual text can be set on the field but can also be set using
InputField.setInstructionalText(String)- Specified by:
setInstructionalMessagein interfaceInputField- Parameters:
instructionalMessage- the instructional message to set
-
getHelperText
Help text that displays under the control and is disclosed on focus.- Specified by:
getHelperTextin interfaceInputField- Returns:
- String help text for input
-
setHelperText
- Specified by:
setHelperTextin interfaceInputField- See Also:
-
getConstraintText
Text that display a restriction on the value a field can holdFor example when the value must be a valid format (phone number, email), certain length, min/max value and so on this text can be used to indicate the constraint to the user. Generally displays with the control so it is visible when the user tabs to the field
- Specified by:
getConstraintTextin interfaceInputField- Returns:
- text to display for the constraint message
-
setConstraintText
Setter for the constraint message text- Specified by:
setConstraintTextin interfaceInputField- Parameters:
constraintText- the constraint text to set
-
getConstraintMessage
Message field that displays constraint textThis message field can be configured to for adjusting how the constrain text will display. Generally the styleClasses property will be of most interest
- Specified by:
getConstraintMessagein interfaceInputField- Returns:
- constraint message field
-
setConstraintMessage
Setter for the constraint text message fieldNote this is the setter for the field that will render the constraint text. The actual text can be set on the field but can also be set using
InputField.setConstraintText(String)- Specified by:
setConstraintMessagein interfaceInputField- Parameters:
constraintMessage- the constrain message field to set
-
getValidCharactersConstraint
- Specified by:
getValidCharactersConstraintin interfaceValidCharactersConstrainable
-
setValidCharactersConstraint
Setter forvalidCharacterConstraint- Specified by:
setValidCharactersConstraintin interfaceInputField- Parameters:
validCharactersConstraint- theValidCharactersConstraintto set
-
getCaseConstraint
- Specified by:
getCaseConstraintin interfaceCaseConstrainable
-
setCaseConstraint
Setter forcaseConstraint- Specified by:
setCaseConstraintin interfaceInputField- Parameters:
caseConstraint- theCaseConstraintto set
-
getDependencyConstraints
List ofPrerequisiteConstraintthat apply to thisInputField- Specified by:
getDependencyConstraintsin interfaceInputField- Returns:
- the dependency constraints for this input field
-
setDependencyConstraints
Setter fordependencyConstraints- Specified by:
setDependencyConstraintsin interfaceInputField- Parameters:
dependencyConstraints- list ofPrerequisiteConstraintto set
-
getPrerequisiteConstraints
- Specified by:
getPrerequisiteConstraintsin interfacePrerequisiteConstrainable
-
getMustOccurConstraints
- Specified by:
getMustOccurConstraintsin interfaceMustOccurConstrainable
-
setMustOccurConstraints
Setter formustOccurConstraints- Specified by:
setMustOccurConstraintsin interfaceInputField- Parameters:
mustOccurConstraints- list ofMustOccurConstraintto set
-
getSimpleConstraint
- Specified by:
getSimpleConstraintin interfaceSimpleConstrainable
-
setSimpleConstraint
Setter for simple constraintWhen a simple constraint is set on this object ALL simple validation constraints set directly will be overridden - recommended to use this or the other gets/sets for defining simple constraints, not both.
- Specified by:
setSimpleConstraintin interfaceInputField- Parameters:
simpleConstraint- the simple constraint to set
-
getDataType
Gets the DataType of this InputField, note that DataType set to be date when this field is using a date picker with a TextControl and has not otherwise been explicitly set.- Specified by:
getDataTypein interfaceInputField- Returns:
- DataType
-
setDataType
This does not have to be set, represents the DataType constraint of this field. This is only checked during server side validation.- Specified by:
setDataTypein interfaceInputField- Parameters:
dataType- the dataType to set
-
setDataType
- Specified by:
setDataTypein interfaceInputField
-
getMaxLength
Maximum number of characters the input field value is allowed to haveThe maximum length determines the maximum allowable length of the value for data entry editing purposes. The maximum length is inclusive and can be smaller or longer than the actual control size. The constraint is enforced on all data types (e.g. a numeric data type needs to meet the maximum length constraint in which digits and symbols are counted).
- Specified by:
getMaxLengthin interfaceInputField- Returns:
- the maximum length of the input field
-
setMaxLength
Setter for input field max length- Specified by:
setMaxLengthin interfaceInputField- Parameters:
maxLength- the maximum length to set
-
getMinLength
Minimum number of characters the input field value needs to beThe minimum length determines the minimum required length of the value for data entry editing purposes. The minimum length is inclusive. The constraint is enforced on all data types (e.g. a numeric data type needs to meet the minimum length requirement in which digits and symbols are counted).
- Specified by:
getMinLengthin interfaceInputField- Returns:
- the minimum length of the input field
-
setMinLength
Setter for input field minimum length- Specified by:
setMinLengthin interfaceInputField- Parameters:
minLength- the minLength to set
-
getRequired
Indicates whether the component is requiredAt the general component level required means there is some action the user needs to take within the component. For example, within a section it might mean the fields within the section should be completed. At a field level, it means the field should be completed. This provides the ability for the renderers to indicate the required action.
- Specified by:
getRequiredin interfaceComponent- Specified by:
getRequiredin interfaceInputField- Overrides:
getRequiredin classComponentBase- Returns:
- boolean true if the component is required, false if it is not required
- See Also:
-
setRequired
Setter for the required indicator- Specified by:
setRequiredin interfaceComponent- Specified by:
setRequiredin interfaceInputField- Overrides:
setRequiredin classComponentBase- Parameters:
required-- See Also:
-
getExclusiveMin
The exclusive minimum value for numeric or date field.The exclusiveMin element determines the minimum allowable value for data entry editing purposes. This constrain is supported for numeric and date fields and to be used in conjunction with the appropriate
ValidCharactersConstraint. For numeric constraint the value can be an integer or decimal such as -.001 or 99.- Specified by:
getExclusiveMinin interfaceInputField- Returns:
- the exclusive minimum numeric value of the input field
-
setExclusiveMin
Setter for the field's exclusive minimum value- Specified by:
setExclusiveMinin interfaceInputField- Parameters:
exclusiveMin- the minimum value to set
-
getInclusiveMax
The inclusive maximum value for numeric or date field.The inclusiveMax element determines the maximum allowable value for data entry editing purposes. This constrain is supported for numeric and date fields and to be used in conjunction with the appropriate
ValidCharactersConstraint. For numeric constraint the value can be an integer or decimal such as -.001 or 99.- Specified by:
getInclusiveMaxin interfaceInputField- Returns:
- the inclusive maximum numeric value of the input field
-
setInclusiveMax
Setter for the field's inclusive maximum value- Specified by:
setInclusiveMaxin interfaceInputField- Parameters:
inclusiveMax- the maximum value to set
-
getAttributeQuery
Attribute query instance configured for this field to dynamically pull information back for updates other fields or providing messagesIf field attribute query is not null, associated event script will be generated to trigger the query from the UI. This will invoke the
AttributeQueryServiceto execute the query and return an instance ofAttributeQueryResultthat is then read by the script to update the UI. Typically used to update informational property values or other field values- Specified by:
getAttributeQueryin interfaceInputField- Returns:
- AttributeQuery instance
-
setAttributeQuery
Setter for this field's attribute query- Specified by:
setAttributeQueryin interfaceInputField- Parameters:
attributeQuery-
-
isUppercaseValue
public boolean isUppercaseValue()Perform uppercase flag for this field to force input to uppercase.It this flag is set to true the 'text-transform' style on the field will be set to 'uppercase' which will automatically change any text input into the field to uppercase.
- Specified by:
isUppercaseValuein interfaceInputField- Returns:
- performUppercase flag
-
setUppercaseValue
public void setUppercaseValue(boolean uppercaseValue) Setter for this field's performUppercase flag- Specified by:
setUppercaseValuein interfaceInputField- Parameters:
uppercaseValue- boolean flag
-
isDisableNativeAutocomplete
public boolean isDisableNativeAutocomplete()Indicates whether the browser autocomplete functionality should be disabled for the input field (adds autocomplete="off")The browser's native autocomplete functionality can cause issues with security fields and also fields with the UIF suggest widget enabled
- Specified by:
isDisableNativeAutocompletein interfaceInputField- Returns:
- true if the native autocomplete should be turned off for the input field, false if not
-
setDisableNativeAutocomplete
public void setDisableNativeAutocomplete(boolean disableNativeAutocomplete) Setter to disable browser autocomplete for the input field- Specified by:
setDisableNativeAutocompletein interfaceInputField- Parameters:
disableNativeAutocomplete-
-
isRenderFieldset
public boolean isRenderFieldset()- Specified by:
isRenderFieldsetin interfaceDataField- Specified by:
isRenderFieldsetin interfaceInputField- Overrides:
isRenderFieldsetin classDataFieldBase
-
completeValidation
Validates different requirements of component compiling a series of reports detailing information on errors found in the component. Used by the RiceDictionaryValidator.- Specified by:
completeValidationin interfaceComponent- Specified by:
completeValidationin interfaceDataField- Specified by:
completeValidationin interfaceInputField- Overrides:
completeValidationin classDataFieldBase- Parameters:
tracer- Record of component's location- See Also:
-
hasAutoQuickfinderRelationship
protected boolean hasAutoQuickfinderRelationship()Determines wheter or not to create an automatic quickfinder widget for this field within the current lifecycle.- Returns:
- True if an automatic quickfinder widget should be created for this field on the current lifecycle.
-