QuickFix – Toggle Row Selection in ng-grid when multiselect is false

By default, when a ng-grid is set to single row selection mode (multiselect: false), we cannot deselect the row by clicking on it again.
Here is a quick solution for toggling row selection in ng-grid. You just need to set keepLastSelected: true in gridOptions.
Resources: https://github.com/angular-ui/ui-grid/wiki/Configuration-Options

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s