Venue & Organizer Draft

Home Forums Calendar Products Events Calendar PRO Venue & Organizer Draft

Viewing 12 posts - 1 through 12 (of 12 total)
  • Author
    Posts
  • #24035
    Alex
    Participant

    Not sure if this is a bug:
    Currently using this script https://github.com/adispezio/gf_ecp_frontend_submission/blob/master/functions.php
    and everything is working perfectly! The event’s Venue and Organizer meta and IDs get sent through gravity forms but the only problem is that the new venue and organizer get sent as drafts while the event gets sent as published. Can everything be set to be published right away ? Maybe this is a bug in:
    // don’t do anything on autosave or auto-draft either or massupdates
    //if ( wp_is_post_autosave( $postId ) || isset($_GET[‘bulk_edit’]) )
    if ( wp_is_post_autosave( $postId ) || $post->post_status == ‘auto-draft’ || isset($_GET[‘bulk_edit’]) || $_REQUEST[‘action’] == ‘inline-save’ )
    {
    return;
    }

    if( class_exists(‘TribeEventsAPI’) ) {
    $_POST[‘Organizer’] = stripslashes_deep($_POST[‘organizer’]);
    $_POST[‘Venue’] = stripslashes_deep($_POST[‘venue’]);
    $_POST[‘Recurrence’] = stripslashes_deep($_POST[‘recurrence’]);

    if( !empty($_POST[‘Venue’][‘VenueID’]) )
    $_POST[‘Venue’] = array(‘VenueID’ => $_POST[‘Venue’][‘VenueID’]);

    if( !empty($_POST[‘Organizer’][‘OrganizerID’]) )
    $_POST[‘Organizer’] = array(‘OrganizerID’ => $_POST[‘Organizer’][‘OrganizerID’]);

    TribeEventsAPI::saveEventMeta($postId, $_POST, $post);
    }
    }

    #24044
    Barry
    Member

    Hi Alex – thanks for connecting with us. I don’t really think we can offer any support for someone else’s custom script in this way, but we can certainly see if anyone else in the community is available to offer some guidance 🙂

    Have you tried contacting the author of the code?

    #24091
    Alex
    Participant

    yea that script is from you guys, here:
    https://theeventscalendar.com/event-submissions-using-gravity-forms-in-2-0/
    https://theeventscalendar.com/gravity-forms-events-calendar-submissions/
    For some reason with this it saves venue and organizer as drafts but the event gets published

    #24093
    Barry
    Member

    Still could be worth contacting the author – Tim Bowen of Creative Slice – as he will have the best handle on this.

    You can see the relevant blog post on the Creative Slice website. I think we essentially borrowed this, but it isn’t something we put together ourselves.

    #24101
    Alex
    Participant

    Thanks man. I’ll send him an email

    #24120
    Barry
    Member

    Cool, hopefully he can help you out. Feel free to post back if there are any tips that might helps others do the same!

    #25175
    Alex
    Participant

    He sent me the following:
    “It’s my understanding that they API has been updated with easier methods for creating venues and organizers. The code I have should be considered deprecated.”

    This is what happens on submission:
    Event – Published
    Venue – Draft
    Organizer – Draft

    #25373
    Alex
    Participant

    Do we need to upgrade to developer? … please let me know

    #25385
    Barry
    Member

    No not at all, that has no impact on the level of support you are provided with (beyond the number of sites that are involved, of course).

    But we can’t dig into highly custom stuff like this too deeply – it would simply take too long, besides which I’m unfamiliar with Gravity Forms and so testing something like this out isn’t a possibility for me.

    As before the tutorial you’ve looked at was borrowed from Tim at Creative Slice and he is the person to seek advice from – if he considers it to be deprecated then there is not much else I can do to help at this point in time, though I have noted down that it is in need of revision and a team member will either get around to that (or remove it) in due course.

    What I’ll do later today is ask if anyone else on the community team is better positioned to help out with this question, failing that all I can suggest is leaving this thread open for a period of time as someone else in the community might be able to help you out here.

    Sorry I can’t do more on this occasion.

    #25460
    Barry
    Member

    Hey Alex, just to follow up on this, after talking to fellow team members about this it sounds like those tutorials were created prior to the release of our Community Events plugin – and it was clearly a useful resource at that point in time (of course it may still be useful to many people – however we now have a viable, fully supported alternative in place in the form of Community Events).

    With that in mind it is probable that we will not revise the tutorial.

    #25469
    Alex
    Participant

    Thank you so much barry. I will check this plugin out 🙂

    #25471
    Barry
    Member

    Cool – hopefully it covers what you are looking for and feel free to check out the Community Events forum, too.

Viewing 12 posts - 1 through 12 (of 12 total)
  • The topic ‘Venue & Organizer Draft’ is closed to new replies.