Bug 428434 - Column not deleted on update of a forecast with different cycle duration
Summary: Column not deleted on update of a forecast with different cycle duration
Status: RESOLVED FIXED
Alias: None
Product: kmymoney
Classification: Applications
Component: general (show other bugs)
Version: 5.0.8
Platform: Mint (Ubuntu based) Linux
: NOR minor
Target Milestone: ---
Assignee: KMyMoney Devel Mailing List
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2020-10-29 14:44 UTC by sayanel
Modified: 2020-11-01 11:59 UTC (History)
0 users

See Also:
Latest Commit:
Version Fixed In: 5.1.1


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description sayanel 2020-10-29 14:44:03 UTC
SUMMARY
Extra columns, if there are any, are not deleted when changing the "Days of cycle" of a forecast.

STEPS TO REPRODUCE
1. Go to 'forecast' tab. Days to forecast: 90. Days of cycle: 15. Click forecast
2. Displayed summary has a total of 9 columns
3. Change days of cycle to 30 (or whatever number above). Hit forecast.
4. Displayed output has now 6 (or less) columns


OBSERVED RESULT
Columns 7 to 9 still have their old headers ("75 days", "90 days" and "Total variation") and are empty. They should have been deleted or have their header removed.

EXPECTED RESULT
Their should be only 6 columns, whatever the previous setting is.


SOFTWARE/OS VERSIONS
Linux/KDE Plasma: Linux Mint 20 Cinnamon. Cinnamon 4.6.7.
KDE Plasma Version: ?
KDE Frameworks Version: 5.68.0
Qt Version: 5.12.8 (build against 5.12.8)
Comment 1 Thomas Baumgart 2020-11-01 11:58:32 UTC
Git commit 2bc5474f3043d0814dfddec52ef70ae2f8edd6d9 by Thomas Baumgart.
Committed on 01/11/2020 at 11:52.
Pushed by tbaumgart into branch 'master'.

Adjust column count in forecast view

A call to QTreeWidget::clear() does not affect the column count. This
needs to be handled separately.

M  +4    -2    kmymoney/plugins/views/forecast/kforecastview_p.h

https://invent.kde.org/office/kmymoney/commit/2bc5474f3043d0814dfddec52ef70ae2f8edd6d9
Comment 2 Thomas Baumgart 2020-11-01 11:59:39 UTC
Git commit 7323b85a3df8329c6bc1baf3197ee9953afd6833 by Thomas Baumgart.
Committed on 01/11/2020 at 11:59.
Pushed by tbaumgart into branch '5.1'.

Adjust column count in forecast view

A call to QTreeWidget::clear() does not affect the column count. This
needs to be handled separately.
FIXED-IN: 5.1.1

(cherry picked from commit 2bc5474f3043d0814dfddec52ef70ae2f8edd6d9)

M  +4    -2    kmymoney/plugins/views/forecast/kforecastview_p.h

https://invent.kde.org/office/kmymoney/commit/7323b85a3df8329c6bc1baf3197ee9953afd6833