public class ERXJSToManyRelationshipEditor extends ERXNonSynchronizingComponent
Name | Description |
---|---|
displayString | for the items in the menu, this should be a keyPath that will be resolved from each item to produce the display string for the item. |
item | to use as an iteration variable |
list | of items to display; equivalent to the possible values from which a user might choose |
selections | items from the list that are selected. The resulting selections will be pushed back into the
parent component's variable that is bound to the selections binding. |
sortKey | (optional) to use in order to produce a sorted menu |
Modifier and Type | Class and Description |
---|---|
static interface |
ERXJSToManyRelationshipEditor.Keys |
WOComponent._EventLoggingEnabler, WOComponent.Event
NSKeyValueCodingAdditions.DefaultImplementation, NSKeyValueCodingAdditions.Utility
NSKeyValueCoding._BooleanFieldBinding, NSKeyValueCoding._BooleanMethodBinding, NSKeyValueCoding._FieldBinding, NSKeyValueCoding._ForwardingBinding, NSKeyValueCoding._KeyBinding, NSKeyValueCoding._KeyBindingCreation, NSKeyValueCoding._MethodBinding, NSKeyValueCoding._NumberFieldBinding, NSKeyValueCoding._NumberMethodBinding, NSKeyValueCoding._ReflectionKeyBindingCreation, NSKeyValueCoding.ErrorHandling, NSKeyValueCoding.MapImplementation, NSKeyValueCoding.Null<T>, NSKeyValueCoding.UnknownKeyException, NSKeyValueCoding.ValueAccessor
NSValidation._MethodBinding, NSValidation._ValidationBinding, NSValidation.DefaultImplementation, NSValidation.Utility, NSValidation.ValidationException
Modifier and Type | Field and Description |
---|---|
protected NSArray |
_list |
protected NSArray |
_selections |
protected Object |
currentItem |
_dynamicBindings
_Extension, _IsEventLoggingEnabled, _keyAssociations
_CLASS
_CLASS, _KeyPathSeparatorChar, KeyPathSeparator
NullValue
_CLASS
Constructor and Description |
---|
ERXJSToManyRelationshipEditor(WOContext context) |
Modifier and Type | Method and Description |
---|---|
String |
addItemScript()
Builds the JavaScript used to add the selected item from the selections popup to the selected items.
|
void |
appendToResponse(WOResponse aResponse,
WOContext aContext)
Calls
ERXNonSynchronizingComponent.resetCachedBindingsInStatefulComponent() prior to super.appendToResponse. |
String |
availableValuesPopupMenu()
Builds the select menu for adding available items to the selected items.
|
Object |
currentItem()
Gets the item currently being displayed.
|
String |
displayString()
Gets the display string for the current item.
|
String |
editorContextID()
Gets the context ID of the editor (this component), escaped for use in JavaScript.
|
String |
editorName()
Formats the name of this editor instance.
|
String |
hiddenFieldName()
Formats the name of the hidden field for this editor instance.
|
void |
invalidateCaches()
Resets the state variables.
|
boolean |
isListEmpty()
Determines if the list is empty
|
boolean |
isStateless() |
int |
itemIndex()
Gets the index of the current item in the overall list.
|
String |
javascriptForThisEditorInstance()
Formats the JavaScript used to initialize this instance of the editor.
|
NSArray |
list()
Gets the list of items to display.
|
NSArray |
maybeSortedList()
Gets the list of items and sorts it by the sort key if a sort key is available.
|
String |
removeItemScript()
Builds the JavaScript used to remove the item from the selections.
|
void |
reset()
このメソッドは、指定されているコンテクストのオブジェクトに対する、
ステートレス・コンポーネントの一時的リファレンスをリセットもしくは削除します。
あるコンポーネントの共有化されたインスタンスが、他のセッションによって再利用されるとき、
このメソッドを利用し、各コンポーネントのインスタンス変数を解放します。
|
String |
selectedValuesTableName()
Formats the name of the selected values table for this editor instance.
|
NSArray |
selections()
Gets the selections.
|
String |
selectionsString()
Formats the selection string for the hidden field from the indexes of the items in the selection subset of the list.
|
void |
setCurrentItem(Object anItem)
Sets the item being displayed.
|
void |
setSelectionsString(String value)
Sets the selection string from the input.
|
void |
sleep() |
invokeAction, resetCachedBindingsInStatefulComponent, synchronizesVariablesWithBindings, takeValuesFromRequest
_awakeInContext, _checkAccess, _frameworkName, _includeCSSResources, _includeJavascriptResources, additionalCSSFiles, additionalJavascriptFiles, arrayValueForBinding, arrayValueForBinding, booleanValueForBinding, booleanValueForBinding, booleanValueForBinding, browser, checkAccess, clickToOpenEnabled, componentName, defaultCSSPath, defaultJavascriptPath, dynamicBindings, floatValueForBinding, intValueForBinding, isPageAccessAllowed, localizer, objectValueForBinding, objectValueForBinding, pageWithName, postAppendToResponse, preAppendToResponse, primaryCSSFile, primaryJavascriptFile, shouldCheckAccess, stringValueForBinding, stringValueForBinding, useDefaultComponentCSS, useDefaultComponentJavascript
__valueForBinding, _associationWithName, _childTemplate, _cleanUpStatelessComponent, _componentDefinition, _componentUnroll, _isPage, _setContext, _setIsPage, _setParent, _setSubcomponent, _sleepInContext, _subcomponentForElementWithID, _templateNameForClass, _unroll, application, awake, baseURL, bindingKeys, canAccessFieldsDirectly, canGetValueForBinding, canSetValueForBinding, clone, context, debugString, descriptionForResponse, ensureAwakeInContext, frameworkName, generateResponse, handleQueryWithUnboundKey, handleTakeValueForUnboundKey, hasBinding, hasSession, isCachingEnabled, isEventLoggingEnabled, logString, name, pageWithName, parent, path, pathURL, performParentAction, pullValuesFromParent, pushValuesToParent, session, set_componentUnroll, set_unroll, setCachingEnabled, setValueForBinding, setVariableValueForName, takeValueForKey, takeValueForKeyPath, template, templateWithHTMLString, templateWithHTMLString, templateWithHTMLString, templateWithName, toString, unableToSetNullForKey, validateTakeValueForKeyPath, validateValueForKey, validationFailedWithException, valueForBinding, valueForBooleanBinding, valueForIntegerBinding, valueForKey, valueForKeyPath, valueForNSArrayBindings, valueForNSDictionaryBindings, valueForNumberBinding, valueForStringBinding, variableValueForName, variableWithName
protected NSArray _list
protected NSArray _selections
protected Object currentItem
public ERXJSToManyRelationshipEditor(WOContext context)
public boolean isStateless()
isStateless
in class WOComponent
public void reset()
ERXComponent
reset
in class ERXComponent
public Object currentItem()
public void setCurrentItem(Object anItem)
anItem
- to displaypublic NSArray list()
public NSArray selections()
public String displayString()
public void invalidateCaches()
public void sleep()
sleep
in class WOComponent
public void appendToResponse(WOResponse aResponse, WOContext aContext)
ERXNonSynchronizingComponent
ERXNonSynchronizingComponent.resetCachedBindingsInStatefulComponent()
prior to super.appendToResponse.appendToResponse
in class ERXNonSynchronizingComponent
aResponse
- to which we are appendingaContext
- context of the responsepublic NSArray maybeSortedList()
public boolean isListEmpty()
public int itemIndex()
public String selectionsString()
public void setSelectionsString(String value)
value
- of the selections stringpublic String editorContextID()
public String editorName()
public String hiddenFieldName()
public String selectedValuesTableName()
public String javascriptForThisEditorInstance()
public String removeItemScript()
public String addItemScript()
public String availableValuesPopupMenu()
Copyright © 2002 – 2024 Project Wonder.