Does anyone have an idea how to fix it?Guys, do you get error after u delete the one of the product which are in combination ?
I have to edit one of the product in combination to working again.
Any solutions?
Invalid product vars
169. if (is_array($product) && isset($product['id_product'])) {
170. $params['id'] = $product['id_product'];
171. } elseif ((int) $product) {
172. $params['id'] = $product;
173. } else {
174. throw new PrestaShopException('Invalid product vars');
175. }
176. } else {
177. $params['id'] = $product->id;
178. }
179.
29. $_from = $_smarty_tpl->smarty->ext->_foreach->init($_smarty_tpl, $_smarty_tpl->tpl_vars['pc_combs']->value, 'comb');
30. $_smarty_tpl->tpl_vars['comb']->do_else = true;
31. if ($_from !== null) foreach ($_from as $_smarty_tpl->tpl_vars['comb']->value) {
32. $_smarty_tpl->tpl_vars['comb']->do_else = false;
33. ?>
34. <?php $_smarty_tpl->_assignInScope('productLink', $_smarty_tpl->tpl_vars['link']->value->getProductLink($_smarty_tpl->tpl_vars['comb']->value->id,$_smarty_tpl->tpl_vars['comb']->value->link_rewrite,null,null,null,null,$_smarty_tpl->tpl_vars['comb']->value->cache_default_attribute));?>
35. <a class="variant-url imgsel<?php echo htmlspecialchars($_smarty_tpl->tpl_vars['comb']->value->id, ENT_QUOTES, 'UTF-8');?>
36. <?php if ($_smarty_tpl->tpl_vars['comb']->value->id == $_smarty_tpl->tpl_vars['product']->value['id']) {?>selected<?php }?>"
37. href="<?php if ($_smarty_tpl->tpl_vars['comb']->value->id == $_smarty_tpl->tpl_vars['product']->value['id']) {?>#<?php } else {
38. echo htmlspecialchars($_smarty_tpl->tpl_vars['productLink']->value, ENT_QUOTES, 'UTF-8');
39. }?>">
118. if ($_template->startRenderCallbacks) {
119. foreach ($_template->startRenderCallbacks as $callback) {
120. call_user_func($callback, $_template);
121. }
122. }
123. $unifunc($_template);
124. foreach ($_template->endRenderCallbacks as $callback) {
125. call_user_func($callback, $_template);
126. }
127. $_template->isRenderingCache = false;
128. } catch (Exception $e) {
Gracias por compartir. Voy a probarlo a ver si es lo que esperaba. Gracias.Here's the latest version of this module (v1.1.0).
Link for purchase: https://addons.prestashop.com/en/co...on/41032-normal-products-as-combinations.html
Overview
This module allows to use normal products as combinations.
Instead of using attributes, you can link multiple normal products between them and they will appear in the product page as if they are combinations.
What this module does for you
- Promote your products
- Useful if you have only a few products to sell, but with many variants. It won't make your shop look empty.
- You will also have full control on texts displayed for each combinations, since they are different products with their own texts and meta tags. This is especially useful for SEO and avoid duplicate content.
- It's also useful if you want to show available accessories for your products.
Installation
- Download the zip file
- Install from the Backoffice
- Link your products from the module tab in your edit product page.
Post automatically merged:
I also made a nicer theme override as the default behaviour broke the image carousel... this one purely links to the products instead of updating the DOM with javascript (over-engineering for no reason in my opinion).
Just unzip and upload to the modules folder in your enabled theme folder.
Guys, do you get error after u delete the one of the product which are in combination ?
I have to edit one of the product in combination to working again.
Any solutions?
Post automatically merged:
Does anyone have an idea how to fix it?
View attachment 45575
Post automatically merged:
Invalid product vars
at line 174 in file classes/Link.php
Code:169. if (is_array($product) && isset($product['id_product'])) { 170. $params['id'] = $product['id_product']; 171. } elseif ((int) $product) { 172. $params['id'] = $product; 173. } else { 174. throw new PrestaShopException('Invalid product vars'); 175. } 176. } else { 177. $params['id'] = $product->id; 178. } 179.
LinkCore->getProductLink - [line 34 - var/cache/dev/smarty/compile/classic/5b/ab/84/5bab8483e3fba71abaa974445826996e7a9d4624_2.file.combinations.tpl.php] - [7 Arguments]
Code:29. $_from = $_smarty_tpl->smarty->ext->_foreach->init($_smarty_tpl, $_smarty_tpl->tpl_vars['pc_combs']->value, 'comb'); 30. $_smarty_tpl->tpl_vars['comb']->do_else = true; 31. if ($_from !== null) foreach ($_from as $_smarty_tpl->tpl_vars['comb']->value) { 32. $_smarty_tpl->tpl_vars['comb']->do_else = false; 33. ?> 34. <?php $_smarty_tpl->_assignInScope('productLink', $_smarty_tpl->tpl_vars['link']->value->getProductLink($_smarty_tpl->tpl_vars['comb']->value->id,$_smarty_tpl->tpl_vars['comb']->value->link_rewrite,null,null,null,null,$_smarty_tpl->tpl_vars['comb']->value->cache_default_attribute));?> 35. <a class="variant-url imgsel<?php echo htmlspecialchars($_smarty_tpl->tpl_vars['comb']->value->id, ENT_QUOTES, 'UTF-8');?> 36. <?php if ($_smarty_tpl->tpl_vars['comb']->value->id == $_smarty_tpl->tpl_vars['product']->value['id']) {?>selected<?php }?>" 37. href="<?php if ($_smarty_tpl->tpl_vars['comb']->value->id == $_smarty_tpl->tpl_vars['product']->value['id']) {?>#<?php } else { 38. echo htmlspecialchars($_smarty_tpl->tpl_vars['productLink']->value, ENT_QUOTES, 'UTF-8'); 39. }?>">
- content_6222b3f27a2ee5_06229859 - [line 123 - vendor/smarty/smarty/libs/sysplugins/smarty_template_resource_base.php] - [1 Arguments]
Code:118. if ($_template->startRenderCallbacks) { 119. foreach ($_template->startRenderCallbacks as $callback) { 120. call_user_func($callback, $_template); 121. } 122. } 123. $unifunc($_template); 124. foreach ($_template->endRenderCallbacks as $callback) { 125. call_user_func($callback, $_template); 126. } 127. $_template->isRenderingCache = false; 128. } catch (Exception $e) {
Post automatically merged:
Any solutions ?
Won't anyone help me? Please i need your help.Is there anyone to help me? I really need this module ..
BUMP! BUMP! BUMP!Won't anyone help me? Please i need your help.
Gracias por compartir. Lo probare a ver que tal va.Here's the latest version of this module (v1.1.0).
Link for purchase: https://addons.prestashop.com/en/co...on/41032-normal-products-as-combinations.html
Overview
This module allows to use normal products as combinations.
Instead of using attributes, you can link multiple normal products between them and they will appear in the product page as if they are combinations.
What this module does for you
- Promote your products
- Useful if you have only a few products to sell, but with many variants. It won't make your shop look empty.
- You will also have full control on texts displayed for each combinations, since they are different products with their own texts and meta tags. This is especially useful for SEO and avoid duplicate content.
- It's also useful if you want to show available accessories for your products.
Installation
- Download the zip file
- Install from the Backoffice
- Link your products from the module tab in your edit product page.
Post automatically merged:
I also made a nicer theme override as the default behaviour broke the image carousel... this one purely links to the products instead of updating the DOM with javascript (over-engineering for no reason in my opinion).
Just unzip and upload to the modules folder in your enabled theme folder.