0
$scope.gridApi.selection.selectRow(rowIndex)
選擇一行,然後我想
$scope.gridApi.selection.getSelectedRows()
我得到了0(零)行返回所選行。爲什麼?我究竟做錯了什麼?
$scope.gridApi.selection.selectRow(rowIndex)
選擇一行,然後我想
$scope.gridApi.selection.getSelectedRows()
我得到了0(零)行返回所選行。爲什麼?我究竟做錯了什麼?
我不知道rowIndex
是什麼,但selectRow()
接收對象而不是整數。
例如:$scope.gridApi.selection.selectRow($scope.gridOptions.data[0])
在一些示例Plunker
所以,這是一個黑客.. :)它的工作就像一個魅力現在!謝謝! – lazerbrain
沒有人知道,直到你分享更多的代碼 –