Observable Filter BooleanFilter
Package: | Ext.ux.grid.filter |
Defined In: | BooleanFilter.js |
Class: | BooleanFilter |
Extends: | Filter |
Example Usage:
var filters = new Ext.ux.grid.GridFilters({
...
filters: [{
// required configs
type: 'boolean',
dataIndex: 'visible'
// optional configs
defaultValue: null, // leave unselected (false selected by default)
yesText: 'Yes', // default
noText: 'No' // default
}]
});
Config Options | Defined By | |
---|---|---|
active : Boolean Indicates the initial status of the filter (defaults to false). | Filter | |
dataIndex : String The Ext.data.Store dataIndex of the field this filter represents.
The dataIndex does not actually have to exist in t... The Ext.data.Store dataIndex of the field this filter represents.
The dataIndex does not actually have to exist in the store. | Filter | |
defaultValue : Boolean Set this to null if you do not want either option to be checked by default. Defaults to false. | BooleanFilter | |
listeners : Object A config object containing one or more event handlers to be added to this
object during initialization. This should ... A config object containing one or more event handlers to be added to this object during initialization. This should be a valid listeners config object as specified in the addListener example for attaching multiple handlers at once. DOM events from ExtJs Components While some ExtJs Component classes export selected DOM events (e.g. "click", "mouseover" etc), this
is usually only done when extra value can be added. For example the DataView's
| Observable | |
noText : String Defaults to 'No'. | BooleanFilter | |
updateBuffer : Number Number of milliseconds to wait after user interaction to fire an update. Only supported
by filters: 'list', 'numeri... Number of milliseconds to wait after user interaction to fire an update. Only supported
by filters: 'list', 'numeric', and 'string'. Defaults to 500. | Filter | |
yesText : String Defaults to 'Yes'. | BooleanFilter |
Property | Defined By | |
---|---|---|
active : Boolean True if this filter is active. Use setActive() to alter after configuration. | Filter | |
getSerialArgs : Object Template method to be implemented by all subclasses that is to
get and return serialized filter data for transmissio... Template method to be implemented by all subclasses that is to
get and return serialized filter data for transmission to the server.
Defaults to Ext.emptyFn. | Filter | |
init : Object Template method to be implemented by all subclasses that is to
initialize the filter and install required menu items... Template method to be implemented by all subclasses that is to
initialize the filter and install required menu items.
Defaults to Ext.emptyFn. | Filter | |
menu : Ext.menu.Menu The filter configuration menu that will be installed into the filter submenu of a column menu. | Filter |
Method | Defined By | |
---|---|---|
addEvents( Object|String o , string Optional. )
:
voidAdds the specified events to the list of events which this Observable may fire. Adds the specified events to the list of events which this Observable may fire. Parameters:
| Observable | |
addListener( String eventName , Function handler , [Object scope ], [Object options ] )
:
voidAppends an event handler to this object. Appends an event handler to this object. Parameters:
| Observable | |
destroy()
:
void Destroys this filter by purging any event listeners, and removing any menus. Destroys this filter by purging any event listeners, and removing any menus. Parameters:
| Filter | |
enableBubble( Object events )
:
voidEnables events fired by this Observable to bubble up an owner hierarchy by calling
this.getBubbleTarget() if present... Enables events fired by this Observable to bubble up an owner hierarchy by calling
This is commonly used by Ext.Components to bubble events to owner Containers. See Ext.Component.getBubbleTarget. The default implementation in Ext.Component returns the Component's immediate owner. But if a known target is required, this can be overridden to access the required target more quickly. Example:
Parameters:
| Observable | |
fireEvent( String eventName , Object... args )
:
BooleanFires the specified event with the passed parameters (minus the event name).
An event may be set to bubble up an Obse... Fires the specified event with the passed parameters (minus the event name). An event may be set to bubble up an Observable parent hierarchy (See Ext.Component.getBubbleTarget) by calling enableBubble. Parameters:
| Observable | |
getValue()
:
Object Template method to be implemented by all subclasses that is to
get and return the value of the filter.
Defaults to ... Template method to be implemented by all subclasses that is to
get and return the value of the filter.
Defaults to Ext.emptyFn. Parameters:
| Filter | |
hasListener( String eventName )
:
BooleanChecks to see if this object has any listeners for a specified event Checks to see if this object has any listeners for a specified event Parameters:
| Observable | |
isActivatable()
:
Boolean Template method to be implemented by all subclasses that is to
return true if the filter has enough configuration in... Template method to be implemented by all subclasses that is to
return true if the filter has enough configuration information to be activated.
Defaults to return true. Parameters:
| Filter | |
on( String eventName , Function handler , [Object scope ], [Object options ] )
:
voidAppends an event handler to this object (shorthand for addListener.) Appends an event handler to this object (shorthand for addListener.) Parameters:
| Observable | |
purgeListeners()
:
void Removes all listeners for this object Removes all listeners for this object Parameters:
| Observable | |
relayEvents( Object o , Array events )
:
voidRelays selected events from the specified Observable as if the events were fired by this. Relays selected events from the specified Observable as if the events were fired by this. Parameters:
| Observable | |
removeListener( String eventName , Function handler , [Object scope ] )
:
voidRemoves an event handler. Removes an event handler. Parameters:
| Observable | |
resumeEvents()
:
void Resume firing events. (see suspendEvents)
If events were suspended using the queueSuspended parameter, then all
event... Resume firing events. (see suspendEvents)
If events were suspended using the queueSuspended parameter, then all
events fired during event suspension will be sent to any listeners now. Parameters:
| Observable | |
serialize()
:
Object/Array Returns the serialized filter data for transmission to the server
and fires the 'serialize' event. Returns the serialized filter data for transmission to the server
and fires the 'serialize' event. Parameters:
| Filter | |
setActive( Boolean active , Boolean suppressEvent )
:
voidSets the status of the filter and fires the appropriate events. Sets the status of the filter and fires the appropriate events. Parameters:
| Filter | |
setValue( Object data )
:
voidTemplate method to be implemented by all subclasses that is to
set the value of the filter and fire the 'update' eve... Template method to be implemented by all subclasses that is to
set the value of the filter and fire the 'update' event.
Defaults to Ext.emptyFn. Parameters:
| Filter | |
suspendEvents( Boolean queueSuspended )
:
voidSuspend the firing of all events. (see resumeEvents) Suspend the firing of all events. (see resumeEvents) Parameters:
| Observable | |
un( String eventName , Function handler , [Object scope ] )
:
voidRemoves an event handler (shorthand for removeListener.) Removes an event handler (shorthand for removeListener.) Parameters:
| Observable | |
validateRecord( Ext.data.Record record )
:
BooleanTemplate method that is to validate the provided Ext.data.Record
against the filters configuration. Template method that is to validate the provided Ext.data.Record
against the filters configuration. Parameters:
| BooleanFilter |
Event | Defined By | |
---|---|---|
activate :
( Ext.ux.grid.filter.Filter this )
Fires when an inactive filter becomes active Fires when an inactive filter becomes active Listeners will be called with the following arguments:
| Filter | |
deactivate :
( Ext.ux.grid.filter.Filter this )
Fires when an active filter becomes inactive Fires when an active filter becomes inactive Listeners will be called with the following arguments:
| Filter | |
serialize :
( Array/Object data , Ext.ux.grid.filter.Filter filter )
Fires after the serialization process. Use this to attach additional parameters to serialization
data before it is e... Fires after the serialization process. Use this to attach additional parameters to serialization
data before it is encoded and sent to the server. Listeners will be called with the following arguments:
| Filter | |
update :
( Ext.ux.grid.filter.Filter this )
Fires when a filter configuration has changed Fires when a filter configuration has changed Listeners will be called with the following arguments:
| Filter |