| Defined In: | CheckboxSelectionModel.js |
| Class: | Ext.grid.CheckboxSelectionModel |
| Extends: | Ext.grid.RowSelectionModel |
| 配置项 | 定义者 | |
|---|---|---|
|
header
: String
任何显示在checkbox列头部上有效的HTML片断(默认为 '<...
任何显示在checkbox列头部上有效的HTML片断(默认为 '<div class="x-grid3-hd-checker"> </div>')
默认的CSS样式类'x-grid3-hd-checker'负责头部的那个checkbox,以支持全局单击、反选的行为。
这个字符串可以替换为任何有效的HTML片断,包括几句的文本字符串(如'Select Rows'),
但是全局单击、反选行为的checkbox就只能“ x-grid3-hd-checker”的出现才能工作。
|
CheckboxSelectionModel | |
|
width
: Number
checkbox列默认的宽度(默认为20)
checkbox列默认的宽度(默认为20)
|
CheckboxSelectionModel | |
|
sortable
: Boolean
True表示为checkbox列可以被排序(默认为fasle)
True表示为checkbox列可以被排序(默认为fasle)
|
CheckboxSelectionModel | |
|
singleSelect
: Boolean
True表示为同时只能选单行(默认false)
True表示为同时只能选单行(默认false)
|
RowSelectionModel | |
|
listeners
: Object
一个配置项对象,可方便在该对象初始化时便加入多个事件处理函数。 这应该...
一个配置项对象,可方便在该对象初始化时便加入多个事件处理函数。 这应该是一个如#addListener有效的配置项对象,即可一次过加入多个事件处理函数。
|
Observable | |
| 方法 | 定义者 | |
|---|---|---|
CheckboxSelectionModel
(
Object config
)
: Ext.grid.CheckboxSelectionModel
构造器
构造器
参数项:
|
CheckboxSelectionModel | |
RowSelectionModel
(
Object config
)
: Ext.grid.RowSelectionModel
构造器
构造器
参数项:
|
RowSelectionModel | |
selectRecords
(
Array records,
[Boolean keepExisting]
)
选择多个记录
选择多个记录
参数项:
|
RowSelectionModel | |
|
getCount
(
)
: Number
获取已选择的行数
获取已选择的行数
参数项:
|
RowSelectionModel | |
|
selectFirstRow
(
)
选择GRID的第一行
选择GRID的第一行
参数项:
|
RowSelectionModel | |
selectLastRow
(
[Boolean keepExisting]
)
选择最后一行
选择最后一行
参数项:
|
RowSelectionModel | |
selectNext
(
[Boolean keepExisting]
)
选取上次选取的最后一行
选取上次选取的最后一行
参数项:
|
RowSelectionModel | |
selectPrevious
(
[Boolean keepExisting]
)
选取上次选取的最前一行
选取上次选取的最前一行
参数项:
|
RowSelectionModel | |
|
hasNext
(
)
: Boolean
Returns true if there is a next r...
Returns true if there is a next record to select
参数项:
|
RowSelectionModel | |
|
hasPrevious
(
)
: Boolean
Returns true if there is a previo...
Returns true if there is a previous record to select
参数项:
|
RowSelectionModel | |
|
getSelections
(
)
: Array
Returns the selected records
Returns the selected records
参数项:
|
RowSelectionModel | |
|
getSelected
(
)
: Record
Returns the first selected record.
Returns the first selected record.
参数项:
|
RowSelectionModel | |
each
(
Function fn,
Object scope
)
: Boolean
Calls the passed function with ea...
Calls the passed function with each selection. If the function returns false, iteration is
stopped and this function returns false. Otherwise it returns true.
参数项:
|
RowSelectionModel | |
|
clearSelections
(
)
Clears all selections.
Clears all selections.
参数项:
|
RowSelectionModel | |
|
selectAll
(
)
Selects all rows.
Selects all rows.
参数项:
|
RowSelectionModel | |
|
hasSelection
(
)
: Boolean
Returns True if there is a select...
Returns True if there is a selection.
参数项:
|
RowSelectionModel | |
isSelected
(
Number/Record record
)
: Boolean
Returns True if the specified row...
Returns True if the specified row is selected.
参数项:
|
RowSelectionModel | |
isIdSelected
(
String id
)
: Boolean
Returns True if the specified rec...
Returns True if the specified record id is selected.
参数项:
|
RowSelectionModel | |
selectRows
(
Array rows,
[Boolean keepExisting]
)
选取多行。
选取多行。
参数项:
|
RowSelectionModel | |
selectRange
(
Number startRow,
Number endRow
)
选取某个范围内的行(rows)。所有在startRow和endRo...
选取某个范围内的行(rows)。所有在startRow和endRow之间的行都会被选中。
参数项:
|
RowSelectionModel | |
deselectRange
(
Number startRow,
Number endRow,
[Boolean keepExisting]
)
反选某个范围内的行(rows)。所有在startRow和endRo...
反选某个范围内的行(rows)。所有在startRow和endRow之间的行都会被选反。
参数项:
|
RowSelectionModel | |
selectRow
(
Number row
)
选择一行
选择一行
参数项:
|
RowSelectionModel | |
deselectRow
(
Number row
)
反选一个行
反选一个行
参数项:
|
RowSelectionModel | |
|
AbstractSelectionModel
(
)
: Ext.grid.AbstractSelectionModel
构造器
构造器
参数项:
|
AbstractSelectionModel | |
|
lock
(
)
锁定多个选区
锁定多个选区
参数项:
|
AbstractSelectionModel | |
|
unlock
(
)
解锁多个选区
解锁多个选区
参数项:
|
AbstractSelectionModel | |
|
isLocked
(
)
: Boolean
返回true如果选区被锁
返回true如果选区被锁
参数项:
|
AbstractSelectionModel | |
fireEvent
(
String eventName,
Object... args
)
: Boolean
触发指定的事件,并将欲执行的处理函数的参数传入。(应该至少要有事件的...
触发指定的事件,并将欲执行的处理函数的参数传入。(应该至少要有事件的名称)
参数项:
|
Observable | |
addListener
(
String eventName,
Function handler,
[Object scope],
[Object options]
)
为该组件加入事件处理函数(event handler)
sc...
为该组件加入事件处理函数(event handler)
处理函数执行时所在的作用域。处理函数“this”的上下文。 触发事件后开始执行处理函数的延时时间(invocation:the act of making a particular function start),单位:毫秒 true代表为下次事件触发加入一个要处理的处理函数,然后再移除本身。 不同配搭方式的选项 一次调用加入上多个处理函数(handlers) 或者是以简写的方式书写,前提是只允许同一个的作用域对象传入到所有的处理函数中:
参数项:
|
Observable | |
removeListener
(
String eventName,
Function handler,
[Object scope]
)
移除侦听器
移除侦听器
参数项:
|
Observable | |
|
purgeListeners
(
)
从这个对象身上移除所有的侦听器
从这个对象身上移除所有的侦听器
参数项:
|
Observable | |
addEvents
(
Object object
)
定义观察者的事件。
定义观察者的事件。
参数项:
|
Observable | |
hasListener
(
String eventName
)
: Boolean
查询该对象是否有指定事件的侦听器
查询该对象是否有指定事件的侦听器
参数项:
|
Observable | |
|
suspendEvents
(
)
暂停触发所有的事件(参阅#resumeEvents)
暂停触发所有的事件(参阅#resumeEvents)
参数项:
|
Observable | |
|
resumeEvents
(
)
重新触发事件(参阅{@link #suspendEvents})
重新触发事件(参阅{@link #suspendEvents})
参数项:
|
Observable | |
on
(
String eventName,
[Object scope],
Function handler,
[Object options]
)
为该元素添加事件处理函数(event handler),addLis...
为该元素添加事件处理函数(event handler),addListener的简写方式 @param {String} eventName 侦听事件的类型 @param {Object} scope (可选的) 执行处理函数的作用域 @param {Function} handler 事件涉及的方法 @param {Object} options (可选的)
参数项:
|
Observable | |
un
(
String eventName,
Function handler,
[Object scope]
)
移除侦听器 @param {String} eventName ...
移除侦听器 @param {String} eventName 侦听事件的类型 @param {Function} handler 事件涉及的方法 @param {Object} scope (可选的)处理函数的作用域
参数项:
|
Observable | |
capture
(
Observable o,
Function fn,
[Object scope]
)
开始捕捉特定的观察者。 在事件触发之前,所有的事件会以“事件名称+标...
开始捕捉特定的观察者。 在事件触发之前,所有的事件会以“事件名称+标准签名”的形式传入到函数(传入的参数是function类型)。 如果传入的函数执行后返回false,则接下的事件将不会触发。 @param {Observable} o 要捕捉的观察者 @param {Function} fn 要调用的函数 @param {Object} scope (可选的)函数作用域
参数项:
|
Observable | |
releaseCapture
(
Observable o
)
从Observable身上移除所有已加入的捕捉captures。 @...
从Observable身上移除所有已加入的捕捉captures。 @param {Observable} o 要释放的观察者
参数项:
|
Observable | |
| 事件 | 定义者 | |
|---|---|---|
selectionchange
(
SelectionModel this
)
当选区改变时触发
当选区改变时触发
参数项:
|
RowSelectionModel | |
beforerowselect
(
SelectionModel this,
Number rowIndex
)
当行(row)是选中又被选择触发,返回false取消。
当行(row)是选中又被选择触发,返回false取消。
参数项:
|
RowSelectionModel | |
rowselect
(
SelectionModel this,
Number rowIndex
)
当行(row)被选中时触发。
当行(row)被选中时触发。
参数项:
|
RowSelectionModel | |
rowdeselect
(
SelectionModel this,
Number rowIndex
)
当行(row)反选时触发。
当行(row)反选时触发。
参数项:
|
RowSelectionModel | |