在ui-grid上选择所有事件时选择组级别行 [英] Selecting group level row on selecting all event on ui-grid
问题描述
当用户单击ui-grid标头上的全选事件时,我试图对事件做出反应.确实会选择所有行,这是预期的行为,但是没有选择高级别的组行,我认为这对用户而言是违反直觉的.您可以在此处看到示例:
我知道触发的事件是:
gridApi.selection.on.rowSelectionChangedBatch($ scope,function(rows){//做一点事});
但是当我遍历传递给函数的行时,看不到属于组级别行的行,因此可以选择它们.有办法吗?
根据文档
I am trying to react on event when user clicks on select all event on header of ui-grid. All rows do get selected, which is expected behavior, but high level group rows are not selected which in my opinion is counter-intuitive for a user. You can see example here: http://embed.plnkr.co/rUsK0LfGF3ws8vhsc9sR/
I know that triggered event is:
gridApi.selection.on.rowSelectionChangedBatch($scope,function(rows){
// do something
});
But when I iterate through rows passed to function I don't see the ones that are group level rows so I could select them. Is there a way to do this?
As per the documentation HERE
Group header rows cannot be edited, and if using the selection feature, cannot be selected. They can, however, be exported.
Have a look at the below screen shot which is taken from Complex grouping found
这篇关于在ui-grid上选择所有事件时选择组级别行的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!