November Happy Hour will be moved to Thursday December 5th.

epi-cms/contentediting/editors/CollectionEditor

Location

epi-cms/contentediting/editors/CollectionEditor

Extends

Properties

templateString

The widget's template.

multiple

Indicates that the widget's value is array-like.

baseClass

The widget's base css class.

value

The widget's value.

model

The widget's model.

itemType

The collection item type on the server. This is used to retrieve item metadata.

generateColumns

excludedColumns

List of columns those are excluded from generated columns

includedColumns

List of columns which are configured to assemble the grid.

gridSettings

The grid settings.

itemModelType

Item Model constructor. Default is epi-cms/contentediting/editors/model/CollectionEditorItemModel.

useFullWidth

Specifies that this widget should be rendered in full width.

_noDataMessage

_currentProviderHandler

id

A unique, opaque ID string that can be assigned by users or by the system. If the developer passes an ID which is known not to be unique, the specified ID is ignored and the system-generated ID is used instead.

_setIdAttr

lang

Rarely used. Overrides the default Dojo locale used to render this widget, as defined by the HTML LANG attribute. Value must be among the list of locales specified during by the Dojo bootstrap, formatted according to RFC 3066 (like en-us).

_setLangAttr

dir

Bi-directional support, as defined by the HTML DIR attribute. Either left-to-right "ltr" or right-to-left "rtl". If undefined, widgets renders in page's default direction.

_setDirAttr

textDir

Bi-directional support, the main variable which is responsible for the direction of the text. The text direction can be different than the GUI direction by using this parameter in creation of a widget.

Allowed values:

  1. "ltr"
  2. "rtl"
  3. "auto" - contextual the direction of a text defined by first strong letter.

By default is as the page direction.

class

_setClassAttr

style

HTML style attributes as cssText string or name/value hash

title

HTML title attribute.

For form widgets this specifies a tooltip to display when hovering over the widget (just like the native HTML title attribute).

For TitlePane or for when this widget is a child of a TabContainer, AccordionContainer, etc., it's used to specify the tab label, accordion pane title, etc.

tooltip

When this widget's title attribute is used to for a tab label, accordion pane title, etc., this specifies the tooltip to appear when the mouse is hovered over that text.

srcNodeRef

pointer to original DOM node

domNode

This is our visible representation of the widget! Other DOM Nodes may by assigned to other properties, usually through the template system's data-dojo-attach-point syntax, but the domNode property is the canonical "top level" node in widget UI.

containerNode

Designates where children of the source DOM node will be placed. "Children" in this case refers to both DOM nodes and widgets. For example, for myWidget:

<div data-dojo-type=myWidget>
    <b> here's a plain DOM node
    <span data-dojo-type=subWidget>and a widget</span>
    <i> and another plain DOM node </i>
</div>

containerNode would point to:

<b> here's a plain DOM node
<span data-dojo-type=subWidget>and a widget</span>
<i> and another plain DOM node </i>

In templated widgets, "containerNode" is set via a data-dojo-attach-point assignment.

containerNode must be defined for any widget that accepts innerHTML (like ContentPane or BorderContainer or even Button), and conversely is null for widgets that don't, like TextBox.

ownerDocument

The document this widget belongs to. If not specified to constructor, will default to srcNodeRef.ownerDocument, or if no sourceRef specified, then to dojo/_base/window::doc

_started

startup() has completed.

attributeMap

Deprecated. Instead of attributeMap, widget should have a _setXXXAttr attribute for each XXX attribute to be mapped to the DOM.

attributeMap sets up a "binding" between attributes (aka properties) of the widget and the widget's DOM. Changes to widget attributes listed in attributeMap will be reflected into the DOM.

For example, calling set('title', 'hello') on a TitlePane will automatically cause the TitlePane's DOM to update with the new title.

attributeMap is a hash where the key is an attribute of the widget, and the value reflects a binding to a:

  • DOM node attribute

    focus: {node: "focusNode", type: "attribute"} Maps this.focus to this.focusNode.focus

  • DOM node innerHTML

    title: { node: "titleNode", type: "innerHTML" } Maps this.title to this.titleNode.innerHTML

  • DOM node innerText

    title: { node: "titleNode", type: "innerText" } Maps this.title to this.titleNode.innerText

  • DOM node CSS class

    myClass: { node: "domNode", type: "class" } Maps this.myClass to this.domNode.className

If the value is an array, then each element in the array matches one of the formats of the above list.

There are also some shorthands for backwards compatibility:

  • string --> { node: string, type: "attribute" }, for example:
"focusNode" ---> { node: "focusNode", type: "attribute" }
  • "" --> { node: "domNode", type: "attribute" }

_blankGif

Path to a blank 1x1 image. Used by <img> nodes in templates that really get their image via CSS background-image.

_attrPairNames

focused

This widget or a widget it contains has focus, or is "active" because it was recently clicked.

_focusManager

dndType

Defines a type of widget.

templatePath

Path to template (HTML file) for this widget relative to dojo.baseUrl. Deprecated: use templateString with require([... "dojo/text!..."], ...) instead

_skipNodeCache

_earlyTemplatedStartup

A fallback to preserve the 1.0 - 1.3 behavior of children in templates having their startup called before the parent widget fires postCreate. Defaults to 'false', causing child widgets to have their .startup() called immediately before a parent widget .startup(), but always after the parent .postCreate(). Set to 'true' to re-enable to previous, arguably broken, behavior.

_attachPoints

List of widget attribute names associated with data-dojo-attach-point=... in the template, ex: ["containerNode", "labelNode"]

_attachEvents

List of connections associated with data-dojo-attach-event=... in the template

modelBindingMap

The binding map. Each key in the map must be an observable property in the model and each item in the map is a list of widget properties.

_ownedByKey

The owned handles

_itemEditor

_dialog

dialogParams

_editingItemIndex

required

User is required to enter data into this field.

missingMessage

Message which is displayed when required is true and value is empty.

_valueValidationTooltip

The validation tooltip.

cssStateNodes

List of sub-nodes within the widget that need CSS classes applied on mouse hover/press and focus

Each entry in the hash is a an attachpoint names (like "upArrowButton") mapped to a CSS class names (like "dijitUpArrowButton"). Example:

{
    "upArrowButton": "dijitUpArrowButton",
    "downArrowButton": "dijitDownArrowButton"
}

The above will set the CSS class dijitUpArrowButton to the this.upArrowButton DOMNode when it

is hovered, etc.

hovering

True if cursor is over this widget

active

True if mouse was pressed while over this widget, and hasn't been released yet

isShowingChildDialog

Indicates whether a child dialog window is currently being displayed.

_openedChildDialog

A reference to the currently open child dialog

_waitingForFocus

A flag indicating that the child dialog has been closed and we're waiting for a focus on this widget


Methods

protected method modelType()

The widget's model class. By default it is epi-cms/contentediting/editors/model/CollectionEditorModel

protected method gridType()

The grid class. By default it is OnDemandGrid with Formatter, Selection, Keyboard, and DnD supports.

protected method gridAssemblerType()

The grid assembler class.

protected method itemEditorType()

The item editor class. By default, it is FormContainer

protected method postMixInProperties()

Post mix in properties initialization.

protected method postCreate()

Post create initialization.

protected method onChange(value)

Triggered when the widget's value changes.

Parameters
Name Summary Type Usage
value undefined required

protected method _setValueAttr(value)

Value setter.

Parameters
Name Summary Type Usage
value undefined required

protected method _dndNodeCreator(item, hint)

Custom DnD avatar creator method

Parameters
Name Summary Type Usage
item Object required
hint Object required

protected method _setupGrid()

Set up the grid.

protected method _setupDnD()

Set up the dnd on the grid.

protected method onDndDrop(dndData, source, nodes, copy)

Parameters
Name Summary Type Usage
dndData undefined required
source undefined required
nodes undefined required
copy undefined required

protected method _addItem(item)

Parameters
Name Summary Type Usage
item undefined required

protected method _dndGetItemData(item)

Parameters
Name Summary Type Usage
item undefined required

protected method _getGridDefinition()

Returns grid's columns definition.

protected method _onGridRowSelect(e)

Makes sure the right commands are available in the context menu when selecting a row in the grid.

Parameters
Name Summary Type Usage
e undefined required

protected method onGridRowClick(e)

Makes sure the right commands are available in the context menu when selecting a row in the grid.

Parameters
Name Summary Type Usage
e undefined required

protected method onGridRowDblClick(e)

Makes sure the right commands are available in the context menu when selecting a row in the grid.

Parameters
Name Summary Type Usage
e undefined required

protected method _getDialogConfirmActionText()

protected method onExecuteDialog()

protected method _onCancelDialog()

Blur widget to force stop editing the EditingWrapper

protected method _onItemsChanged(items)

The model's itemsChanged event handler.

Parameters
Name Summary Type Usage
items

The items list (Note that it is an item model instance, not the raw data item).

Array required

protected method _renderNoDataMessage()

protected method onClick(event)

Connect to this function to receive notifications of mouse click events.

Parameters
Name Summary Type Usage
event

mouse Event

undefined required

protected method onDblClick(event)

Connect to this function to receive notifications of mouse double click events.

Parameters
Name Summary Type Usage
event

mouse Event

undefined required

protected method onKeyDown(event)

Connect to this function to receive notifications of keys being pressed down.

Parameters
Name Summary Type Usage
event

key Event

undefined required

protected method onKeyPress(event)

Connect to this function to receive notifications of printable keys being typed.

Parameters
Name Summary Type Usage
event

key Event

undefined required

protected method onKeyUp(event)

Connect to this function to receive notifications of keys being released.

Parameters
Name Summary Type Usage
event

key Event

undefined required

protected method onMouseDown(event)

Connect to this function to receive notifications of when the mouse button is pressed down.

Parameters
Name Summary Type Usage
event

mouse Event

undefined required

protected method onMouseMove(event)

Connect to this function to receive notifications of when the mouse moves over nodes contained within this widget.

Parameters
Name Summary Type Usage
event

mouse Event

undefined required

protected method onMouseOut(event)

Connect to this function to receive notifications of when the mouse moves off of nodes contained within this widget.

Parameters
Name Summary Type Usage
event

mouse Event

undefined required

protected method onMouseOver(event)

Connect to this function to receive notifications of when the mouse moves onto nodes contained within this widget.

Parameters
Name Summary Type Usage
event

mouse Event

undefined required

protected method onMouseLeave(event)

Connect to this function to receive notifications of when the mouse moves off of this widget.

Parameters
Name Summary Type Usage
event

mouse Event

undefined required

protected method onMouseEnter(event)

Connect to this function to receive notifications of when the mouse moves onto this widget.

Parameters
Name Summary Type Usage
event

mouse Event

undefined required

protected method onMouseUp(event)

Connect to this function to receive notifications of when the mouse button is released.

Parameters
Name Summary Type Usage
event

mouse Event

undefined required

protected method constructor(params, srcNodeRef)

Create the widget.

Parameters
Name Summary Type Usage
params

Hash of initialization parameters for widget, including scalar values (like title, duration etc.) and functions, typically callbacks like onClick. The hash can contain any of the widget's properties, excluding read-only properties.

Object|null required
srcNodeRef

If a srcNodeRef (DOM node) is specified:

  • use srcNodeRef.innerHTML as my contents
  • if this is a behavioral widget then apply behavior to that srcNodeRef
  • otherwise, replace srcNodeRef with my generated DOM tree
DOMNode|String optional

protected method on(type, func)

Parameters
Name Summary Type Usage
type String|Function required
func Function required

protected method _setFocusedAttr(val)

Parameters
Name Summary Type Usage
val undefined required

protected method setAttribute(attr, value)

Deprecated. Use set() instead.

Parameters
Name Summary Type Usage
attr String required
value anything required

protected method attr(name, value)

Set or get properties on a widget instance.

Parameters
Name Summary Type Usage
name

The property to get or set. If an object is passed here and not a string, its keys are used as names of attributes to be set and the value of the object as values to set in the widget.

String|Object required
value

Optional. If provided, attr() operates as a setter. If omitted, the current value of the named property is returned.

Object optional

protected method getDescendants()

Returns all the widgets contained by this, i.e., all widgets underneath this.containerNode. This method should generally be avoided as it returns widgets declared in templates, which are supposed to be internal/hidden, but it's left here for back-compat reasons.

protected method _onShow()

Internal method called when this widget is made visible. See onShow for details.

protected method onShow()

Called when this widget becomes the selected pane in a dijit/layout/TabContainer, dijit/layout/StackContainer, dijit/layout/AccordionContainer, etc.

Also called to indicate display of a dijit.Dialog, dijit.TooltipDialog, or dijit.TitlePane.

protected method onHide()

Called when another widget becomes the selected pane in a dijit/layout/TabContainer, dijit/layout/StackContainer, dijit/layout/AccordionContainer, etc.

Also called to indicate hide of a dijit.Dialog, dijit.TooltipDialog, or dijit.TitlePane.

protected method onClose()

Called when this widget is being displayed as a popup (ex: a Calendar popped up from a DateTextBox), and it is hidden. This is called from the dijit.popup code, and should not be called directly.

Also used as a parameter for children of dijit/layout/StackContainer or subclasses. Callback if a user tries to close the child. Child will be closed if this function returns true.

protected method _setOwnerDocumentAttr(val)

Parameters
Name Summary Type Usage
val undefined required

protected method postscript(params, srcNodeRef)

Kicks off widget instantiation. See create() for details.

Parameters
Name Summary Type Usage
params Object optional
srcNodeRef DomNode|String required

protected method create(params, srcNodeRef)

Kick off the life-cycle of a widget

Parameters
Name Summary Type Usage
params

Hash of initialization parameters for widget, including scalar values (like title, duration etc.) and functions, typically callbacks like onClick. The hash can contain any of the widget's properties, excluding read-only properties.

Object|null required
srcNodeRef

If a srcNodeRef (DOM node) is specified:

  • use srcNodeRef.innerHTML as my contents
  • if this is a behavioral widget then apply behavior to that srcNodeRef
  • otherwise, replace srcNodeRef with my generated DOM tree
DOMNode|String optional

protected method _applyAttributes()

Step during widget creation to copy widget attributes to the DOM according to attributeMap and _setXXXAttr objects, and also to call custom _setXXXAttr() methods.

Skips over blank/false attribute values, unless they were explicitly specified as parameters to the widget, since those are the default anyway, and setting tabIndex="" is different than not setting tabIndex at all.

For backwards-compatibility reasons attributeMap overrides _setXXXAttr when _setXXXAttr is a hash/string/array, but _setXXXAttr as a functions override attributeMap.

protected method buildRendering()

Construct the UI for this widget, setting this.domNode. Most widgets will mixin dijit._TemplatedMixin, which implements this method.

protected method startup()

Processing after the DOM fragment is added to the document

protected method destroyRecursive(preserveDom)

Destroy this widget and its descendants

Parameters
Name Summary Type Usage
preserveDom

If true, this method will leave the original DOM structure alone of descendant Widgets. Note: This will NOT work with dijit._Templated widgets.

Boolean optional

protected method destroy(preserveDom)

Destroy this widget, but not its descendants. This method will, however, destroy internal widgets such as those used within a template.

Parameters
Name Summary Type Usage
preserveDom

If true, this method will leave the original DOM structure alone. Note: This will not yet work with _Templated widgets

Boolean required

protected method destroyRendering(preserveDom)

Destroys the DOM nodes associated with this widget

Parameters
Name Summary Type Usage
preserveDom

If true, this method will leave the original DOM structure alone during tear-down. Note: this will not work with _Templated widgets yet.

Boolean optional

protected method destroyDescendants(preserveDom)

Recursively destroy the children of this widget and their descendants.

Parameters
Name Summary Type Usage
preserveDom

If true, the preserveDom attribute is passed to all descendant widget's .destroy() method. Not for use with _Templated widgets.

Boolean optional

protected method uninitialize()

Deprecated. Override destroy() instead to implement custom widget tear-down behavior.

protected method _setStyleAttr(value)

Sets the style attribute of the widget according to value, which is either a hash like {height: "5px", width: "3px"} or a plain string

Parameters
Name Summary Type Usage
value String||Object required

protected method _attrToDom(attr, value, commands)

Reflect a widget attribute (title, tabIndex, duration etc.) to the widget DOM, as specified by commands parameter. If commands isn't specified then it's looked up from attributeMap. Note some attributes like "type" cannot be processed this way as they are not mutable.

Parameters
Name Summary Type Usage
attr

Name of member variable (ex: "focusNode" maps to this.focusNode) pointing to DOMNode inside the widget, or alternately pointing to a subwidget

String required
value String required
commands Object optional

protected method get(name)

Get a property from a widget.

Parameters
Name Summary Type Usage
name

The property to get.

undefined required

protected method set(name, value)

Set a property on a widget

Parameters
Name Summary Type Usage
name

The property to set.

undefined required
value

The value to set in the property.

undefined required

protected method _getAttrNames(name)

Helper function for get() and set(). Caches attribute name values so we don't do the string ops every time.

Parameters
Name Summary Type Usage
name undefined required

protected method _set(name, value)

Helper function to set new value for specified attribute, and call handlers registered with watch() if the value has changed.

Parameters
Name Summary Type Usage
name String required
value anything required

protected method emit(type, eventObj, callbackArgs)

Used by widgets to signal that a synthetic event occurred, ex:

myWidget.emit("attrmodified-selectedChildWidget", {}).

Emits an event on this.domNode named type.toLowerCase(), based on eventObj. Also calls onType() method, if present, and returns value from that method. By default passes eventObj to callback, but will pass callbackArgs instead, if specified. Modifies eventObj by adding missing parameters (bubbles, cancelable, widget).

Parameters
Name Summary Type Usage
type String required
eventObj Object optional
callbackArgs Array optional

protected method _onMap(type)

Maps on() type parameter (ex: "mousemove") to method name (ex: "onMouseMove"). If type is a synthetic event like touch.press then returns undefined.

Parameters
Name Summary Type Usage
type String|Function required

protected method toString()

Returns a string that represents the widget

protected method getChildren()

Returns all the widgets contained by this, i.e., all widgets underneath this.containerNode. Does not return nested widgets, nor widgets that are part of this widget's template.

protected method getParent()

Returns the parent widget of this widget

protected method connect(obj, event, method)

Deprecated, will be removed in 2.0, use this.own(on(...)) or this.own(aspect.after(...)) instead.

Connects specified obj/event to specified method of this object and registers for disconnect() on widget destroy.

Provide widget-specific analog to dojo.connect, except with the implicit use of this widget as the target object. Events connected with this.connect are disconnected upon destruction.

Parameters
Name Summary Type Usage
obj Object|null required
event String|Function required
method String|Function required

Examples

var btn = new Button();
// when foo.bar() is called, call the listener we're going to
// provide in the scope of btn
btn.connect(foo, "bar", function(){
    console.debug(this.toString());
});

protected method disconnect(handle)

Deprecated, will be removed in 2.0, use handle.remove() instead.

Disconnects handle created by connect.

Parameters
Name Summary Type Usage
handle undefined required

protected method subscribe(t, method)

Deprecated, will be removed in 2.0, use this.own(topic.subscribe()) instead.

Subscribes to the specified topic and calls the specified method of this object and registers for unsubscribe() on widget destroy.

Provide widget-specific analog to dojo.subscribe, except with the implicit use of this widget as the target object.

Parameters
Name Summary Type Usage
t

The topic

String required
method

The callback

Function required

Examples

var btn = new Button();
// when /my/topic is published, this button changes its label to
// be the parameter of the topic.
btn.subscribe("/my/topic", function(v){
    this.set("label", v);
});

protected method unsubscribe(handle)

Deprecated, will be removed in 2.0, use handle.remove() instead.

Unsubscribes handle created by this.subscribe. Also removes handle from this widget's list of subscriptions

Parameters
Name Summary Type Usage
handle Object required

protected method isLeftToRight()

Return this widget's explicit or implicit orientation (true for LTR, false for RTL)

protected method isFocusable()

Return true if this widget can currently be focused and false if not

protected method placeAt(reference, position)

Place this widget somewhere in the DOM based on standard domConstruct.place() conventions.

Parameters
Name Summary Type Usage
reference

Widget, DOMNode, or id of widget or DOMNode

String|DomNode|_Widget required
position

If reference is a widget (or id of widget), and that widget has an ".addChild" method, it will be called passing this widget instance into that method, supplying the optional position index passed. In this case position (if specified) should be an integer.

If reference is a DOMNode (or id matching a DOMNode but not a widget), the position argument can be a numeric index or a string "first", "last", "before", or "after", same as dojo/dom-construct::place().

String|Int optional

Examples

// create a Button with no srcNodeRef, and place it in the body:
var button = new Button({ label:"click" }).placeAt(win.body());
// now, 'button' is still the widget reference to the newly created button
button.on("click", function(e){ console.log('click'); }));
// create a button out of a node with id="src" and append it to id="wrapper":
var button = new Button({},"src").placeAt("wrapper");
// place a new button as the first element of some div
var button = new Button({ label:"click" }).placeAt("wrapper","first");
// create a contentpane and add it to a TabContainer
var tc = dijit.byId("myTabs");
new ContentPane({ href:"foo.html", title:"Wow!" }).placeAt(tc)

protected method getTextDir(text, originalDir)

Return direction of the text. The function overridden in the _BidiSupport module, its main purpose is to calculate the direction of the text, if was defined by the programmer through textDir.

Parameters
Name Summary Type Usage
text String required
originalDir String required

protected method applyTextDir(element, text)

The function overridden in the _BidiSupport module, originally used for setting element.dir according to this.textDir. In this case does nothing.

Parameters
Name Summary Type Usage
element DOMNode required
text String required

protected method defer(fcn, delay)

Wrapper to setTimeout to avoid deferred functions executing after the originating widget has been destroyed. Returns an object handle with a remove method (that returns null) (replaces clearTimeout).

Parameters
Name Summary Type Usage
fcn undefined required
delay undefined required

protected method _get(name, names)

Private function that does a get based off a hash of names

Parameters
Name Summary Type Usage
name undefined required
names

Hash of names of custom attributes

undefined required

protected method _changeAttrValue(name, value)

Internal helper for directly changing an attribute value.

Parameters
Name Summary Type Usage
name

The property to set.

String required
value

The value to set in the property.

Mixed required

protected method watch(name, callback)

Watches a property for changes

Parameters
Name Summary Type Usage
name

Indicates the property to watch. This is optional (the callback may be the only parameter), and if omitted, all the properties will be watched

String optional
callback

The function to execute when the property changes. This will be called after the property has been changed. The callback will be called with the |this| set to the instance, the first argument as the name of the property, the second argument as the old value and the third argument as the new value.

Function required

protected method own()

Track specified handles and remove/destroy them when this instance is destroyed, unless they were already removed/destroyed manually.

protected method onFocus()

Called when the widget becomes "active" because it or a widget inside of it either has focus, or has recently been clicked.

protected method onBlur()

Called when the widget stops being "active" because focus moved to something outside of it, or the user clicked somewhere outside of it, or the widget was hidden.

protected method _onFocus()

This is where widgets do processing for when they are active, such as changing CSS classes. See onFocus() for more details.

protected method _onBlur()

This is where widgets do processing for when they stop being active, such as changing CSS classes. See onBlur() for more details.

protected method _stringRepl(tmpl)

Does substitution of ${foo} type properties in template string

Parameters
Name Summary Type Usage
tmpl undefined required

protected method _beforeFillContent()

protected method _fillContent(source)

Relocate source contents to templated container node. this.containerNode must be able to receive children, or exceptions will be thrown.

Parameters
Name Summary Type Usage
source DomNode required

protected method _attachTemplateNodes(rootNode, getAttrFunc)

Iterate through the template and attach functions and nodes accordingly. Alternately, if rootNode is an array of widgets, then will process data-dojo-attach-point etc. for those widgets.

Parameters
Name Summary Type Usage
rootNode

the node to search for properties. All children will be searched.

DomNode|Widget[] required
getAttrFunc

a function which will be used to obtain property for a given DomNode/Widget

Function required

protected method _setModelAttr(value)

Parameters
Name Summary Type Usage
value undefined required

protected method _setupModelBindings()

protected method _modelWatch(modelProperty, oldValue, value)

Parameters
Name Summary Type Usage
modelProperty undefined required
oldValue undefined required
value undefined required

protected method _getNormalizedBindingMap()

protected method ownByKey(key, handle)

Own a set of handles

Parameters
Name Summary Type Usage
key

The key to identify the set of handles. It can be a model object, but note that the same instance must be used when destroying the handles

Object required
handle

The handle

Object... required

protected method destroyByKey(key)

Destroy a set of handles

Parameters
Name Summary Type Usage
key

The key to identify the set of handles. It can be a model object, but note that the same instance must be used as when owning the handles

undefined required

protected method _findOwnedByKey(key)

find a set of owned handles

Parameters
Name Summary Type Usage
key Object required

protected method _onToggleItemEditor(item, index)

The model's toggleItemEditor event handler.

Parameters
Name Summary Type Usage
item

The item to edit (Note that it is an item model instance, not the raw data item). If null, open item editor to create new item.

Object required
index undefined required

protected method _setupItemEditor()

Returns grid's columns definition.

protected method _createItemEditor()

protected method _setDialogTitle(existingItem)

Parameters
Name Summary Type Usage
existingItem undefined required

protected method _getDialogTitleText(existingItem)

Parameters
Name Summary Type Usage
existingItem undefined required

protected method _onDialogExecute()

Validates the dialog before calling the public callback onExecuteDialog.

protected method onCancelDialog()

Callback for when the dialog is cancelled.

protected method _setDialogConfirmActionText(existingItem)

Parameters
Name Summary Type Usage
existingItem undefined required

protected method _setDialogConfirmActionStatus(item)

Parameters
Name Summary Type Usage
item undefined required

protected method validate(isFocused)

Show missing or invalid messages if appropriate, and highlight textbox field.

Parameters
Name Summary Type Usage
isFocused Boolean required

protected method isValid(isFocused)

Check if widget's value is valid.

Parameters
Name Summary Type Usage
isFocused

Indicate that the widget is being focused.

Boolean required

protected method displayMessage(message)

Overridable method to display validation errors/hints. By default uses a tooltip.

Parameters
Name Summary Type Usage
message String required

protected method hideMessage()

Hides a message

protected method getErrorMessage(isFocused)

Return an error message to show if appropriate

Parameters
Name Summary Type Usage
isFocused Boolean required

protected method _cssMouseEvent(event)

Handler for CSS event on this.domNode. Sets hovering and active properties depending on mouse state, which triggers _setStateClass() to set appropriate CSS classes for this.domNode.

Parameters
Name Summary Type Usage
event Event required

protected method _setStateClass()

Update the visual state of the widget by setting the css classes on this.domNode (or this.stateNode if defined) by combining this.baseClass with various suffixes that represent the current widget state(s).

protected method _subnodeCssMouseEvent(node, clazz, evt)

Handler for hover/active mouse event on widget's subnode

Parameters
Name Summary Type Usage
node undefined required
clazz undefined required
evt undefined required

protected method _trackMouseState(node, clazz)

Track mouse/focus events on specified node and set CSS class on that node to indicate current state. Usually not called directly, but via cssStateNodes attribute.

Parameters
Name Summary Type Usage
node

Should be a sub-node of the widget, not the top node (this.domNode), since the top node is handled specially and automatically just by mixing in this class.

DomNode required
clazz

CSS class name (ex: dijitSliderUpArrow)

String required

protected method _onPopupOpen(openArgs)

Called before a popup is opened. Checks if the popup is opened for a descendant, and if so it's assumed to be a child dialog.

Parameters
Name Summary Type Usage
openArgs undefined required

protected method _onPopupClosed(popup)

Called when a popup dialog has been closed

Parameters
Name Summary Type Usage
popup

The provided closed popup instance

Object required

protected method _waitForFocus()

Pop-up was closed and we should have received focus by now if we are the new focus target.


Parameters
Name Summary Type Usage
params

Hash of initialization parameters for widget, including scalar values (like title, duration etc.) and functions, typically callbacks like onClick. The hash can contain any of the widget's properties, excluding read-only properties.

Object|null required
srcNodeRef

If a srcNodeRef (DOM node) is specified:

  • use srcNodeRef.innerHTML as my contents
  • if this is a behavioral widget then apply behavior to that srcNodeRef
  • otherwise, replace srcNodeRef with my generated DOM tree
DOMNode|String optional