Skip to main content

Displaying version of product dimensions ?

More
15 years 6 months ago #12389 by pproject
Hi,

I would like to display the dimensions of product versions, but I could manage displaying the
dimensions of main product only.
Can you help inserting the right code?

Thanks.

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

More
15 years 6 months ago #12416 by nicolas
Hi,

It's a lot more complicated because you need to refresh the display with the correct variant dimension...

What code did you use for the dimensions of the main product ?

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

More
15 years 6 months ago #12427 by pproject
I have duplicated the code of showing the weight of product, also duplicated the code at the
showing variants of weight, but that is not refreshing.(weight doing). If I set style=display:block
the list of variants displayed correctly, but refreshing does not work.

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

More
15 years 6 months ago #12456 by nicolas
In the file administrator/components/com_hikashop/types/characteristic.php you have the line:
var names = [\'id\',\'name\',\'code\',\'image\',\'price\',\'quantity\',\'description\',\'weight\',\'url\'];

you will need to add your new fields so that they are handled as well. So, for example if you have the id hikashop_product_dimension_main you would change that line into:
var names = [\'id\',\'name\',\'code\',\'image\',\'price\',\'quantity\',\'description\',\'weight\',\'url\',\'dimension\'];

Note that the modifications in that file will be overwritten when you update hikashop.

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

More
15 years 6 months ago #12484 by pproject
Thanks a lot Nicolas! Now that is working as a dream.

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

Time to create page: 0.188 seconds
Powered by Kunena Forum