How could I turn off "none" for options?

  • Posts: 2293
  • Thank you received: 315
6 years 1 month ago #288705

-- HikaShop version -- : 3.3.0

I have added two options to my product.
And on the product page I have two options:
(none) (first)
(none (second)

Could I choose default option with option on?


Я не явлюсь официальной службой поддержки!
Я здесь добровольно!

Хочешь получить купон на скидку Hikashop? Спроси меня как!
Attachments:
Last edit: 6 years 1 month ago by progreccor.

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

  • Posts: 81504
  • Thank you received: 13062
  • MODERATOR
6 years 1 month ago #288708

Hi,

You could edit the file "option" of the view "product" via the menu Display>Views and add the code:

$value = $optionElement->product_id;
after the line:
if(empty($optionElement->variants)){

Last edit: 6 years 1 month ago by nicolas.

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

  • Posts: 2293
  • Thank you received: 315
6 years 1 month ago #288760

and how could I gain the same result as in your demo site?

demo.hikashop.com/index.php/fr/hikashop/...ct-page/with-options

Here we can get three options and there is no option "none"



P.S.
As I can see - I need to create variants for options?
Am I right?


Я не явлюсь официальной службой поддержки!
Я здесь добровольно!

Хочешь получить купон на скидку Hikashop? Спроси меня как!
Attachments:
Last edit: 6 years 1 month ago by progreccor.

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

  • Posts: 81504
  • Thank you received: 13062
  • MODERATOR
6 years 1 month ago #288774

That's right, you need to have variants in your option product.

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

Time to create page: 0.072 seconds
Powered by Kunena Forum