diff options
| author | Daniel Schmitzer <noreply@maennchen1.de> | 2016-01-14 14:55:36 +0000 |
|---|---|---|
| committer | Daniel Schmitzer <noreply@maennchen1.de> | 2016-01-14 14:55:36 +0000 |
| commit | ad405c7045c6e242080ec9d3ce4c9e586b517c4f (patch) | |
| tree | b41905f4d27f3eaaabd5bad3a39f8d3873540b46 /views/mods/mod_micropayment/order_done.phtml | |
- Testweise 4
git-svn-id: https://[internal]/wordpress/plugins/wpsg4@5261 0d5edaf7-2b12-4e95-93f4-047927463d4b
Diffstat (limited to 'views/mods/mod_micropayment/order_done.phtml')
| -rw-r--r-- | views/mods/mod_micropayment/order_done.phtml | 122 |
1 files changed, 122 insertions, 0 deletions
diff --git a/views/mods/mod_micropayment/order_done.phtml b/views/mods/mod_micropayment/order_done.phtml new file mode 100644 index 0000000..33bc32b --- /dev/null +++ b/views/mods/mod_micropayment/order_done.phtml @@ -0,0 +1,122 @@ +<?php
+
+ /**
+ * Template welches den Zahlungsdienstleister nach Bestellabschluß einbindet
+ */
+
+?>
+<?php if (wpsg_isSizedString($this->view['wpsg_mod_micropayment']['payLink'])) { ?>
+<?php echo __('Klicken Sie auf das folgende Logo um ihre Bestellung zu bezahlen.', 'wpsg'); ?>
+<br /><br />
+
+<a href="<?php echo $this->view['wpsg_mod_micropayment']['payLink']; ?>"><img src="<?php echo $this->view['wpsg_mod_micropayment']['logo']; ?>" alt="<?php echo $this->view['wpsg_mod_micropayment']['title']; ?>" /></a>
+
+ <?php if ($this->get_option('wpsg_mod_micropayment_paystart') == '1') { ?>
+ <script type="text/javascript">
+
+ jQuery(document).ready(function() {
+ window.setTimeout(function() {
+ location.href = "<?php echo $this->view['wpsg_mod_micropayment']['payLink']; ?>";
+ }, 1000);
+ } );
+
+ </script>
+ <?php } ?>
+
+<?php } else { ?>
+
+<p><?php echo __('Bitte geben Sie ihre Kreditkarteninformationen (Kartennummer, Gültigkeitsdatum und Prüfnummer) in folgende Felder ein. Die Daten werden an Micropayment übermittelt und nicht durch uns gespeichert oder ausgewertet.', 'wpsg'); ?></p>
+
+<form method="post" id="wpsg_mod_micropayment_creditcard">
+
+ <div class="micropayment_card">
+ <div class="front card">
+ <div class="chip"></div>
+ <div class="number"><input placeholder="<?php echo __('Kreditkartennummer', 'wpsg'); ?>" type="text" name="number" /></div>
+ <div class="bankname"><?php echo __('Kreditkarte - Vorderseite', 'wpsg'); ?></div>
+ <div class="name"><?php echo __('Max Mustermann', 'wpsg'); ?></div>
+ <div class="validthrough"><?php echo __('Gültig bis', 'wpsg'); ?>:</div>
+ <div class="valid">
+ <select name="expiryMonth">
+ <?php for ($i = 1; $i <= 12; $i ++) { ?>
+ <option value="<?php echo $i; ?>"><?php echo str_pad($i, 2, '0', STR_PAD_LEFT); ?>
+ <?php } ?>
+ </select>
+ <span>/</span>
+ <select name="expiryYear">
+ <?php for ($i = date('Y'); $i <= date('Y') + 10; $i ++) { ?>
+ <option value="<?php echo $i; ?>"><?php echo $i; ?></option>
+ <?php } ?>
+ </select>
+ </div>
+ </div>
+
+ <div class="back card">
+ <div class="bankname"><?php echo __('Kreditkarte - Rückseite', 'wpsg'); ?></div>
+ <div class="blackmagnetic"></div>
+ <div class="number"><?php echo __('HC600214C', 'wpsg'); ?></div>
+ <div class="signature"><?php echo __('Unterschrift Max Mustermann', 'wpsg'); ?></div>
+ <div class="sign"><input type="text" name="cvc2" value="" placeholder="<?php echo __('Prüfnummer', 'wpsg'); ?>" /></div>
+ </div>
+
+ <input type="button" id="wpsg_mod_micropayment_pay_button" class="wpsg_button" value="<?php echo __('Zahlung starten', 'wpsg'); ?>" />
+
+ </div>
+
+</form>
+
+<script type="text/javascript">/* <![CDATA[ */ + + jQuery(document).ready(function() {
+
+ jQuery('#wpsg_mod_micropayment_pay_button').bind('click', function() {
+
+ var form_data = jQuery('#wpsg_mod_micropayment_creditcard').serialize();
+
+ jQuery('.micropayment_card input, .micropayment_card select').prop('disabled', true);
+
+ jQuery.ajax( {
+ url: wpsg_ajax.ajaxurl,
+ data: {
+ action: 'ajax',
+ wpsg_plugin: 'wpsg_mod_micropayment',
+ module_action: 'pay',
+ form_data: form_data,
+ order_id: <?php echo $this->view['o_id']; ?>
+ },
+ success: function(data) {
+
+ if (data === "1")
+ {
+
+ alert('<?php echo __('Vielen Dank für Ihre Zahlungsreservierung.', 'wpsg'); ?>');
+ location.href = '<?php echo get_permalink($this->get_option('wpsg_mod_micropayment_successPage')); ?>';
+
+ }
+ else
+ {
+
+ alert(data);
+
+ }
+
+ jQuery('.micropayment_card input, .micropayment_card select').prop('disabled', false);
+
+ },
+ error: function(rdata, data)
+ {
+
+ alert("<?php echo __('Unerwarteter Serverfehler!', 'wpsg'); ?>");
+
+ }
+ } );
+
+ return false;
+
+ } );
+
+ } ); + +/* ]]> */</script>
+
+<?php } ?>
\ No newline at end of file |
