Home › Forums › Ticket Products › Event Tickets Plus › Default tickets set to 0
- This topic has 5 replies, 2 voices, and was last updated 8 years, 3 months ago by Brook.
-
AuthorPosts
-
December 25, 2015 at 5:49 am #1046453MatthewParticipant
Hi,
I raised this issue a while back but didn’t have time at that point to implement the advice I was given. I’d like to change the default value in the tickets field for woocommerce from 0 to 1. This is because if the user clicks add to cart with 0 in the field they get to a page that says ‘Your cart is currently empty.’ and ‘return to shop’ – which takes them to an empty products archive for those of us just selling tickets : ) – I think you guys should change it during one of your updates to default to 1 as I’ve seen this issue come up in many threads.
Anyway, the fix I was given no longer applies since wootickets is gone and I’m using Event Tickets now. I found Tickets.php in this folder – event-tickets/src/template-tags/tickets.php – but there is no mention of ‘input_value’ that can be changed to 1 instead of 0 which is the advice given to someone in a previous thread here – https://theeventscalendar.com/support/forums/topic/add-to-cart-doesnt-work-with-quantity-set-to-0/.
So how do I go about changing the default value in the tickets field to 1 now?
Thanks,
MatJanuary 4, 2016 at 11:34 pm #1050234BrookParticipantHowdy Mat,
Thanks for your feedback! We are catching up on post from during the holiday break. I appreciate your patience.
The file you are looking for has moved, but other than that the instructions you read are still applicable. You can find the file’s new location here: /wp-content/plugins/event-tickets-plus/src/views/wootickets/tickets.php and from there you can edit the input_value.
We might be able to change it to 1 by default, but only for event which have one ticket available. Otherwise when a customer clicks add to cart it will add all of the tickets! And adding something to a users cart without their knowledge won’t make for happy customers. Thanks for voicing your idea.
Does that all make sense? Will that work for you? Please let me know.
Cheers!
– Brook
January 5, 2016 at 5:41 am #1050276MatthewParticipantHi Brook,
Thanks for you help. It works if I edit it directly in your plugin but when I followed the Themers Guide advice and created the folder in my child theme to overwrite your plugin instructions it doesn’t work. Have I set up the folder wrong or something? This is the directory I created:
/wp-content/themes/pootlepress-child-theme/tribe-events/event-tickets-plus/src/views/wootickets
Then I put the tickets.php in there and changed the input value to 1. You can see it in the wordpress backend in this screenshot:
I tried clearing the cache but that didn’t help. What am I missing?
Cheers,
MatJanuary 5, 2016 at 9:31 pm #1050866BrookParticipantA very fair question. I would like torewrite our themer’s guide and make things like this more clear.
You have put your file here:
/wp-content/themes/pootlepress-child-theme/tribe-events/event-tickets-plus/src/views/wootickets/tickets.php
But it should be here:
/wp-content/themes/pootlepress-child-theme/tribe-events/wootickets/tickets.php
Just moving it should cause your change to become visible. 🙂 Sorry about the confusion, I can totally see why you put it in the other folder. It work now?
– Brook
January 6, 2016 at 4:20 am #1050937MatthewParticipantHi Brook,
That worked nicely, thanks mate.
I see what you mean that if more than one ticket is available it will add one of each to the cart. I hadn’t thought of that! It may come up as an issue if my vendors make multiple tickets available. I think your suggestion that it defaults to one if only one ticket type is available would be an excellent solution. If you guys could consider it for a future update I would much appreciate it 🙂
Cheers,
Mat
January 6, 2016 at 11:07 pm #1051619BrookParticipantI appreciate it Mat. Feedback is very helpful. I will pass the idea along. Just as a note, if you ever have ideas for the calendar don’t forget about UserVoice (feature suggestion page for The Events Calendar). Submitting ideas there is quick/easy and ensures they get seen by the masses. Then people can vote their support.
Cheers!
– Brook
-
AuthorPosts
- The topic ‘Default tickets set to 0’ is closed to new replies.