$.fn.dataTable.render.number

$.fn.dataTable.render.number

cybersapiencybersapien Posts: 7Questions: 1Answers: 0
edited June 2014 in Bug reports

negative float values showing an extra digit

jquery.dataTables.js @ line 14055

--- var floatPart = precision ? (decimal+(d - intPart).toFixed( precision )).substring( 2 ):'';

+++ var floatPart = precision ? (decimal+(d - intPart).toFixed( precision )).replace('-', '').substring( 2 ):'';

Replies

  • allanallan Posts: 63,498Questions: 1Answers: 10,471 Site admin

    Nice one thanks for pointing this out! I'll commit the fix when I get back into the office on Monday.

    Regards,
    Allan

  • allanallan Posts: 63,498Questions: 1Answers: 10,471 Site admin

    Sorry, I was a bit tied up at the start of the week. I've just committed a fix here: https://github.com/DataTables/DataTablesSrc/commit/89ab148ad45a . When taking into account the currency symbol (prefix) I had to make a couple of other changes as well, but this will be the 1.10.1 release and is now in the nightly.

    Thanks again!
    Allan

  • cybersapiencybersapien Posts: 7Questions: 1Answers: 0

    Thank you Allan

This discussion has been closed.