Skip to content

Commit

Permalink
Fix: sorting not working for columns with special characters
Browse files Browse the repository at this point in the history
  • Loading branch information
arikfr committed May 19, 2015
1 parent 30a89bf commit f46e8af
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion rd_ui/app/scripts/ng_smart_table.js
Original file line number Diff line number Diff line change
Expand Up @@ -381,7 +381,10 @@
function sortDataRow(array, column) {
var sortAlgo = (scope.sortAlgorithm && angular.isFunction(scope.sortAlgorithm)) === true ? scope.sortAlgorithm : filter('orderBy');
if (column) {
return arrayUtility.sort(array, sortAlgo, column.sortPredicate, column.reverse);
var predicate = function(o) {
return o[column.sortPredicate];
};
return arrayUtility.sort(array, sortAlgo, predicate, column.reverse);
} else {
return array;
}
Expand Down

0 comments on commit f46e8af

Please sign in to comment.