diff options
| -rw-r--r-- | views/mods/mod_productvariants/admin_edit.phtml | 6 | ||||
| -rw-r--r-- | views/warenkorb/basket.phtml | 6 | ||||
| -rw-r--r-- | views/warenkorb/overview.phtml | 7 |
3 files changed, 15 insertions, 4 deletions
diff --git a/views/mods/mod_productvariants/admin_edit.phtml b/views/mods/mod_productvariants/admin_edit.phtml index f55bc9f..94a577d 100644 --- a/views/mods/mod_productvariants/admin_edit.phtml +++ b/views/mods/mod_productvariants/admin_edit.phtml @@ -185,7 +185,7 @@ $href = wp_get_attachment_image_src($b['post_id'], Array(25, 25));
?>
<a class="<?php echo ((in_array($file2, explode(",", $vari['pic'])))?'mark':''); ?> pic" id="<?php echo $file2; ?>"
- onclick="return wpsg_vp_vari_setPic(this, <?php echo $k; ?>, <?php echo $kv; ?>, '<?php echo $file2; ?>', <?php echo $j; ?>);">
+ onclick="return wpsg_vp_vari_setPic(this, <?php echo $k; ?>, <?php echo $kv; ?>, '<?php echo $file2; ?>', <?php echo $j; ?>, <?php echo $b['post_id']; ?>);">
<img src="<?php echo $href[0]; ?>" alt="" width="25px" height="25px"/>
</a>
<?php } ?>
@@ -243,7 +243,7 @@ <script type="text/javascript">/* <![CDATA[ */
- function wpsg_vp_vari_setPic(htmlElement, var_id, vari_id, pic, pic_index)
+ function wpsg_vp_vari_setPic(htmlElement, var_id, vari_id, pic, pic_index, post_id)
{
<?php if (!isset($_REQUEST['wpsg_lang'])) { ?>
@@ -259,6 +259,8 @@ var_id: var_id,
vari_id: vari_id,
iid: iid,
+ pic_index: pic_index,
+ post_id: post_id,
pic: pic
},
success: function(data) {
diff --git a/views/warenkorb/basket.phtml b/views/warenkorb/basket.phtml index 4c68672..1454e54 100644 --- a/views/warenkorb/basket.phtml +++ b/views/warenkorb/basket.phtml @@ -76,7 +76,11 @@ <?php if (wpsg_isSizedString($arBilder[0]['guid'])) { ?>
<?php
- $url = $this->callMod('wpsg_mod_produktbilder', 'getProductImage_MT', array($p['product_key'], 'medium'));
+ if (isset($p['product_key'])) {
+ $url = $this->callMod('wpsg_mod_produktbilder', 'getProductImage_MT', array($p['product_key'], 'medium'));
+ } else {
+ $url = $this->callMod('wpsg_mod_produktbilder', 'getProductImage_MT', array($p['productkey'], 'medium'));
+ }
echo "<img src=".$url." alt='' />";
?>
diff --git a/views/warenkorb/overview.phtml b/views/warenkorb/overview.phtml index 1433e94..4e11189 100644 --- a/views/warenkorb/overview.phtml +++ b/views/warenkorb/overview.phtml @@ -148,7 +148,12 @@ <?php if (wpsg_isSizedString($arBilder[0]['guid'])) { ?>
- <?php $img_url = $this->callMod('wpsg_mod_produktbilder', 'getProductImage_MT', array($p['product_key'], 'thumbnail')); ?>
+ <?php
+ if (isset($p['product_key'])) {
+ $img_url = $this->callMod('wpsg_mod_produktbilder', 'getProductImage_MT', array($p['product_key'], 'thumbnail'));
+ } else {
+ $img_url = $this->callMod('wpsg_mod_produktbilder', 'getProductImage_MT', array($p['productkey'], 'thumbnail'));
+ } ?>
<?php if ($img_url !== false) { ?>
<img class="theme_border_color_2 theme_color_2" src="<?php echo $img_url; ?>" alt="<?php echo wpsg_translate(__('Produktbilder von Produkte #1#', 'wspg'), $p['name']); ?>" />
<?php } ?>
|
