KoolReport's Forum

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

Datatable export showing wrong footer by dividing it to hundred #2021

Open ankit raj opened this topic on on Apr 12, 2021 - 4 comments

ankit raj commented on Apr 12, 2021

Hi , In datagrid i am using a footerText which renders perfect in UI but while exporting it divides the footer by 100. how can i remove it?

  "footerText"=>'100%'

Attached screenshot

Sebastian Morales commented on Apr 13, 2021

Did you mean export using Buttons plugin or our Export package? Please share your report code, export code and screenshots as well. Tks,

ankit raj commented on Apr 13, 2021

Hi i am using export buttons plugin.

This is the code snippet for that column and buttons:

'LFY_Count' =>
                    [
                        'label'=>'LFY % Cont.',
                        'formatValue'=>function($value,$row){
                         //added formatting to display % in the end
                        },
                       "footerText"=>'100%'

                  "buttons" => [
                        array(
                            'extend'=>'excelHtml5',
                            'text'=>'<i class="fa fa-file-excel-o"></i>',
                            'titleAttr'=>'Excel',
                           'footer'=>true,
                        )
                    ],

This 100% is showing properly in footer as seen in the UI screenshot. But while exporting , it shows 1 as shown in the question screenshot.

ankit raj commented on Apr 14, 2021

Hi koolreport , any updates on this?

Sebastian Morales commented on Apr 15, 2021

Pls try to change your column's meta type to "string". If that doesn't work, try to change the footer text to "100 %" instead of "100%". Let us know the result. Tks,

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
help needed

DataGrid