News:

You may pay someone to create your store, or you visit our seminar and become a professional yourself with the silver certification

Main Menu

VM2 allows checkout of out of stock products

Started by e-trader, January 31, 2014, 16:57:22 PM

Previous topic - Next topic

vaistik

Quote from: GJC Web Design on June 04, 2014, 16:42:43 PM
correct in the VM version you mention  - this is why I went with my system - to attach a flag as soon as it enters a cart.

Haven't checked the VM2.6.x series...

If you want to check it at Confirm purchase your going to have to write your own check in the cart system.

Thanks for the reply! It's a shame the client insists on doing the check during purchase confirmation, your plugin would save me ALOT of time. Do you have any pointers as to which files/functions I should look at?

I was thinking messing around with the dataValidated variable but couldn't find a proper way to do so.

GJC Web Design

I haven't investigated this - I just attach a custom field to the product when 1st added to cart - any subsequent add to carts trigger a check if the product has that custom field - if so block it

You need to trace what triggers are called on confirm cart and write something for that that checks if it's really in stock..

from a user point of view  - you risk annoying the client with his nice selection of products - filled out his address, chosen payment - and then finds he can't confirm the cart.. :-[

GJC Web Design
VirtueMart and Joomla Developers - php developers https://www.gjcwebdesign.com
VM4 AusPost Shipping Plugin - e-go Shipping Plugin - VM4 Postcode Shipping Plugin - Radius Shipping Plugin - VM4 NZ Post Shipping Plugin - AusPost Estimator
Samport Payment Plugin - EcomMerchant Payment Plugin - ccBill payment Plugin
VM2 Product Lock Extension - VM2 Preconfig Adresses Extension - TaxCloud USA Taxes Plugin - Virtuemart  Product Review Component
https://extensions.joomla.org/profile/profile/details/67210
Contact for any VirtueMart or Joomla development & customisation

Milbo

Quote from: bunglehaze on June 04, 2014, 22:49:49 PM
http://www.rupostel.com/phpBB3/viewtopic.php?f=5&t=937&sid=1b5d2e395866210264df3bf3f077ebbc

The strange thing is that exactly this line should update the product with the new stocking. For me it looks like the check is just disabled.
Should I fix your bug, please support the VirtueMart project and become a member
______________________________________
Extensions approved by the core team: http://extensions.virtuemart.net/

Milbo

Quote from: bunglehaze on June 04, 2014, 22:49:49 PM
Ignore the above - fix was found today that I can confirm works:
http://www.rupostel.com/phpBB3/viewtopic.php?f=5&t=937&sid=1b5d2e395866210264df3bf3f077ebbc

Again, I just rechecked it. This "fix" is definitly wrong, you just disable the function. Please try the attached file in BE/models

[attachment cleanup by admin]
Should I fix your bug, please support the VirtueMart project and become a member
______________________________________
Extensions approved by the core team: http://extensions.virtuemart.net/

bunglehaze

Quote from: Milbo on June 06, 2014, 10:39:38 AM
Quote from: bunglehaze on June 04, 2014, 22:49:49 PM
Ignore the above - fix was found today that I can confirm works:
http://www.rupostel.com/phpBB3/viewtopic.php?f=5&t=937&sid=1b5d2e395866210264df3bf3f077ebbc

Again, I just rechecked it. This "fix" is definitly wrong, you just disable the function. Please try the attached file in BE/models

OK, I removed the commenting on Rupostel 'fix' and replaced the /administrator/components/com_virtuemart/models/product.php with the file you attached Milbo,  the add to cart function  is no different to how it was before the 'fix' (ie you cannot check out anything). I re-commented the line again and I can add to cart again.

I hope that helps figure this out.

Milbo

It works for me. I tested it. So please give me your exact configuration of the stocking and the settings of the products.
Should I fix your bug, please support the VirtueMart project and become a member
______________________________________
Extensions approved by the core team: http://extensions.virtuemart.net/

bunglehaze

How do you want me to do that Milbo?  What files do you want to see?

norris

i can confirm the same experience as bunglehaze, after updating VM to 2.6.12 I had the problem with child variants showing up, but not able to be added to the cart unless the parent had some stock set.

I tried  replaced the /administrator/components/com_virtuemart/models/product.php with the file Milbo attached, but it didn't work.  I restored the original product.php and tried commenting out the line in cart.php and that fixed it.

bunglehaze

I have updated each version of VM2 since that 'fix' was first found and each time the same situation occurs with parent products flagging up the "out of stock" error when selecting child products in stock. Each time I commented the line in the 'fix' and it works again.

Milbo

Should I fix your bug, please support the VirtueMart project and become a member
______________________________________
Extensions approved by the core team: http://extensions.virtuemart.net/

bunglehaze

Quote from: Milbo on October 28, 2014, 01:59:26 AM
How works vm3 for you?

I haven't tried it for the last couple of revisions as the stockable plugin migration wasn't in place and my entire site us pretty much using it.

I have been hanging on until that worked and I'll give it a try