I am able to get the aggreate values from server to
client, but could not display it on the template. Am i missing something
here.Appreciate your help. iam using meteorhacks/meteor-aggregate package.
thanks for direction, i have done that but getting the following error. Not sure what iam missing here.
my client.js file
Template.DashboardCategoriesChart.helpers({
âCategoryAggregateItemâ:function(){
return this.CategoryAggregateItem;
}
});
Template.DashboardCategoriesChart.onCreated(function () {
this.CategoryAggregateItem = new ReactiveVar(null);
Meteor.call(âgetAggregateCategoriesSumâ,function(errors,results){
console.log("results value: "+ JSON.stringify(results))
this.CategoryAggregateItem.set(results);
})
})
Getting the following error.
Exception in delivering result of invoking âgetAggregateCategoriesSumâ: TypeError: Cannot read property âsetâ of undefined