Automatic generation of variant product codes..

  • Posts: 2
  • Thank you received: 0
13 years 8 months ago #9788

When creating variants, the product codes are automatically generated. By default it seems that the variant id is appended to the parent product name. Is it possible to have the variant value appended instead? For Example: Example-prod_Small, Example-prod_Med, Example-prod_Large.... instead of Example-prod_2, Example-prod_3, Example-prod_4?

Thanks in advance,

Mark

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

  • Posts: 82863
  • Thank you received: 13372
  • MODERATOR
13 years 8 months ago #9805

Hi,

There is no option for that. You would have to edit the function updateCharacteristics in the file administrator/components/com_hikashop/classes/product.php
However, the data of the characteristics is not loaded so you only have access to the characteristics values ids. If you want to do it, you will have to load the information from the table hikashop_characteristic before setting the value in the product code.
We didn't want to do that because the product code can only have alpha numeric characters and if you have characteristic values in a language which doesn't use alpha numeric characters like japanese or russian, it would not work properly.

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

Time to create page: 0.054 seconds
Powered by Kunena Forum