Forum
12:32
10/08/2009
Hello Tony,
I tried to use defaultValue for columns having select element and I think that the current implementation (the meaning) of it is not the best. So I decide to post my doubts here.
The documentation (common searching options) says
If not empty set a default value in the search input element.
It says nothing about the meaning of it in case of usage stype: "select". On the other side the current implementation of defaultValue is the following:
- Searching Dialog ignores searchoptions.defaultValue. So it can't be used to preselect some select option as default per column which will be used in searching dialog.
- Searching toolbar fills the default values at the initialization time or on call of clearToolbar, but not apply the filter. In the case the user sees data which don't corresponds the filter displayed. In case of usage searchOnEnter: false option the filter can be applyed if the user types not quick enough. After applying of filter it's not easy to remove all filters especially if one have grid with many columns. If the user clears unneeded fields it will be refilled one more time after clicking "Reload Grid" button.
I used to have grids which many columns of select type. The current behavior of usage searchoptions.defaultValue seems me not the best one. The usage of the option in Serching Dialog is what it seems me interesting. The usage of it in the searching toolbar disturb me opposite.
What do you think about changing the behavior of usage searchoptions.defaultValue. For example the options useDefaultValue of filterToolbar (managed by $.jgrid.search too) and the same option of searching dialog could be a possible solution. One can use special string value "dialog", "toollbar" of useDefaultValue additionally to true and false to allows selective behavior inside of common $.jgrid.search.useDefaultValue.
What is your oppinion Tony about the subject?
Best regards
Oleg
08:25
Moderators
30/10/2007
Hello Oleg,
Everthing what you write here is true - really not best implementation of this
Not sure what to do. Let me think about this.
Regards
Tony
For professional UI suites for Java Script and PHP visit us at our commercial products site - guriddo.net - by the very same guys that created jqGrid.
Most Users Ever Online: 715
Currently Online:
27 Guest(s)
Currently Browsing this Page:
1 Guest(s)
Top Posters:
OlegK: 1255
markw65: 179
kobruleht: 144
phicarre: 132
YamilBracho: 124
Renso: 118
Member Stats:
Guest Posters: 447
Members: 11373
Moderators: 2
Admins: 1
Forum Stats:
Groups: 1
Forums: 8
Topics: 10592
Posts: 31289
Newest Members:
, razia, Prankie, psky, praveen neelam, greg.valainis@pa-tech.comModerators: tony: 7721, Rumen[Trirand]: 81
Administrators: admin: 66