Variants don't change on product page in Debut Theme

Solved
New Member
7 0 0

Hello, i have tried different ways to fix this issue but it still remains a mystery. I haven't changed much from the product page but until recently the variants were working properly and all of a sudden they just stopped. I have tried changing or even removing and adding them again but still the problem is there. Any help on the code or any suggestion what might be the problem

0 Likes
Shopify Expert
2466 414 519

Hi @Gregoris 

Send your store url

Want to modify or custom changes on store hire me.
If helpful then please Like and Accept Solution.
Email: jasoliyabrijesh123@gmail.com
Skype: jasoliya.brijesh
Want to get Free review and advice for sale on store ?? just text me here
0 Likes
Shopify Expert
2466 414 519

Open Asset->theme.js file and find below:

 

this.$container.trigger({
        type: 'variantSKUChange',
        variant: variant
      });
    },

Now remove last '},'

 

Want to modify or custom changes on store hire me.
If helpful then please Like and Accept Solution.
Email: jasoliyabrijesh123@gmail.com
Skype: jasoliya.brijesh
Want to get Free review and advice for sale on store ?? just text me here
0 Likes
New Member
7 0 0

Hello, unfortunately the problem remains. The variants are shown as usual but are not changing value, price or the image. this is the main problem

0 Likes
Shopify Expert
2466 414 519

Yes thats because of you have added js code and not closed  bracket properly so all massed with Js code

Add me as staff (jasoliyabrijesh123@gmail.com) i have to check code

 

Or try to add } after this:

 

 _updateSKU: function(variant) {
      if (variant.sku === this.currentVariant.sku) {
        return;
}

You have not added } after return

 

 

Note: add previous }, back

Want to modify or custom changes on store hire me.
If helpful then please Like and Accept Solution.
Email: jasoliyabrijesh123@gmail.com
Skype: jasoliya.brijesh
Want to get Free review and advice for sale on store ?? just text me here
0 Likes
New Member
7 0 0

Added you now. 

0 Likes
Shopify Expert
2466 414 519

Done check now.

Dont know why you added below code but that affecting because 'cache' cant find in Js still it generating issue but variants working now.

 cache.$parents.on('click.siteNav', function(evt) {
        var $el = $(this);
        if (!$el.hasClass(config.activeClass)) {
          // force stop the click from happening
          evt.preventDefault();
          evt.stopImmediatePropagation();
        }

        showDropdown($el);
      });
Want to modify or custom changes on store hire me.
If helpful then please Like and Accept Solution.
Email: jasoliyabrijesh123@gmail.com
Skype: jasoliya.brijesh
Want to get Free review and advice for sale on store ?? just text me here
0 Likes
New Member
7 0 0

Hello yes that code was made in order to hover the menu without needing to click on the button. but anw the variants are working properly now. Unfortunately the hover dropdown menu is not working properly tho. 

 

0 Likes
Shopify Expert
2466 414 519

check now working  fine menu on hover

Want to modify or custom changes on store hire me.
If helpful then please Like and Accept Solution.
Email: jasoliyabrijesh123@gmail.com
Skype: jasoliya.brijesh
Want to get Free review and advice for sale on store ?? just text me here
0 Likes