Summary: | 2 payments shown in payments overview | ||
---|---|---|---|
Product: | [Applications] kmymoney | Reporter: | Achim Schaefer <achim_schaefer> |
Component: | general | Assignee: | Ian Neal <iann_bugzilla> |
Status: | RESOLVED FIXED | ||
Severity: | normal | CC: | asoliverez, iann_bugzilla, kmymoney-devel |
Priority: | NOR | ||
Version: | unspecified | ||
Target Milestone: | --- | ||
Platform: | Debian testing | ||
OS: | Linux | ||
Latest Commit: | Version Fixed In: | ||
Bug Depends on: | |||
Bug Blocks: | 238937 | ||
Attachments: |
Change how khomeview counts overdue dates v0.1
Backport to KMM2 of khomeview patch v0.1 |
Description
Achim Schaefer
2010-05-17 20:47:30 UTC
Unfortunatly the version did not get into the bug. it is 3.98.0 It just so happens, that I see the same thing here. The problem only shows for those schedules, that are overdue and the due date falls on a non-processing day (weekend) and the option is set to adjust the payment date to the previous processing date (Friday). In that case, one gets an extra occurrence. I will check tomorrow (Tuesday) if that only shows on a Monday (the day after the non-processing period) Looks like this one also applies to version 1.0.5 of the application. The problem lies in MyMoneySchedule, in the way nextPayment and adjustedNextPayment work. adjustedNextPayment only adjusts the calculation made by nextPayment, whereas nextPayment should have within its logic how to adjust the date. Otherwise, when it gets a date prior to current date, it simply returns the current date, which is the logic thing to do. nextPayment has to be modified to account for adjusted dates and behave accordingly. I have a rewrite of nextPayment and adjustedNextPayment sitting in my tree, just needs a bit more testing before releasing. Created attachment 43877 [details]
Change how khomeview counts overdue dates v0.1
This patch:
* Splits the existing mymoneyscheduled method transactionsRemaining into two methods:
** transactionsRemainingUntil which takes an endDate parameter and counts the number of transactions until that endDate;
** transactionsRemaining now calls transactionsRemainingUntil with m_endDate as an argument.
* Additional checks are in transactionsRemainingUntil to make sure the start and end date passed to paymentDates are valid;
* khomeview's showPayment function uses the new transactionsRemainingUntil method with an argument of the day before the current date.
Created attachment 43878 [details]
Backport to KMM2 of khomeview patch v0.1
This is a backport to KMM2 of the KMM4 patch.
SVN commit 1130652 by iann: BUG: 237964 2 payments shown in payments overview This patch: * Splits the existing mymoneyscheduled method transactionsRemaining into two methods: ** transactionsRemainingUntil which takes an endDate parameter and counts the number of transactions until that endDate; ** transactionsRemaining now calls transactionsRemainingUntil with m_endDate as an argument. * Additional checks are in transactionsRemainingUntil to make sure the start and end date passed to paymentDates are valid; * khomeview's showPayment function uses the new transactionsRemainingUntil method with an argument of the day before the current date. M +8 -3 mymoney/mymoneyscheduled.cpp M +9 -0 mymoney/mymoneyscheduled.h M +2 -10 views/khomeview.cpp WebSVN link: http://websvn.kde.org/?view=rev&revision=1130652 |