Hi,
is it possible to get the value of the footer (sum) of a datatable (and a Pivot Datatable) for further use?
Thanks!
Martin
Hi,
is it possible to get the value of the footer (sum) of a datatable (and a Pivot Datatable) for further use?
Thanks!
Martin
Hi,
There is not possibility to get footer text. Therefore, you need to calculate sum for columns values. For example:
$$("pivot").$$("data").attachEvent("onAfterLoad", function(){
var columns = this.config.columns;
var sum = {};
for(var i =1; i< columns.length; i++){
var columnId = columns[i].id;
sum[columnId] = 0;
this.eachRow(function(id){
var item = this.getItem(id);
if(item.$level ==1){
sum[columnId] += item[columnId]||0;
}
});
}
});
$$("pivot").load(url);