magento / magento2

Prior to making any Submission(s), you must sign an Adobe Contributor License Agreement, available here at: https://opensource.adobe.com/cla.html. All Submissions you make to Adobe Inc. and its affiliates, assigns and subsidiaries (collectively “Adobe”) are subject to the terms of the Adobe Contributor License Agreement.
http://www.magento.com
Open Software License 3.0
11.56k stars 9.32k forks source link

We can't find quote item error on configurable product after updating item in IE 11 #7120

Closed sneha-sukumaran closed 7 years ago

sneha-sukumaran commented 8 years ago

Preconditions

  1. Magento 2.0.10

    Steps to reproduce

  2. Install Magento 2.0.10 with sample data
  3. In IE 11 load magento site frontend
  4. Add a configurable product to cart.
  5. Goto cart page and click edit item icon.
  6. Will be redirected to Product page, Select options and click update cart

    Expected result

  7. Cart item updated and rediect to shopping cart page

    Actual result

  8. Cart item is updated, but "We can't find the quote item." error message is displayed and stays in product detail page itself.

This also happens in demo site http://magento2-demo.nexcess.net/

dthampy commented 8 years ago

This is already fixed in 2.0.11 . Jira ticket: MAGETWO-58035

magento-engcom-team commented 7 years ago

@sneha-sukumaran, thank you for your report. We were not able to reproduce this issue by following the steps you provided. If you'd like to update it, please reopen the issue. We tested the issue on 2.3.0-dev, 2.2.0, 2.1.9

stacypob1 commented 6 years ago

Hi @magento-engcom-team and @kfriend I have seen this issue on both chrome, IE, and safari for the site in question, across devices and ISPs. I was able to capture the source code and errors for this happening in the product page, the cart, and a variation on chrome last week. Below I have shared view-only google docs that will allow you to see the code, screenshots of what the issue looks like, and the error that shows up on the page. I have highlighted the section of code that i THINK is the culprit, but please note I am not a coder, so the code below might not be the culprit. The google docs are like 70 pages each but I didn't want to leave anything out. :)

Product Page Error Code: https://docs.google.com/document/d/1n_6_ilrpQFIb_g_4J9Vu-F3s0Jfm-pKDCDrc5P9_9ng/edit?usp=sharing

Product Page red Error Code AND green OK: https://docs.google.com/document/d/1pc1wWeKKamBFE3oyAyTlBvPjdMrNibsFe-jAEHbYye4/edit?usp=sharing

Cart Error Code: https://docs.google.com/document/d/1wYjCbWgBVzcIsZdLy0MQPDuCou3CMr61Tztt0HFEslE/edit?usp=sharing

No issue in the cart: https://docs.google.com/document/d/1nvxdoOL-Q_HyoZ9qmYu_DDFmluzYSDLJYYfGLKVf-XU/edit?usp=sharing

nitin-bc commented 5 years ago

Hi @magento-admin Would you please provide some patch for 2.2.7 version if you have resolved it in 2.2.9 as stated here? https://github.com/magento/magento2/issues/11411

Vital388 commented 5 years ago

@nitin-bc You can do it by yourself Create a module. In module create a javascript mixin example of requirejs-config.js file var config = { 'Magento_Msrp/js/msrp': { 'MyVendor_MyModule/js/mixin/msrp': true } } } }; MyVendor/MyModule/view/frontend/web/js/mixin/msrp.js

define(['jquery'], function ($) {
 return function (originalWidget) {

        $.widget('mage.addToCart', $.mage.sidebar,
            {
                //fix bug on chrome with double submit form, when you updating cart item

                _addToCartSubmit: function (event) {
                    event.preventDefault();
                    this.element.trigger('addToCart', this.element);

                    if (this.element.data('stop-processing')) {
                        return false;
                    }

                    if (this.options.addToCartButton) {
                        $(this.options.addToCartButton).click();

                        return false;
                    }

                    if (this.options.addToCartUrl) {
                        $('.mage-dropdown-dialog > .ui-dialog-content').dropdownDialog('close');
                    }
                    $(this.options.cartForm).submit();

                }
            }
        );
        return $.mage.addToCart;
    };
});

The problem is in event.preventDefault(); Didn't test it on IE 11 but in chrome it fixed this problem

miteshdhaduk commented 5 years ago

@Vital388 It's working properly. Thank you.