Column sorting is not working with numbers(formatted like 1,234,45.00) #2868
Unanswered
rajesh-rk1
asked this question in
PrimeNG
Replies: 1 comment 1 reply
-
@rajesh-rk1 Hi! It should work. This is what's happening internally: https://github.com/primefaces/primeng/blob/d6c7ffcfc5cb9a8ed355399ddae276c279836ccf/src/app/components/table/table.ts#L1593-L1605 Which PrimeNg version are you using? const a = '2,234,45.00';
const b = '1,234,45.00';
console.log(b.localeCompare(a));
console.log(a < b);
> -1
> false |
Beta Was this translation helpful? Give feedback.
1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Beta Was this translation helpful? Give feedback.
All reactions