Forum Replies Created
-
Author
-
[SOLVED]
Finally, i get what i need, thnx Mariya for your inspired reply…. nice to meet u btw…
I’m modified some code here :
{
text: ‘Akurasi Stok WIP Keramik’,
align: ‘center’,
datafield: ‘akurasi’,
filterable: false,
cellsalign: ‘right’,
width: 120,
aggregates: [‘avg’],
aggregatesrenderer: function (aggregates, column, element, summaryData) {
var renderstring = “<div style=’padding:5px’>Rerata: “;
var total = aggregates.avg;
renderstring += total.toFixed(2);;
renderstring += ” %</div>”;
return renderstring;
}
},Note : How to closed this thread as closed / solved?
Thanx for fast respons.
I’ve seen the demo before, but still confused how to combine in this code below.{
text: ‘Akurasi Stok WIP Keramik’,
align: ‘center’,
datafield: ‘akurasi’,
filterable: false,
cellsformat: ‘n’,
cellsalign: ‘right’,
width: 120,
aggregates: [
{
‘total’: function (aggregatedValue, currentValue, column, record) {
return aggregatedValue + currentValue;
}
},
],
aggregatesrenderer: function (aggregates, column, element, summaryData) {
var renderstring = “<div style=’padding:5px’>”;
var total = aggregates.total;
renderstring += total;
renderstring += “</div>”;
return renderstring;
}
},can u help how to add code (what i must add) to get average value replace sum value.
-
AuthorPosts