We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. (Last updated on: November 16, 2018).
Unfortunately, activation email could not send to your email. Please try again.
Syncfusion Feedback

How do we do Row Summaries?

Thread ID:

Created:

Updated:

Platform:

Replies:

130651 May 23,2017 05:44 PM UTC May 24,2017 04:14 AM UTC JavaScript 2
loading
Tags: ejGrid
Bruce Van Horn
Asked On May 23, 2017 05:44 PM UTC

We can do column summaries, but what about row summaries?  Even better, selective columns?

Consider a grid that has file size totals broken down by how old the files are.  We want to tell the customer how much space they can save if they move all their files two years and older to a cheaper drive:

$("#enterprisefilesharesummarygrid").ejGrid({
dataSource: data,
allowPaging: true,
allowSorting: true,
allowReordering: true,
allowResizing: true,
allowFiltering: true,
enableHeaderHover: true,
filterSettings: {filterType: "Excel"},
columns: [
{field: "share_name", headerText: "Share Name", textAlign: ej.TextAlign.Center},
{field: "30 day", format: "{0:N2}", headerText: "30 Days", textAlign: ej.TextAlign.Right},
{field: "90 day", format: "{0:N2}", headerText: "90 Days", textAlign: ej.TextAlign.Right},
{field: "180 day", format: "{0:N2}", headerText: "180 Days", textAlign: ej.TextAlign.Right},
{field: "365 day", format: "{0:N2}", headerText: "365 Days", textAlign: ej.TextAlign.Right},
{field: "730 day", format: "{0:N2}", headerText: "730 Days", textAlign: ej.TextAlign.Right},
{field: "older", format: "{0:N2}", headerText: "Older", textAlign: ej.TextAlign.Right},
          ?? total column here for the row ??

]
});
So it'd be great if I could total 365 and older.  Sure, I could do that in the DB or the controller, 
but what if I gave them some sort of slider that let them set the threshold.  maybe they want to see
what the totals would look like for six months and over - i'd need to dynamically summarize the rows.
Any  tips?

Bruce Van Horn
Replied On May 23, 2017 07:33 PM UTC

Nevermind - I found an example:  https://www.syncfusion.com/kb/7626/how-to-place-a-calculated-column-in-grid.


Mani Sankar Durai [Syncfusion]
Replied On May 24, 2017 04:14 AM UTC

Hi Bruce, 

Thanks for the update. 

Please let us know if you need further assistance. 

Regards, 
Manisankar Durai. 


CONFIRMATION

This post will be permanently deleted. Are you sure you want to continue?

Sorry, An error occured while processing your request. Please try again later.

Warning Icon You are using an outdated version of Internet Explorer that may not display all features of this and other websites. Upgrade to Internet Explorer 8 or newer for a better experience.Close Icon

;