Variant published by default is not working

  • Posts: 24
  • Thank you received: 1
10 years 2 months ago #205017

-- HikaShop version -- : 2.5.0
-- Joomla version -- : 3.4.1
-- PHP version -- : 5.4.36

Options "Variant published by default" is not working. Products always display with variant by default if option set as Yes or No.

The following user(s) said Thank You: A. van de Kamp

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

  • Posts: 13201
  • Thank you received: 2322
10 years 2 months ago #205022

Hi,

Yes indeed this option is no more used, the variant system has changed, now you have to create your variants, they are no more generated automatically so when adding new variants you can publish or unpublish them directly in the listing from the product edition page.

We will see to add back that feature or remove the option definitively. Thanks for the report.

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

  • Posts: 24
  • Thank you received: 1
10 years 2 months ago #205118

The problem is that I want to that no option is not displayed by default. But I can not do it in backend. Besides that on click by checkmark "published" nothing happens.

Attachments:

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

  • Posts: 13201
  • Thank you received: 2322
10 years 2 months ago #205124

Hi,

Yes my bad, you have to click on the variant to open its edition and then unpublish it thanks to the option.

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

  • Posts: 24
  • Thank you received: 1
10 years 2 months ago #205238

Ok. I'm understand with option published.
But I want that no one variant not published by default. How can i do this?

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

  • Posts: 84304
  • Thank you received: 13699
  • MODERATOR
10 years 2 months ago #205273

Hi,

Can you try to change the line:

' SELECT '.$p_code.' as c_product_code, '. $this->database->Quote('variant') .','. (int)$product_id . ',1,' . $t . ',' . $t . ',' . $this->database->Quote(@$element->product_group_after_purchase) .
to:
' SELECT '.$p_code.' as c_product_code, '. $this->database->Quote('variant') .','. (int)$product_id . ',0,' . $t . ',' . $t . ',' . $this->database->Quote(@$element->product_group_after_purchase) .
in the file administrator/components/com_hikashop/classes/product.php and see if that helps ?

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

  • Posts: 24
  • Thank you received: 1
10 years 2 months ago #205399

It's not work

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

  • Posts: 84304
  • Thank you received: 13699
  • MODERATOR
10 years 2 months ago #205757

Hi,

I've done a test on my end with that same modification and it works. Variants are created unpublished by default when you create them in the Variants tab of the new HikaShop product edition interface.
I don't see why that wouldn't work. Can you double check ?

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

  • Posts: 24
  • Thank you received: 1
10 years 2 months ago #205867

Finally it received. My mistake was that when I'm choose the characteristic, I'm not filled value by default and tab variants not exist. And I could not guess intuitively.

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

  • Posts: 26274
  • Thank you received: 4045
  • MODERATOR
10 years 2 months ago #205877

Hi,

In the variant listing, you have a column for the "default" where you can see the default variant.
So if in the list there is none variant with the green tick, it means that your default variant does not exist (and you have to choose one in the current list)

When with the old interface you had to read the default variant configuration in one page and check it is exists in the variant listing, with the new interface you can see that directly in the listing.
But we will see to add a little message above the variant listing when there is no default variant in the list.

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.

Time to create page: 0.076 seconds
Powered by Kunena Forum