Author Topic: Comma as currency separator can mess up your budget  (Read 411 times)

Offline coel

Comma as currency separator can mess up your budget
« on: December 31, 2016, 12:39:44 PM »
I just noticed that right now, it is very easy to mess up your budget if your localisation settings have a comma as currency separator. Entering a value of 10,50 must be entered as '10.50' to be displayed correctly as '10,50' in the budget cell. Entering '10,50' will result in a value of 1.050,00.

The dangerous part is, that selecting/highlighting any value in a budget cell and pressing <enter> will ignore the comma and result in 100x the correct amount being entered as the new value. Now the next cell is selected, and the problem repeats. Hitting <enter> several times in a row can quickly mess things up.

I have run into this problem in Firefox 50.1.0 on a Windows 7 machine.

EDIT: Restarting Firefox has apparently solved the problem. Very strange.

EDIT 2: Just happened again, refreshing the page fixed it.
« Last Edit: January 01, 2017, 01:59:05 PM by coel »

Offline Alex

Re: Comma as currency separator can mess up your budget
« Reply #1 on: January 01, 2017, 10:16:06 PM »
That's really weird. I will definitely keep my eye out for it. Thanks for reporting.

Also if anyone else is encountering this, please let me know!
I am the Financier owner/admin/coder dude.

Offline NeV3rKilL

Re: Comma as currency separator can mess up your budget
« Reply #2 on: January 16, 2017, 09:52:29 AM »
In my system, apart of the numpad (.) issue, is working as intended.

If I put 12.3 the system screws and put 123. If I put 12.345 the system put 12345.

But if I use the comma decimal 12,3 then the quantity noted is 12,3 as expected.

I think you should replace all "," introduced to "." in the input (I guess in the code the decimal separator is a dot point), and then show the number according the system localization and completely forget about "," as thousands separator.