Whats the equivalent for ng-grid's beforeSelectionChange in ui-grid?
See original GitHub issueIn this section of the documentation: http://ui-grid.info/docs/#/api/ui.grid.selection.api:PublicApi
I see two events:
rowSelectionChanges
and rowSelectionChangedBatch
What is the equivalent for beforeSelectionChange
that was available back in ng-grid?
Why I need it and why I was using it in ng-grid?: When the user selects a row, an ajax call is performed. While this ajax call is happenning, I don’t want to allow the selection to be modified, so I used to do this:
beforeSelectionChange: function () {
return !($scope.doingAjaxCall);
},
which locks selection if ajax is happenning
Issue Analytics
- State:
- Created 8 years ago
- Comments:10 (3 by maintainers)
Top Results From Across the Web
Whats the equivalent for ng-grid's "beforeSelectionChange" in ...
While the ajax call is happenning I set $scope.doingAjaxCall = true , and to prevent the user from changing the selection, I had...
Read more >210 Selection - UI Grid
By default the selection feature will divide selection changes into batch events and single events, there are two different events provided in the...
Read more >Angular Data Grid Overview and Configuration - Infragistics
Create super fast, responsive Angular data grids and tables with Ignite UI for Angular. Supports editing, filtering, data binding and many more. Try...
Read more >Upgrading to ng-grid 3.0 (ui-grid) | technpol
You can also use curl to retrieve the files, or right click on them in your browser and select save as. As before,...
Read more >Styling UI grid - Forum - Refinitiv Developer Community
I am using UI-grid to display data, and I would like to style it, so that gets Reuters look and feel. Could you...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Sorry if it sounds pushy, but for me it is clearly a defect that
ui-grid
doesn’t have an easy way of disabling selection while an ajax call is happenning.ng-grid
had an easy way for that.defect: a shortcoming, imperfection, or lack.
ui-grid lacks this feature.
Regarding closing this question: maybe I should have written this question with the shape of a defect, and not as a question itself.
You may not be aware of it, but your tone is somewhat pushy in that last comment.
If we had stated that the new ui-grid was a superset of all ng-grid functionality, then yes it would be a defect if ui-grid didn’t have some things that ng-grid used to. However, we didn’t state that. ui-grid has many of the features of ng-grid and tried to keep similar interfaces where we could. But there’s no guarantee it has all the features of ng-grid.
ui-grid has a way to achieve what you are seeking to achieve, your issue was actually a question as to how to use that capability. Stack overflow is the correct place for questions.