VirtueMart Forum

VirtueMart 2 + 3 + 4 => General Questions => Topic started by: drevokocur on May 07, 2014, 14:59:27 PM

Title: Can`t select first child option
Post by: drevokocur on May 07, 2014, 14:59:27 PM
If I have more child items, and the parent is not orderable. I can't add the first selected child to the cart.  I actually have to chose the second child item, then select the first again for it to be enabled to be added to the cart.

I need there also a someting like a first empty position like "Please select variant" or something like that.

I have also searched the forum, and found this, but the hack didn`t worked for me: https://forum.virtuemart.net/index.php?topic=110203.msg410620

Joomla! 2.5.14
VM 2.0.24c
Title: Re: Can`t select first child option
Post by: GJC Web Design on May 07, 2014, 15:11:31 PM
from memory I got around this by making a dummy first child called Select with 0 price etc
Title: Re: Can`t select first child option
Post by: drevokocur on May 07, 2014, 17:26:08 PM
Quote from: GJC Web Design on May 07, 2014, 15:11:31 PM
from memory I got around this by making a dummy first child called Select with 0 price etc

I need a global code-solution for this, I think this is a bug. Funny is, that by some products (or by one child parameter) it works, and others not:
works: http://www.zvarmat.sk/zvaracka-esab-heliarc-283i-ac-dc
works not: http://www.zvarmat.sk/nehorlava-krycia-textilia-esab-1850

And child options settings are the same...
Title: Re: Can`t select first child option
Post by: GJC Web Design on May 07, 2014, 18:26:09 PM
there must be something different between the two produt setups then - the base problem is the working one has a  "Selected" option the 1st one is "selected" when you open the page in a html sense

works
<option selected="selected" value="/zvaracka-esab-heliarc-283i-ac-dc">Prosím vyberte</option>

doesn't work
<option value="/nehorlava-krycia-textilia-esab-1850-rozmer-2m-x-1m">Nehorľavá krycia textília ESAB 1850 rozmer 2m x 1m</option>
Title: Re: Can`t select first child option
Post by: drevokocur on May 08, 2014, 09:18:02 AM
Quote from: GJC Web Design on May 07, 2014, 18:26:09 PM
there must be something different between the two produt setups then - the base problem is the working one has a  "Selected" option the 1st one is "selected" when you open the page in a html sense

works
<option selected="selected" value="/zvaracka-esab-heliarc-283i-ac-dc">Prosím vyberte</option>

doesn't work
<option value="/nehorlava-krycia-textilia-esab-1850-rozmer-2m-x-1m">Nehorľavá krycia textília ESAB 1850 rozmer 2m x 1m</option>

I have found the difference. The first that works is a product, where the parent can by ordered, but by the second the parent can`t be ordered. But I don`t know how to fix it. :(