我正在尝试在iggrid上实现"RowSelectors“特性,但它不会更改为下一行。
在进一步的检查中,我得到了所选择的row方法,并且每一行都显示相同的id。我通过ajax返回我的数据,如果我在变量中使用静态json并将其用作数据源,它会按预期工作,所以不确定问题是什么。
$("#selector").igGrid("selectedRow");
我只能在按住control键并单击时获得行更改。
Object {element: n.fn.init(1), index: 0, id: 3407751001}
那么下一行是
Object {element: n.fn.init(1), index: 1, id: 3407751001}
设置..
features: [
{
name: "Sorting",
columnSettings: [
{
columnIndex: 4,
allowSorting: true,
firstSortDirection: "ascending",
currentSortDirection: "descending"
}
]
},
{
name: 'RowSelectors',
enableCheckBoxes: true,
checkBoxStateChanging: function (ui, args) {
return false;
},
multipleSelection: true,
rowSelectorClicked: function (evt, ui) {
// Handle event
},
},
{
name: 'Selection'
}
]
发布于 2017-07-31 16:37:10
这个问题已经解决了,但我添加了答案,这样它就不会一直没有得到回答。
igGrid
使用的primaryKey
列必须是每条记录都具有唯一标识符的列。
https://stackoverflow.com/questions/44139568
复制相似问题