bertvandepoel / tabby

A friendly tool to manage debt
GNU Affero General Public License v3.0
71 stars 11 forks source link

Debt values >1,000.00 not shown properly in record #8

Closed tghdev closed 3 years ago

tghdev commented 3 years ago

Debt records with values above 1,000.00 are not displayed correct. The total amount of debt per person on the other hand is correct.

Add new debt via activity: 1,234.56 shows up under people overview as -1.23 Database field "amount" [int(11)] shows 123

Add new debt via activity: 1234.56 shows up under people overview as -1.00 Database field "amount" [int(11)] shows 123456

Technical: MariaDB 10, php7.2

bertvandepoel commented 3 years ago

Thank you for reporting this bug. Since I'm mostly tracking small amounts, I hadn't noticed this yet. It stems from some number formatting that is getting confused by both "," and "." in the numbers. This has also caused me to notice there are some other problems in places where numbers are formatted. I'm probably going to write a fix tonight and make a new minor release. After upgrading (either through the release or through git) should then solve your issue. I will let you know when the fix is available. If you come across any further problems, then feel free to create more issues on Github.

bertvandepoel commented 3 years ago

Sorry for the delay. While making the necessary changes, I found more problems that needed addressing. Could you upgrade to version 1.1.2 please? This update requires no database changes, so just unpacking the necessary files from the release or pulling git (depending on your installation type) should get you sorted. Then give it a try and let me know if your problem is fixed. It looks fine on my end, but I would like to be sure it's all working and clear for you as well before closing this issue.

tghdev commented 3 years ago

No hurry! The changes look good. Values are now properly displayed. I'm closing this issue. Thanks @bertvandepoel