Jump to content

This Combination Does Not Exist For This Product. Please Select Another Combination.


LazyCircles

Recommended Posts

Hello,

 

I need help solving a problem with my store. I've set a combination "Age" and I want it to define quantitys of that product combination.

The thing is that in product page only appears a message saying "This combination does not exist for this product. Please select another combination." with no buy button...

 

I've read throuh forums and nothing found :(

My problem is similiar to this one. I tried to do this but no success.

 

https://www.prestashop.com/forums/topic/414314-this-combination-does-not-exist-for-this-product-please-select-another-combination-please-help/

 

Thanks,

 

Beste regards

 

 

 

Link to comment
Share on other sites

  • 2 weeks later...

I had this same problem as well, but i think this might be specific to me only. Anyway, i share my solution:

 

Inside your theme folder, look for : js folder. Example:

 

prestashop_directory/themes/your_theme_folder/js/

 

Inside this folder, try to look a javascript file called : 'product.js' and open it with your text editor (e.g. Sublime Text).

Find the following line:

 

i.e. Hit CTRL + F and search for 'combinationsFromController'

function updatePrice()
{
// Get combination prices
var combID = $('#idCombination').val();
var combination = combinationsFromController[combID];


if (typeof combination == 'undefined')
return;

In my case, the reason that "Add to Cart" button is missing, because i had a javascript error that says : "variable combinationsFormController is not declared". REMEMBER, yours might be different.

 

Try to modify the above code so it looks like this:

function updatePrice()
{
// Get combination prices
var combID = $('#idCombination').val();
var combination = combinationsFromController[combID];
typeof combination = 'undefined';


if (typeof combination == 'undefined')
return;

Notice that i added a new line : 

typeof combination = 'undefined';

Remember:

  1. This is a temporary fix. Add that new only will always set the combination to 'undefined'. Meaning, your product combination will always fail to work. I don't mind with this, since my product does not required any combination.
  2. There is also a possibility when you update the qty (i.e. buy more than 1 products or increment the product), it will look as if nothing happen (no response). But actually the product gets added/incremented. 

The real solution would be to declare this var 'combinationsFromController'. However, i have no idea in which function or where should i declare that. Perhaps anyone knows ?

 

Hope this helps.

Link to comment
Share on other sites

I had this same problem as well, but i think this might be specific to me only. Anyway, i share my solution:

 

Inside your theme folder, look for : js folder. Example:

 

prestashop_directory/themes/your_theme_folder/js/

 

Inside this folder, try to look a javascript file called : 'product.js' and open it with your text editor (e.g. Sublime Text).

Find the following line:

 

i.e. Hit CTRL + F and search for 'combinationsFromController'

function updatePrice()
{
// Get combination prices
var combID = $('#idCombination').val();
var combination = combinationsFromController[combID];


if (typeof combination == 'undefined')
return;

In my case, the reason that "Add to Cart" button is missing, because i had a javascript error that says : "variable combinationsFormController is not declared". REMEMBER, yours might be different.

 

Try to modify the above code so it looks like this:

function updatePrice()
{
// Get combination prices
var combID = $('#idCombination').val();
var combination = combinationsFromController[combID];
typeof combination = 'undefined';


if (typeof combination == 'undefined')
return;

Notice that i added a new line : 

typeof combination = 'undefined';

Remember:

  1. This is a temporary fix. Add that new only will always set the combination to 'undefined'. Meaning, your product combination will always fail to work. I don't mind with this, since my product does not required any combination.
  2. There is also a possibility when you update the qty (i.e. buy more than 1 products or increment the product), it will look as if nothing happen (no response). But actually the product gets added/incremented. 

The real solution would be to declare this var 'combinationsFromController'. However, i have no idea in which function or where should i declare that. Perhaps anyone knows ?

 

Hope this helps.

Hello Sibrodo,

 

I managed to fixed it, it was a script introduced by my coworker, I just replaced with the original file and the combinations are working again. yei! :)

Thanks for share your solution!

 

Best regards,

Bruno

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...