meteor-tabular
meteor-tabular copied to clipboard
is there any plan to support sorting on calculated fields?
i.e,
- if user collection contains two field
amt1andamt2 - using
columns: [{title: "toatalamt", data: 'total()'}],totalamtfield doesn't exists in user collection. - and meter helper as below.
User.helpers({
total: function () {
return this.amt1 + this.amt2;
}
});
The sort icon doesn't appears on totalamt column
I doubt it at this point. The only thing meteor-tabular seems to be able to sort (and search) is native data fields on the document.
So denormalizing this value to your actual document is one work-around.
Anybody have any workarounds for this? Was thinking of way to override the orderable events and then pass in a sort option to the pub