wishlist isn't working allright after the update

  • Posts: 410
  • Thank you received: 9
  • Hikaserial Subscription Hikashop Business
7 years 2 months ago #278263

-- url of the page with the problem -- : hierutest.incunopra.nl
-- HikaShop version -- : 3.2.0
-- Joomla version -- : 3.7.5
-- PHP version -- : 6.x.x

Hello,

I got a problem with the wishlist and that is the following.
When i put a product with characteristics and other option of custom filelds in the wishtlist. they are neatly in it.
When i add this product with all options to the cart, the characteristics are gone ? why?
And also i want if we add the product from wishlist to be directly moved towards the checkout and not the step in between to the cart and then to the checkout.
Please help.

Thanks.

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

  • Posts: 26158
  • Thank you received: 4028
  • MODERATOR
7 years 2 months ago #278264

Hello,

Would it be possible to have an example (which product you're using, with which data), so we can test and reproduce it in one of our test website.

Regards,


Jerome - Obsidev.com
HikaMarket & HikaSerial developer / HikaShop core dev team.

Also helping the HikaShop support team when having some time or couldn't sleep.
By the way, do not send me private message, use the "contact us" form instead.

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

  • Posts: 410
  • Thank you received: 9
  • Hikaserial Subscription Hikashop Business
7 years 2 months ago #278320

Hello,
I've made screenshots to show you what is happening. You can test it for yourself. I will give you 2 different users to log in cause with each user the wishlist is reacting differently.

Hope you can help out.thanks.

Attachments:
Last edit: 7 years 2 months ago by Jerome. Reason: removing confidential information

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

  • Posts: 26158
  • Thank you received: 4028
  • MODERATOR
7 years 2 months ago #278362

Hello,

I'm trying to analyze the product page from the product which was already in the user cart) but I cannot see any kind of characteristic or variants.
But I can see a lot of custom item fields and some options.

So can you please provide some elements for your products with the characteristics ; because I can't find it.

Regards,


Jerome - Obsidev.com
HikaMarket & HikaSerial developer / HikaShop core dev team.

Also helping the HikaShop support team when having some time or couldn't sleep.
By the way, do not send me private message, use the "contact us" form instead.

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

  • Posts: 410
  • Thank you received: 9
  • Hikaserial Subscription Hikashop Business
7 years 2 months ago #278419

Hello Jerome,

Sorry my bad, i confused i meant the options. it has to do with the options in the product. for example in this product.
hierutest.incunopra.nl/producten-dienste...oduct/basis-uitvaart


In the backend of the product it is like this.

and so in the option product it look likes this.

These won't go to the cart while they are in the wishlist.
Hope you understand it better now.
Sorry i mixed up some names. :)
Hope you can help.

Attachments:

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

  • Posts: 82863
  • Thank you received: 13372
  • MODERATOR
7 years 2 months ago #278454

Hi,

Thank you for the access.
I think that we've found the fix for the issue.
Replace the code:

if(empty($cart_product->cart_option_parent_id) || !in_array((int)$cart_product->cart_option_parent_id, $cart_products_ids))
to:
if(empty($cart_product->cart_option_parent_id) || !in_array((int)$cart_product->cart_option_parent_id, $cart_product_ids))
in the file administrator/components/com_hikashop/classes/cart.php and that should fix the problem.

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

  • Posts: 410
  • Thank you received: 9
  • Hikaserial Subscription Hikashop Business
7 years 2 months ago #278484

Hello,

I have replaced the code. but i am sorry to inform you that that doesn't fix the issue.

What could it be more then?

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

  • Posts: 26158
  • Thank you received: 4028
  • MODERATOR
7 years 2 months ago #278551

Hello,

Can you please try with:

if(empty($cart_product->cart_option_parent_id) || in_array((int)$cart_product->cart_option_parent_id, $cart_product_ids))

Regards,


Jerome - Obsidev.com
HikaMarket & HikaSerial developer / HikaShop core dev team.

Also helping the HikaShop support team when having some time or couldn't sleep.
By the way, do not send me private message, use the "contact us" form instead.
Last edit: 7 years 2 months ago by Jerome.

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

  • Posts: 410
  • Thank you received: 9
  • Hikaserial Subscription Hikashop Business
7 years 2 months ago #278557

I am sorry to inform you that also this does not work. The options are gone when putting the wishlist into the cart.
you can see for yourself at the website.

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

  • Posts: 82863
  • Thank you received: 13372
  • MODERATOR
7 years 2 months ago #278665

Hi,

I did some tests on my end and I was able to reproduce and fix the issue.
Change that line to:

if(empty($cart_product->cart_product_option_parent_id) || !in_array((int)$cart_product->cart_product_option_parent_id, $cart_product_ids))
and it will work.

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

  • Posts: 410
  • Thank you received: 9
  • Hikaserial Subscription Hikashop Business
7 years 1 month ago #279105

hi nicolas,

This made it working alright thanks.
implemented it and tested it.
thanks.

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

  • Posts: 410
  • Thank you received: 9
  • Hikaserial Subscription Hikashop Business
7 years 1 month ago #279126

one little last question, how is the data for the options grabbed into the wishlist cause i see a diference of showing the option data in the checkout. see images.


can you please tell how this is done? or how i can fetch the data ?

Attachments:

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

  • Posts: 82863
  • Thank you received: 13372
  • MODERATOR
7 years 1 month ago #279141

Hi,

The data is already loaded in the view in the product data object in ->prices, like on the checkout.
We just don't display it on the wishlist/cart manager. So you could use code similar to the code in the show_block_cart view file for the price display.

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

  • Posts: 410
  • Thank you received: 9
  • Hikaserial Subscription Hikashop Business
7 years 1 month ago #279206

just a little question where can i find that view?

can not find it in the views. :)

Attachments:

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

  • Posts: 82863
  • Thank you received: 13372
  • MODERATOR
7 years 1 month ago #279209

Hi,

It is in Display>Views. So you must have missed it. Use the search input field in order to search for it.

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

  • Posts: 410
  • Thank you received: 9
  • Hikaserial Subscription Hikashop Business
7 years 1 month ago #279421

As you said i search for this file in display->views using the search tool but this file isn't there: show_block_cart

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

  • Posts: 12953
  • Thank you received: 1778
7 years 1 month ago #279426

Hello,

If you have Hikashop's 3.2.0 version, you should find it through the "Hikashop->Display->Views" page by searching for the "show_block_cart" file of the "checkout" view of your front-end template.

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

  • Posts: 410
  • Thank you received: 9
  • Hikaserial Subscription Hikashop Business
7 years 1 month ago #279674

Hello,

Found the right view, but can not figure out how to get it. to explain I made this code in the hikashop version 2.6.4 in the view cart/showcart .

<?php 
$itemFields = $this->fieldsClass->getFields('display:field_item_show_cart=1',$cart,'item');
?>
              
               <a href="<?php echo hikashop_contentLink('product&task=show&cid='.$cart->product_id.'&name='.$cart->alias.$url_itemid,$cart); ?>?<?php
						
						if(!empty($itemFields)) {
							foreach($itemFields as $field) {
								$namekey = $field->field_namekey;
								if(!empty($cart->$namekey) && strlen($cart->$namekey)) {
									echo ''.$field->field_namekey.'='.$cart->$namekey.'&';
								}
							}
						} 
                        ;
?><?php echo $string_url,'pageis=wishlist'; ?>" class=" button hikashop_cart_input_button">
Wijzig Product</a>
With this code i managed to trigger that the option and custom fields value's come along when i modify the product in the wishlist and could add an extra product in the list with modifications in the options. This is working. But however after the update to hikashop version 3.2.0 i have implement the code in the cart/show view. but now i can not get the right value's to come along to modify the product .
The option fields and custom fields now are set on default when i click on modify, can you help me with this little peace of code to trigger the right parameters? i have the same site on to different urls one with hikashop 2.6.4 and one with the updated version 3.2.0 for you to better understand
This message contains confidential information

Thanks

Last edit: 7 years 1 month ago by nicolas.

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

  • Posts: 82863
  • Thank you received: 13372
  • MODERATOR
7 years 1 month ago #279682

Hi,

First, you need to change: $url_itemid
to something like that: '&Itemid=XXX'
where XXX is the id of the products listing menu item you're using.

Second, you need to change: field_item_show_cart
to: front_cart_details
as the name of the option changed with HikaShop 3.

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

  • Posts: 410
  • Thank you received: 9
  • Hikaserial Subscription Hikashop Business
7 years 1 month ago #279762

Hello Nicolas,

I have made the change to front_cart_details.. but where can i find the id of the products listing menu? is it the joomla menu item id? that seems not to work.. what i have so far is that the custom fields now will hold there original settings as put in the wishlist.. that is oke only the options are still gone and back on default.. is this because of the Itemid??

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

Time to create page: 0.120 seconds
Powered by Kunena Forum