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

How to get multi variant childs stock

Started by kogos, July 22, 2017, 18:10:51 PM

Previous topic - Next topic

kogos

Hi all,
i already asked once in forum, but i got no answer because my question was too complicated (i think)...

So, i'm asking once again, and hope for an answer.

I am using multi variant custom field to select size and color of clothes. How can i get the stock level (product_in_stock - product_ordered) from multi variant childs?

I tried to implement various methods with no luck.

Any help would be greatly appreciated.

Thanks in advance

loppan

I'm using Breakdesign's Stockable custom fields plugin for this exact purpose... works great :) https://breakdesigns.net/extensions/joomla/stockable-custom-fields

kogos

million thanks for the reply m8. I will definitely check it out. Appreciated

johnkont

I think only if you use custom multivariant fields you can use the availability per product.

kogos

thats the custom field type i am using, multivariant type. But my problem is that when a product is out of stock, you can either hide it, or change the "add to cart" button to "notify"... and there is no way to show the product variant with line-through, no matter what is done with overrides or css...

I think that my problem will be solved with Breakdesign's Stockable custom fields plugin, as loppan suggested, but unfortunately i did not have the time to test it yet.

However, i will get back with results once it's tested for future reference, in case someone else has the same demand/problem

Studio 42

CSS line-through is not possible in select list , you can only "disable" an option but i think that VM do not include this.
See https://www.w3schools.com/tags/att_option_disabled.asp for the disable atribute
So you have to components\com_virtuemart\sublayouts\customfield.php
Or you can change the color with CSS .yourclass {color:red;} but need to add the class in the option tag