diff options
Diffstat (limited to 'views')
| -rw-r--r-- | views/mods/mod_productvariants/admin_edit.phtml | 18 | ||||
| -rw-r--r-- | views/produkttemplates/standard2.phtml | 19 |
2 files changed, 34 insertions, 3 deletions
diff --git a/views/mods/mod_productvariants/admin_edit.phtml b/views/mods/mod_productvariants/admin_edit.phtml index 57d4f47..9bca475 100644 --- a/views/mods/mod_productvariants/admin_edit.phtml +++ b/views/mods/mod_productvariants/admin_edit.phtml @@ -303,7 +303,7 @@ });
</script>
-
+
<?php if (intval($this->view['product_id']) <= 0) { ?>
<span style="padding-left:15px;">
<span style="display:inline-block; margin-right:5px;"><?php echo __('Für alle Downloadplus Produkte:', 'wpsg'); ?></span>
@@ -316,6 +316,22 @@ </div>
<?php } ?>
+ <div style="margin-top:0.25rem;">
+ <span>EAN:
+ <span title="<?php echo __('EAN der Produktvariation', 'wpsg'); ?>" class="wpsg_editable" id="productvariation_ean_<?php echo $vari['id']; ?>"><?php echo $vari['ean']??''; ?></span>
+ </span>
+ <script>
+
+ jQuery('#productvariation_ean_<?php echo $vari['id']; ?>').wpsg_editable('<?php echo WPSG_URL_WP; ?>wp-admin/admin.php?page=wpsg-Admin&action=module&modul=wpsg_mod_productvariants&subaction=admin_inlineEdit&noheader=1', {
+ submitdata: {
+ field: 'ean',
+ field_id: '<?php echo $vari['id']; ?>'
+ }
+ });
+
+ </script>
+ </div>
+
<script>
function wpsg_mod_downloadplus_setProducts(vari_id, active) {
diff --git a/views/produkttemplates/standard2.phtml b/views/produkttemplates/standard2.phtml index 3318460..5658288 100644 --- a/views/produkttemplates/standard2.phtml +++ b/views/produkttemplates/standard2.phtml @@ -12,6 +12,14 @@ $oProduct = $this->view['oProduct'];
+ $var_info = [];
+
+ if ($this->callMod('wpsg_mod_productvariants', 'isVariantsProductKey', [$oProduct->getProductKey()])) {
+
+ $var_info = $this->callMod('wpsg_mod_productvariants', 'getVariantenInfoArray', [$oProduct->getProductKey()]);
+
+ }
+
?>
<div class="wpsg_produkt_wrapper wpsg_produkt_wrapper2">
@@ -22,8 +30,10 @@ <div class="wpsg_produkt wpsg_product_name">
<?php if (!$this->titleDisplayed) { ?>
- <h1 itemprop="name" class="wpsg_producttitle"><?php echo $this->getProductName($this->view['data']['id']); ?></h1>
- <h2 itemprop="detailname" class="wpsg_productdetailtitle"><?php echo $this->view['data']['detailname']; ?></h2>
+ <h1 class="wpsg_producttitle"><?php echo $this->getProductName($this->view['data']['id']); ?></h1>
+ <?php if ($this->getProductName($this->view['data']['id']) !== $this->view['data']['detailname']) { ?>
+ <h2 class="wpsg_productdetailtitle"><?php echo $this->view['data']['detailname']; ?></h2>
+ <?php } ?>
<?php } ?>
<?php $this->callMods('product_top_afterheadline', array(&$this->view['data']['id'], $this->getTemplateIndex())); ?>
@@ -34,6 +44,11 @@ <div itemscope itemtype="http://schema.org/Product" class="wpsg_produkt wpsg_produkt_<?php echo $this->view['data']['id']; ?>">
+ <meta itemprop="url" content="<?php echo $oProduct->getProductURL().'?test'; ?>" />
+ <meta itemprop="name" content="<?php echo wpsg_hspc($this->getProductName($this->view['data']['id'])); ?>" />
+ <meta itemprop="detailname" content="<?php echo wpsg_hspc($this->getProductName($this->view['data']['id']).' / '.rtrim(($var_info['key']??''), ' /')); ?>" />
+ <meta itemprop="sku" content="<?php echo wpsg_hspc($oProduct->getEAN()); ?>" />
+
<?php /* Block für die Produktbilder START */ ?>
<?php
|
