Magenerds / BasePrice

38 stars 38 forks source link

JS Error on configurable product in 2.2.6 #34

Open ju2kr opened 6 years ago

ju2kr commented 6 years ago

I have an issue where the swatch-renderer doesn't work anymore on a configurable product with base price in Magento 2.2.6

The JS console throws an "Cannot read property 'element' of undefined" error when I loading the page. The interesting thing is that sometimes the page is loaded correctly. I suspect a timing problem, but unfortunately I can't narrow down the error. As you can see from the screenshot, the script assumes that it is not a swatchWidget. But this is wrong. It is a swatchWidget

bildschirmfoto 2018-10-25 um 15 03 57
svlauer commented 6 years ago

I have the same problem.

I suspect that the problem is the following: Base price (or magento core?) seems to assume that there is always a selected option/swatch when the price is calculated via js.

But this is not the case: When a configurable product is first displayed, there is no selected option/swatch.

JoergLindner commented 5 years ago

Same issue in 2.2.7. Main problem is, that the failure is not consistent and it seems to be speed/timing issue. We have a programmer overseas who supposed to solve it, but he saw it just one time. We have it on our 1Gbit Lint at all products, using WLAN with smaller Bandwidth it happens only at 50-60% of the products, some time even only 10-20%. So it is very inconsistent. We changed the Baseprice Module to an other Module developer. OK it is not free, but 49EUR is not a big price to solve a problem. Installation of the new Module is easy and the settings of the product is easy to import. Just export the product change the relevant items (replace in Excel/Openoffice), remove not used fields/colums and import it again. The only thing is, even if the Magenerds Basprice Module is disabled, you will see both Baseprice settings in Admin. So the get rid of it, the database needs to modified.. Took us 10 min. to change all product Baseprice settings. Of course if you run other Modules, which was Modifies to run with MN Baseprice, they need to be modified.