Bug 430409 - Can't cancel Schedule Details dialog presented on startup
Summary: Can't cancel Schedule Details dialog presented on startup
Status: RESOLVED FIXED
Alias: None
Product: kmymoney
Classification: Applications
Component: general (show other bugs)
Version: 5.1.0
Platform: Arch Linux Linux
: NOR normal
Target Milestone: ---
Assignee: KMyMoney Devel Mailing List
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2020-12-15 04:02 UTC by gnemas
Modified: 2020-12-16 21:40 UTC (History)
0 users

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


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description gnemas 2020-12-15 04:02:09 UTC
SUMMARY

When the "Schedule Details" dialog is presented at startup, KMyMoney
enters the scheduled transaction even though Cancel or Ignore is
clicked.

This incorrect behavior seems to occur only when the data file is loaded at
program startup. If the data file is loaded manually after starting the
program (e.g., by closing without saving and reopening), the Schedule
Details dialog again opens, but this time the Cancel and Ignore buttons
function correctly.

STEPS TO REPRODUCE
1. Create a new data file with a single checking account with $100 balance.
2. Schedule a monthly bill starting 5 days in the future with amount
$50 with "The amount is an estimate" and "Enter this schedule into register
automatically" checked.
3. In options, check "Check schedules on startup", and set "Enter transactions this number of days in advance" to 14.
4. Save the file and exit KMyMoney.
5. Restart KMyMoney.
6. When Schedule Details dialog is presented, click Cancel or Ignore

OBSERVED RESULT

The transaction is entered and the next date is updated.

EXPECTED RESULT

The transaction should not be entered, and the next date should remain
unchanged.

SOFTWARE/OS VERSIONS
Operating System: Arch Linux
KDE Plasma Version: 5.20.4
KDE Frameworks Version: 5.77.0
Qt Version: 5.15.2
Kernel Version: 5.9.14-arch1-1
OS Type: 64-bit
Processors: 2 × Intel® Celeron® CPU N2840 @ 2.16GHz
Memory: 1.9 GiB of RAM
Graphics Processor: Mesa DRI Intel® HD Graphics
Comment 1 Thomas Baumgart 2020-12-16 21:40:08 UTC
Git commit eb19959bc70ac7fa90f05012dc19614648e14a0f by Thomas Baumgart.
Committed on 16/12/2020 at 21:39.
Pushed by tbaumgart into branch '5.1'.

Make sure canceling a schedule entry does not create a transaction

The cancel transaction is disabled in the background in the
kgloballedgerview code. This causes the cancel operation to fail.
Enabling it after this solves the problem.
FIXED-IN: 5.1.1

M  +4    -2    kmymoney/views/kscheduledview_p.h

https://invent.kde.org/office/kmymoney/commit/eb19959bc70ac7fa90f05012dc19614648e14a0f