Reference Source
public class | source

PanelBar

PanelBar web control

See:

Constructor Summary

Public Constructor
public

constructor(id: String, options: Object)

constructor

Method Summary

Public Methods
public

clearSelection(): Null

clear the selected items

public

collapse the item

public

return the item's data

public

enable(item: String, enable: Boolean): Null

sets the item's status

public

expand(item: String): Object

expand the item

public

select(item: String): Object

sets or gets the selected item

Public Constructors

public constructor(id: String, options: Object) source

constructor

Params:

NameTypeAttributeDescription
id String

panelbar id

options Object

config params

options.dataSource Object

the data source of the widget which is used to render panelbar, a javascript array.

options.dataSource.text String

item's text

options.dataSource.imageUrl String

item's image

options.expandMode String

expand mode: 1 "single" 2 "multiple" (default: "multiple")

options.template String

template for node rendering

Emit:

select

triggers when a user selects or cancels a selected node (callback function format: CALLBACK_NAME(e) e.item selected item)

Public Methods

public clearSelection(): Null source

clear the selected items

Return:

Null

public collapse(item: String): Object source

collapse the item

Params:

NameTypeAttributeDescription
item String

an item that needs collapse(jQuery selector)

Return:

Object

return the panelbar control for chained operations

public dataItem(item: String): Object source

return the item's data

Params:

NameTypeAttributeDescription
item String

Dom element(jQuery selector)

Return:

Object

the item's data

public enable(item: String, enable: Boolean): Null source

sets the item's status

Params:

NameTypeAttributeDescription
item String

an item(jQuery selector)

enable Boolean

status: 1 true: enabled 2 false: disabled

Return:

Null

public expand(item: String): Object source

expand the item

Params:

NameTypeAttributeDescription
item String

an item that needs expand(jQuery selector)

Return:

Object

return the panelbar control for chained operations

public select(item: String): Object source

sets or gets the selected item

Params:

NameTypeAttributeDescription
item String

an item(jQuery selector)

Return:

Object

if there is no parameter call, return the selected item , otherwise return null