Class AdvancedLookupField
- java.lang.Object
-
- org.zkoss.zk.ui.AbstractComponent
-
- org.zkoss.zk.ui.HtmlBasedComponent
-
- org.zkoss.zul.impl.XulElement
-
- org.zkoss.zul.Box
-
- org.zkoss.zul.Hbox
-
- com.saperion.ngc.iform.field.lookup.AdvancedLookupField
-
- All Implemented Interfaces:
EventChild
,IntelligentField
,LookupField
,Localized
,Identifiable
,java.io.Serializable
,java.lang.Cloneable
,org.zkoss.zk.ui.Component
,org.zkoss.zk.ui.ext.Scope
,org.zkoss.zk.ui.sys.ComponentCtrl
public class AdvancedLookupField extends org.zkoss.zul.Hbox implements IntelligentField, Identifiable, LookupField
A field for lookup-tables that uses a popup to show a query-form for advanced functionality. A AdvancedLookupField contains an internal field that is used to handle entering and displaying of the actual value(s).
Server-scripts on the query-form can obtain a reference to the current instance of this field by retrieving the attributePOPUP_FIELD_ATTRIBUTE
from the form.- See Also:
- Serialized Form
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class org.zkoss.zk.ui.HtmlBasedComponent
org.zkoss.zk.ui.HtmlBasedComponent.ExtraCtrl
-
Nested classes/interfaces inherited from class org.zkoss.zk.ui.AbstractComponent
org.zkoss.zk.ui.AbstractComponent.Children
-
Nested classes/interfaces inherited from interface com.saperion.ngc.iform.field.IntelligentField
IntelligentField.ElementType
-
-
Field Summary
Fields Modifier and Type Field Description static java.lang.String
POPUP_FIELD_ATTRIBUTE
Name of the attribute of the form in the popup that contains this field.-
Fields inherited from interface org.zkoss.zk.ui.Component
APPLICATION_SCOPE, COMPONENT_SCOPE, DESKTOP_SCOPE, PAGE_SCOPE, REQUEST_SCOPE, SESSION_SCOPE, SPACE_SCOPE
-
Fields inherited from interface org.zkoss.zk.ui.sys.ComponentCtrl
AFTER_CHILD_ADDED, AFTER_CHILD_REMOVED, AFTER_PAGE_ATTACHED, AFTER_PAGE_DETACHED, CE_BUSY_IGNORE, CE_DUPLICATE_IGNORE, CE_IMPORTANT, CE_NON_DEFERRABLE, CE_REPEAT_IGNORE
-
Fields inherited from interface com.saperion.ngc.events.EventChild
ALL_EVENTS, ON_ADD_LINK, ON_ADD_LOOKUP, ON_ADD_TO_FAVORITES, ON_AFTER_QUERY, ON_BUTTON, ON_BUTTON_QUERY, ON_CANCEL, ON_CANCEL_AND, ON_CANCEL_EDIT, ON_CHANGE_DOCUMENT_SECURITY, ON_CHANGE_FOLDER_SECURITY, ON_CLEAR, ON_DELETE_SELECTED, ON_DISPLAY_POPUP, ON_DISPLAY_RESULTITEM, ON_DISPLAY_TEMPORARY_DOCUMENT, ON_DOCUMENT_ADDED, ON_DOCUMENT_CHECK, ON_DOCUMENT_FILING, ON_DOCUMENT_LOCKED, ON_DOCUMENT_PROLONG_RETENTION, ON_DOCUMENT_REDUCE_DISPOSITION, ON_DOCUMENT_RELEASE, ON_DOWNLOAD_RESULTITEM, ON_EDIT_CONTENT, ON_EDIT_FOLDER, ON_EDIT_ITEM, ON_EDIT_ITEM_SELECTED, ON_EDIT_LOOKUP, ON_EDIT_SELECTED, ON_EDIT_STRUCTURE, ON_EXPORT, ON_EXTERNAL_STORAGE_UPLOAD, ON_EXTERNAL_STORAGE_UPLOAD_STATUS, ON_FAST_ACCESS_DRAG_OVER, ON_FIELD_CHANGE, ON_FILE_ACTION, ON_FILE_PREVIEW, ON_FILE_SEARCH, ON_FORM_CREATED, ON_FORM_RENDER_ERROR, ON_FORWARD, ON_IGNORE, ON_INDEX, ON_INDEX_CLEAR, ON_INDEX_RESULTITEM, ON_ITEM_DOUBLECLICK, ON_LAUNCH_WORKFLOW, ON_LOG, ON_LOGON, ON_MACRO, ON_NAVIGATION, ON_NAVIGATION_FOLDER, ON_NAVIGATION_FORM, ON_NAVIGATION_WEBPART, ON_NEW_ITEM, ON_NEW_SELECTED, ON_OK, ON_ONEDRIVE_LOGIN, ON_OPEN_INDEX_MASK, ON_OPEN_MASK, ON_OPEN_QUERY_MASK, ON_PASSWORD_EXPIRED, ON_PRINT_DOCUMENTS, ON_QUERY, ON_QUERY_FAVORITE, ON_REFRESH, ON_REFRESH_FOLDER, ON_RESET_GUI, ON_REVISION_CREATED, ON_SAVE_AND, ON_SAVE_DOC, ON_SAVE_FOLDER, ON_SCROLL_NODE, ON_SELECT_TREE_ITEM, ON_SELECTDDC, ON_SEND_MAIL_RESULTITEM, ON_SET_LITIGATION_HOLD, ON_SHAREBASE_DOCUMENT_CHECK, ON_SHAREBASE_LOGIN, ON_START_WORKFLOW, ON_TAB_SELECTED, ON_UNDELETE_SELECTED, ON_UPLOAD_DOCUMENT, ON_UPLOAD_EXTERNAL_STORAGE_DOCUMENT, ON_UPLOAD_SUCCESS, ON_VARIABLES_AVAILABLE, ON_WF, ON_WF_COMMENT_DIALOG_CANCEL, ON_WF_COMMENT_DIALOG_OK, ON_WFCOMMENTS, ON_WFDELEGATE, ON_WFFORWARD, ON_WFFORWARD1, ON_WFFORWARD2, ON_WFFORWARD3, ON_WFFORWARD4, ON_WFFORWARD5, ON_WFHISTORY, ON_WFPUTBACK, ON_WFREMINDER, ON_WFTAKE, ON_WORKFLOW_ACTION, ON_WORKFLOW_COMMENT, ON_WORKFLOW_DISPLAY_COMMENT
-
Fields inherited from interface com.saperion.ngc.iform.field.LookupField
ON_LOOKUP_SELECTED
-
-
Constructor Summary
Constructors Constructor Description AdvancedLookupField()
Constructor to be used when the field is not part of a form.AdvancedLookupField(com.saperion.ngc.iform.xml.EditFieldType field, com.saperion.ngc.iform.xml.PosType panePosition)
Constructor to be used when the field is part of a form.AdvancedLookupField(java.lang.String formName)
Constructor to be used when the field is not part of a form.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
clear()
Clears the value(s) of this field.void
clearErrorMessage()
Removes the validation error message if present.void
clearSelectedRow()
Clears the selected row from the field.void
doChangeValue(org.zkoss.zk.ui.event.Event event)
java.lang.String
generateUUID()
com.saperion.ngc.iform.xml.EditFieldType
getEditField()
Returns the EditFieldType defining the properties of this field.IntelligentField.ElementType
getElementType()
Returns the type of this element.java.util.Set<org.zkoss.zk.ui.Component>
getEventtarget(java.lang.String eventName)
Reads the event target for the given event name, if set or the root element.java.lang.String
getFieldName()
Returns the name of the field.InternalField
getInternalField()
java.lang.String
getLimit()
Returns the limit of this field (upper, lower or both).IntelligentFormView
getParentForm()
Returns the parent form or null if this field is not part of a form.java.lang.String
getPopupFormName()
com.saperion.intf.SaPropertyValue
getPropertyValue()
Returns the current value of the field asSaPropertyValue
.FieldResultBean
getResultBean()
Returns a bean containing the current value, type, name and limit of this field.ResultProperties
getSelectedRow()
Returns the selected row in the lookup table belonging to this lookup field.int
getTabindex()
<T> T
getTypedValue()
Returns the typed value of this AdvancedLookupField.boolean
isChanged()
Returns true if the value of this field was changed.boolean
isContentValid()
Performs a validation and returns true, if the content is valid.boolean
isEmpty()
boolean
isFieldInactive()
Returns the fieldInactive parameter.boolean
isNoLocalize()
Returns the noLocalize parameter.boolean
isReadonly()
gets the readonly state of this field.void
onCancelEdit(org.zkoss.zk.ui.event.Event event)
Event handler for cancel edit event.void
onCreate(org.zkoss.zk.ui.event.Event event)
Event handler forEventChild.ON_FORM_CREATED
event.void
onCtrlKey(org.zkoss.zk.ui.event.Event event)
Event handler forEvents.ON_CTRL_KEY
events.void
onIndexChange(org.zkoss.zk.ui.event.Event event)
Event handler for index changes.void
onIndexClear(org.zkoss.zk.ui.event.Event event)
Event handler for index clear.void
onOK(org.zkoss.zk.ui.event.Event event)
Event handler forEvents.ON_OK
events.void
onPageAttached(org.zkoss.zk.ui.Page newpage, org.zkoss.zk.ui.Page oldpage)
void
onPageDetached(org.zkoss.zk.ui.Page page)
void
onVariablesAvailable(org.zkoss.zk.ui.event.Event event)
Event handler for variablesAvailableEvent.void
setChangedImplicitly()
Sets the changed-property of this field to true.void
setChangedImplicitly(boolean fireChangedEvent)
Sets the changed-property of this field to true.void
setDefaultValue(java.lang.String valueAsString)
Sets the default value.void
setDisabled(boolean disabled)
Sets the disabled state of this field.void
setEventOnOk(ButtonInfo.EventType type)
Starts event handling on enter key.void
setEventtarget(org.zkoss.zk.ui.Component comp, java.lang.String eventName)
Set the event target.void
setFieldInactive(boolean inactive)
Sets the fieldInactive parameter.void
setFieldName(java.lang.String name)
Sets the name of the field.void
setLimit(java.lang.String limit)
Sets the limit type.void
setNoLocalize(boolean noLocalize)
Sets the noLocalize parameter that can be used to disable localization of this component.void
setPopupFormName(java.lang.String popupFormName)
Sets the name of the form to display in the popup.void
setReadonly(boolean readonly)
Sets the readonle state of this field.void
setTabindex(int index)
Sets the tabindex of this field.void
setTypedValue(java.lang.Object value)
Sets the value of this AdvancedLookupField.void
setValue(com.saperion.intf.SaPropertyValue value)
(@inheritDoc)void
setValueImplicitly(com.saperion.intf.SaPropertyValue value)
Sets the value of this field and sets the changed-property of this field to true.void
setValueImplicitly(com.saperion.intf.SaPropertyValue value, boolean fireChangedEvent)
Sets the value of this field and sets the changed-property of this field to true.void
updateAttribute(java.lang.String attr, java.lang.Object value)
Performs a smartUpdate on the specified attribute.void
validate()
Starts validation of the field.-
Methods inherited from class org.zkoss.zul.Box
getAlign, getHeights, getOrient, getPack, getSpacing, getWidths, getZclass, isHorizontal, isSizedByContent, isVertical, renderProperties, setAlign, setHeights, setOrient, setPack, setSizedByContent, setSpacing, setWidths
-
Methods inherited from class org.zkoss.zul.impl.XulElement
clone, getContext, getCtrlKeys, getPopup, getPropertyAccess, getTooltip, setContext, setContext, setContextAttributes, setCtrlKeys, setPopup, setPopup, setPopupAttributes, setTooltip, setTooltip, setTooltipAttributes
-
Methods inherited from class org.zkoss.zk.ui.HtmlBasedComponent
addSclass, focus, getAction, getDraggable, getDroppable, getExtraCtrl, getHeight, getHflex, getLeft, getRenderdefer, getSclass, getStyle, getTabindexInteger, getTooltiptext, getTop, getVflex, getWidth, getZindex, getZIndex, removeSclass, removeSclass, service, setAction, setClass, setDraggable, setDroppable, setFocus, setHeight, setHeight0, setHeightDirectly, setHflex, setHflex0, setHflexDirectly, setLeft, setLeftDirectly, setRenderdefer, setSclass, setStyle, setTabindex, setTooltiptext, setTop, setTopDirectly, setVflex, setVflex0, setVflexDirectly, setWidth, setWidth0, setWidthDirectly, setZclass, setZindex, setZIndex, setZIndexDirectly
-
Methods inherited from class org.zkoss.zk.ui.AbstractComponent
addAnnotation, addAnnotation, addCallback, addClientEvent, addEventHandler, addEventListener, addEventListener, addForward, addForward, addForward, addForward, addMoved, addRedrawCallback, addScopeListener, addShadowRoot, addShadowRootBefore, addSharedEventHandlerMap, appendChild, applyProperties, beforeChildAdded, beforeChildRemoved, beforeParentChanged, detach, didActivate, didActivate, didDeserialize, didDeserialize, disableBindingAnnotation, disableClientUpdate, enableBindingAnnotation, getAnnotatedProperties, getAnnotatedPropertiesBy, getAnnotation, getAnnotation, getAnnotations, getAnnotations, getAnnotations, getAttribute, getAttribute, getAttribute, getAttributeOrFellow, getAttributes, getAttributes, getAuService, getAutag, getCallback, getChildren, getClientAttribute, getClientDataAttribute, getClientEvents, getDefaultMold, getDefinition, getDesktop, getEventHandler, getEventHandlerNames, getEventListenerMap, getEventListeners, getFellow, getFellow, getFellowIfAny, getFellowIfAny, getFellows, getFirstChild, getId, getLastChild, getListenerIterator, getMold, getNextSibling, getPage, getParent, getPreviousSibling, getRedrawCallback, getRoot, getShadowFellowIfAny, getShadowRoots, getShadowVariable, getShadowVariable, getShadowVariable0, getSpaceOwner, getSpecialRendererOutput, getStubonly, getSubBindingAnnotationCount, getTemplate, getTemplateNames, getUuid, getWidgetAttribute, getWidgetAttributeNames, getWidgetClass, getWidgetListener, getWidgetListenerNames, getWidgetOverride, getWidgetOverrideNames, hasAttribute, hasAttribute, hasAttribute, hasAttributeOrFellow, hasBindingAnnotation, hasFellow, hasFellow, hasSubBindingAnnotation, insertBefore, invalidate, isChildable, isInvalidated, isListenerAvailable, isVisible, onChildAdded, onChildRemoved, onWrongValue, query, queryAll, redraw, redrawChildren, removeAttribute, removeAttribute, removeAttribute, removeCallback, removeChild, removeEventListener, removeForward, removeForward, removeRedrawCallback, removeScopeListener, removeShadowRoot, render, render, render, replace, response, response, response, service, sessionDidActivate, sessionWillPassivate, setAttribute, setAttribute, setAttribute, setAuService, setAutag, setClientAttribute, setClientDataAttribute, setDefinition, setDefinition, setId, setMold, setPage, setPageBefore, setParent, setStubonly, setStubonly, setSubBindingAnnotationCount, setTemplate, setVisible, setVisibleDirectly, setWidgetAttribute, setWidgetClass, setWidgetListener, setWidgetOverride, smartUpdate, smartUpdate, smartUpdate, smartUpdate, smartUpdate, smartUpdate, smartUpdate, smartUpdate, smartUpdate, smartUpdateWidgetListener, smartUpdateWidgetOverride, toString, updateByClient, updateSubBindingAnnotationCount, willPassivate, willPassivate, willSerialize, willSerialize
-
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface org.zkoss.zk.ui.Component
addEventListener, addEventListener, addForward, addForward, addForward, addForward, appendChild, applyProperties, clone, detach, getAttribute, getAttribute, getAttributeOrFellow, getAttributes, getAttributes, getAuService, getAutag, getChildren, getClientAttribute, getClientDataAttribute, getDefinition, getDesktop, getEventListeners, getFellow, getFellow, getFellowIfAny, getFellowIfAny, getFellows, getFirstChild, getId, getLastChild, getListenerIterator, getMold, getNextSibling, getPage, getParent, getPreviousSibling, getRoot, getShadowVariable, getShadowVariable, getSpaceOwner, getStubonly, getTemplate, getTemplateNames, getUuid, getWidgetAttribute, getWidgetAttributeNames, getWidgetClass, getWidgetListener, getWidgetListenerNames, getWidgetOverride, getWidgetOverrideNames, hasAttribute, hasAttribute, hasAttributeOrFellow, hasFellow, hasFellow, insertBefore, invalidate, isInvalidated, isListenerAvailable, isVisible, query, queryAll, removeAttribute, removeAttribute, removeChild, removeEventListener, removeForward, removeForward, setAttribute, setAttribute, setAuService, setAutag, setClientAttribute, setClientDataAttribute, setId, setMold, setPage, setPageBefore, setParent, setStubonly, setStubonly, setTemplate, setVisible, setWidgetAttribute, setWidgetClass, setWidgetListener, setWidgetOverride
-
Methods inherited from interface com.saperion.ngc.iform.field.IntelligentField
attachClientScripts, attachScripts, attachServerScripts, detachScripts, focus
-
-
-
-
Field Detail
-
POPUP_FIELD_ATTRIBUTE
public static final java.lang.String POPUP_FIELD_ATTRIBUTE
Name of the attribute of the form in the popup that contains this field.- See Also:
- Constant Field Values
-
-
Constructor Detail
-
AdvancedLookupField
public AdvancedLookupField()
Constructor to be used when the field is not part of a form.
-
AdvancedLookupField
public AdvancedLookupField(java.lang.String formName)
Constructor to be used when the field is not part of a form.- Parameters:
formName
- name of the form to open in the popup
-
AdvancedLookupField
public AdvancedLookupField(com.saperion.ngc.iform.xml.EditFieldType field, com.saperion.ngc.iform.xml.PosType panePosition)
Constructor to be used when the field is part of a form.- Parameters:
field
- field definition from the formpanePosition
- position in the form
-
-
Method Detail
-
getInternalField
public InternalField getInternalField()
- Returns:
- the internal field that is used to enter and display the value(s).
-
setEventtarget
public void setEventtarget(org.zkoss.zk.ui.Component comp, java.lang.String eventName)
Description copied from interface:EventChild
Set the event target.- Specified by:
setEventtarget
in interfaceEventChild
- Parameters:
comp
- Event targeteventName
- Event name or null for main target
-
getEventtarget
public java.util.Set<org.zkoss.zk.ui.Component> getEventtarget(java.lang.String eventName)
Description copied from interface:EventChild
Reads the event target for the given event name, if set or the root element.- Specified by:
getEventtarget
in interfaceEventChild
- Parameters:
eventName
- Event name or null for main target- Returns:
- Set of event targets
-
isNoLocalize
public boolean isNoLocalize()
Description copied from interface:Localized
Returns the noLocalize parameter.- Specified by:
isNoLocalize
in interfaceLocalized
- Returns:
- noLocalize
-
setNoLocalize
public void setNoLocalize(boolean noLocalize)
Description copied from interface:Localized
Sets the noLocalize parameter that can be used to disable localization of this component.- Specified by:
setNoLocalize
in interfaceLocalized
- Parameters:
noLocalize
- value
-
doChangeValue
public void doChangeValue(org.zkoss.zk.ui.event.Event event)
- Specified by:
doChangeValue
in interfaceIntelligentField
- Parameters:
event
- Event
-
getElementType
public IntelligentField.ElementType getElementType()
Description copied from interface:IntelligentField
Returns the type of this element. The type defines the kind of data and control used for this IntelligentField. SeeIntelligentField.ElementType
for a list of types.- Specified by:
getElementType
in interfaceIntelligentField
- Returns:
- Element type
-
getResultBean
public FieldResultBean getResultBean()
Description copied from interface:IntelligentField
Returns a bean containing the current value, type, name and limit of this field.- Specified by:
getResultBean
in interfaceIntelligentField
- Returns:
- Result bean
-
onIndexChange
public void onIndexChange(org.zkoss.zk.ui.event.Event event)
Description copied from interface:IntelligentField
Event handler for index changes.- Specified by:
onIndexChange
in interfaceIntelligentField
- Parameters:
event
- Event
-
onVariablesAvailable
public void onVariablesAvailable(org.zkoss.zk.ui.event.Event event)
Description copied from interface:IntelligentField
Event handler for variablesAvailableEvent. The event-object sent does not contain data. To retrieve variables, useIntelligentFormView.getIndexMaskDocument()
.- Specified by:
onVariablesAvailable
in interfaceIntelligentField
- Parameters:
event
- Event
-
onCancelEdit
public void onCancelEdit(org.zkoss.zk.ui.event.Event event)
Description copied from interface:IntelligentField
Event handler for cancel edit event.- Specified by:
onCancelEdit
in interfaceIntelligentField
- Parameters:
event
- event
-
onCreate
public void onCreate(org.zkoss.zk.ui.event.Event event)
Event handler forEventChild.ON_FORM_CREATED
event.- Parameters:
event
- Create event.
-
onPageAttached
public void onPageAttached(org.zkoss.zk.ui.Page newpage, org.zkoss.zk.ui.Page oldpage)
- Specified by:
onPageAttached
in interfaceorg.zkoss.zk.ui.sys.ComponentCtrl
- Overrides:
onPageAttached
in classorg.zkoss.zk.ui.AbstractComponent
-
onPageDetached
public void onPageDetached(org.zkoss.zk.ui.Page page)
- Specified by:
onPageDetached
in interfaceorg.zkoss.zk.ui.sys.ComponentCtrl
- Overrides:
onPageDetached
in classorg.zkoss.zk.ui.AbstractComponent
- See Also:
AbstractComponent.onPageDetached(org.zkoss.zk.ui.Page)
-
onOK
public void onOK(org.zkoss.zk.ui.event.Event event)
Event handler forEvents.ON_OK
events.- Parameters:
event
- OK event.
-
onCtrlKey
public void onCtrlKey(org.zkoss.zk.ui.event.Event event)
Event handler forEvents.ON_CTRL_KEY
events.- Parameters:
event
- key event
-
setValue
public void setValue(com.saperion.intf.SaPropertyValue value)
(@inheritDoc)- Specified by:
setValue
in interfaceIntelligentField
- Parameters:
value
- value- See Also:
IntelligentField.setValue(SaPropertyValue)
-
getPropertyValue
public com.saperion.intf.SaPropertyValue getPropertyValue()
Description copied from interface:IntelligentField
Returns the current value of the field asSaPropertyValue
.- Specified by:
getPropertyValue
in interfaceIntelligentField
- Returns:
- the field's current value
-
setValueImplicitly
public void setValueImplicitly(com.saperion.intf.SaPropertyValue value)
Description copied from interface:IntelligentField
Sets the value of this field and sets the changed-property of this field to true.- Specified by:
setValueImplicitly
in interfaceIntelligentField
- Parameters:
value
- value
-
setChangedImplicitly
public void setChangedImplicitly()
Description copied from interface:IntelligentField
Sets the changed-property of this field to true.- Specified by:
setChangedImplicitly
in interfaceIntelligentField
-
setValueImplicitly
public void setValueImplicitly(com.saperion.intf.SaPropertyValue value, boolean fireChangedEvent)
Description copied from interface:IntelligentField
Sets the value of this field and sets the changed-property of this field to true.- Specified by:
setValueImplicitly
in interfaceIntelligentField
- Parameters:
value
- valuefireChangedEvent
- if true, aEvents.ON_CHANGE
event will be fired after the value was set
-
setChangedImplicitly
public void setChangedImplicitly(boolean fireChangedEvent)
Description copied from interface:IntelligentField
Sets the changed-property of this field to true.- Specified by:
setChangedImplicitly
in interfaceIntelligentField
- Parameters:
fireChangedEvent
- if true, aEvents.ON_CHANGE
event will be fired
-
onIndexClear
public void onIndexClear(org.zkoss.zk.ui.event.Event event)
Description copied from interface:IntelligentField
Event handler for index clear.- Specified by:
onIndexClear
in interfaceIntelligentField
- Parameters:
event
- Event
-
setEventOnOk
public void setEventOnOk(ButtonInfo.EventType type)
Description copied from interface:IntelligentField
Starts event handling on enter key.- Specified by:
setEventOnOk
in interfaceIntelligentField
- Parameters:
type
- Event type
-
isChanged
public boolean isChanged()
Description copied from interface:IntelligentField
Returns true if the value of this field was changed.- Specified by:
isChanged
in interfaceIntelligentField
- Returns:
- Value is changed.
-
setDisabled
public void setDisabled(boolean disabled)
Description copied from interface:IntelligentField
Sets the disabled state of this field.- Specified by:
setDisabled
in interfaceIntelligentField
- Parameters:
disabled
- Disabled
-
setReadonly
public void setReadonly(boolean readonly)
Description copied from interface:IntelligentField
Sets the readonle state of this field.- Specified by:
setReadonly
in interfaceIntelligentField
- Parameters:
readonly
- readonly
-
isReadonly
public boolean isReadonly()
gets the readonly state of this field.- Specified by:
isReadonly
in interfaceIntelligentField
- See Also:
InputElement.setReadonly(boolean)
-
isContentValid
public boolean isContentValid()
Description copied from interface:IntelligentField
Performs a validation and returns true, if the content is valid.- Specified by:
isContentValid
in interfaceIntelligentField
- Returns:
- Field content is valid.
-
getFieldName
public java.lang.String getFieldName()
Description copied from interface:IntelligentField
Returns the name of the field.- Specified by:
getFieldName
in interfaceIntelligentField
- Returns:
- Field name
-
getLimit
public java.lang.String getLimit()
Description copied from interface:IntelligentField
Returns the limit of this field (upper, lower or both).- Specified by:
getLimit
in interfaceIntelligentField
- Returns:
- limit
-
setLimit
public void setLimit(java.lang.String limit)
Description copied from interface:IntelligentField
Sets the limit type. Possible values are: 'lower', 'upper', 'both'.- Specified by:
setLimit
in interfaceIntelligentField
- Parameters:
limit
- Limit type
-
getEditField
public com.saperion.ngc.iform.xml.EditFieldType getEditField()
Description copied from interface:IntelligentField
Returns the EditFieldType defining the properties of this field.- Specified by:
getEditField
in interfaceIntelligentField
- Returns:
- the edit field
-
setDefaultValue
public void setDefaultValue(java.lang.String valueAsString)
Description copied from interface:IntelligentField
Sets the default value.- Specified by:
setDefaultValue
in interfaceIntelligentField
- Parameters:
valueAsString
- string representation of value
-
setFieldInactive
public void setFieldInactive(boolean inactive)
Description copied from interface:IntelligentField
Sets the fieldInactive parameter. Same assetReadonly(inactive)
.- Specified by:
setFieldInactive
in interfaceIntelligentField
- Parameters:
inactive
- value
-
isFieldInactive
public boolean isFieldInactive()
Description copied from interface:IntelligentField
Returns the fieldInactive parameter.- Specified by:
isFieldInactive
in interfaceIntelligentField
- Returns:
- fieldInactive
-
setFieldName
public void setFieldName(java.lang.String name)
Description copied from interface:IntelligentField
Sets the name of the field. The name is required to be the same as in the database table representing the DDC used.- Specified by:
setFieldName
in interfaceIntelligentField
- Parameters:
name
- field name
-
validate
public void validate()
Description copied from interface:IntelligentField
Starts validation of the field.- Specified by:
validate
in interfaceIntelligentField
-
clearErrorMessage
public void clearErrorMessage()
Description copied from interface:IntelligentField
Removes the validation error message if present.- Specified by:
clearErrorMessage
in interfaceIntelligentField
-
getParentForm
public IntelligentFormView getParentForm()
Description copied from interface:IntelligentField
Returns the parent form or null if this field is not part of a form.- Specified by:
getParentForm
in interfaceIntelligentField
- Returns:
- parent form or null
-
updateAttribute
public void updateAttribute(java.lang.String attr, java.lang.Object value)
Description copied from interface:IntelligentField
Performs a smartUpdate on the specified attribute.- Specified by:
updateAttribute
in interfaceIntelligentField
- Parameters:
attr
- attribute namevalue
- attribute value
-
isEmpty
public boolean isEmpty()
- Specified by:
isEmpty
in interfaceIntelligentField
- Returns:
- true if the field's value is empty.
-
getTypedValue
public <T> T getTypedValue()
Returns the typed value of this AdvancedLookupField. This method throws aClassCastException
when the field's value cannot be converted to the specified type. If the field contains no value, this method returns null.
If this is a non-empty multivalue-field, this method will return aList
<T>
.
To get the type of values stored in this field, use the utility-methods inFieldUtil
.- Type Parameters:
T
- generic type parameter- Returns:
- the field's value as instance of type
-
setTypedValue
public void setTypedValue(java.lang.Object value)
Sets the value of this AdvancedLookupField. If the specified value parameter's type cannot be used by this field, an IllegalArgumentException is thrown. If the specified value is null, the field is cleared.
Multivalue-fields accept aCollection
of typed values.- Parameters:
value
- value to set
-
setTabindex
public void setTabindex(int index)
Description copied from interface:IntelligentField
Sets the tabindex of this field.- Specified by:
setTabindex
in interfaceIntelligentField
- Overrides:
setTabindex
in classorg.zkoss.zk.ui.HtmlBasedComponent
- Parameters:
index
- tab index
-
getTabindex
public int getTabindex()
- Specified by:
getTabindex
in interfaceIntelligentField
- Overrides:
getTabindex
in classorg.zkoss.zk.ui.HtmlBasedComponent
- Returns:
- the tabindex of this field.
-
generateUUID
public java.lang.String generateUUID()
- Specified by:
generateUUID
in interfaceIdentifiable
- Returns:
- the generated uuid for the DOM tree
-
getSelectedRow
public ResultProperties getSelectedRow()
Description copied from interface:LookupField
Returns the selected row in the lookup table belonging to this lookup field.- Specified by:
getSelectedRow
in interfaceLookupField
- Returns:
ResultProperties
containing the selected row or null, if no row was selected so far
-
clearSelectedRow
public void clearSelectedRow()
Description copied from interface:LookupField
Clears the selected row from the field. The lookup table will not be changed.- Specified by:
clearSelectedRow
in interfaceLookupField
-
clear
public void clear()
Description copied from interface:IntelligentField
Clears the value(s) of this field.- Specified by:
clear
in interfaceIntelligentField
-
getPopupFormName
public java.lang.String getPopupFormName()
- Returns:
- the name of the form that will be displayed in the popup
-
setPopupFormName
public void setPopupFormName(java.lang.String popupFormName)
Sets the name of the form to display in the popup.- Parameters:
popupFormName
- name of the form to display
-
-