Jump to content

change weight to product if I change variants


Recommended Posts

Hello 

 

I have prestashop 1.6 and i vant change product weight if i change variants.

 

examble>

 

variant 1. - - - 1kg

variant 2 - - - 2kg

 

if i have variant 1 defaul I have in protuct page waight: 1kg and if I change variant 2 .. weight is 2kg.

 

Big thans for help

 

 

Link to comment
Share on other sites

You can use the "Impact on weight" text fields on the "Combinations" tab of the product editor to set the weight of each combination. You can choose to set a base weight and then add weight differences or set the base weight to 0 and then set the exact weight for each combination.

Link to comment
Share on other sites

yes, but in my themes doesnt change weight if i change combination with different weight

 

edit:

 

im change file
 
product.js
 
im put in function
addCombination(...,...,weight) 
and after 
var combination = []; 
this
combination['weight'] = weight;
 
and in 

function findCombination()

selectedCombination['weight'] = combination['weight'];
var fweight= selectedCombination['weight'];  
$('.whatever-box').html('<span>Hmotnost: '+fweight +'</span>');  

 .. and in .whatever-box i have: Undefined

Edited by lier (see edit history)
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...