thank for you reply, look here is my issue
I have this two combogrid, cg2 depends on cg1
<input class="easyui-combogrid" id="cg1" name="cg1" style="width:230px;" data-options="
panelWidth:200,
panelHeight:305,
idField:'key',
textField:'name',
url:'get_category.php',
mode:'remote',
fitColumns:'false',
columns:[[
{field:'key',title:'Id',width:60},
{field:'name',title:'Name',width:175}
]],
onHidePanel: function(){
var g = $('#cg1').combogrid('grid');
var r = g.datagrid('getSelected');
var key = r.key;
$('#cg2').combogrid('clear');
$('#cg2').combogrid('grid').datagrid('load', {
param1: $('#other_combo').combogrid('getValue'),
param2: key
});
$('#dg').datagrid('load', {
other_combo: $('#other_combo').combogrid('getValue'),
cg1: key,
cg2: $('#cg2').combogrid('getValue')
});
}"
/>
<input class="easyui-combogrid" id="cg2" name="cg2" style="width:270px;" data-options="
panelWidth:500,
idField:'key',
textField:'description',
url:'get_products.php',
mode:'remote',
fitColumns:'false',
columns:[[
{field:'key',title:'Id',width:100},
{field:'description',title:'Description',width:140},
{field:'price',title:'Price',width:60}
]],
queryParams: {
param1: $('#other_combo').combogrid('getValue'),
param2: $('#cg1').combogrid('getValue')
},
onHidePanel: function(){
var g = $('#cg2').combogrid('grid');
var r = g.datagrid('getSelected');
var key = r.key;
$('#dg').datagrid('load', {
other_combo: $('#other_combo').combogrid('getValue'),
cg1: $('#cg1').combogrid('getValue'),
cg2: key
});
}"
/>
When I change a category in cg1 I notice that cg2 change his content ok, for example:
cg1 = garden
cg2 loads the content of products:
-- plantpot
-- shovel
-- fertilizer
then I change it another category:
cg1 = cleaning
cg2 loads the content of products:
-- vacuum cleaner
-- garbage bag
-- trash can
The problem is that having selected cleaning category, I write fertilizer for search and the combogrid show me the result. Looks like the param2 don't be send it in cg2
That's a mistake because fertilizer dont belong it to cleaning category
any idea?