File tree Expand file tree Collapse file tree 3 files changed +4
-3
lines changed Expand file tree Collapse file tree 3 files changed +4
-3
lines changed Original file line number Diff line number Diff line change 235
235
} ) ;
236
236
237
237
// Figure out whether this column is sortable or not
238
- if ( uiGridCtrl . grid . options . enableSorting && $scope . col . enableSorting ) {
238
+ if ( $scope . col . enableSorting ) {
239
239
$scope . sortable = true ;
240
240
}
241
241
else {
Original file line number Diff line number Diff line change @@ -645,7 +645,7 @@ angular.module('ui.grid')
645
645
//self.cursor = self.sortable ? 'pointer' : 'default';
646
646
647
647
// Turn on sorting by default
648
- self . enableSorting = typeof ( colDef . enableSorting ) !== 'undefined' ? colDef . enableSorting : true ;
648
+ self . enableSorting = typeof ( colDef . enableSorting ) !== 'undefined' ? colDef . enableSorting : self . grid . options . enableSorting ;
649
649
self . sortingAlgorithm = colDef . sortingAlgorithm ;
650
650
651
651
/**
Original file line number Diff line number Diff line change @@ -356,7 +356,8 @@ angular.module('ui.grid')
356
356
* @propertyOf ui.grid.class:GridOptions
357
357
* @description True by default. When enabled, this setting adds sort
358
358
* widgets to the column headers, allowing sorting of the data for the entire grid.
359
- * Sorting can then be disabled on individual columns using the columnDefs.
359
+ * Sorting can then be disabled / enabled on individual columns using the columnDefs,
360
+ * if it set, it will override GridOptions enableSorting setting.
360
361
*/
361
362
baseOptions . enableSorting = baseOptions . enableSorting !== false ;
362
363
You can’t perform that action at this time.
0 commit comments