SchedulerAppointment.clone() doesn't clone the recurrence rule?

2 posts, 0 answers
  1. Sam
    Sam avatar
    10 posts
    Member since:
    Nov 2012

    Posted 14 Apr 2013 Link to this post

    Hi guys,

    We noticed that the client-side clone() method for a SchedulerAppointment does not seem to clone the recurrence rule.

    The definition of the function as we see it in your build 2013.1.220.45 is (minified)

    I would have expected a line something like:

    h.set_recurrenceRule(this.get_recurrenceRule());

    Is there a reason why the recurrence rule isn't cloned?

    Cheers,
    Sam




  2. Plamen
    Admin
    Plamen avatar
    3079 posts

    Posted 17 Apr 2013 Link to this post

    Hi Sam,

     
    Thank you for pointing this issue. I have logged it for investigation and possible implementation. Meanwhile you can use the following code to workaround it:

    function OnClientAppointmentClick(sender, args) {
              var appointment = args.get_appointment();
              var newAppointment = appointment.clone();
              newAppointment.set_recurrenceRule(appointment.get_recurrenceRule());
              sender.insertAppointment(newAppointment);
          }

    Hope this will be helpful.

    Greetings,
    Plamen
    the Telerik team
    If you want to get updates on new releases, tips and tricks and sneak peeks at our product labs directly from the developers working on the RadControls for ASP.NET AJAX, subscribe to their blog feed now.
Back to Top