Ext


Go Back   Ext JS Forums > Ext JS Community Forums (2.0) > Ext 2.x: User Extensions and Plugins

Reply
 
Thread Tools
  #11  
Old 10-07-2007, 04:18 PM
galdaka's Avatar
galdaka galdaka is offline
Ext User
 
Join Date: Mar 2007
Location: Spain
Posts: 1,072
galdaka is on a distinguished road
Default

Excellent work!! Thanks for share!!
Reply With Quote
  #12  
Old 10-07-2007, 06:52 PM
ambience's Avatar
ambience ambience is offline
Ext User
 
Join Date: Mar 2007
Location: Denver, CO
Posts: 135
ambience is on a distinguished road
Send a message via AIM to ambience Send a message via MSN to ambience Send a message via Yahoo to ambience
Default

Quote:
Originally Posted by franklt69 View Post
very cool the filter, is there any way to do filter in the side client only for instance or it is only to server side?

regards
Frank
Sorry I missed your question until now. I will be looking into a 'local: true' config option soon. In theory the Ext.data.Store.filterBy function should be robust enough to allow me to do this, I just need to implement support for it on the filters. Perhaps something along the lines of Ext.ux.grid.filter.Filter.validateRecord(record).
Reply With Quote
  #13  
Old 10-08-2007, 04:09 AM
AlxH AlxH is offline
Ext User
 
Join Date: May 2007
Location: Germany
Posts: 36
AlxH is on a distinguished road
Default

Hi ambience!

Great work! Thanks!

Im trying to use this filters in an autogrid (which reconfigures itself with metadata from server). Currently there seems to be a problem with calling addFilter() in the onMetaChange event of the grids store.
I cant see why the call of addFilter doesnt return, it just quits the onMetaChange event.

Any hint?
Reply With Quote
  #14  
Old 10-08-2007, 12:08 PM
ambience's Avatar
ambience ambience is offline
Ext User
 
Join Date: Mar 2007
Location: Denver, CO
Posts: 135
ambience is on a distinguished road
Send a message via AIM to ambience Send a message via MSN to ambience Send a message via Yahoo to ambience
Default

Quote:
Originally Posted by AlxH View Post
Hi ambience!

Great work! Thanks!

Im trying to use this filters in an autogrid (which reconfigures itself with metadata from server). Currently there seems to be a problem with calling addFilter() in the onMetaChange event of the grids store.
I cant see why the call of addFilter doesnt return, it just quits the onMetaChange event.

Any hint?
My first guess is that it is unable to find the filter type you are requesting and is throwing an exception which is getting swallowed some where. If you uncomment the try catch block inside the addFilter method and have firebug it should alert you to this case.

GridFilters does not load filters automagicly any longer. It is the responsibility of the getFilter method to locate and return the class for a requested filter. If you would like to enable dynamic loading of filters, overwrite this method with some form of synchronous script loader and return with the loaded filter class.
Reply With Quote
  #15  
Old 10-08-2007, 01:14 PM
andrei.neculau's Avatar
andrei.neculau andrei.neculau is offline
Ext User
 
Join Date: Jul 2007
Location: Romania
Posts: 196
andrei.neculau is on a distinguished road
Send a message via ICQ to andrei.neculau Send a message via AIM to andrei.neculau Send a message via MSN to andrei.neculau Send a message via Yahoo to andrei.neculau Send a message via Skype™ to andrei.neculau
Default

For some reasons, it's impossible to reach your site.
Can you please attach the plugin's source to the main post of this thread? Thanks in advance
Reply With Quote
  #16  
Old 10-08-2007, 01:21 PM
AlxH AlxH is offline
Ext User
 
Join Date: May 2007
Location: Germany
Posts: 36
AlxH is on a distinguished road
Default

Quote:
Originally Posted by ambience View Post
My first guess is that it is unable to find the filter type you are requesting and is throwing an exception which is getting swallowed some where. If you uncomment the try catch block inside the addFilter method and have firebug it should alert you to this case.

GridFilters does not load filters automagicly any longer. It is the responsibility of the getFilter method to locate and return the class for a requested filter. If you would like to enable dynamic loading of filters, overwrite this method with some form of synchronous script loader and return with the loaded filter class.

Thanks for your quick answer.
Sorry, I didnt write the hole story: The filters are cleanly applied by addFilter.
The problem is when a value is supplied to the addFilter argument.
Seems to be that a value will cause the grid to be reloaded, thats of cause not quite useful while the grid currently loading.
I wanted to have a preset value when the data for the grid is loaded.
That way I want to achieve a state saving/restoring for the filters.


(Sorry for my bad english)

Greetings
Reply With Quote
  #17  
Old 10-08-2007, 02:48 PM
ambience's Avatar
ambience ambience is offline
Ext User
 
Join Date: Mar 2007
Location: Denver, CO
Posts: 135
ambience is on a distinguished road
Send a message via AIM to ambience Send a message via MSN to ambience Send a message via Yahoo to ambience
Default

Quote:
Originally Posted by andrei.neculau View Post
For some reasons, it's impossible to reach your site.
Can you please attach the plugin's source to the main post of this thread? Thanks in advance
Not sure what the problem is. But here you go =)
Attached Files
File Type: zip source.zip (12.6 KB, 598 views)
Reply With Quote
  #18  
Old 10-09-2007, 02:41 AM
AlxH AlxH is offline
Ext User
 
Join Date: May 2007
Location: Germany
Posts: 36
AlxH is on a distinguished road
Default

Is there an easy way to preset the filters initial values, without triggering the events, so that the grid doesnt get reloaded?


Quote:
Originally Posted by AlxH View Post
Thanks for your quick answer.
Sorry, I didnt write the hole story: The filters are cleanly applied by addFilter.
The problem is when a value is supplied to the addFilter argument.
Seems to be that a value will cause the grid to be reloaded, thats of cause not quite useful while the grid currently loading.
I wanted to have a preset value when the data for the grid is loaded.
That way I want to achieve a state saving/restoring for the filters.


(Sorry for my bad english)

Greetings
Reply With Quote
  #19  
Old 10-09-2007, 12:44 PM
ambience's Avatar
ambience ambience is offline
Ext User
 
Join Date: Mar 2007
Location: Denver, CO
Posts: 135
ambience is on a distinguished road
Send a message via AIM to ambience Send a message via MSN to ambience Send a message via Yahoo to ambience
Default

Quote:
Originally Posted by AlxH View Post
Is there an easy way to preset the filters initial values, without triggering the events, so that the grid doesnt get reloaded?
Sorry I didn't have time to really fully address your issue. It's a bit of a hack, but you could call gridFilter.deferredUpdate.cancle(); immediately after you add your filters / set values.

I'll see if I can come up with something a bit more elegant in a future version.
Reply With Quote
  #20  
Old 10-09-2007, 02:08 PM
ambience's Avatar
ambience ambience is offline
Ext User
 
Join Date: Mar 2007
Location: Denver, CO
Posts: 135
ambience is on a distinguished road
Send a message via AIM to ambience Send a message via MSN to ambience Send a message via Yahoo to ambience
Default

Quote:
Originally Posted by ejetorix View Post
BTW, problems like krycek has noticed, are the reason for what i prefer a separate panel/region/whatever for filtering, instead of rendering it on columns menu.
As this seems to be a common criticism (esp from ejetorix ), I just want to take a moment to defend my decisions =)

While I agree the filters under the headers are perhaps more comfortable for users who are familiar with Excel, this method simply does not provide the space / flexibility we (the people at my company) need. For example, one of our columns represents an object in a directed acyclic graph. For which we provide the ability to filter on name, id range, or by selecting the object in a tree (rendered in place) and optionally include all children. One or more of these options may be active at any given time.(Screenshot 1&2) Or, in a much more simple example you have the list filter which can allow for the selection of one or more items to filter by. With out the filter menu, these options would be far to complex to express in the limited space under the headers. Additionally, chances are that if a grid is filtered it is because a user has chosen to filter it and I feel that having that information constantly displayed verbosely is unneeded clutter. Especially when, in the case of commonly filtered fields in a complex layout, you can us listeners and API driven filter activation to provider richer feedback about what the data shown represents (Screenshot 3)

Furthermore, I feel that the logical 'binding' of filters to an existing visual representation of the data key (the column header) is much easier for people to understand then disjoint spreadsheet of filters. While a separate tab could provide compound column filters and additional flexibility (AND / OR instead of just and); it has been our experience (as we've developed similar panels in the past) that that kind of power is confusing to must users and only leveraged by ... well mostly just the developers =\

I do appreciate feedback and will try to incorporate what I can into the filters to make them better. However (there's always a however), I am fairly confident in my decision to make them menu driven as opposed to panel/tab driven. This does not preclude a panel based tie-in. It simply means I my self will most likely not be developing it.

Screenshots:
Screenshot 1


Screenshot 2


Screenshot 3
Reply With Quote
Reply

Thread Tools

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump

All times are GMT -5. The time now is 05:07 AM.

© 2006-2009 Ext, LLC
Powered by vBulletin® Version 3.8.4
Copyright ©2000 - 2009, Jelsoft Enterprises Ltd.