tonis Posted November 10, 2011 Share Posted November 10, 2011 Hello As the title says.... i have different combinations of products, for example jacket in color black, in sizes L, M, S and in white in size L. But, for the white combination it is displaing also the sizes M and S. In the configuration - "Display unavailable product attributes on product page" is set to "no". What is wrong please? Presta version 1.4.4.0 Link to comment Share on other sites More sharing options...
Mike Kranzler Posted November 10, 2011 Share Posted November 10, 2011 Hi tonis, Can you please PM me with your Back Office login credentials (username, password and admin URL) so that I can look into this for you? -Mike Link to comment Share on other sites More sharing options...
tonis Posted November 10, 2011 Author Share Posted November 10, 2011 ... here you can see it http://www.nasemuzst...?id_product=236 ... when you choose color combination (Farebná kombinácia) - white/black/blue (biela/cierna/modra) its only in size 11,5, but it also displays all other sizes for the other colors ... and the message to choose other variation. Link to comment Share on other sites More sharing options...
Mike Kranzler Posted November 10, 2011 Share Posted November 10, 2011 Hi tonis, It looks to me that the combinations were generated incorrectly in this situation. Our Combination Generator function is great if you have every product in the same colors and sizes, but otherwise it is important that you create each combination individually through the Combinations tab of the product in your catalog. I hope this helps. -Mike Link to comment Share on other sites More sharing options...
tonis Posted November 10, 2011 Author Share Posted November 10, 2011 Even when i create them manually, the problem remains. (i think that also in the example they were created manualy and not by the Generator) Link to comment Share on other sites More sharing options...
Mike Kranzler Posted November 10, 2011 Share Posted November 10, 2011 Hi tonis, In this situation, I would need to take a look at your Back Office in order to give any additional advice on how to fix this. -Mike Link to comment Share on other sites More sharing options...
Mike Kranzler Posted November 10, 2011 Share Posted November 10, 2011 Hi tonis, I took a look at this and did some research for you, and it appears that there is no current function to completely hide unavailable options from the dropdown menu, although it is not possible to purchase any unavailable combination. -Mike Link to comment Share on other sites More sharing options...
tonis Posted November 10, 2011 Author Share Posted November 10, 2011 Too bad , but thank you for your time. Link to comment Share on other sites More sharing options...
tomerg3 Posted January 12, 2012 Share Posted January 12, 2012 You can check out http://www.presto-changeo.com/en/attribute-modules/24-attribute-order.html and http://www.presto-changeo.com/en/attribute-modules/23-attribute-wizard.html Both have an option to hide or disable unavailable / out of stock attributes Link to comment Share on other sites More sharing options...
Aldeag Posted January 12, 2012 Share Posted January 12, 2012 Tomerg, don´t forget to mention Attributegrib, which I use and is great! Link to comment Share on other sites More sharing options...
tomerg3 Posted January 12, 2012 Share Posted January 12, 2012 I forgot it also has this feature, but it was worth it as I now know of another happy customer Link to comment Share on other sites More sharing options...
Aldeag Posted January 12, 2012 Share Posted January 12, 2012 Just have a look here, some sizes/colour are in stock, some don´t: http://aldeaglobaltarifa.com/tiendaweb/product.php?id_product=10 Link to comment Share on other sites More sharing options...
NithyaStephen Posted March 6, 2012 Share Posted March 6, 2012 n Link to comment Share on other sites More sharing options...
nightmagic Posted August 18, 2012 Share Posted August 18, 2012 I am having an issue with the message that pops up when a certain attribute is not available ... part of the message is duplicated and I would like to know where to go to change it ... here is what it currently looks like now if you select the size that has 0 Qty Availability: This product is no longer in stock with these options but is available with others with those attributes but is available with other I would simply like to end the statement as follows: Availability: This product is no longer in stock with these options but is available with others Link to comment Share on other sites More sharing options...
Caracal Posted September 4, 2012 Share Posted September 4, 2012 (edited) Hello, all. This is script hide unavailable product attributes: $(function(){ var groupIds=new Array(); $('select[id^="group_"]').each(function(){ groupIds.push(this.id); }); var allCombinations=new Array(); $.each(combinations,function(key,combination){ allCombinations.push(combination['idsAttributes']); }); $('select[id^="group_"]').change(function(){checkCombination()}); checkCombination(); function checkCombination() { $('select[id^="group_"] option').removeAttr('disabled'); $.each(groupIds,function(key,groupId){ var this_select=$('select[id='+groupId+']'); this_select.children('option').each(function(){ if(this_select.val()!=this.value){ var combination=new Array(); combination[key]=this.value; $.each(groupIds,function(key2,groupId2){ if(key!=key2){ combination[key2]=$('select[id='+groupId2+']').val(); } }); var position=-1; $.each(allCombinations,function(key1,theCombination){ if(position==-1){ position=key1; $.each(theCombination,function(key2,value){ if(combination[key2]!=value)position=-1; }); } }); if(position<0) { this_select.children('option[value='+this.value+']').attr('disabled','disabled'); } } }); }); } }); However, the option can not be hidden. But they can be disabled. Edited September 4, 2012 by Caracal (see edit history) 2 Link to comment Share on other sites More sharing options...
k-rum Posted September 6, 2012 Share Posted September 6, 2012 Hello, all. This is script hide unavailable product attributes: $(function(){ var groupIds=new Array(); $('select[id^="group_"]').each(function(){ groupIds.push(this.id); }); var allCombinations=new Array(); $.each(combinations,function(key,combination){ allCombinations.push(combination['idsAttributes']); }); $('select[id^="group_"]').change(function(){checkCombination()}); checkCombination(); function checkCombination() { $('select[id^="group_"] option').removeAttr('disabled'); $.each(groupIds,function(key,groupId){ var this_select=$('select[id='+groupId+']'); this_select.children('option').each(function(){ if(this_select.val()!=this.value){ var combination=new Array(); combination[key]=this.value; $.each(groupIds,function(key2,groupId2){ if(key!=key2){ combination[key2]=$('select[id='+groupId2+']').val(); } }); var position=-1; $.each(allCombinations,function(key1,theCombination){ if(position==-1){ position=key1; $.each(theCombination,function(key2,value){ if(combination[key2]!=value)position=-1; }); } }); if(position<0) { this_select.children('option[value='+this.value+']').attr('disabled','disabled'); } } }); }); } }); However, the option can not be hidden. But they can be disabled. Where to place this script? Link to comment Share on other sites More sharing options...
Caracal Posted September 7, 2012 Share Posted September 7, 2012 (edited) Where to place this script? between tags <head> and </head> in header.tpl <script type="text/javascript"> $(function(){ var groupIds=new Array(); $('select[id^="group_"]').each(function(){ groupIds.push(this.id); }); var allCombinations=new Array(); $.each(combinations,function(key,combination){ allCombinations.push(combination['idsAttributes']); }); $('select[id^="group_"]').change(function(){checkCombination()}); checkCombination(); function checkCombination() { $('select[id^="group_"] option').removeAttr('disabled'); $.each(groupIds,function(key,groupId){ var this_select=$('select[id='+groupId+']'); this_select.children('option').each(function(){ if(this_select.val()!=this.value){ var combination=new Array(); combination[key]=this.value; $.each(groupIds,function(key2,groupId2){ if(key!=key2){ combination[key2]=$('select[id='+groupId2+']').val(); } }); var position=-1; $.each(allCombinations,function(key1,theCombination){ if(position==-1){ position=key1; $.each(theCombination,function(key2,value){ if(combination[key2]!=value)position=-1; }); } }); if(position<0) { this_select.children('option[value='+this.value+']').attr('disabled','disabled'); } } }); }); } }); </script> However, this is not so important. Edited September 7, 2012 by Caracal (see edit history) Link to comment Share on other sites More sharing options...
dangee Posted June 17, 2013 Share Posted June 17, 2013 Hello, This is what I was looking for, but unfortunately it doesn't seems to work with PS1.5.x...it just hide all unselected combinations. Any help ? Link to comment Share on other sites More sharing options...
marcko Posted October 9, 2013 Share Posted October 9, 2013 between tags <head> and </head> in header.tpl <script type="text/javascript"> $(function(){ var groupIds=new Array(); $('select[id^="group_"]').each(function(){ groupIds.push(this.id); }); var allCombinations=new Array(); $.each(combinations,function(key,combination){ allCombinations.push(combination['idsAttributes']); }); $('select[id^="group_"]').change(function(){checkCombination()}); checkCombination(); function checkCombination() { $('select[id^="group_"] option').removeAttr('disabled'); $.each(groupIds,function(key,groupId){ var this_select=$('select[id='+groupId+']'); this_select.children('option').each(function(){ if(this_select.val()!=this.value){ var combination=new Array(); combination[key]=this.value; $.each(groupIds,function(key2,groupId2){ if(key!=key2){ combination[key2]=$('select[id='+groupId2+']').val(); } }); var position=-1; $.each(allCombinations,function(key1,theCombination){ if(position==-1){ position=key1; $.each(theCombination,function(key2,value){ if(combination[key2]!=value)position=-1; }); } }); if(position<0) { this_select.children('option[value='+this.value+']').attr('disabled','disabled'); } } }); }); } }); </script> However, this is not so important. hello! I put this code in the header.tpl and the result is a blank page. I tried both in PS 149 and 152. What am I doing wrong? It will be great to make this work. Link to comment Share on other sites More sharing options...
websprint Posted November 11, 2013 Share Posted November 11, 2013 hello! I put this code in the header.tpl and the result is a blank page. I tried both in PS 149 and 152. What am I doing wrong? It will be great to make this work. You must insert script into "literals": {literal} script text {/literal} . Working 100% Link to comment Share on other sites More sharing options...
Ether Création Posted February 21, 2014 Share Posted February 21, 2014 Hello,I think this module could answer your needs.http://addons.prestashop.com/fr/fonctionnalites-front-office-modules-prestashop/12352-affichage-des-declinaisons-avancee.htmlBest regards Link to comment Share on other sites More sharing options...
bulla101 Posted February 23, 2015 Share Posted February 23, 2015 between tags <head> and </head> in header.tpl <script type="text/javascript"> $(function(){ var groupIds=new Array(); $('select[id^="group_"]').each(function(){ groupIds.push(this.id); }); var allCombinations=new Array(); $.each(combinations,function(key,combination){ allCombinations.push(combination['idsAttributes']); }); $('select[id^="group_"]').change(function(){checkCombination()}); checkCombination(); function checkCombination() { $('select[id^="group_"] option').removeAttr('disabled'); $.each(groupIds,function(key,groupId){ var this_select=$('select[id='+groupId+']'); this_select.children('option').each(function(){ if(this_select.val()!=this.value){ var combination=new Array(); combination[key]=this.value; $.each(groupIds,function(key2,groupId2){ if(key!=key2){ combination[key2]=$('select[id='+groupId2+']').val(); } }); var position=-1; $.each(allCombinations,function(key1,theCombination){ if(position==-1){ position=key1; $.each(theCombination,function(key2,value){ if(combination[key2]!=value)position=-1; }); } }); if(position<0) { this_select.children('option[value='+this.value+']').attr('disabled','disabled'); } } }); }); } }); </script> However, this is not so important. Just trying to get this to work on PS 1.6 and having no luck. Does anyone know how to hide product attributes when they don't exist for a product? My store is still showing all possible attributes and when selecting one that isn't possible you get the annoying message "combination doesn't exist for this attribute"... Link to comment Share on other sites More sharing options...
dwojod Posted February 25, 2015 Share Posted February 25, 2015 it is posible to change code by caracal ? i mean change field select for radio ? Link to comment Share on other sites More sharing options...
Recommended Posts