This event has passed message on events

Home Forums Calendar Products Events Calendar PRO This event has passed message on events

Viewing 9 posts - 1 through 9 (of 9 total)
  • Author
    Posts
  • #32624
    Adrian
    Participant

    Hi,
    I discovered that the plugin shows a “This event has passed” message on all events posted by users who are not admins. Posting as an admin does not encounter any problems.
    What can the problem be?
    Regards,
    Adrian

    #32629
    Barry
    Member

    Hi Adrian, that’s strange. Can you provide a URL for one of the affected events? I did try the following steps to replicate this:

    • Created a new user and assigned him to the editor role
    • Signed in as the editor and created a new event in the future
    • Visited the event page (still logged in) and didn’t see the “Event has passed” message
    • Visited in a different browser (not logged in) and, again, could not see the “Event has passed” message

    Is there anything I would need to do differently/am I misunderstanding at all?

    #32632
    Adrian
    Participant

    Hi Barry!
    These are the steps I did for adding events. The only difference is that I use custom roles created by a plugin.
    Here comes the URL for one of the events: http://meramusik.nu/livespelning/event-001/
    (please provide me your IP address so that I can give you access to the website, as it is under development)
    I have noticed that the Events Calendar Pro plugin assigns my computer date and time when I publish an event.

    #32642
    Barry
    Member

    The only difference is that I use custom roles created by a plugin.

    Perhaps that’s the problem. Can you give an example of one of the roles that have been set up and list its capabilities?

    #32806
    Adrian
    Participant

    We would deactivate that plugin, but unfortunately we need it, so we would very much appreciate if you could give us some assistance.

    The problem we have is when users add events. As ‘Administrator’ (or ‘Editor’, or ‘Author’, or ‘Contributor’), everything works fine and the ‘wp_postmeta’ table gets populated properly (see http://meramusik.nu/images/event_as_admin.jpg attached). However, when logged in as user with custom role ‘artist’ (or default role Subscriber), the ‘wp_postmeta’ table gets populated with just a few new entries (see http://meramusik.nu/images/event_as_custom_role.jpg). No meta on the post, venue or organizer gets inserted. We would expect either all data, or no data being inserted, but this is confusing.

    We assume there’s some kind of user check somewhere in the plugin, and it’s not inserting the meta data, because it doesn’t like something with the custom user, but we couldn’t find or pin-point that bit of code.

    We would very much appreciate if you would take some time and look into our problem.

    Regards.

    #32809
    Barry
    Member

    Well, there is a limit to the degree of support we can offer where custom/third party code is involved, but we’re definitely happy to at least see if it’s possible to help or even just nudge you in the right direction.

    We would deactivate that plugin, but unfortunately we need it, so we would very much appreciate if you could give us some assistance.

    I totally understand and I’m not asking you to deactivate it – but I would need you to meet me halfway here and answer my question: can you give an example of one of the roles that have been set up and list its capabilities?

    #32811
    Adrian
    Participant

    One of the 2 custom roles set up by this plugin called WP Custom Types is called Artist and we gave it level 3, which is between Author and Editor on WP default roles scale. It is strange though that we can post events with Author, but not with Artist, which has a higher level.
    Also, why can’t Subscriber, a default WP role, post events?

    #32814
    Barry
    Member

    The thing is subscribers cannot post anything by default – neither pages nor posts. It’s basically the least empowered user role and is really just used for those people who have subscribed to the blog.

    So, for that reason, their only capability in a regular installation is “read” – and so it wouldn’t really make sense to let them post events in most cases.

    In this case what I’d recommend here is taking a look at the code in TribeEvents::addCapabilities() which you can find in:

    the-events-calendar/lib/the-events-calendar.class.php

    (Approx lines 734-884.) Your custom roles would need to build in many of those capabilities that are added to default roles by The Events Calendar.

    #32833
    Adrian
    Participant

    Thank you for your answer, Barry. I managed to solve the problem.
    Kudos for answering support questions on a Saturday night!

Viewing 9 posts - 1 through 9 (of 9 total)
  • The topic ‘This event has passed message on events’ is closed to new replies.