dart-league/ng_bootstrap

Bs-table column does not support sorting on Number and Date basis !!!

Closed this issue · 1 comments

The bs-column component does not supports sorting on number and date basis.
Its supports sorting on String .

Is it possible to add any customize method/function for sorting on number /Date basis ???

Returning data as Comparable (rather than String) helps:

Comparable getData(dynamic row, String fieldName) {
var data = fieldName.split('.').fold(row, _getDataFn);
if(data is Comparable) {
return data;
}
return data.toString();
}