KoolReport's Forum

Official Support Area, Q&As, Discussions, Suggestions and Bug reports.
Forum's Guidelines

Own value in footer instead of aggregate function #797

Open Oliver Nitschke opened this topic on on Apr 11, 2019 - 5 comments

Oliver Nitschke commented on Apr 11, 2019

I need my own calculated value in the footer. Unfortunately, this is currently not possible, because only the predefined aggregate functions can be used. Therefore I added a default to the switch statement in the file DataTables.tpl.php (line 109).

default:
$footerValue = $footerMethod;
break;

It would be great if you could take this over into the next deploy and if necessary this extension into further packages.

KoolReport commented on Apr 12, 2019

I have sent your suggestion to dev.team, probably the solution will be the ability to assign anonymous function for your own footer calculation like this:

"footer"=>function($store)
{
    return $my_own_value;
}

The $store is the actually the datastore assigned to datatables, you can use the data to generate your own calculated value.

Eugene commented on Aug 17, 2019

Hi,

Was it implemented? I tried but it looks like was not...

KoolReport commented on Aug 18, 2019

It wasn't implemented yet. May be in next version.

KoolReport commented on Aug 18, 2019

I've asked dev.team and they said the feature has been implemented and confirmed to be available in next version.

Eugene commented on Aug 18, 2019

Thanks.... It is a good news I hope my issue with css in pdf will be also resolved soon :-)

Build Your Excellent Data Report

Let KoolReport help you to make great reports. It's free & open-source released under MIT license.

Download KoolReport View demo
suggestion

DataGrid