Merge similar events doesn't work anymore

Home Forums Calendar Products Events Calendar PRO Merge similar events doesn't work anymore

Viewing 8 posts - 1 through 8 (of 8 total)
  • Author
    Posts
  • #1000310
    Oliver
    Participant

    Hi,

    to merge similar events an option in the settings can be activated by commenting this line in tribe-options-general.php:
    //’conditional’ => ( $tec->getOption( ‘organizer_venue_amalgamation’, 0 ) < 1 ),

    https://www.dropbox.com/s/0bll3siod0llawg/Screenshot%202015-08-30%2021.06.41.png?dl=0

    To make the button visible still works, but the ability to merge doesn’t work anymore.
    Has this feature maybe deprecated? We used this a lot on our website to get rid of duplicate events.

    Best regards,
    Oliver

    • This topic was modified 10 years, 7 months ago by Oliver.
    #1000600
    Nico
    Member

    Hi Oliver,

    Glad to be helping you out with this one also!

    Not sure about your screenshot because my German is very very very basic πŸ˜› but that option is to ‘Merge duplicate Venues & Organizers’ not to merge events. It was intended to fix possible duplicates generated when updating from 2.x to 3.0. Maybe the translation is showing a wrong description of this option?

    Please let me know about it,
    Best,
    Nico

    #1000675
    Oliver
    Participant

    Sorry, my fault. I meant to merge “duplicate venues and organizers” (it was late when posting this).
    And this is not working anymore :-()

    Any idea why? Is it deprecated?

    Regards,
    Oliver

    • This reply was modified 10 years, 7 months ago by Oliver.
    #1001413
    Nico
    Member

    Hi Oliver,

    Oh, thanks for clarifying that. This feature is not deprecated, but you’ve discovered a bug in it!

    There’s an encoding issue in the link for the ‘Merge Duplicates’ button, that’s why it doesn’t work. Take a look:


    Actual link - wrong: wp-admin/edit.php?post_type=tribe_events&_wpnonce=b3dbee92de#038;page=tribe-events-calendar&amalgamate=1
    Correct link: wp-admin/edit.php?post_type=tribe_events&_wpnonce=b3dbee92de&page=tribe-events-calendar&amalgamate=1

    There’s an encoding issue after the _wpnonce value, hopefully if you change that manually and execute that URL, it will work. When this runs it sets the option ‘organizer_venue_amalgamation’ to 1, which prevents the button from showing up again. So if you need the option to be visible again just reset the option value, you can do by adding this code to your functions.php file:

    add_action( 'admin_init', 'reset_amalgamator' );
    function reset_amalgamator ( ) {
    $events = Tribe__Events__Main::instance();
    $events->setOption( 'organizer_venue_amalgamation', 0 );
    }

    This code will run every time you access the WP-Admin area, so just add this when you need to reactivate the button!

    Thanks a lot for reporting this bug, a fix for this will be included in the upcoming release, which will see the light next week or so πŸ™‚

    Please let me know if you can run it manually for now,
    Best,
    Nico

    #1001474
    Oliver
    Participant

    Hi Nico!

    the snippets for always displaying the “Merge Duplicates” button works great, thanks! πŸ™‚

    To solve the bug: in which file do I need to change the link?

    Best regards,
    Oliver

    #1001989
    Nico
    Member

    Hey Oliver,

    Great to hear the snippet worked as expected πŸ™‚

    You can take a look in the fix PR for this: https://github.com/moderntribe/the-events-calendar/pull/291. Bear in mind this will be part of the upcoming release, coming out most probably next week.

    Thanks once again for reporting this! You rock!

    Please let me know if there’s anything else I can help you with,
    Best,
    Nico

    #1002144
    Oliver
    Participant

    Thanks Nico!

    I guess I will wait for the update πŸ™‚

    Have a nice weekend!
    Oliver

    #1002255
    Nico
    Member

    Oliver,

    Thank you πŸ™‚

    I’ll go ahead and close out this thread, but if you need help with anything else please don’t hesitate to create a new one and we will be happy to assist you.

    Have a great weekend yourself,
    Cheers,
    Nico

Viewing 8 posts - 1 through 8 (of 8 total)
  • The topic ‘Merge similar events doesn't work anymore’ is closed to new replies.