Close

AjaxCart action filter overwriting property DisableBuyButton (ProductPriceModel)

Jacob
9 years ago
#8034 Quote
Avatar
  • 6
Hello!,

We've been using the plugins in most of our projects, and we have recently updated them to version 3.40 (from 3.30). I think that we have found a behavior that we did not see in the last version.

One of our ecommerce sites disables the buy button if the user is not registered. This is accomplished by setting the ACL properly (DisplayPrices):

priceModel.DisableBuyButton =
product.DisableBuyButton ||
!permissionService.Authorize(StandardPermissionProvider.EnableShoppingCart) ||
!permissionService.Authorize(StandardPermissionProvider.DisplayPrices);

If AjaxCart is present (not active, just present with the DLL in the folder) seems to do something in one of their actionfilters (ProductOverviewModelActionFilterAttribute maybe). If DisableBuyButton is set to true, the action filter makes it false again.

We know that it has to be related with AjaxCart because we changed the property DisableBuyButton name, and we saw the exception being thrown from there.

Does anyone know something about it?

Thanks!

PS: If we remove the plugin from the plugins folder, everything works as intended.
Stefan
9 years ago
#8046 Quote
Avatar
  • Moderator
  • 157
Hi Jacob,

Thank you for your reply!

We are aware of this issue and working on it to get it fix a.s.a.p. For the time being you can enable the Ajax Cart plugin and disable the "Enable Ajax Cart On Grouped Product On Pages With Product Boxes:" setting from the plugin setting and everything should work as expected.

Best Regards!
Best Regards,

Stefan Hristov
Nop-Templates.com