inputEx Documentation Back to homepage

inputEx Documentation > inputEx.ListField 1.0.0

Class inputEx.ListField - extends inputEx.Field

Known Subclasses:
inputEx.TreeField
Meta field to create a list of other fields

Constructor

inputEx.ListField ( options )
Parameters:
options <Object>  - inputEx.Field options object

Properties

subFields - Object

List of all the subField instances

Methods

addElement

addElement(value)
Adds an element
Parameters:
    value

getValue

getValue()
Return the array of values

initEvents

initEvents()
Handle the click event on the add button

onAddButton

onAddButton(e)
Add a new element to the list and fire updated event
Parameters:
    <Event>  - The original click event

onArrowDown

onArrowDown(e)
Switch a subField with its next one Called when the user clicked on the down arrow of a sortable list
Parameters:
    <Event>  - Original click event

onArrowUp

onArrowUp(e)
Switch a subField with its previous one Called when the user clicked on the up arrow of a sortable list
Parameters:
    <Event>  - Original click event

onDelete

onDelete(e, params)
Called when the user clicked on a delete button.
Parameters:
    e
    params

removeElement

removeElement(index)
Remove the line from the dom and the subField from the list.
Parameters:
    index

renderComponent

renderComponent()
Render the addButton

renderSubField

<inputEx.Field> renderSubField(value)
Adds a new line to the List Field
Parameters:
    value
Returns:
    <inputEx.Field> instance of the created field (inputEx.Field or derivative)

setOptions

setOptions()
Set the ListField classname

setValue

setValue(value)
Set the value of all the subfields
Parameters:
    value




Copyright (c) 2008 Eric Abouaf. All rights reserved.
Generated by JsDoc Toolkit 1.4.1 on Wed, 07 May 2008 10:26:30 GMT.