Create Pinned (frozen) rows feature
While not a 2.x feature, allow the user to freeze a row or rows at the top or bottom of the viewport would be the cat's meow.
Cat's meow indeed! +1
Yeah please, pretty please :+1:
This is an important feature to have. Please try to address this as it would be a good feature to include.
Yes good to have it.
+1 too!
This is complete in 3.0.
Any Update?
I have extensively search this feature in 3.0 (Row Pinning) but i could not figure out. please advice. May be i am not interpreting well.
+1
This feature is still not available or I am not able to find this? Please reply
This feature is available and present in 3.0, tutorial is http://ui-grid.info/docs/#/tutorial/203_pinning
I am talking about row pinning here. I want a frozen row at the top of the grid just below the header.
Nope, that's not available.
Has anyone worked on freezing of the top most row? Any pointers would be very much appreciated.
This might be a temporary but only available solution. To freeze a row at top(other than header), you can move footer above view port. Go to ui-grid-unstable.js file. Search for uiGridRenderContainer template cache.
old code: $templateCache.put('ui-grid/uiGridRenderContainer', "[div class="ui-grid-render-container" ng-style="{ 'margin-left': colContainer.getMargin('left') + 'px', 'margin-right': colContainer.getMargin('right') + 'px' }"][div ui-grid-header][/div][div ui-grid-viewport][/div][div ui-grid-footer ng-if="grid.options.showColumnFooter"][/div][/div]" );
New code: $templateCache.put('ui-grid/uiGridRenderContainer', "[div class="ui-grid-render-container" ng-style="{ 'margin-left': colContainer.getMargin('left') + 'px', 'margin-right': colContainer.getMargin('right') + 'px' }"][div ui-grid-header][/div][div ui-grid-footer ng-if="grid.options.showColumnFooter"][/div][div ui-grid-viewport][/div][/div]" ); Note the position of footer div. I have just shifted it before viewport. That's it. No other change required.
Could this feature request be reopened since it was wrongfully closed?
@c0bra It seems this was closed by mistake; while column pinning has been implemented, row pinning has not. On our project we'd like to have a row that batch updates all other selected rows, and this is on a grid that already has several pinned columns (so it's difficult to fake/work around it). Thanks!
Please reopen this feature - it does appear to have been closed by mistake upon the completion of column pinning. This feature is row pinning.
My solution for row pinning is to create a hidden column that looks like this:
{
field: 'pinned',
visible: false,
sort: {direction: uiGridConstants.ASC, priority: 0}, //use uiGridConstants.DESC for pinning to the bottom
suppressRemoveSort: true,
sortDirectionCycle: [uiGridConstants.ASC] //use uiGridConstants.DESC for pinning to the bottom
}
Then include a button for each row to toggle their 'pinned' state.
Row entities which have pinned = true rise to the top, even when other sorting are applied.