Bug Tracker

Current Project: Guriddo jqGrid JS

Issue ID# 3 Event is raised only once when reloadOnExpand is true.
Status: Resolved Version: 4.8 Priority: 3
Assigned to: tony Submitted by: Tony Russo Attached file:
Type: Bug Submitted:
2015-01-04 13:47:23 UTC
Last Update:
2015-01-07 13:30:23 UTC
Description: To replicate use Tony Tomov's code below with Two level hierarchy demo.

When reloadOnExpand is true a previous expanded subGrid collapses so only one subGrid is viewable at a time.

When reloadOnExpand is false a previous expanded subGrid does not collapse if it is clicked again.

What happends:
Clicking on Row 1 expands as expected.
Clicking on Row 2 collapses Row 1 and expands Row 2 as expected.
Clicking on Row 1 expands Row 1 as expected but does not collapse Row 2.
This occurs when any previous expanded row is clicked on again.

Tony Tomov Code:
....
subGridBeforeExpand: function(divid, rowid) {
// #grid is the id of the grid
var expanded = jQuery("td.sgexpanded", "#grid")[0];
if(expanded) {
setTimeout(function(){
$(expanded).trigger("click");
}, 100);
},
...

Stay connected with us in your favorite flavor!