Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fasttrack : Quick Checkcout does not appear if product added to basket on home page. #2254

Open
John-Blair opened this issue Apr 10, 2019 · 0 comments

Comments

Projects
None yet
1 participant
@John-Blair
Copy link

commented Apr 10, 2019

A page change is required for the quick checkout to show.

I don't know how to create a pull request yet - but the code i changed to fix this is in
merchello.ui.js: basketItemCount function.

basketItemCount: function(evt, args) {
            if (args.Success) {
                var label = $('[data-muilabel="basketcount"]');
                var $quickcheckout = $('[data-value="quickcheckout"]');
                if (label.length > 0) {
                    $(label).html(args.ItemCount);
                    // If there's a quick checkout menu item show or hide it according to basket count.
                    if ($quickcheckout.length > 0) {
                        if (args.ItemCount != 0) {
                            $quickcheckout.removeClass('mui-quickcheckout');
                        }
                        else {
                            $quickcheckout.addClass('mui-quickcheckout');
                        }
                    }
                }
                
            }
        }
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.