Jump to content

Recommended Posts

Posted

Just upgraded to 5.2.10 and now in admin I can't set a products stock level to 0. I can set it from 1 to 5 but not 1 to 0. Same issue on another website that I've upgraded. Anyone else experienced this or know how to put it right? Thanks.

Posted

Okay. (Sigh).

Would be useful to add a topic after each update to show "manual patches to version xx" so I don't have to read through all the posts after each update to pre-locate bugs, which won't be patched for another 4-6 weeks. Doing an update, then having client point out a bug, or me locating one, then having to come back here to find the patch in a scavenger hunt, is a little time consuming.

 

Just annoying customer feedback there.

 

Thanks for keeping the train rolling, nonetheless :-)


Mmmmm....... icing and sprinkles!!!!  :-)

Posted

 

Fix below. Sorry about this. 

hi, I made the fix as you advised, to allow me to set the stock level to zero,, but now I cannot change the stock levels at all, they used to allow me to set them to different values except 1 or zero before, now I change them in the product in the admin control panel, but stock levels do not change on the website. Any ideas?

Posted

"now I change them in the admin Edit Product, but stock levels do not change on the website"

 

Of the products you have changed stock levels for, and notice no change on the storefront, do they use the Product Options Matrix table?

Posted

"now I change them in the admin Edit Product, but stock levels do not change on the website"

 

Of the products you have changed stock levels for, and notice no change on the storefront, do they use the Product Options Matrix table?

yes they would, is there another place i need to edit also?

 

"now I change them in the admin Edit Product, but stock levels do not change on the website"

 

Of the products you have changed stock levels for, and notice no change on the storefront, do they use the Product Options Matrix table?

yes they would, is there another place i need to edit also?

 

aha, lower the level of the options stock, and the stock level will reduce accordingly, apologies, sorted now. Thank you for your help

Posted

Bring the product up for editing, on the Options tab, make sure the Options Matrix table is showing. Set the stock level for each option combination.

Posted

@Al, with respect to post #2, I see the change as partly complete:

 

From testing for empty, but keep the integer 0 or the float 0.0

To testing for empty, but keep the string '0' or the string '0.0' (as web forms submit only strings)

 

does not allow for the possibility of keeping any other response that could be seen as numerically zero: '.0', '0.0000', etc.

 

I suggest:

if (empty($record[$r]) && !is_numeric($record[$r])) {

 

This keeps any empty value that looks numeric.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...