summaryrefslogtreecommitdiff
path: root/views
diff options
context:
space:
mode:
authorhartmut <noreply@maennchen1.de>2017-03-08 07:34:56 +0000
committerhartmut <noreply@maennchen1.de>2017-03-08 07:34:56 +0000
commitbd56b6eb31cc1625d830dda84c8d2e28ff5c4ebd (patch)
treed5efff789793e81e97b81c505cd32e9f4823e56e /views
parent4088aa3cabf3ccf35389576282dcb349bcc5d2ea (diff)
Adressteilung und Produktbilder mit Mediathek
git-svn-id: https://[internal]/wordpress/plugins/wpsg4@6094 0d5edaf7-2b12-4e95-93f4-047927463d4b
Diffstat (limited to 'views')
-rw-r--r--views/mods/mod_kundenverwaltung/index.phtml4
-rw-r--r--views/mods/mod_productvariants/admin_edit.phtml91
-rw-r--r--views/mods/mod_produktbilder/produkt_addedit_content.phtml213
-rw-r--r--views/mods/mod_produktbilder/produkt_edit_list_MT.phtml27
-rw-r--r--views/mods/mod_shippingadress/wpsg_order_view_customerdata.phtml2
-rw-r--r--views/order/view_customerdata.phtml2
-rw-r--r--views/produkttemplates/standard_mt.phtml341
7 files changed, 554 insertions, 126 deletions
diff --git a/views/mods/mod_kundenverwaltung/index.phtml b/views/mods/mod_kundenverwaltung/index.phtml
index 49d06d7..b54e340 100644
--- a/views/mods/mod_kundenverwaltung/index.phtml
+++ b/views/mods/mod_kundenverwaltung/index.phtml
@@ -16,7 +16,7 @@
<div class="collapse navbar-collapse" id="bs-customer-navbar-collapse-1">
<ul class="nav navbar-nav">
<li role="presentation" class="wpsg-customer-tab-a active"><a href="#" onclick="return false;"><?php echo __("Kundenverwaltung", "wpsg"); ?></a></li>
- <li role="presentation" class="wpsg-customer-tab-a wpsg_showhide_filter <?php echo (($this->view['hasFilter'])?'active':''); ?>" id="wpsg-customer-tab-0"><a href="#" onclick="return false;"><span class="glyphicon glyphicon-search"></span><?php echo __("Suche", "wpsg"); ?></a></li>
+ <li role="presentation" class="wpsg-customer-tab-a wpsg_showhide_filter <?php echo ((wpsg_isTrue($this->view['hasFilter']))?'active':''); ?>" id="wpsg-customer-tab-0"><a href="#" onclick="return false;"><span class="glyphicon glyphicon-search"></span><?php echo __("Suche", "wpsg"); ?></a></li>
<li role="presentation" class="<?php echo ((wpsg_isSizedString($_REQUEST['action'], 'add'))?'active':''); ?>"><a href="<?php echo WPSG_URL_WP; ?>wp-admin/admin.php?page=wpsg-Customer&action=add"><span class="glyphicon glyphicon-plus"></span><?php echo __("Hinzufügen", "wpsg"); ?></a></li>
</ul>
<ul class="nav navbar-nav navbar-right">
@@ -28,7 +28,7 @@
</div>
</div>
- <div class="wpsg-filter wpsg-customer-tab wpsg-customer-tab-0 container-fluid form-horizontal" style="display:<?php echo (($this->view['hasFilter'] === true)?'block':'none'); ?>;">
+ <div class="wpsg-filter wpsg-customer-tab wpsg-customer-tab-0 container-fluid form-horizontal" style="display:<?php echo ((wpsg_isTrue($this->view['hasFilter']))?'block':'none'); ?>;">
<div class="row">
<div class="col-lg-4">
<form method="post" id="filter_form">
diff --git a/views/mods/mod_productvariants/admin_edit.phtml b/views/mods/mod_productvariants/admin_edit.phtml
index 11a8825..4a1f691 100644
--- a/views/mods/mod_productvariants/admin_edit.phtml
+++ b/views/mods/mod_productvariants/admin_edit.phtml
@@ -132,6 +132,24 @@
<td class="col_id">&nbsp;</td>
<td class="col_image" colspan="<?php echo $colspan; ?>">
TODO: Bilder
+ <?php
+ $pbArr = $this->callMod('wpsg_mod_produktbilder', 'getProduktBilder_MT', array($this->view['product_id']));
+ $k = $this->view['variant']['id'];
+ $kv = $vari['id'];
+ $temp = $this->callMod('wpsg_mod_productvariants', 'getVariImages', array($this->view['product_id'], $k, $kv));
+ ?>
+ <?php $j = 0; foreach ($pbArr as $b) { $j ++; ?>
+ <?php // $this->view['variant']['id'] $vari $var $kv $_REQUEST['pic']
+ $file = $b['basename'];
+ $href = wp_get_attachment_image_src($b['post_id'], Array(25, 25));
+ ?>
+ <a class="<?php //echo ((in_array($file, explode(",", $vari['pic'])))?'mark':''); ?> pic" id="<?php echo $file; ?>"
+ onclick="return wpsg_vp_vari_setPic(this, <?php echo $k; ?>, <?php echo $kv; ?>, '<?php echo $file; ?>', <?php echo $j; ?>);" href="">
+ <img src="<?php echo $href[0]; ?>" alt="" width="25px" height="25px"/>
+ </a>
+ <?php } ?>
+
+
</td>
</tr>
@@ -142,6 +160,79 @@
<script type="text/javascript">/* <![CDATA[ */
+ function wpsg_vp_vari_setPic(htmlElement, var_id, vari_id, pic, pic_index)
+ {
+
+ <?php if (!isset($_REQUEST['wpsg_lang'])) { ?>
+
+ wpsg_vp_ajaxloading_show();
+
+ jQuery.ajax( {
+ url: "<?php echo WPSG_URL_WP; ?>wp-admin/admin.php?page=wpsg-Produkt&action=ajax&mod=wpsg_mod_productvariants&cmd=wpsg_vp_vari_setPic&noheader=1&edit_id=<?php echo $this->view['product_id']; ?>",
+ async: false,
+ data: {
+ var_id: var_id,
+ vari_id: vari_id,
+ pic: pic
+ },
+ success: function(data) {
+ if (vari_id >= 0)
+ {
+
+ if (jQuery(htmlElement).hasClass('mark'))
+ {
+ jQuery(htmlElement).removeClass('mark');
+ }
+ else
+ {
+ jQuery(htmlElement).addClass('mark');
+ }
+
+ }
+ else
+ {
+
+ if (jQuery(htmlElement).hasClass('mark'))
+ {
+ jQuery(htmlElement).removeClass('mark');
+ }
+ else
+ {
+ jQuery(htmlElement).addClass('mark');
+ }
+
+ }
+
+ wpsg_vp_ajaxloading_hide();
+
+ }
+ } );
+
+ <?php } ?>
+
+ return false;
+
+ }
+
+ function wpsg_vp_ajaxloading_show()
+ {
+
+ jQuery('.wpsg_mod_varianten_ajaxloading').show();
+
+ }
+
+ function wpsg_vp_ajaxloading_hide()
+ {
+
+ jQuery('.wpsg_mod_varianten_ajaxloading').hide();
+
+ }
+
+
+ <?php
+ $p1 = wpsg_getInt($this->view['product_id']);
+ $p2 = ($this->view['variant']['product_id']);
+ ?>
<?php if (!wpsg_isSizedInt($this->view['product_id']) || wpsg_isSizedInt($this->view['variant']['product_id'])) { ?>
jQuery('.wpsg_mod_productvariants_table_variation').sortable( {
diff --git a/views/mods/mod_produktbilder/produkt_addedit_content.phtml b/views/mods/mod_produktbilder/produkt_addedit_content.phtml
index bc4cabd..a23ab69 100644
--- a/views/mods/mod_produktbilder/produkt_addedit_content.phtml
+++ b/views/mods/mod_produktbilder/produkt_addedit_content.phtml
@@ -7,7 +7,7 @@
?>
-<!-- Modal für FTP Pfad anzeige -->
+<!-- Modal für FTP Pfad Anzeige -->
<div class="modal fade" id="wpsg_mod_produktbilder_ftppath" tabindex="-1" role="dialog">
<div class="modal-dialog" role="document">
<div class="modal-content">
@@ -25,6 +25,7 @@
</div>
</div>
+<!-- Modal für Löschabfrage -->
<div class="modal fade" tabindex="-1" role="dialog" id="wpsg_produktbilder_remove">
<div class="modal-dialog" role="document">
<div class="modal-content">
@@ -40,7 +41,7 @@
</div>
<div class="modal-footer">
<button type="button" class="btn btn-default" data-dismiss="modal"><?php echo __('Abbrechen', 'wpsg'); ?></button>
- <button type="button" class="btn btn-primary" onclick="return wpsg_remove_bild2OK();"><?php echo __('Löschen', 'wpsg'); ?></button>
+ <button type="button" class="btn btn-primary" onclick="return wpsg_remove_bild_MT_OK();"><?php echo __('Löschen', 'wpsg'); ?></button>
</div>
</div>
</div>
@@ -55,8 +56,6 @@
<?php if ($this->view['data']['id'] > 0) { ?>
- <div id="produktbilder_target"><?php echo $this->view['ProduktList']; ?></div>
-
<?php if (get_option("wpsg_classicupload") == "1") { ?>
<div class="wpsg_clear"></div><br />
@@ -66,125 +65,27 @@
<input type="file" multiple="multiple" name="wpsg_mod_produktbilder_file[]" />
<?php } else { ?>
-
- <div class="wpsg_clear"></div><br />
- <div><?php echo __("Bitte klicken Sie auf Upload um ein Bild hochzuladen. Um ein Bild zu löschen klicken Sie einfach auf das Bild.", "wpsg"); ?></div>
- <div class="wpsg_clear"></div><br />
-
- <input value="Upload" type="text" style="text-align:center;" size="10" id="upload_button" />
-
- <script type="text/javascript">/* <![CDATA[ */
-
- jQuery(document).ready(function() {
- new AjaxUpload(
- "upload_button", {
- action: "<?php echo WPSG_URL_WP; ?>wp-admin/admin.php?page=wpsg-Produkt&action=ajax&mod=wpsg_mod_produktbilder&cmd=upload&edit_id=<?php echo $this->view['data']['id']; ?>&noheader=1",
- onSubmit: function(file, extension) {
- jQuery('#produktbilder_target').html('<img src="<?php echo WPSG_URL; ?>views/gfx/ajax-loader.gif" alt="<?php echo __('Bitte warten ...', 'wpsg'); ?>" />');
-
- },
- onComplete: function(file, response) {
+ <!-- Mediathek -->
- if (response == '1')
- {
-
- jQuery("#produktbilder_target").load("<?php echo WPSG_URL_WP; ?>wp-admin/admin.php?page=wpsg-Produkt&action=ajax&mod=wpsg_mod_produktbilder&cmd=produktbilder_liste&edit_id=<?php echo $this->view['data']['id']; ?>&noheader=1");
+ <div id="produktbilder_target_MT"><?php echo $this->view['ProduktList_MT']; ?></div>
- if (typeof wpsg_vp_refresh == "function") wpsg_vp_refresh();
-
- }
- else
- {
- alert(response);
- }
-
- }
- }
- );
- });
-
- /* ]]> */</script>
-
- <?php } ?>
-
- <script type="text/javascript">/* <![CDATA[ */
-
- /**
- * Löscht den Bildercache dieses Produktes
- */
- function wpsg_clearImageCache()
- {
-
- jQuery.ajax( {
- url: '<?php echo WPSG_URL_WP; ?>wp-admin/admin.php?page=wpsg-Produkt&action=ajax&mod=wpsg_mod_produktbilder&cmd=clearProductCache&noheader=1&edit_id=<?php echo $this->view['data']['id']; ?>',
- async: true,
- success: function(data) { alert(data); }
- } );
-
- return false;
-
- } // function wpsg_clearImageCache()
-
- /**
- * Wird beim löschen eines Bilds (anklicken) aufgerufen
- */
- function wpsg_remove_bild(strBild)
- {
-
- if (!confirm('<?php echo __('Sind Sie sicher, das Sie dieses Bild löschen möchten?', 'wpsg'); ?>')) return false;
-
- jQuery('#produktbilder_target').html('<img src="<?php echo WPSG_URL; ?>views/gfx/ajax-loader.gif" alt="<?php echo __('Bitte warten ...', 'wpsg'); ?>" />');
-
- jQuery.ajax( {
- url: '<?php echo WPSG_URL_WP; ?>wp-admin/admin.php?page=wpsg-Produkt&action=ajax&mod=wpsg_mod_produktbilder&cmd=remove&noheader=1&edit_id=<?php echo $this->view['data']['id']; ?>',
- async: true,
- data: {
- file: strBild
- },
- success: function(data) {
-
- jQuery('#produktbilder_target').html(data);
-
- if (typeof wpsg_vp_refresh == "function") wpsg_vp_refresh();
-
- }
- } );
-
- return false;
-
- }
-
- /* ]]> */</script>
-
- <?php } else { ?>
- <p><?php echo __('Das Hochladen von Produktbildern ist erst nach erstmaligem speichern möglich.', 'wpsg'); ?></p>
- <?php } ?>
-
- <div class="wpsg_clear"></div><br />
-
- <?php if (wpsg_isSizedInt($this->view['data']['id'])) { ?>
- <a href="#" data-toggle="modal" data-target="#wpsg_mod_produktbilder_ftppath"><span class="wpsg-glyphicon glyphicon glyphicon-folder-open"></span><?php echo __('FTP Pfad anzeigen', 'wpsg'); ?></a><br />
- <a href="#" onclick="return wpsg_clearImageCache();"><span class="wpsg-glyphicon glyphicon glyphicon-trash"></span><?php echo __('Bildercache dieses Produktes löschen', 'wpsg'); ?></a><br />
- <?php } ?>
-
- <a href="<?php echo WPSG_URL_WP; ?>wp-admin/admin.php?page=wpsg-Admin&action=module&modul=wpsg_mod_produktbilder"><span class="wpsg-glyphicon glyphicon glyphicon-wrench"></span><?php echo __('Zur Konfiguration der Produktbilder', 'wpsg'); ?></a>
+ <div class="wpsg_clear"></div>
+ <div><?php echo __("Bitte klicken Sie auf Mediathek um ein Bild hochzuladen. Um ein Bild zu löschen klicken Sie einfach auf das Bild.", "wpsg"); ?></div>
+ <div class="wpsg_clear"></div><br />
- <!-- Mediathek -->
- <hr>
- <div id="produktbilder_target2"><?php echo $this->view['ProduktList2']; ?></div>
-
- <input value="WPmedia" class="button" type="text" style="text-align:center;" size="10" id="btnAddImgLink" />
- <input value="Upload2" class="button" type="text" style="text-align:center;" size="10" id="upload_button2" />
+ <input value="Mediathek" class="button" type="text" style="text-align:center;" size="10" id="btnAddImgLink" />
+ <!-- <input value="UploadMT" class="button" type="text" style="text-align:center;" size="10" id="upload_button_mt" /> -->
<script type="text/javascript">/* <![CDATA[ */
+ /*
jQuery(document).ready(function() {
new AjaxUpload(
- "upload_button2", {
- action: "<?php echo WPSG_URL_WP; ?>wp-admin/admin.php?page=wpsg-Produkt&action=ajax&mod=wpsg_mod_produktbilder&cmd=upload2&edit_id=<?php echo $this->view['data']['id']; ?>&noheader=1",
+ "upload_button_mt", {
+ action: "<?php echo WPSG_URL_WP; ?>wp-admin/admin.php?page=wpsg-Produkt&action=ajax&mod=wpsg_mod_produktbilder&cmd=upload_mt&edit_id=<?php echo $this->view['data']['id']; ?>&noheader=1",
onSubmit: function(file, extension) {
- jQuery('#produktbilder_target2').html('<img src="<?php echo WPSG_URL; ?>views/gfx/ajax-loader.gif" alt="<?php echo __('Bitte warten ...', 'wpsg'); ?>" />');
+ jQuery('#produktbilder_target_MT').html('<img src="<?php echo WPSG_URL; ?>views/gfx/ajax-loader.gif" alt="<?php echo __('Bitte warten ...', 'wpsg'); ?>" />');
},
onComplete: function(file, response) {
@@ -193,9 +94,9 @@
if (response == '1')
{
- jQuery("#produktbilder_target2").load("<?php echo WPSG_URL_WP; ?>wp-admin/admin.php?page=wpsg-Produkt&action=ajax&mod=wpsg_mod_produktbilder&cmd=produktbilder_liste2&edit_id=<?php echo $this->view['data']['id']; ?>&noheader=1");
+ jQuery("#produktbilder_target_MT").load("<?php echo WPSG_URL_WP; ?>wp-admin/admin.php?page=wpsg-Produkt&action=ajax&mod=wpsg_mod_produktbilder&cmd=produktbilder_liste_MT&edit_id=<?php echo $this->view['data']['id']; ?>&noheader=1");
- //jQuery('#produktbilder_target2').html(data);
+ //jQuery('#produktbilder_target_MT').html(data);
//if (typeof wpsg_vp_refresh == "function") wpsg_vp_refresh();
}
@@ -208,12 +109,14 @@
}
);
});
-
+ */
+
var post_id;
+
/**
* Wird beim löschen eines Bilds (anklicken) aufgerufen
*/
- function wpsg_remove_bild2(pid) {
+ function wpsg_remove_bild_MT(pid) {
post_id = pid;
//jQuery('#wpsg_produktbilder_remove').show();
@@ -222,17 +125,17 @@
}
- function wpsg_remove_bild2OK() {
+ function wpsg_remove_bild_MT_OK() {
delmt = jQuery('#dialog_produktbilder_delmt').is(':checked');
del = jQuery('#dialog_produktbilder_del').is(':checked');
jQuery('#wpsg_produktbilder_remove').modal('hide');
- jQuery('#produktbilder_target2').html('<img src="<?php echo WPSG_URL; ?>views/gfx/ajax-loader.gif" alt="<?php echo __('Bitte warten ...', 'wpsg'); ?>" />');
+ jQuery('#produktbilder_target_MT').html('<img src="<?php echo WPSG_URL; ?>views/gfx/ajax-loader.gif" alt="<?php echo __('Bitte warten ...', 'wpsg'); ?>" />');
jQuery.ajax( {
- url: '<?php echo WPSG_URL_WP; ?>wp-admin/admin.php?page=wpsg-Produkt&action=ajax&mod=wpsg_mod_produktbilder&cmd=remove2&noheader=1&edit_id=<?php echo $this->view['data']['id']; ?>',
+ url: '<?php echo WPSG_URL_WP; ?>wp-admin/admin.php?page=wpsg-Produkt&action=ajax&mod=wpsg_mod_produktbilder&cmd=removemt&noheader=1&edit_id=<?php echo $this->view['data']['id']; ?>',
async: true,
data: {
del: del,
@@ -241,7 +144,7 @@
},
success: function(data) {
- jQuery('#produktbilder_target2').html(data);
+ jQuery('#produktbilder_target_MT').html(data);
//if (typeof wpsg_vp_refresh == "function") wpsg_vp_refresh();
@@ -307,7 +210,7 @@
},
success: function(data) {
- jQuery('#produktbilder_target2').html(data);
+ jQuery('#produktbilder_target_MT').html(data);
}
} );
@@ -336,6 +239,72 @@
});
/* ]]> */</script>
+
+
+ <?php } ?>
+
+ <script type="text/javascript">/* <![CDATA[ */
+
+ /**
+ * Löscht den Bildercache dieses Produktes
+ */
+ function wpsg_clearImageCache()
+ {
+
+ jQuery.ajax( {
+ url: '<?php echo WPSG_URL_WP; ?>wp-admin/admin.php?page=wpsg-Produkt&action=ajax&mod=wpsg_mod_produktbilder&cmd=clearProductCache&noheader=1&edit_id=<?php echo $this->view['data']['id']; ?>',
+ async: true,
+ success: function(data) { alert(data); }
+ } );
+
+ return false;
+
+ } // function wpsg_clearImageCache()
+
+ /**
+ * Wird beim löschen eines Bilds (anklicken) aufgerufen
+ */
+ function wpsg_remove_bild(strBild)
+ {
+
+ if (!confirm('<?php echo __('Sind Sie sicher, das Sie dieses Bild löschen möchten?', 'wpsg'); ?>')) return false;
+
+ jQuery('#produktbilder_target').html('<img src="<?php echo WPSG_URL; ?>views/gfx/ajax-loader.gif" alt="<?php echo __('Bitte warten ...', 'wpsg'); ?>" />');
+
+ jQuery.ajax( {
+ url: '<?php echo WPSG_URL_WP; ?>wp-admin/admin.php?page=wpsg-Produkt&action=ajax&mod=wpsg_mod_produktbilder&cmd=remove&noheader=1&edit_id=<?php echo $this->view['data']['id']; ?>',
+ async: true,
+ data: {
+ file: strBild
+ },
+ success: function(data) {
+
+ jQuery('#produktbilder_target').html(data);
+
+ if (typeof wpsg_vp_refresh == "function") wpsg_vp_refresh();
+
+ }
+ } );
+
+ return false;
+
+ }
+
+ /* ]]> */</script>
+
+ <?php } else { ?>
+ <p><?php echo __('Das Hochladen von Produktbildern ist erst nach erstmaligem speichern möglich.', 'wpsg'); ?></p>
+ <?php } ?>
+
+ <div class="wpsg_clear"></div><br />
+
+ <?php if (false && wpsg_isSizedInt($this->view['data']['id'])) { ?>
+ <a href="#" data-toggle="modal" data-target="#wpsg_mod_produktbilder_ftppath"><span class="wpsg-glyphicon glyphicon glyphicon-folder-open"></span><?php echo __('FTP Pfad anzeigen', 'wpsg'); ?></a><br />
+ <a href="#" onclick="return wpsg_clearImageCache();"><span class="wpsg-glyphicon glyphicon glyphicon-trash"></span><?php echo __('Bildercache dieses Produktes löschen', 'wpsg'); ?></a><br />
+ <?php } ?>
+
+ <a href="<?php echo WPSG_URL_WP; ?>wp-admin/admin.php?page=wpsg-Admin&action=module&modul=wpsg_mod_produktbilder"><span class="wpsg-glyphicon glyphicon glyphicon-wrench"></span><?php echo __('Zur Konfiguration der Produktbilder', 'wpsg'); ?></a>
+
</div>
</div> \ No newline at end of file
diff --git a/views/mods/mod_produktbilder/produkt_edit_list_MT.phtml b/views/mods/mod_produktbilder/produkt_edit_list_MT.phtml
new file mode 100644
index 0000000..b7e701b
--- /dev/null
+++ b/views/mods/mod_produktbilder/produkt_edit_list_MT.phtml
@@ -0,0 +1,27 @@
+<?php
+
+ /**
+ * Template für die Liste der Bilder eines Produkts
+ */
+
+?>
+
+ <?php if (isset($this->view['ProduktBilder_MT']) && (sizeof($this->view['ProduktBilder_MT']) > 0)) { ?>
+
+ <?php foreach ($this->view['ProduktBilder_MT'] as $b) { ?>
+
+ <div class="wpsg_mod_produktbilder_admin_bild">
+
+ <a onclick="return wpsg_remove_bild_MT('<?php echo $b['pid']; ?>');" href="#" title="<?php echo __('Dieses Bild löschen.', 'wpsg'); ?>">
+ <img src="<?php echo $b['guid']; ?>" alt="<?php echo wpsg_hspc($b['fname']); ?>" />
+ <span><span class="glyphicon glyphicon-trash"></span></span>
+ </a>
+
+ </div>
+
+ <?php } ?>
+ <div class="wpsg_clear"></div>
+
+ <?php } else { ?>
+ <p><?php echo __('Bisher keine Produktbilder hochgeladen.', 'wpsg'); ?></p>
+ <?php } ?> \ No newline at end of file
diff --git a/views/mods/mod_shippingadress/wpsg_order_view_customerdata.phtml b/views/mods/mod_shippingadress/wpsg_order_view_customerdata.phtml
index d27f09a..c091272 100644
--- a/views/mods/mod_shippingadress/wpsg_order_view_customerdata.phtml
+++ b/views/mods/mod_shippingadress/wpsg_order_view_customerdata.phtml
@@ -68,7 +68,7 @@
<?php
if (wpsg_isSizedString($this->view['wpsg_mod_shippingadress']['shipping_title']) && $this->view['wpsg_mod_shippingadress']['shipping_title'] != '-1')
- echo $this->view['arTitles'][$this->view['wpsg_mod_shippingadress']['shipping_title']];
+ echo $this->view['wpsg_mod_shippingadress']['shipping_title'];
?> <?php echo wpsg_hspc($this->view['wpsg_mod_shippingadress']['shipping_vname']); ?> <?php echo wpsg_hspc($this->view['wpsg_mod_shippingadress']['shipping_name']); ?><br />
<?php echo wpsg_hspc($this->view['wpsg_mod_shippingadress']['shipping_strasse']); ?><br />
diff --git a/views/order/view_customerdata.phtml b/views/order/view_customerdata.phtml
index 317339e..24faf4b 100644
--- a/views/order/view_customerdata.phtml
+++ b/views/order/view_customerdata.phtml
@@ -57,7 +57,7 @@
<?php if (trim($this->view['data']['firma']) != '') { ?>
<?php echo wpsg_hspc($this->view['data']['firma']); ?><br />
<?php } ?>
- <?php echo (($this->view['data']['title'] != '' && $this->view['data']['title'] != '-1')?wpsg_hspc($this->view['arTitles'][$this->view['data']['title']]).' ':''); ?><?php echo wpsg_hspc($this->view['data']['vname']); ?> <?php echo wpsg_hspc($this->view['data']['name']); ?><br />
+ <?php echo (($this->view['data']['title'] != '' && $this->view['data']['title'] != '-1')?wpsg_hspc($this->view['data']['title']).' ':''); ?><?php echo wpsg_hspc($this->view['data']['vname']); ?> <?php echo wpsg_hspc($this->view['data']['name']); ?><br />
<?php echo wpsg_hspc($this->view['data']['strasse']); ?><br />
<?php echo wpsg_hspc($this->view['data']['plz']); ?> <?php echo wpsg_hspc($this->view['data']['ort']); ?> <?php echo wpsg_hspc($this->view['country']['kuerzel']); ?><br />
diff --git a/views/produkttemplates/standard_mt.phtml b/views/produkttemplates/standard_mt.phtml
new file mode 100644
index 0000000..d310391
--- /dev/null
+++ b/views/produkttemplates/standard_mt.phtml
@@ -0,0 +1,341 @@
+<?php
+
+ /*
+ * Template für das Produkt im Frontend
+ */
+
+ //Ausgabe der verfügbaren Variablen
+ //wpsg_debug($this->view['data']);
+
+ // Damit keine Zubehörprodukte ausgegeben werden
+ //$this->noReleatedProducts = true;
+
+ //wpsg_debug($_SESSION);
+
+if (!function_exists('is_plugin_active'))
+ require_once(ABSPATH.'/wp-admin/includes/plugin.php');
+?>
+<div class="container container-fluid-page">
+
+ <div class="wpsg_produkt_wrapper">
+
+ <input type="hidden" name="wpsg_post_id" value="<?php echo get_the_ID(); ?>" />
+
+ <?php $this->callMods('product_top', array(&$this->view['data']['id'], $this->getTemplateIndex())); ?>
+
+ <div itemscope itemtype="http://schema.org/Product" class="wpsg_produkt wpsg_produkt_<?php echo $this->view['data']['id']; ?>">
+
+ <div class="wpsg_product_mod_information_left">
+ <div class="wpsg_product_afterimage">
+ <?php /* Block für die Produktbilder START */ ?>
+ <?php if ($this->hasMod('wpsg_mod_produktbilder')) { ?>
+ <div class="wpsg_produkt_produktbilder">
+ <?php
+ $pbw = $this->get_option('wpsg_mod_produktbilder_width');
+ $pbh = $this->get_option('wpsg_mod_produktbilder_height');
+ $pbm = $this->get_option('wpsg_mod_produktbilder_mode');
+ $pbArr = $this->callMod('wpsg_mod_produktbilder', 'getProduktBilder2', array($this->view['data']['id']));
+ ?>
+ <?php if (sizeof($pbArr)) { ?>
+ <?php $i = 0; foreach ($pbArr as $b) { $i ++; ?>
+ <?php if ($i == 1 && !wpsg_isSizedString($this->view['data']['varianten_image']) || $b['basename'] == $this->view['data']['varianten_image']) { ?>
+ <div class="wpsg_produkt_preview wpsg_pb_pic">
+ <?php
+ $href = wp_get_attachment_image_src($b['post_id'], Array(800, 600));
+ $imgtag = wp_get_attachment_image($b['post_id'], Array($pbw, $pbh));
+ ?>
+ <a class="wpsg_imagelink thickbox" rel="<?php echo $this->view['product_index']; ?>-<?php echo $this->view['data']['id']; ?>"
+ href="<?php echo $href[0]; ?>"> <?php echo $imgtag; ?>
+ </a>
+ </div>
+ <?php } else { ?>
+ <div class="wpsg_pb_pic" style="display:none;">
+ <?php
+ $href = wp_get_attachment_image_src($b['post_id'], Array(800, 600));
+ $imgtag = wp_get_attachment_image($b['post_id'], Array($pbw, $pbh));
+ ?>
+ <a class="wpsg_imagelink thickbox" rel="<?php echo $this->view['product_index']; ?>-<?php echo $this->view['data']['id']; ?>" href="<?php echo $href[0]; ?>">
+ <?php echo $imgtag; ?>
+ </a>
+ </div>
+ <?php } ?>
+ <?php } ?>
+ <?php } ?>
+ <div class="wpsg_clear"></div>
+ </div>
+ <?php } ?>
+ <?php /* Block für die Produktbilder ENDE */ ?>
+ </div>
+ </div>
+
+ <div class="wpsg_product_mod_information_right">
+ <?php /* Block für Produktbeschreibung START */ ?>
+ <div class="wpsg_produkt wpsg_product_name">
+ <h1 itemprop="name" class="wpsg_producttitle"><?php echo $this->getProductName($this->view['data']['id']); ?></h1>
+ <?php $this->callMods('product_top_afterheadline', array(&$this->view['data']['id'], $this->getTemplateIndex())); ?>
+ </div>
+ <br/>
+ <?php if ($this->get_option('wpsg_showArticelnumber') == '1') { ?>
+ <div class="wpsg_artikelnummer">
+ <?php echo __('Artikelnummer', 'wpsg'); ?>: <span class="wpsg_anr"><?php echo wpsg_hspc($this->view['data']['anr']); ?></span><br />
+ <?php if (wpsg_isSizedInt($this->get_option('wpsg_mod_produktartikel_ean'))) {?>
+ <?php echo __('EAN','wpsg');?>:<span class="wpsg_ean"><?php echo wpsg_hspc($this->view['data']['ean']); ?></span><br />
+ <?php } ?>
+ <?php if (wpsg_isSizedInt($this->get_option('wpsg_mod_produktartikel_gtin'))) {?>
+ <?php echo __('GTIN','wpsg');?>:<span class="wpsg_gtin"><?php echo wpsg_hspc($this->view['data']['gtin']); ?></span><br />
+ <?php }?></div>
+ <?php } ?>
+
+ <?php /* Abfrage Preisanzeige nur für eingeloggte User aktiv und User eingeloggt START*/ ?>
+ <?php if (($this->callMod('wpsg_mod_kundenverwaltung', 'isLoggedIn') && ($this->get_option('wpsg_mod_kundenverwaltung_preisAnzeige') == '1')) || ($this->get_option('wpsg_mod_kundenverwaltung_preisAnzeige') == '0')) { ?>
+
+ <div itemprop="offers" itemscope itemtype="http://schema.org/Offer" class="wpsg_produkt_preis">
+ <label><?php echo __('Stückpreis:', 'wpsg'); ?></label>
+ <meta itemprop="priceCurrency" content="<?php echo $this->get_option('wpsg_currency'); ?>" />
+ <span itemprop="price" class="wpsg_preis preis_<?php echo $this->view['data']['id']; ?>" id="preis_<?php echo $this->view['data']['id']; ?>">
+ <?php echo wpsg_ff($this->view['data']['preis'], $this->get_option('wpsg_currency')); ?>
+ </span> <?php if (wpsg_isSizedString($this->view['data']['price_info'])) { echo '<div class="wpsg_priceinfo">'.wpsg_hspc($this->view['data']['price_info']).'</div>'; } ?>
+
+ <?php if ($this->hasMod('wpsg_mod_discount') && wpsg_getInt($this->view['data']['preis_prediscount']) > 0 && wpsg_isSizedInt($this->get_option('wpsg_mod_discount_show'))) { ?>
+ <div itemprop="offers" itemscope itemtype="http://schema.org/Offer" class="wpsg_produkt_preis new_price">
+ <?php echo __('Originalpreis', 'wpsg'); ?>: <span class="wpsg_preis_prediscount"><?php echo wpsg_ff($this->view['data']['preis_prediscount'], $this->get_option('wpsg_currency')); ?></span>
+ </div>
+ <?php } ?>
+ </div>
+
+ <?php if ($this->get_option('wpsg_kleinunternehmer')) { /* Kleinunternehmerregelung aktiviert START */ ?>
+
+ <div class="wpsg_produkt_preishinweis">
+ <?php echo wpsg_translate(__('#2# zzgl. #1#', 'wpsg'), '<a href="'.$this->getURL(wpsg_ShopController::URL_VERSANDKOSTEN).'">'.__('Versandkosten', 'wpsg').'</a>', '<a href="#kkhint" title="'.wpsg_hspc($this->get_option('wpsg_kleinunternehmer_text')).'">Endpreis</a>'); ?>
+ </div>
+
+ <?php } else { /* Kleinunternehmerregelung aktiviert ENDE */ ?>
+
+ <div class="wpsg_produkt_preishinweis">
+ <?php if ($this->getFrontendTaxview() == WPSG_NETTO) { /* Frontend = NETTO Preise */ ?>
+ <?php echo wpsg_translate(__('(zzgl. #1#% MwSt. und zzgl. #2#)', 'wpsg'), wpsg_ff($this->view['data']['mwst_value']), '<a href="'.$this->getURL(wpsg_ShopController::URL_VERSANDKOSTEN).'">'.__('Versandkosten', 'wpsg').'</a>'); ?>
+ <?php } else { /* Frontend = BRUTTO Preise */ ?>
+ <?php echo wpsg_translate(__('(inkl. #1#% MwSt. und zzgl. #2#)', 'wpsg'), wpsg_ff($this->view['data']['mwst_value']), '<a href="'.$this->getURL(wpsg_ShopController::URL_VERSANDKOSTEN).'">'.__('Versandkosten', 'wpsg').'</a>'); ?>
+ <?php } ?>
+ </div>
+
+ <?php } ?>
+ <?php } else {?>
+
+ <?php echo wpsg_translate(__('Die Produktpreise werden nur eingeloggten Benutzern angezeigt. Loggen Sie sich <a href="'.$this->getURL(wpsg_ShopController::URL_PROFIL).'">hier</a> bitte ein, um zu bestellen.')); ?>
+
+
+ <?php }?>
+ <?php /* Abfrage Preisanzeige nur für eingeloggte User aktiv und User eingeloggt ENDE */ ?>
+
+ <div itemprop="description" class="wpsg_produkt_shortdescription">
+ <h3><?php echo wpsg_translate(__('Produktbeschreibung', 'wpsg')); ?></h3>
+ <span><?php echo $this->view['data']['shortdesc']; ?></span>
+ </div>
+
+ <div class="wpsg_product_informations_left">
+ <?php /* Lagerbestand START*/?>
+ <?php if ($this->hasMod('wpsg_mod_stock') && $this->get_option('wpsg_mod_stock_showProduct') == '1') { ?>
+ <div class="wpsg_mod_produktindex_stock">
+ <img src="<?php echo WPSG_URL_WP;?>wp-content/plugins/wpshopgermany/views/gfx/stock_pos.png" />
+ <label><?php echo wpsg_translate(__('#1#','wpsg'), $this->view['data']['stock']); ?></label><?php echo wpsg_translate(__(' Artikel auf Lager', 'wpsg')); ?>
+ </div>
+ <?php } ?>
+ <?php /* Lagerbestand ENDE*/?>
+
+ <?php /* Füllmengenanzeige START */ ?>
+ <?php if ($this->hasMod('wpsg_mod_fuellmenge')) { ?>
+
+ <div class="wpsg_produkt_fuellmenge">
+ <label><?php echo wpsg_translate(__('Füllmenge:', 'wpsg')); ?></label>
+ <?php echo wpsg_translate(__('#1# (#2# / #3#)', 'wpsg'),
+ '<span class="wpsg_fmenge">'.wpsg_ff($this->view['data']['fmenge'], '', true).'</span> '.$this->view['data']['feinheit'],
+ '<span class="fmenge_preis">'.wpsg_ff($this->view['data']['fmenge_preis'], $this->get_option('wpsg_currency')).'</span> ',
+ wpsg_ff($this->get_option('wpsg_mod_fuellmenge_bezug'), $this->view['data']['feinheit'])
+ ); ?>
+ </div>
+
+ <?php } ?>
+ <?php /* Füllmengenanzeige ENDE */ ?>
+ </div>
+
+ <div class="wpsg_product_informations_right">
+ <?php /* Lieferzeit Anzeige START */ ?>
+ <?php if ($this->hasMod('wpsg_mod_deliverytime') && $this->get_option('wpsg_mod_deliverytime_show_product') == '1') { ?>
+
+ <?php /* Produkt nur im Store, nicht im Onlineshop vorhanden */ ?>
+ <?php if ($this->callMod('wpsg_mod_deliverytime', 'isStoreProduct', array($this->view['data']['product_key']))) {?>
+
+ <span class="wpsg_product_only_store"><?php echo wpsg_translate($this->get_option('wpsg_mod_deliverytime_storetext')); ?></span>
+ <?php if (wpsg_isSizedInt($this->get_option('wpsg_page_mod_deliverytime_storelink'))) { ?>
+ &nbsp;<a href="<?php echo get_permalink($this->get_option('wpsg_page_mod_deliverytime_storelink')); ?>"><?php echo __('So erreichen Sie uns.'); ?></a>
+ <?php } ?>
+ <br />
+
+ <?php } else {?>
+ <div class="wpsg_mod_deliverytime">
+ <img src="<?php echo WPSG_URL_WP;?>wp-content/plugins/wpshopgermany/views/gfx/deliverytime.png" />
+ <label><?php echo wpsg_translate(__('Lieferzeit:', 'wpsg')); ?></label>
+ <?php echo $this->callMod('wpsg_mod_deliverytime', 'displayDeliveryTime', array($this->view['data']['product_key'])); ?>
+
+ </div>
+
+ <?php $strDelayNote = $this->callMod('wpsg_mod_deliverytime', 'displayDelayTime', array($this->view['data']['product_key'])); ?>
+ <?php if (wpsg_isSizedString($strDelayNote)) { ?>
+ <div class="wpsg_mod_deliverytime_offline">
+ <img src="<?php echo WPSG_URL_WP;?>wp-content/plugins/wpshopgermany/views/gfx/deliverytime-offline.png" />
+ <div class="wpsg_mod_deliverytime_delay"><?php echo wpsg_hspc($strDelayNote); ?></div>
+ </div>
+ <?php } ?>
+
+ <?php } ?>
+ <?php } ?>
+ <?php /* Lieferzeit Anzeige ENDE */ ?>
+
+ <?php /* Gewichtsanzeige START */ ?>
+ <?php if ($this->hasMod('wpsg_mod_weight') && $this->get_option('wpsg_mod_weight_showProduct') === '1') { ?>
+ <div class="wpsg_mod_weight_produkt">
+ <label><?php echo wpsg_translate(__('Gewicht:', 'wpsg')); ?></label>
+ <?php echo wpsg_translate(__('#1# #2#', 'wpsg'), '<span class="wpsg_weight" id="weight_'.$this->view['data']['id'].'">'.wpsg_ff($this->view['data']['weight']).'</span>', $this->get_option('wpsg_mod_weight_unit')); ?>
+ </div>
+ <?php } ?>
+ <?php /* Gewichtsanzeige ENDE */ ?>
+
+ <?php /* Varianten START */ ?>
+ <div class="wpsg_produkt_varianten">
+ <?php echo $this->callMod('wpsg_mod_varianten', 'renderTemplate', array($this->view['data']['product_key'])); ?>
+ </div>
+ <?php /* Varianten ENDE */ ?>
+ </div>
+
+ <div class="wpsg_clear"></div>
+
+ <div class="wpsg_product_buttonarea">
+ <div class="wpsg_product_buttons_add_basket">
+ <?php if ($this->callMods('productForSale', array($this->view['data']['product_key'])) || ($this->hasMod('wpsg_mod_request') && $this->callMod('wpsg_mod_request', 'isRequestProduct', array($this->view['data']['id'])))) { ?>
+ <div class="wpsg_produkt_add_basket_wrapper">
+
+ <label class="wpsg_amount_label" for="wpsg_menge_<?php echo $this->getTemplateIndex(); ?>"><?php echo __('Anzahl', 'wpsg'); ?>:</label>
+
+ <input type="text" value="<?php echo ((wpsg_isSizedInt($this->view['data']['menge']))?$this->view['data']['menge']:'1'); ?>" name="wpsg[menge]" class="wpsg_menge" id="wpsg_menge_<?php echo $this->getTemplateIndex(); ?>"
+ <?php echo (($this->view['data']['basket_multiple'] == 4)?' readonly="readonly" ':''); ?>
+ />
+
+ <?php if (in_array($this->get_option('wpsg_afterinsert'), array('2', '3'))) { ?>
+ <script type="text/javascript">
+
+ jQuery(document).ready(function() {
+
+ jQuery('.wpsg_add_basket_<?php echo $this->getTemplateIndex(); ?>').bind('click', function() {
+
+ jQuery('.wpsg_add_basket_<?php echo $this->getTemplateIndex(); ?>').prop('disabled', true);
+
+ jQuery.ajax( {
+ url: '<?php echo $this->getURL(wpsg_ShopController::URL_BASKET); ?>',
+ data:
+ {
+ 'wpsg_form_data': jQuery('#wpsg_produktform_<?php echo $this->getTemplateIndex(); ?>').serialize(),
+ 'wpsg[ajax]': '1',
+ 'wpsg[submit]': '1'
+ },
+ success: function(data)
+ {
+
+ <?php if ($this->get_option('wpsg_afterinsert') == '2') { ?>
+ tb_show('<?php echo __('Ihr Warenkorb', 'wpsg'); ?>', '<?php echo $this->getURL(wpsg_ShopController::URL_BASKET_AJAX); ?>&height=500');
+ <?php } else { ?>
+
+ jQuery('#wpsg_basket_ajax_message_wrap').remove();
+ jQuery('body').append('<div id="wpsg_basket_ajax_message_wrap">' + data + '</div>');
+
+ <?php } ?>
+
+ wpsg_refreshBasketWidget();
+ jQuery('.wpsg_add_basket_<?php echo $this->getTemplateIndex(); ?>').prop('disabled', false);
+
+ }
+ } );
+
+ return false;
+
+ } );
+
+ } );
+
+ </script>
+ <?php } ?>
+
+ <div class="wpsg_clear"></div>
+
+ </div>
+ <?php } ?>
+ </div>
+
+ <?php /* Abfrage Warenkorbanzeige nur für eingeloggte Benutzer START */ ?>
+ <div class="wpsg_product_button_basket">
+ <?php if (($this->callMod('wpsg_mod_kundenverwaltung', 'isLoggedIn') && ($this->get_option('wpsg_mod_kundenverwaltung_preisAnzeige') == '1')) || ($this->get_option('wpsg_mod_kundenverwaltung_preisAnzeige') == '0')) { ?>
+ <?php if ($this->callMods('productForSale', array($this->view['data']['product_key']))) { ?>
+ <input class="wpsg_button wpsg_add_basket wpsg_add_basket_<?php echo $this->getTemplateIndex(); ?>" type="submit" value="<?php echo __('In den Warenkorb', 'wpsg'); ?>" name="wpsg[submit]" />
+ <?php } ?>
+ <?php }else{?>
+ <a class="wpsg_blind_basket_button" href="#"><?php echo wpsg_translate(__('Loggen Sie sich bitte ein, um zu bestellen', 'wpsg')); ?></a>
+ <?php } ?>
+ <?php /* Abfrage Warenkorbanzeige nur für eingeloggte Benutzer ENDE */ ?>
+ </div>
+ </div>
+
+ <div class="wpsg_clear"></div>
+
+ <?php if ($this->hasMod('wpsg_mod_request') && $this->callMod('wpsg_mod_request', 'isRequestProduct', array($this->view['data']['id']))) { ?>
+ <input class="wpsg_button wpsg_add_requestlist" id="wpsg_add_requestlist_<?php echo $this->getTemplateIndex(); ?>" type="submit" value="<?php echo __('Auf die Anfrageliste', 'wpsg'); ?>" name="wpsg[submit_request]" />
+ <?php } ?>
+
+ </div>
+
+ <div class="wpsg_clear"></div>
+
+ </div>
+
+ <?php /* Produktcontentbereich START */ ?>
+ <div class="wpsg_product_informationarea">
+
+ <?php if (strlen(trim($this->view['data']['longdescription'])) > 0) { ?>
+ <div class="wpsg_product_information_large">
+ <div class="wpsg_produkt_additional_information">
+ <div itemprop="description" class="wpsg_produkt_longdescription">
+ <h3><?php echo wpsg_translate(__('Beschreibung', 'wpsg')); ?></h3>
+ <span><?php echo $this->view['data']['longdescription']; ?></span>
+ </div>
+ </div>
+ </div>
+ <?php } ?>
+
+ <div class="wpsg_product_information_more">
+ <div itemprop="description" class="wpsg_produkt_more_information">
+ <h3><?php echo wpsg_translate(__('Zusätzliche Informationen', 'wpsg')); ?></h3>
+ </div>
+ </div>
+
+ <div class="wpsg_product_assessment">
+ <div itemprop="description" class="wpsg_product_assessments">
+ <h3><?php echo wpsg_translate(__('Bewertungen', 'wpsg')); ?></h3>
+ </div>
+ </div>
+
+ <?php /* Produktcontentbereich ENDE */ ?>
+ </div>
+
+ <div class="wpsg_clear"></div>
+
+ <?php /* Social Media Integration */ ?>
+ <div class="wpsg_product_social_media">
+ <?php if ( is_plugin_active( 'plugin-directory/shariff.php' )) {?>
+ <?=do_shortcode('[shariff]')?>
+ <?php } ?>
+ </div>
+
+ <?php $this->callMods('product_bottom', array(&$this->view['data']['id'], $this->getTemplateIndex())); ?>
+
+ </div>
+
+</div> \ No newline at end of file