summaryrefslogtreecommitdiff
path: root/views/mods/mod_gutschein/add.phtml
diff options
context:
space:
mode:
Diffstat (limited to 'views/mods/mod_gutschein/add.phtml')
-rw-r--r--views/mods/mod_gutschein/add.phtml11
1 files changed, 11 insertions, 0 deletions
diff --git a/views/mods/mod_gutschein/add.phtml b/views/mods/mod_gutschein/add.phtml
index b6b4b6a..3166f21 100644
--- a/views/mods/mod_gutschein/add.phtml
+++ b/views/mods/mod_gutschein/add.phtml
@@ -4,6 +4,16 @@
* Template für die Maske eines neuen Gutscheins
*/
+ $used = 0;
+
+ if (wpsg_isSizedInt($_REQUEST['voucher_id'])) {
+
+ $oVoucher = wpsg_voucher::getInstance($_REQUEST['voucher_id']);
+
+ $used = $oVoucher->getUsedAmount();
+
+ }
+
?>
<div class="content form-horizontal">
@@ -13,6 +23,7 @@
<?php wpsg_drawForm_AdminboxStart(); ?>
<?php echo wpsg_drawForm_Input('wpsg_mod_gutschein_value', __('Betrag', 'wpsg'), wpsg_ff($this->view['mod_gutschein']['value'])); ?>
+ <?php echo wpsg_drawForm_Input(false, __('Bereits verwendet'), wpsg_ff($used), ['field_id' => 'wpsg_voucher_used', 'readonly' => true]); ?>
<div style="margin-top:-15px;">
<?php echo wpsg_drawForm_Checkbox('wpsg_mod_gutschein_coupon', __('Als Wertgutschein behandeln', 'wpsg'), $this->view['mod_gutschein']['coupon']); ?>