Modified Express Theme - Quantity selector in Collections

calculicious
Tourist
9 0 3

Hello!

 

I added a custom quantity selector code to each item in collection showing on my main website. It worked well for a while, but now the quantity selector doesn't function correctly. Quick add works, but then when you hit "+", the quantity does not increase in the cart. When I input a number for quantity and hit enter, it does add quantity 1 to the cart, but not the quantity I'm inputting in the quantity field. The website is donutflyer.com. How can I fix it so the quantity selector works again?

 

{%- if show_quantity_selector -%}
<div class="form__input-wrapper form__input-wrapper--select" data-quantity-input-wrapper>
<label class="form__select-label" for="Quantity-{{ section_id }}">
{{ 'products.product.quantity' | t }}
</label>

<div class="quantity-input">
<button
class="quantity-input__button button"
type="button"
aria-label="{{ 'products.product.decrease_quantity' | t: title: product.title }}"
data-quantity-selector
data-product-id="{{ product.id }}"
>
{%- render 'icon-minus' -%}
</button>
<input
class="quantity-input__element center"
type="number"
name="quantity"
id="Quantity-{{ section_id }}"
value="1"
min="1"
aria-label="{{ 'products.product.product_quantity' | t }}"
data-quantity-input
data-product-id="{{ product.id }}"
>
<button
class="quantity-input__button button"
type="button"
aria-label="{{ 'products.product.increase_quantity' | t: title: product.title }}"
data-quantity-selector
data-quantity-selector-increase
data-product-id="{{ product.id }}"
>
{%- render 'icon-plus' -%}
</button>
</div>
</div>
{%- endif -%}

Replies 2 (2)

Rishihuptech
Shopify Partner
430 73 76

Hi @calculicious , I have reviewed the above code. Can you please share the store URL so I can check it?

If you found this response helpful, please do like and accept the solution. Thanks!
Need support with Customizing your Shopify store?
Feel free to contact me at info@huptechweb.com or Visit our website Huptech Web.
Instant Shortcode Builder: Integrate customizable UI features anywhere in your store - No coding knowledge required
calculicious
Tourist
9 0 3

www.donutflyer.com

 

I realized since posting that this particular code isn't the quantity selector I'm using in my collection shown on my homepage. I tried deleting this code and it didn't affect my quantity selector.