I've set a product with multiple variations, which are the dates to book a travel tour. Is there a way to have the variations deleted automatically through time?
This solution does require working with code and Liquid files, and if this is something you would not be comfortable with, I would advise you to reach out to one of Shopify Experts, or contact me. As always, when making code changes to your theme, please remember to create a backup, in case you need to revert back to previous versions of the theme.
Dallas here from the Social Care team.
I did some pondering on what you're looking for and I think I found a better option.
Have you looked into the booking app called Book That App? It's actually designed to allow your customers to book specific slots on specific days that you have available. Once that date is done your customers can't purchase anymore. Poof, it's gone. The nice thing for this option is that it's also in a calendar format so it's easier to read.
The other option would be to do what they're doing in that link that you gave. However, in order to do that, you'd have to add inventory numbers for each variant. When it's sold out it would automatically be removed from your selection of products on your storefront. You'd just have to make sure that you set up your store so that the sold out items are removed from the front end once they officially are sold out. This link here will show you the steps to follow in order to do that. It's a bit of a brain teaser, but does this make sense?
Do note that this won't delete the variant in the back end of your store and it also would only work if each event is completely sold out.
Now for what you're wanting I'm not sure if the second option is even possible because I don't know if your events are the kind of events where there are only a limited number of tickets. For that reason, I suggest the first option.
If these aren't possible please feel free to clarify for me as to what your store is going to be selling so that I can see if there is another option that might work for you.
I look forward to hearing from you,
Wonderful! If you have any questions as you go along, or if you want any more information please don't hesitate let me know.