onCellClick: lang.hitch(this, function(event){ //单元格单击事件 var grid = dijit.byId("__geodisa_grid"); var rowIndex = event.rowIndex; //如果已有选择的行则取消改行选中状态 if (grid.selection.selectedIndex >= 0) { grid.selection.setSelected(grid.selection.selectedIndex, false); } //选择当前点击的行 grid.selection.setSelected(rowIndex,true); }
DOJO dataGrid 单击单元格选中行,布布扣,bubuko.com
时间: 2024-10-11 00:05:56