I'm trying to upgrade from jqGrid v4.7 to the latest jqGrid 4.12.1 - free jqGrid fork.
The problem I face is that, using server side searching, filter parameters don´t get built using the former
{"groupOp":"AND","rules":[{"field":"Name","op":"cn","data":"bob"}]}
style, I just get an additional Name
parameter with bob
value (_search
is true
).
What am I missing here?
Thanks in advance
I suppose that you use filterToolbar
without stringResult: true
parameter and the problem have no relation with the upgrade of jqGrid 4.7 to free jqGrid 4.12.1. See the first part of the documentation of filterToolbar
which describes:
When the search is activated, an array of type
name:value
is posted to the server. Note that this array is added to thepostData
parameter. We post only fields that have an entered value. When we clear the the search form, the values are deleted from thepostData
array. When posting to the server, we try to pass, not the name, but theindex
set incolModel
. When theindex
is not found we use thename
. Additionally, we add a_search=true
to the posted data.When the
stringResult
option is set to true the data posted to the server is a string and the structure of the posted data is the same as in Advanced Search.