Bug 510448 - When editing a share transaction I cannot change the total amount
Summary: When editing a share transaction I cannot change the total amount
Status: NEEDSINFO WAITINGFORINFO
Alias: None
Product: kmymoney
Classification: Applications
Component: general (other bugs)
Version First Reported In: 5.2.1
Platform: Other Linux
: NOR normal
Target Milestone: ---
Assignee: KMyMoney Devel Mailing List
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2025-10-10 09:46 UTC by Ingo Klöcker
Modified: 2025-10-10 23:55 UTC (History)
0 users

See Also:
Latest Commit:
Version Fixed In:
Sentry Crash Report:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Ingo Klöcker 2025-10-10 09:46:27 UTC
I wanted to fix a typo in the numbers of shares of a Sell shares transaction. Although the price entry for this share is set to "Total for all shares" in the editor I cannot change the total (which is wrong after changing the number of shares because KMyMoney recalculates it based on the wrong price/share).

STEPS TO REPRODUCE
1. Create a share with price entry "Total for all shares"
2. Sell some of those shares (very likely you can also buy some shares)
3. Now try to edit the number of shares you sold/bought without changing the Total price

OBSERVED RESULT
1. The Total changes when I edit the number of shares.
2. I cannot edit the Total (but I can edit the price/share).

EXPECTED RESULT
1. For a share configured with price entry "Total for all shares" when changing the number of shares of an existing transaction then the price/share should be recalculated based on the new number of shares and the (old) Total.
2. For a share configured with price entry "Total for all shares" when editing a buy/sell/etc. for such a share then it should be possible to change the Total and the Price/share should be read-only.
Comment 1 Jack 2025-10-10 23:55:01 UTC
I cannot reproduce this with a recent version compiled from git (either master (self compiled) or 5.2 branch (Appimage)) but I CAN reproduce with an older Appimage from the 5.2 branch.  If you are using a released version of 5.2.1, then I would say to confirm with a version from git (either master or 5.2 branch, Appimage should be fine for testing) as it appears this may have been fixed already.