Problem with drop-down lists of venues and organisers for a marketplace

Home Forums Calendar Products Community Events Problem with drop-down lists of venues and organisers for a marketplace

Viewing 9 posts - 1 through 9 (of 9 total)
  • Author
    Posts
  • #1209258
    Huiwen
    Participant

    hi,

    My website is a marketplace for events. I just noticed that whenever a new event organiser registers his/her venue and the organiser info, they are added in the drop-down lists of venues and organisers. It is great that this info is saved and the event organiser does not have to enter a second time; but it also means that the other event organisers would see it and have to bear with increasingly longer drop-down lists of venues and organisers, as the community grows. Is it possible for the system to memorise only the venue and the organiser info from the event organiser him/herself only?

    • This topic was modified 7 years, 5 months ago by Huiwen.
    #1209879
    Cliff
    Member

    Hi, Huiwen.

    Thanks for your detailed question.

    I believe Community Events already works as you’re describing.

    Please test these scenarios on your own site but I believe it works this way:

    • If an Administrator adds an Organizer or Venue (O/V), everyone will be able to see and select it.
    • If a non-Administrator adds an O/V, only they will be able to see it.

    To test these, you could use a plugin like User Role Editor (we cannot guarantee its compatibility but it generally considered a reliable plugin) to switch between your site’s users to see what they see.

    Please let me know if you have any follow-up questions on this topic.

    #1210149
    Huiwen
    Participant

    Hi Cliff,

    Thanks for trying to help.

    Ok I’ve installed the plugin. The question for me is how can I disable the vendors to see others’ O/V? Which capabilities shall I look into specifically?

    • This reply was modified 7 years, 4 months ago by Huiwen.
    #1211441
    Cliff
    Member

    I believe Community Events already works as you’re wanting.

    I’d suggest a plugin like User Switching (third-party, not guaranteed or supported by us) to test out the scenarios you’re concerned about.

    For example, logged in as yourself (an Administrator, I assume), create an Organizer, then switch to an Author user (or whatever level user) and see if that Organizer is available in the drop-down (I believe it should be). Then create a new Organizer as Author X and then switch to another Author Y user and see if they can see the Organizer created by Author X (I believe the will not be able to)… etc…

    Then let me know if something’s not working how you’d like it to.

    #1211469
    Huiwen
    Participant

    Hi Cliff,

    I’m confused. So instead of the User Role Editor plugin that you recommended earlier, I should use User Switching plugin instead?

    As for your suggested scenarios, I’ve already tested without any plugin. I have created a, say, User A (non-admin) to list an event, and then log out, and log in again with a User B (non-admin). User B can still see User A’s O/V in the dropdown menu – the only difference is that it shows in “available venue / organiser” rather than “my venue / organiser”. Below is a screenshot FYI.

    I dont understand what would be the difference by installing those plugins you suggested since these two users are already registered as non-admin.

    Please advice, thanks.

    huiwen

    #1211902
    Cliff
    Member

    My apologies for the confusion. I swear this is the way it used to work (but I didn’t go back looking through past code to verify). Anyway, another person and I both tested and it doesn’t function this way anymore.

    I dug through the code and found Tribe__Events__Linked_Posts__Chooser_Meta_Box from /wp-content/plugins/the-events-calendar-community-events/src/views/community/modules/organizer.php is what renders the O/V edit areas in the Community Events form.

    Tribe__Events__Linked_Posts__Chooser_Meta_Box is from /wp-content/plugins/the-events-calendar/src/Tribe/Linked_Posts/Chooser_Meta_Box.php

    Organizers and Venues (O/V) are “linked posts” to Events, if that helps you understand the naming…

    It uses saved_linked_post_dropdown() from /wp-content/plugins/the-events-calendar/src/Tribe/Linked_Posts.php, which is where the magic happens for what you’re wanting — you can see its code here: https://github.com/moderntribe/the-events-calendar/blob/4.3.5/src/Tribe/Linked_Posts.php#L731-L878

    It uses edit_others_posts capability, but the code didn’t lend itself to a quick and dirty customization to change how this works. But we created a new extension for you. I tested it and it seems to work as expected:

    https://theeventscalendar.com/content/uploads/2016/12/tribe-ext-hide-linked-posts.zip

    Please try it out and let me know how it works for you.

    #1212549
    Huiwen
    Participant

    Ok many thanks Cliff. I need to wait for my web developer to come back from the holidays in order to test your code. Thanks for providing the extension and I will let you know the outcome.

    #1212722
    Cliff
    Member

    Sure thing. Please do let us know how it goes.

    Please note that threads get Closed automatically after a couple weeks of inactivity. If it does get Closed, please open a new thread, adding your current problem description and also linking back to this thread.

    Thank you!

    #1223635
    Support Droid
    Keymaster

    This topic has not been active for quite some time and will now be closed.

    If you still need assistance please simply open a new topic (linking to this one if necessary)
    and one of the team will be only too happy to help.

Viewing 9 posts - 1 through 9 (of 9 total)
  • The topic ‘Problem with drop-down lists of venues and organisers for a marketplace’ is closed to new replies.