Footer callback formatting numbers

Footer callback formatting numbers

ssurancessurance Posts: 2Questions: 1Answers: 0

I have a column with all currency numbers. IE: $0.50, $1.25, $0.05. I am using "footerCallback" to tally this column. The problem is, the total value is showing like "$7.540000000000001" instead of "$7.54". Also, It shows "$5.3" instead of "$5.30".

I tried the following on a column, but this has no effect on the footer tally. Any ideas on how I can get the correct currency to show on the footer tally?

"aoColumnDefs": [ {
        "aTargets": [ 10 ],
            "mRender": function (data, type, full) {
             var formmatedvalue=data.replace(///REGEX);
                  return formmatedvalue;
            }
            }]

Answers

  • ssurancessurance Posts: 2Questions: 1Answers: 0
    edited July 2015

    Is there a way to run the replace function on the footer?

This discussion has been closed.