Jump to content

[SOLVED] Wishlist - add to cart doesn't work if 0 in stock!


Recommended Posts

Hi, all

I'm going crazy about this problem! I'm trying to find where to modify code so you can add products to your cart from Wishlist no matter if they are in stock or not. Please does anybody have the solution? I'm lost!
The button "add to cart" from "My wishlist/View/product" doesn't work if the item is not in stock.. :(

many thanxx

Link to comment
Share on other sites

There is a known bug where the "Add to cart" button is disabled for products without attributes. See my post here for the fix. If you want to make the button always enabled, you could comment out lines 44 and 56-58 of modules/blockwishlist/view.tpl:

{*{if $product.attribute_quantity AND $product.attribute_quantity >= 1}*}
...
{*{else}
{l s='Add to cart' mod='blockwishlist'}
{/if}*}

Link to comment
Share on other sites

PROBLEM SOLVED !

When I changed the value to "0" in the modified code that you posted!
{if isset($product.attribute_quantity) AND $product.attribute_quantity >= 0 OR !isset($product.attribute_quantity) AND $product.product_quantity >= 0}

Thanxx a lot for this help!

Link to comment
Share on other sites

  • 3 years later...

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...