nl_tokens: Function to take the active filters data and build it into a query . The format of the query depends on the { @link #encode } configuration :
pl_tokens: function ( filters ) { var p = { } , i , f , root , dataPrefix , key , tmp , len = filters . length ; if ( ! this . encode ) { for ( i = 0 ; i < len ; i ++ ) { f = filters [ i ] ; root = [ this . paramPrefix , '[' , i , ']' ] . join ( '' ) ; p [ root + '[field]' ] = f . <mask> ; dataPrefix = root + '[data]' ; for ( key in f . data ) { p [ [ dataPrefix , '[' , key , ']' ] . join ( '' ) ] = f . data [ key ] ; } } } else { tmp = [ ] ; for ( i = 0 ; i < len ; i ++ ) { f = filters [ i ] ; tmp . push ( Ext . apply ( { } , { field : f . field } , f . data ) ) ; } // only build if there is active filter if ( tmp . length > 0 ) { p [ this . paramPrefix ] = Ext . JSON . encode ( tmp ) ; } } return p ; }