Repeat events still some bugs

omo66 wrote on Wednesday, October 15, 2008:

Hi,
Jason just fixed the repeat events scheduling for (weekdays)
Now I see that (daily) is not working.
E.g after I choose to schedule once a week SATURDAYS office hours (q6days)
the scheduler will do it for the first Saturday, then a week later it will keep moving a day erlier (will be FRI instead of SAT)
PLEASE help…
Thanks.

cfapress wrote on Tuesday, October 21, 2008:

I think there’s a bug in there but let me ask this question first…

Why would you schedule a weekly event (every Saturday) as recurring every 6th work day?
You should make the event repeat Every Week instead.

And also clarify one more thing…

Saturday and Sunday are not considered 'Workday’s by the system.

Now, back to the bug. I created an event starting on a Saturday (which is not considered a work-day) and repeating every 6th Workday. The event starts on Saturday and shows up correctly. The next occurance happens on a Monday, 9 days in ahead of the first occurance because that is the 6th WorkDay (Mon - Fri) after the first Saturday event.

So far so good…

Now I edit one of the recurring events and change it to repeat on the 5th workday. I choose up modify all instances of the repeating event. Since I didn’t edit the very first occurance of this event the start-date of the recurring event is now changed to be the date which I was editing. This is a bug. A BAD bug. I’m going to delve into additional testing to sort out what is going wrong here. In the meantime I hope my explainations above will help with your scheduling troubles.

Jason

omo66 wrote on Thursday, October 23, 2008:

I thought that the 6th-day repeat event is a fixed day of the week e.g SAT.
No I used the weekend repeat event and fixed the problem as you suggested.
Thank you Jason.

cfapress wrote on Wednesday, October 29, 2008:

Omar,

I can see your confusion. I’d like to see OpenEMR offer some repeating feature so that an event will repeat on the 1st/2nd/3rd/4th/5th Monday/T/W/Th/F/Sa/Su of a month. Perhaps that was the original intent of the programming logic that wasn’t ever finished. In any case, the user interface when creating a new event isn’t clear about making an event repeat like that. That is clear by how you and I interpreted the repeating choices differently.

I’ve got to dig back into the code very soon. When I do, I’ll look into making this logic easier to understand. Often I will look at how MS Outlook or the Palm Desktop programs allow users to create repeating events.

Jason