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

Validating recurrence section

1 Answer 29 Views
Scheduler
This is a migrated thread and some comments may be shown as answers.
Simon
Top achievements
Rank 1
Simon asked on 13 Mar 2019, 05:42 PM

Wondering if you have code samples regarding validating different sections of the recurrence editor. For instance if the user selects a daily recurrence then deletes (using keyboard) the value in the "After" spinner or the "On" date/time picker. Or they do something similar with a Weekly recurrence and perhaps check none of "Repeat on" checkboxes and delete values for "After" or "On". 

I see there is some reasonable default saved for RecurrenceRule in the database - is that by design as a way to avoid exhaustive validation? I can see this being a difficult ask, but it only takes one user to enter a recurring event incorrectly and it leads to a lot of confusion and questions. Is this a validation rabbit hole best avoided?

 

1 Answer, 1 is accepted

Sort by
0
Ianko
Telerik team
answered on 15 Mar 2019, 10:21 AM
Hello Simon,

Validating the way described really sounds quite complex. There is no specific reason for not having validation. As I can see, there is little that could go wrong. Generally, with such editing and event creation you can either add complex validation that would confuse end users more or enable them to actually have the output of their actions and correct afterwards. 

If the user chooses to create a recurring event one will be created no matter what. It is difficult to somehow control how exact this events should be created and I imagine that going with a complex validation would actually lead to limitations. 

However, you could try and create custom editor and add additional validation by following this sample here: https://github.com/telerik/ui-for-aspnet-mvc-examples/tree/master/scheduler/scheduler-custom-editor. You can also see this article here: https://docs.telerik.com/kendo-ui/controls/scheduling/scheduler/how-to/editing/custom-edit-and-event-templates

Regards,
Ianko
Progress Telerik
Get quickly onboarded and successful with your Telerik and/or Kendo UI products with the Virtual Classroom free technical training, available to all active customers. Learn More.
Tags
Scheduler
Asked by
Simon
Top achievements
Rank 1
Answers by
Ianko
Telerik team
Share this question
or