Close

Why AddProductFromProductDetailsPageToCartAjax returns empty view?

a.zoremba
6 years ago
#13981 Quote
Avatar
  • 4
(NOP 3.7)

I encountered weird problem on Azure web application with azure when adding product to cart, nothing in logs.

1. Add to cart popup
2. Product added to cart
3. Empty popup instead of summary with "go to cart".

{"PopupTitle":null,"Status":"success","AddToCartWarnings":"","ErrorMessage":"","RedirectUrl":"","ProductAddedToCartWindow":null}

So I downloaded database bacpac to debug, and it works on local SQL Express. It also works for another azure instance with same codebase, theme and plugin set.
I managed to replicate issue by connecting to Azure database from local instance under debug, execution is not reaching ProductAddedToCartPopupDialog.cshtml, to test I edited it to empty <div class="productAddedToCartWindow">Hello!</div>, still empty popup.

Apparently something weird goes wrong in plugin code and instead of being logged returns null.

Any ideas?
hristian.dimov
6 years ago
#13995 Quote
Avatar
  • Moderator
  • 386
a.zoremba wrote:
(NOP 3.7)

I encountered weird problem on Azure web application with azure when adding product to cart, nothing in logs.

1. Add to cart popup
2. Product added to cart
3. Empty popup instead of summary with "go to cart".

{"PopupTitle":null,"Status":"success","AddToCartWarnings":"","ErrorMessage":"","RedirectUrl":"","ProductAddedToCartWindow":null}

So I downloaded database bacpac to debug, and it works on local SQL Express. It also works for another azure instance with same codebase, theme and plugin set.
I managed to replicate issue by connecting to Azure database from local instance under debug, execution is not reaching ProductAddedToCartPopupDialog.cshtml, to test I edited it to empty <div class="productAddedToCartWindow">Hello!</div>, still empty popup.

Apparently something weird goes wrong in plugin code and instead of being logged returns null.

Any ideas?


Hi,

Could you please submit a ticket and provide a URL to your store and admin credentials to it so that we can inspect it?

Looking forward to your reply!
Regards,
Hristian Dimov
Nop-Templates.com
a.zoremba
6 years ago
#14090 Quote
Avatar
  • 4
hristian.dimov wrote:

Hi,

Could you please submit a ticket and provide a URL to your store and admin credentials to it so that we can inspect it?

Looking forward to your reply!


Sorry for late answer. Problem turned out to be conflict between shop settings and plugin.

Problem occurs with both Ajax Cart enabled and shoppingcartsettings.displaycartafteraddingproduct set to true.