- Posts: 13
- Thank you received: 1
product characteristics on product listing
Please Log in or Create an account to join the conversation.
I also are in desperate need of this function. For a number of websites I even abandoned Hikashop and used Virtuemart to get this function running.
For now the hikashop structure is not capable of adding this function into the product.
But as more and more developers are requesting this feature somewhere in the future this will be also possible with hikashop.
I understand that this select variant and click add to cart function can only be true if only one variant is added to the product.
Kind regards,
Cornel
Please Log in or Create an account to join the conversation.
Any progress on this Hikashop??
Please Log in or Create an account to join the conversation.
- Posts: 12953
- Thank you received: 1778
Note that this feature is actually on our TODO list
Please Log in or Create an account to join the conversation.
I'd really like to be able to add to cart one of each pipe length by choosing from the variants.
I can't see that that is possible with custom fields... or am I misunderstanding?
Please Log in or Create an account to join the conversation.
- Posts: 12953
- Thank you received: 1778
Using custom fields can be the solution only if the price won't change regarding the product variant.
Please Log in or Create an account to join the conversation.
As we've been getting more and more products in different sizes, this functionality is becoming more essential as this would enable us to keep our webshop much more orderly and user-friendly. We've been using Hikashop for many years and have been very satisfied with it and the support, it would be a shame if we have to look at other options.
Hopefully we can look forward to this feature soon!
Please Log in or Create an account to join the conversation.
Thank you for your feedback. We're working actually on a new cart and checkout system. So the characteristics on listing feature is not for now but it's on our todo list.
Please Log in or Create an account to join the conversation.
It's nothing complicated, we haven't changed any code and are not loading the characteristics or anything, we're just adding a couple of buttons in the product description. By placing the following in the product description it's possible to directly add a variant to the cart through Ajax, with a text input field the customer can even enter a desired quantity for the variant:
You have to manually fill in the correct product ID for every variant in the above code, so it does require some manual work, but for us it's a nice improvement and seems to be working fine.
If there are any improvements we can make, we'd be glad to know!
Please Log in or Create an account to join the conversation.
- Posts: 104
- Thank you received: 2
Thank you for your post.
I can't seem to get it working though I added the coding you gave and the system brings up the popup saying the product has been added to the cart, but it does not add anything.
Do you have an example where I can see how this looks and works.
Please Log in or Create an account to join the conversation.
unfortunately we moved away from using characteristics some time ago due to an increase in complexity and some limitations of characteristics, so we don't use the above code anymore.
With the new cart system in Hikashop 3 it looks like things have changed a bit, so if you're using Hikashop 3 that may be the reason why it's not working. Other than that it's difficult to say, if you can provide a link of your product listing, I could take a look for you.
Kind regards,
Please Log in or Create an account to join the conversation.
As written by Nicolas 11 months ago
For sure, the development of HikaShop 3.0 was very long. For now we want to stabilize the new system and thanks to the new code base, new features like characteristics on listing would be possible (but it will require for sure, a development).We're working actually on a new cart and checkout system. So the characteristics on listing feature is not for now but it's on our todo list.
Regards,
Jerome - Obsidev.com
HikaMarket & HikaSerial developer / HikaShop core dev team.
Please Log in or Create an account to join the conversation.
after a few years we've decided to give this another go trying to display also characteristics in our product listing, as we noticed the variant_ids are already being loaded in the product array.
We have no problem getting the variants names, quantities, etc. and we are able to get the price with the usual
Would you know a solution to get the taxes for the variants as well?
We did notice that in the hikashop_product table the product_tax_id field remains 0 for variants. Manually setting this field to the same tax_id as the main product does give us the correct variant prices with taxes, but this is not really a viable solution to do by hand for many products and variants. We were wondering why variants are not automatically given the same product_tax_id as the main product (since it isn't possible to set a different tax rate anyway for a variant in the back-end).
Any help would be very much appreciated!
Kind regards,
Please Log in or Create an account to join the conversation.
You're wrong, the variants are automatically givent the same product_tax_id as the main product. It's actually done dynamically when the products/variants are loaded on the frontend. That's why the value in the database is 0.We were wondering why variants are not automatically given the same product_tax_id as the main product
Doing it like that, it gives us the possibility to be able to have different tax categories for different variants of the same product in the future, which is something that has been requested.
The problem is with your code actually. Normally, when the product page calls the getPrices function, $product is the main product and it has an array of variants in $product->variants. In that case, the getPrices function automatically uses the product_tax_id of the main product if it is empty in the variant.
So supposing that you have the main product data in $this->row, and the variant data in $product, you can add the line:
$product->product_tax_id = $this->row->product_tax_id;
before calling the getPrices function and it will work fine.
Please Log in or Create an account to join the conversation.
ok that makes sense, thanks.
It's been a while since we last made some code changes, but it's working nicely.
Kind regards,
Please Log in or Create an account to join the conversation.