Home › Forums › Ticket Products › Event Tickets Plus › WooCommerce Catalog Visibility
- This topic has 9 replies, 5 voices, and was last updated 8 years, 11 months ago by
Geoff B..
-
AuthorPosts
-
April 19, 2017 at 5:59 pm #1271921
Johannes
ParticipantHello,
By default new tickets should be set to hidden with Events Tickets Plus – correct?
If so, this feature is not working – at least in the newest WooCommerce and Events Tickets Plus version.I believe instead of updating it through update_post_meta( $ticket->ID, ‘_visibility’, ‘hidden’ );
the product_attributes needs to be updated.Thank you!
April 20, 2017 at 9:17 pm #1272493Geoff B.
MemberGood evening Johannes and welcome back!
Thank you for reaching out to us.
We apologize for the inconvenience caused by this glitch.
We are actively working on a solution for this.Alas, I cannot guarantee when it will be fixed, as it’s in the development team’s hands now.
They need to assign it, code it, test it, and schedule it for release.The good news is that you will be contacted as soon as a fix is available.
Thank you for your patience as we see this through.In the meantime, short you could apply the following snippet in the functions.php file of your theme (without the PHP tag at the top): https://gist.github.com/GeoffEW/dc504166ac629c226fa9b1f8988bf082
This will force all of your tickets to become hidden.
Best regards,
Geoff B.April 21, 2017 at 5:32 am #1272598Johannes
ParticipantThank you for checking into it. Unfortunately, the snippet did not work. WooCommerce must keep track differently of the visibility option. I think they moved it to a taxonomy but I am not sure. (I know your hook works though since I use other actions in it). However, since this is not an urgent issue, I will wait for the fix.
Thanks again.
April 21, 2017 at 7:40 am #1272656Philip
ParticipantAs of WooCommerce 3.0; visibility is stored as a taxonomy term instead of post meta. Try this instead.
function tribe_events_woo_change_visibility( $ticket_ID ) { if ($product = wc_get_product($ticket_ID)) { $product->set_catalog_visibility('hidden'); $product->save(); } }Note: I am not affiliated with Modern Tribe/The Events Calendar.
April 21, 2017 at 8:41 am #1272696Johannes
ParticipantThat worked. Thank you!
April 21, 2017 at 9:06 am #1272709Geoff B.
MemberGood afternoon,
Major props to @first4websites here.
I am super stoked that this worked for you Johannes.
You are welcome back in our support forums any time 🙂
For now, I am going to close this thread.
Have a good weekend,
Geoff B.
May 5, 2017 at 7:25 am #1279191Nico
MemberHi there,
Just wanted to share with you that a new maintenance release (for the Week of 1st May 2017) is out, including a fix for this issue 🙂
Find out more about the release → https://theeventscalendar.com/maintenance-release-week-1st-may-2017/
Please update the plugins and let us know if the fix works for your site,
Best,
NicoMay 5, 2017 at 8:58 am #1279246Johannes
ParticipantThank you!
Yes, it took care of the catalog visibility. However, it still would be
nice if new tickets are automatically marked as non taxable. But, I have it
set it with a little code snippet. So, no need to change it for me.Johannes
—————————————————————————-
-
This reply was modified 8 years, 11 months ago by
Johannes.
-
This reply was modified 8 years, 11 months ago by
Johannes.
May 5, 2017 at 11:46 pm #1279740Geoff B.
MemberGood evening Johannes,
Thank you once again for your patience AND help.
I totally agree that such a feature would be useful.
The good news is that out of code snippets, extensions are created 🙂You are welcome back in our support forums any time 🙂
For now, I am going to close this thread.
Have a great week!
Geoff B.
-
This reply was modified 8 years, 11 months ago by
-
AuthorPosts
- The topic ‘WooCommerce Catalog Visibility’ is closed to new replies.
