Bug 492093

Summary: Fees ignore decimal precision set at currency level
Product: [Applications] kmymoney Reporter: koalaleaves+kde
Component: generalAssignee: KMyMoney Devel Mailing List <kmymoney-devel>
Status: RESOLVED NOT A BUG    
Severity: normal    
Priority: NOR    
Version First Reported In: unspecified   
Target Milestone: ---   
Platform: Other   
OS: All   
Latest Commit: Version Fixed In:
Sentry Crash Report:

Description koalaleaves+kde 2024-08-23 16:18:07 UTC
Fees are locked at having only two decimal places despite currencies set at higher levels of precision.
Comment 1 Thomas Baumgart 2024-08-23 16:35:14 UTC
Please provide the KMyMoney version and details on how to reproduce the problem. Thx.
Comment 2 koalaleaves+kde 2024-08-23 16:49:18 UTC
Steps to reproduce:

1. Create a new kmy file and select GBP as default currency
2. Create an investment account with a brokerage account
3. Go to Tools > Currencies > Edit and set GBP price precision to 10 then exit
4. Go to investment account and create a buy stock transaction
5. Fill in anything for the name of the security and create an expense category for fee
6. Type 0.015 for fee with the aforementioned expense category created

Actual behavior: 0.015 rounded to 0.01
Expected: 0.015 becomes 0.0150000000 given the price precision set for this currency
Comment 3 koalaleaves+kde 2024-08-23 16:52:45 UTC
Version 5.116.0
Comment 4 Thomas Baumgart 2024-08-24 06:37:43 UTC
The price precision is not what is taken into account here, but the smallest account and cash units of a currency. I am not sure if you can achieve what you are trying to do..