Home › Forums › Ticket Products › Event Tickets Plus › Notification in List & Single Event View that "Zero Stock" is set
- This topic has 6 replies, 3 voices, and was last updated 9 years, 6 months ago by
Kate.
-
AuthorPosts
-
October 11, 2016 at 7:53 am #1174894
Kate
ParticipantHi,
So I am using your plugins in two ways:
1. To sell tickets
2. To list events that I am not selling tickets for but I want to show my readership they exist and link to a providers websiteIn order for the Filter bar to track the prices of the listings in category 2 I have made a ticket and set the stock to 0.
I now have two issues linked to the same situation:
A- I would like the LIST VIEW to grey out the prices of the category 2 events
B- In Single Event view I would like the WooCommerce table to be taken out… as this currently shows “Sold out” which is not the case.Can you help or point us in the right direction? Thanks in advance…
October 12, 2016 at 9:10 am #1175401Nico
MemberHi there Kate,
Thanks for getting in touch with us! I can help you here π
First of all, let me say what you mention is possible with some custom code but I think it will be simple if you use the event cost field for events without tickets. Please check out this article: https://theeventscalendar.com/knowledgebase/use-the-event-cost-field-with-tickets-installed/. This way it won’t be necessary to hide the tickets form, and now we would have a criteria to ‘grey out’ the prices π
Please give that a try and let me know if it works for you and I’ll continue to help with they list view modification. If you think the other method is better then that’s fine too, in that case will you be using a specific Event Category for those events?
Best,
NicoOctober 12, 2016 at 10:56 pm #1175775Kate
ParticipantNico! That is fab! Thanks so much… my next bit is the identification of what the customers can do… I will tell you what I would like to do in an ideal world and see if you can help.
There are actually four options for the listing:
1. List and booking enabled
2. List and booking ebanled but no tickets left on my platform
3. List and customer is instructed to book by website
4. List drop-in classes (no booking required)For the various options I would love it if I could:
1. Icon/Words next to price saying “Book now”
2. Icon/Words next to price saying “Fully booked”
3. Price greyed out (as I don’t want to really publicise these too much)
4. Icon/Words next to price saying “Drop in”I am open to whatever works best, I would rather use some additional fields than event categories… but if I have to use Event Categories is there a way of filtering these out of the filter bar as I want to keep that simple (hence why the additional field idea would work for me as I could then put these on the filter bar but it wouldn’t confuse people as it would be separate to the categories they are mostly interested in)
Hope this all makes sense.
Thanks again.
KateOctober 14, 2016 at 1:15 pm #1176803Nico
MemberHey Kate,
Thanks for following up! I’m mostly sure I follow you here, so want to group events in groups you mention and hence show a different button linking to the event. Right?
Well first of all let’s see how can the events be distributed in these groups:
- 1 / 2. List and booking enabled / out of stock: system check for tickets and stock level.
- 4. Drop-in: If you prefer not to use Event Categories, that cool. We can use tags, PRO additional fields, or plain WordPress custom fields which won’t show on the front-end as opposed to the others. For the example below I assume you use the following tag ‘drop_in’.
To get this working you’ll need to paste the following snippet in your theme’s (or child theme’s) functions.php file:
/* Tribe, add custom notice to list view */
function tribe_add_custom_notice ( ) {if ( tribe_events_has_tickets() ){
if ( tribe_events_has_soldout() ) {
$html = '<span>Fully Booked</span>';
} else {$html = '<span>Book now</span>';
}
} else if ( has_term( 'drop_in', 'post_tag' ) ) {$html = '<span>Drop In</span>';
}if ( isset($html) ) echo $html;
}add_action ( 'tribe_events_after_the_event_title', 'tribe_add_custom_notice' );
Please let me know if we get this part right, in which case we can look at your second request,
Best,
NicoOctober 17, 2016 at 12:00 pm #1177830Kate
ParticipantYou know what Nico… this is perfect. I think I will keep it simple and stick to just the above. Thanks for your help- you are lovely!
October 17, 2016 at 12:27 pm #1177864Nico
MemberHey Kate!
I’m glad to be of service! Thanks for the kind words π
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.
Best,
Nico -
AuthorPosts
- The topic ‘Notification in List & Single Event View that "Zero Stock" is set’ is closed to new replies.
