Cloning and moving events programmatically

4 posts, 0 answers
  1. Simon
    Simon avatar
    22 posts
    Member since:
    Feb 2019

    Posted 28 Mar 2019 Link to this post

    Hi,

    I am currently trying to implement cloning and moving of events programmatically by using a contextmenu along with menu-options that include a calendar. The idea is to right-click on an event and selecting a date from one of the calenders and moving or copying the selected event (see attachment).

    However I am facing the issue of handling recurring events. I need the option of whether to change the series or the current instance only. Is there some way to open the dialog window asking to "edit current event" or "edit series" manually and handling the user action accordingly?

  2. Simon
    Simon avatar
    22 posts
    Member since:
    Feb 2019

    Posted 30 Mar 2019 in reply to Simon Link to this post

    On a somewhat related note, I see that if I use occurrenceByUid on a recurring event that is not the original event instance (date), I don't get the info regarding the original instance. Instead I get an event that points to the original via recurrence_id.

    How can I get the original occurence in this case?

  3. Simon
    Simon avatar
    22 posts
    Member since:
    Feb 2019

    Posted 01 Apr 2019 in reply to Simon Link to this post

    Solved the "finding original instance" by looping over the whole data source. If there is a better way, please let me know :)
  4. Veselin Tsvetanov
    Admin
    Veselin Tsvetanov avatar
    1207 posts

    Posted 01 Apr 2019 Link to this post

    Hi Simon,

    Concerning the original event instance, after obtaining the id of that instance, you could use the get() method of the DataSource object, which will return the item in question after passing its ID to the call.

    As per the other question, as far as I can understand, you would like to open programmatically a pop-up which is just like the Edit Recurring Item pop-up. Also, you would like to implement a custom logic that will be executed after one of the two buttons has been clicked. If that is the case, I am afraid that the Scheduler widget and its pop-up does not expose configuration options, that would allow you to achieve the desired.

    Regards,
    Veselin Tsvetanov
    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.
Back to Top