angular-ui/ui-grid

suggestion: grouping: support automatic pinning

Open

#4,123 建立於 2015年8月5日

在 GitHub 查看
 (5 留言) (0 反應) (0 負責人)JavaScript (5,395 star) (2,496 fork)batch import
good first issuetype: enhancementworkaround

描述

It would be great to automatically pin a column when grouping by the column.

I've tried to implement a workaround with the available gridApi, but I cannot find an easy way to see if the column is already pinned (for example, the existance of an isPinnedLeft attribute) or already grouped.

pseudo-code:

gridApi.grouping.on.groupingChanged(col){
    if(!col.isPinnedLeft){
        gridApi.pinning.pinColumn(col, uiGridPinningConstants.container.LEFT)
    }
...
}

貢獻者指南