Problem with characteristics/variants

  • Posts: 37
  • Thank you received: 0
13 years 10 months ago #5756

Hi there,

Not sure if this is a bug or something to do with my setup - but can't seem to figure out any way for this to work the way I need it to...

I have setup a product which is a T-Shirt - I have 4 different sizes for the T-Shirt (Small, Medium, Large and Extra Large). I have added these as variations of the T-Shirt.

I see several problems with this setup;

***I have the add to cart button displayed on the product list page - If I click on the button from this page it does not give the opportunity to select a size yet still adds the default product to the cart (i.e. I will get an order for "T-Shirt" as oppose to "T-Shirt Large", "T-Shirt Small" etc). I see two options to get over this - first to set 0 stock for the default item as technically I don't have any of this product in stock so shouldn't be able to order it. If I set this on the product list page it then shows the item as "No Stock" but if I enter the product view page it is in stock (as the variants are used). Second is to add the variants dropdown to the product list page so a variant has to be selected from the list to allow it to be added to cart (a default value will always be selected). I feel this is a bug in the system and could be addressed by a selection of options etc.

*** When on the product view the variant title is appended to the title of the product (which is great, as I want it) - but when the variant is changed in dropdown it doesn't change the title - may confuse people. For example if I enter my T-Shirt product the title by default says "T-Shirt Small" - if I change this option to Large the title still says "T-Shirt Small" but if I click on the add to cart button "T-Shirt Large" gets added to the cart (as it should).


As I began the post, this may be me misunderstanding the configuration but I can't seem to figure anything out from the docs.

I think the variants need a little more work - hopefully you can help me out with my problem here - really what I would like to know for the time being is 1) How can I add the variants dropdown to the product list pages (if a product has variants) and 2)How can I dynamically change the title on the product view page to match the selected variant?

Hope this all makes sense - Found it a little hard to explain!

Thanks
Simon

Please Log in or Create an account to join the conversation.

  • Posts: 82868
  • Thank you received: 13375
  • MODERATOR
13 years 10 months ago #5758

Hi,

1/ Variants options aren't displayed on the listing of products so if you have products with variants you should indeed have the user go in the product page so that he can select the variant before adding to the cart.
Using the quantity of the main product to 0 to remove the 'add to cart' button from the listing is a smart move. You could modify a bit the file quantity of the view product to not display the no stock message in such cases with a small tweak to the code. Another option would be to not display the add to cart button on the products listing.

I understand what you want to do but we wanted to avoid loading all the variants data with all the processing behind for each product of the listing because if you start having a lot of products displayed and a lot of variants for each, it's just too much. So we decided to just do it on the product page. It's not really a bug, that's just the way it is.

2/ That is indeed not normal. The name, as well as the price and any other information related to the product should be updated when you change the value of the dropdown. The most probable reason is that there is a javascript error on your page which prevent the script to function properly. Could you check on that in the error console of your browser ? If you could provide the URL to that page, we might be able to tell you more.

Please Log in or Create an account to join the conversation.

  • Posts: 37
  • Thank you received: 0
13 years 10 months ago #5760

1/I now understand the method behind the madness! However, may I suggest that you maybe consider making this a little easier for the site admins to get their head around. In an ideal world I would like to keep the add to cart buttons on the product list page - therefore would be nice to see some code in the template to detect if variants are required and if so perhaps have a button displayed saying "choose options" or similar to take the user to the product view page to keep the same look and feel on the page (if I have no button on that product customers may assume that it is not in stock, without even looking at the product view page). Most of my products are simple and therefore I would like the customers buying experience to be quick - if they want to order directly from the list page they should be able to and if they choose to see the full description they should be able to, again with the add to cart option.

2/I have made some changes to this template to get the title to display how I wanted it to so it is likely that I have caused this problem here from the sounds of it - I will revert back to the original file in the morning and check - only getting 1 JS error at the moment and that's from a google adsense module as it's being used on localhost.


While this one doesn't actually cause me any problems, it may do for other so I will introduce point 3.

3/As far as I can see, if you have variations it is required to choose one of these variations and the "standard" product cannot be ordered - perhaps in the variations configuration have an option to decide whether the variation is required or optional and if optional ensure that no variation is selected by default (ie a blank row in the dropdown). An example of this would be if I was selling a pc in my shop - by itself would be £100 but if I wanted to add the variation of PC with monitor it would be £150 or PC with monitor and printer for £200. Do you see what I mean?

Think I need to go to bed!
Simon

PS - Is there an easy method for me to change the template for 1/ so if the product has variations that require the full product view I can replace the ADD TO CART button with another button that just takes the user to the product view page (would prefer not to just hide the button).

Thanks

Please Log in or Create an account to join the conversation.

  • Posts: 82868
  • Thank you received: 13375
  • MODERATOR
13 years 10 months ago #5776

1. That's a good idea. We'll look at adding a "choose options" button on the product listing when it has characteristics and that the "add to cart" button option is activated for the listing.

3. I see what you mean. Characteristics have been built on the assumption that you have one product per combination of the characteristics values. In next release, we will add custom fields on the products so that, like for addresses you can ask information on the product to the user on the product page. However, that will apply to all the products of the store. We keep improving things and what you're talking about is also something we have in mind for the future.

PS: We'll look at that today...We need to look a bit on how to do it and test it... We'll probably include such modification in next version...

Please Log in or Create an account to join the conversation.

  • Posts: 209
  • Thank you received: 18
13 years 9 months ago #6116

Hi Nicolas,

It would be good if a variant or product option could have a $ value that adds or subtracts from the base product if chosen.

In Zen Cart for example, using product attributes you can have something like this:

Base product = dress $60

Options =
Choose size (dropdown box - selection required)
Size 10 +/- $0
Size 12 +/- $0

Choose fabric (radio boxes, single choice)
Cotton +/- $0 (default)
Poly cotton - $10
Silk + $20

Choose matching scarfs (checkbox list - no default, no selection required)
Blue + $10
Yellow + $5

So say if someone purchased a dress, size 10, in polycotton with a yellow and a blue scarf, the total product price with the chosen options would be $65.

Translating this into Hikashop speak:
Base Product = Product
Size, fabric, scarves = Characteristics
10, 12, Cotton, etc = Characteristic variants

Also, in this way you can effectively have a base product that is $0 and "build" your product according to the variants.

There would also need to be a Yes/No "Selection required" on each of the characteristics and the ability to set a default variant.

This would be perfect!

cheers!

Please Log in or Create an account to join the conversation.

  • Posts: 82868
  • Thank you received: 13375
  • MODERATOR
13 years 9 months ago #6119

We are thinking of proposing such things with custom item fields in the future so that you will have a lot more possibilities and flexibility.
We will make it possible to link products with custom fields values so that the system would add the corresponding products to the cart.
That way, you could even build a complete "make your pc" page ( where you can select the RAM, monitor size, CPU, HDD, etc, etc ) like this.

Please Log in or Create an account to join the conversation.

  • Posts: 37
  • Thank you received: 0
13 years 9 months ago #6129

nicolas wrote:

1. That's a good idea. We'll look at adding a "choose options" button on the product listing when it has characteristics and that the "add to cart" button option is activated for the listing.


Is there a way I can do this in the templates? Would really like this option if possible.

And sounds like some good ideas being thrown around for the variations.

Simon

Please Log in or Create an account to join the conversation.

  • Posts: 37
  • Thank you received: 0
13 years 9 months ago #6132

In fact I see that this is implemented in the latest version... I will update in the morning.

Do you have a mailing list I can sign up to in order to be kept updated on new releases - maybe an "update is avaliable" notice on the backend like some other components have?

Simon

Please Log in or Create an account to join the conversation.

  • Posts: 82868
  • Thank you received: 13375
  • MODERATOR
13 years 9 months ago #6143

We send newsletters but not really often (we don't want to bother everyone every week, plus the fact that it takes some time for us to write an interesting newsletter).
There is the menu Update/About us which enables you to know if there is a new version available. For now, we didn't yet activate it for the new release (we're waiting for a few days in case there is a problem).

Please Log in or Create an account to join the conversation.

  • Posts: 35
  • Thank you received: 0
13 years 5 months ago #18583

Very interesting thread and great to see the implementation of the 'choose options' button.

I have a related question:

Is it posible to have only the variant options that actually have a product in stock show in the dropdown list or radio button style. That is to say that any variant not in stock would not show up on the list.

In my case of shoes, it is tiresome to click on several sizes to see if it is in stock.

Thanks for the time.

Please Log in or Create an account to join the conversation.

  • Posts: 82868
  • Thank you received: 13375
  • MODERATOR
13 years 5 months ago #18595

If you set it to display in table and that you have two characteristic for your product, you will only be able to select the variants which exist and have a quantity. Otherwise, you can try to change the line:
$filters=array('product_parent_id IN ('.implode(',',$ids).')');
to:
$filters=array('product_parent_id IN ('.implode(',',$ids).')','product_quantity!=0');

in the file components/com_hikashop/views/product/view.html.php
That might work

Please Log in or Create an account to join the conversation.

Time to create page: 0.093 seconds
Powered by Kunena Forum