Waiting list label on collection page

Some themes come with a 'sold out' label that shows on the product card on then.

Most of the time, you'll likely want this replaced with one that says 'Waiting List' or something similar.


This is a relatively easy with some code editing work! Contact us if you'd prefer us to edit your theme files 🙂


  1. Ensure the theme has the wait-li-config.liquid file in the Snippets folder.
  2. Add this code to the top of product-card.liquid or similarly named file:

{% comment %} Wait.li Config Snippet (Required) {% endcomment %}

{% capture 'wait_li_capture' %}{% render 'wait_li_config', product: product %}{% endcapture %}{%- assign wait_li_capture_results = wait_li_capture | split: '|' -%}{%- assign wait_li_active = wait_li_capture_results[0] | strip -%}{%- assign show_waiting_snippet = wait_li_capture_results[1] | strip -%}{%- assign is_customer = wait_li_capture_results[2] | strip -%}{%- assign customer_status = wait_li_capture_results[3] | strip -%}

{% comment %} End Wait.li Config Snippet (Required) {% endcomment %}

  1. Now, find the 'sold out' label in the HTML code. It could look something like this:
 
{%- if product.available == false -%}

{{- 'products.product.sold_out' | t -}}

{%- elsif product.compare_at_price > product.price and product.available -%}

{{- 'products.product.on_sale' | t -}}

{%- endif -%}

  • Now, you'll want to add an if statement like the following (you will need to adjust this depending on the theme code, but use this as a base to work off of:

{% if wait_li_active == 'true' %}

Waitlist

{% else %}

{%- if product.available == false -%}

{{- 'products.product.sold_out' | t -}}

{%- elsif product.compare_at_price > product.price and product.available -%}

{{- 'products.product.on_sale' | t -}}

{%- endif -%}

{% endif %}

  1. That should do it! Refresh your collection page and see if the label is now showing 'Waitlist' in the label.
  2. This label will be removed when you disable the waiting list in the Wait.li app.

Still need help? Contact Us Contact Us