Hi Alvaro,<br><br>Yes I am writing the updates to the database and even ensured that the database was closed after all my operations where completed.<br><br>I noticed that the sched.adjustedNextDueDate() is calling nextDueDate() which returns the actual posting date on the transaction I think. m_PostDate in the transaction is being set in the constructor I think from the node of TRANSACTION type and the attribute "postdate". Now I am not positive what those really are but I "think" those are corresponding to my columns in the kmmSchedule table. So if that is true then I have to have something wrong in my code somewhere, but I am lost as to where it might be.<div>
<br></div><div>Well unless someone else has any other ideas I will keep looking but I am not real sure where.<br>
<br><div class="gmail_quote">On Thu, Jul 12, 2012 at 11:34 AM, Alvaro Soliverez <span dir="ltr"><<a href="mailto:asoliverez@kde.org" target="_blank">asoliverez@kde.org</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">

Are you writing the changes after updating the schedules? I assume you do.<br>
The fields you are using seem to be the right ones.<br>
<br>
sched.adjustedNextDueDate() is a function to check for holidays,<br>
weekends, etc, and adjust the due date accordingly (ie, don't have a<br>
business schedule occur on a Sunday).<br>
<br>
I don't have much more info on that area of code.<br>
<br>
Regards,<br>
Alvaro<br>
<br>
On Thu, Jul 12, 2012 at 12:27 PM, Eric Bonney<br>
<div><div><<a href="mailto:mailinglists@vanhlebarsoftware.com" target="_blank">mailinglists@vanhlebarsoftware.com</a>> wrote:<br>
> So I have tried to do more research on this in the actual source code and I<br>
> am still a bit confused.<br>
><br>
> Inside khomeview.cpp I followed the code for the display of the Payments.<br>
> Down in showPaymentEntry() I see where the method takes a MyMoneySchedule as<br>
> a variable. This schedule is then used to get the transaction which is then<br>
> in turn used to get the split. All is good for me so far. :) but when we<br>
> actually display the date we go back to using the schedule variable that was<br>
> passed into the method and we call sched.adjustedNextDueDate().<br>
><br>
> I am assuming that adjustedNextDueDate() is returning the date from the<br>
> actual schedule not from the splits. This is the logic that I had used in my<br>
> port but when I bring the file back from the device to the desktop and open<br>
> it up, the desktop software still shows my schedule as being due in the<br>
> Payments section on the HomeView on the wrong date. I have looked at the raw<br>
> data in a database viewer and the schedule itself shows the correct next<br>
> date in the nextPaymentDue column.<br>
><br>
> Here is an example with dates to try and make it a little clearer:<br>
> I have a schedule set up at every two weeks and it is due on July 15, 2012<br>
> for $75.00<br>
><br>
> On my device I enter the schedule and move the nextPaymentDue column to<br>
> 2012-07-22 and set the lastPaymentDate to 2012-07-15. I have also set the<br>
> postDate to 2012-07-15 on the schedules splits in kmmSplits table.<br>
><br>
> Now when I look at my updated schedules on my device it properly shows the<br>
> schedule as due next on July 22nd but when I pull the device to the desktop<br>
> it is showing up still in Payments as due on July 15th. It is in the<br>
> register on the correct date just fine, but the schedule inside the Schedule<br>
> View shows July 15th and also in the Payments section of the home view.<br>
><br>
> I know I am missing something here but I can't follow the logic anymore. I<br>
> can't see anywhere else in the database where the dates could be coming from<br>
> for the schedules. They are only kept in kmmSchedules and kmmSplits as far<br>
> as I can tell. Can anyone point me in the right direction here to see what I<br>
> could be doing wrong?<br>
><br>
> Thanks,<br>
> -Eric<br>
><br>
><br>
> On Tue, Jul 10, 2012 at 5:50 PM, Eric Bonney<br>
> <<a href="mailto:mailinglists@vanhlebarsoftware.com" target="_blank">mailinglists@vanhlebarsoftware.com</a>> wrote:<br>
>><br>
>> Hi All:<br>
>><br>
>> So I am now working on implementing schedules to the port. I had read<br>
>> access working just fine and added my home widget and then added the ability<br>
>> to skip a schedule and enter a schedule from the widget itself.<br>
>><br>
>> Entering the widget creates the transaction just fine and on my port it<br>
>> advances the schedule to the next date and seems to be recording the payment<br>
>> correctly in the lastPayment and nextPaymentDue columns just fine. The issue<br>
>> is when I then move the file over to the desktop software the schedule that<br>
>> was entered shows as still being due. The transaction is reflected in the<br>
>> account just fine but the schedule has not been moved to the next due date.<br>
>><br>
>> Is this information being pulled from somewhere other than kmmSchedules? I<br>
>> didn't see anything in the kmmKeyValuePairs table for schedules but I could<br>
>> be missing something I guess.<br>
>><br>
>> Also I noticed that there is now a table kmmSchedulePaymentHistory, this<br>
>> appears to be new but it doesn't seem to have any data in it yet. Is this<br>
>> something that is going to be used in the future? I just need to know if I<br>
>> need to start populating this table as well. :)<br>
>><br>
>> Thanks,<br>
>> -Eric<br>
><br>
><br>
><br>
</div></div>> _______________________________________________<br>
> KMyMoney-devel mailing list<br>
> <a href="mailto:KMyMoney-devel@kde.org" target="_blank">KMyMoney-devel@kde.org</a><br>
> <a href="https://mail.kde.org/mailman/listinfo/kmymoney-devel" target="_blank">https://mail.kde.org/mailman/listinfo/kmymoney-devel</a><br>
><br>
_______________________________________________<br>
KMyMoney-devel mailing list<br>
<a href="mailto:KMyMoney-devel@kde.org" target="_blank">KMyMoney-devel@kde.org</a><br>
<a href="https://mail.kde.org/mailman/listinfo/kmymoney-devel" target="_blank">https://mail.kde.org/mailman/listinfo/kmymoney-devel</a><br>
</blockquote></div><br>
</div>