Closed Acacio2000 closed 7 months ago
To get around the problem, I made an adjustment that worked for me. inside pluto_column_type.dart in 'mixin PlutoColumnTypeWithNumberFormat' I adjusted toNumber
// Convert [String] converted to [applyFormat] to [number]. dynamic toNumber(String formatted) { String match = '0-9\-${numberFormat.symbols.DECIMAL_SEP}'; if (numberFormat.symbols.DECIMAL_SEP == ',') { int countP = formatted.split('.').length - 1; int countV = formatted.split(',').length - 1; if ((countV == 0) && (countP == 1)){ match += '.'; } } if (negative) { match += numberFormat.symbols.MINUS_SIGN; } formatted = formatted.replaceAll(RegExp('[^$match]'), '').replaceFirst(numberFormat.symbols.DECIMAL_SEP, '.'); final num formattedNumber = num.tryParse(formatted) ?? 0; return formattedNumber.isFinite ? formattedNumber : 0; }
This issue is stale because it has been open for 30 days with no activity.
This issue was closed because it has been inactive for 14 days since being marked as stale.
When I click on the title of a numeric column (Number, Currency) using 'locale' numberFormat.symbols.DECIMAL_SEP equal to ',' (comma) the ordering is broken. in example "currency_type_column_screen", try to sort "column 4" or "column 5" ... and see.. sort order fail !