Is a Footer row in a jqgrid selectable/clickable?

后端 未结 3 776
不知归路
不知归路 2021-01-23 16:59

I have a jqgrid that has main rows and a footer row (with userdata loaded) and then a formatter that alters the data in the cells to be linkable. The cells in the main body can

3条回答
  •  梦毁少年i
    2021-01-23 17:39

    While I didn't see any way to have jqGrid respond to select (doesn't even seem that that footer is selectable) or a click. The footer row is specified by a ui-jqgrid-sdiv class. You could attach a click event handler as below.

    $('.ui-jqgrid-sdiv').click(function() {alert('Bong')});
    

    Edit: In response to Gill Bates question to add a footer event but only on a single cell the selector would be:

    $('.ui-jqgrid-sdiv').find('td[aria-describedby="GridName_ColumnName"]').click(function() { alert("Bong");});
    

    GridName_ColumnName is the format for all the footer td aria-describedby, and you can see the exact name via firebug element inspector (or any of it's equivalents).

提交回复
热议问题