This is a migrated thread and some comments may be shown as answers.

Bug regarding saving the End By Date

1 Answer 28 Views
Scheduler
This is a migrated thread and some comments may be shown as answers.
Roatin Marth
Top achievements
Rank 1
Roatin Marth asked on 21 Jan 2010, 02:01 PM
I'm seeing some unexpected and unintuitive behaviour regarding the saving of the End By Date.
There seems to be some faulty logic that will always increment the user selected date by 1 day (or to the next day) therefore if the user keeps viewing the appointment data and doesn't update anything but clicks save, the End By Date will always increment by 1.

The bug seems to be in the _getRange function of the advanced form, which is easily enough modified since i am using the custom advanced form approach.

The code in question is as follows in the getRange js method:

 
                if (!this._getElement("AllDayEvent").checked) 
                    range.set_recursUntil($DateTime.add(range.get_recursUntil(), timePerDay)); 

The problem is that you take the date the user selected and you add an entire day which sets it to midnight, the beginning of the next day all the time so if the user goes to just view the data in edit mode, doesn't change anything but clicks save, as most users will, the end by date shouldn't change but in the current case it will.

It seems to me you need to subtract a second to always put the end by date at the end of the user selected date (just before the day rolls over).

1 Answer, 1 is accepted

Sort by
0
T. Tsonev
Telerik team
answered on 25 Jan 2010, 03:51 PM
Hi Roatin,

Thank you for reporting this problem and for taking the time to track it down to the offending line.

We do such adjustments for all-day events, so we can accurately represent them (from 00:00 to 00:00), but still allow the dates to be edited in a user-friendly fashion.

We'll fix the problem and the fix should be available in the next internal build in about a week.

As a token of our gratitude for your involvement, your Telerik points have been updated.

Sincerely yours,
Tsvetomir Tsonev
the Telerik team

Instantly find answers to your questions on the new Telerik Support Portal.
Watch a video on how to optimize your support resource searches and check out more tips on the blogs.
Tags
Scheduler
Asked by
Roatin Marth
Top achievements
Rank 1
Answers by
T. Tsonev
Telerik team
Share this question
or