Looking for a way to bulk update recurring events

Home Forums Calendar Products Events Calendar PRO Looking for a way to bulk update recurring events

Viewing 6 posts - 1 through 6 (of 6 total)
  • Author
    Posts
  • #1514124
    Rosemary
    Participant

    Hello, my name is Christopher, I’ve been looking for a way to bulk update recurring events.

    A little history:
    The website my team is working on has 300 or so parent events that are recurring for a total of around 10,000 events per year. It has slowed down the website immensely and I’ve been searching for ways to reduce the overall number of events to as few as possible. I have now limited the range of recurrence to three months in the future and cleanup past events after one month. I have discover the runaway recurrence cleanup tool and have used it on an event and then opened the parent event to update it and remake the recurrences. That works fine, but I have 313 parent events and that workflow will take forever. Furthermore, I may have to do this process on an on-going basis so you see the need to be able to do this in bulk. Basically, we need to be able to recreate all recurring events automatically.

    Our approach:
    Our approach was to write a plugin that piggybacks on the Cleanup Recurring Events tool to automatically update the parent event to recreate the recurring events once the recurrences are deleted. It would then cycle to the next parent event to do the same thing until all parent events have been updated. We have some of the pieces figured out. From the Cleanup Recurring Events tool we can get all of the parent events and delete the recurrences and do this in a foreach loop to delete everything all recurrences. The part we haven’t figured out after digging through The Events Calendar/Pro is how to trigger the recreation of event recurrences. We narrowed it down to the Tribe__Events__Pro__Recurrence__Events_Saver class and the save_events() method but then it gets a bit messy because of the never-ending cycle of trying to get the arguments/properties correct. Maybe we aren’t even on the right path at all…

    If you would please help us figure out how to bulk update all parent events to recreate recurrences, we’d be grateful and others may find it useful as well. Likewise, if you require more information, please let me know. Thank you.

    #1515302
    Victor
    Keymaster

    Hi There!

    Thanks for reaching out to us!

    Just wanted to let you know that we are dealing with a high volume of threads at the moment and it may take us more than usual to get back to you.

    Let me note that we are fairly limited in how much support we can give for custom development questions like that.

    I’d recommend you take a look at our Themer’s Guide to learn how to customize our plugins > https://theeventscalendar.com/knowledgebase/themers-guide/

    Please have a look at it and let us know if you have any follow up questions.

    One of our team members will get back to you. We appreciate your patience while we slowly get back to normal response times.

    Best,
    Victor

    #1515829
    Victor
    Keymaster

    Hi Christopher!

    Thanks for the patience here.

    After reviewing your request this essentially looks like a custom development task and so is outside of our stated scope of support.

    With that being said, we’d love to help point you in the right direction.

    We do need to prioritize support requests from other customers at this time but I’ll certainly flag this with the team and – although we can’t make any promises – if we have time and space to come back and help, we’ll be happy to do so.  Please let us know if you’d like to go this route so that you can be added to this queue.

    In the meantime, if there is any more information you can share (including mocks) that will help us to better understand what you are seeking please do feel free to add them to this ticket.

    If you urgently need help with this, however, you may instead wish to consider working with a suitably skilled developer or designer who can offer the additional level of support you require.

    Thanks!
    Victor

     

    #1516295
    Rosemary
    Participant

    Hi Victor,

    Thank you for getting back to me. I guess I need to change my request so that it fits into the support guidelines. The reason why I am looking for a way to programmatically trigger the recreation of recurring events without visiting the event edit page individually is because I cannot access the parent event to click the update button. Upon visiting the edit event page, it hangs-up the browser tab as if it is infinitely loading the page. CPU usage for the browser goes through the roof. It’s the same on multiple computers and browsers.

    The event I’m trying to edit originally had 500 recurrences. I used the Recurrence Cleanup Tool to delete the recurrences with the hope that the page would load if there was only one recurrence, however, it still doesn’t ever finish loading and get hung-up.

    Please let me know if you can assist with this request. Thanks.

    #1516693
    Victor
    Keymaster

    Hi Christopher!

    Thanks for following up with this and for the explanation.

    Sounds like you are dealing with a performance issue there.

    The event I’m trying to edit originally had 500 recurrences. I used the Recurrence Cleanup Tool to delete the recurrences with the hope that the page would load if there was only one recurrence, however, it still doesn’t ever finish loading and get hung-up.

    This may indicate a problem with the database (probably caused by the number of events and posts). Have you done any debugging for this issue?

    I would recommend you enable WP_DEBUG and WP_DEBUG_LOG ? This will create a debug.log file inside the /wp-content directory.

    After that, try reproducing the issue, so that in case there is an error, it will be saved into the debug.log file. Please share that log file with us so we can see if any problem from there.

    The browser hanging up, could throw a different error too. I would also see if any show up when editing a recurring event. Could you please see if there are any console errors by inspecting the page when editing a recurring event? We have an article that explains how to do that here > https://theeventscalendar.com/knowledgebase/using-google-chrome-developer-tools/

    I can also see from your system information that you are using older versions of our plugins, which may contain bugs that were fixed in more recent releases. So please update to the latest versions of our plugins. Remember you can always download our plugins from your downloads page > https://theeventscalendar.com/my-account/downloads/

    I would highly suggest to setup a dev/staging site so you can make this tests and make all plugins, theme and WordPress core updates without disrupting the live site.

    Please let us know about that.

    Thanks,
    Victor

    #1533887
    Support Droid
    Keymaster

    Hey there! This thread has been pretty quiet for the last three weeks, so we’re going to go ahead and close it to avoid confusion with other topics. If you’re still looking for help with this, please do open a new thread, reference this one and we’d be more than happy to continue the conversation over there.

    Thanks so much!
    The Events Calendar Support Team

Viewing 6 posts - 1 through 6 (of 6 total)
  • The topic ‘Looking for a way to bulk update recurring events’ is closed to new replies.