summaryrefslogtreecommitdiff
path: root/views
diff options
context:
space:
mode:
authorkarl <noreply@maennchen1.de>2023-07-28 14:19:34 +0000
committerkarl <noreply@maennchen1.de>2023-07-28 14:19:34 +0000
commit990c8b80689c81a06acd4b4d174c5618ad8fd525 (patch)
tree79c76a7a52c78039ca77382ccd6d8b42fea4aa78 /views
parentdc2b852a13bbe361c6dbf6a41bed60d134a6f9c7 (diff)
- Feature: Modul Vorkasse: QR-Code von QR-Rechnung (Schweiz) kann nun auf der Bestellabschlussseite/Bestellmail angezeigt werden.
git-svn-id: https://[internal]/wordpress/plugins/wpsg4@8336 0d5edaf7-2b12-4e95-93f4-047927463d4b
Diffstat (limited to 'views')
-rw-r--r--views/admin/shopdata.phtml78
-rw-r--r--views/mailtemplates/html/customer.phtml20
-rw-r--r--views/mods/mod_prepayment/order_done.phtml58
-rw-r--r--views/mods/mod_prepayment/settings_edit.phtml42
4 files changed, 149 insertions, 49 deletions
diff --git a/views/admin/shopdata.phtml b/views/admin/shopdata.phtml
index 6531a79..c5e3d83 100644
--- a/views/admin/shopdata.phtml
+++ b/views/admin/shopdata.phtml
@@ -21,6 +21,12 @@
<form name="form1" method="post" enctype="multipart/form-data" action="<?php echo WPSG_URL_WP; ?>wp-admin/admin.php?page=wpsg-Admin&amp;subaction=<?php echo $_REQUEST['subaction']; ?>&amp;noheader=1">
<?php \wp_nonce_field('wpsg-save-admin-shopdata'); ?>
+
+ <?php
+ $countrys = array();
+ $arCountry = wpsg_country::find();
+ foreach ($arCountry as $oCountry) $countrys[$oCountry->getId()] = $oCountry->getName();
+ ?>
<div class="panel panel-default">
<div class="panel-heading clearfix">
@@ -29,6 +35,7 @@
<div class="panel-body">
<?php echo wpsg_drawForm_Input('wpsg_shopdata_name', __('Name des Shops / Firma', 'wpsg'), $this->get_option('wpsg_shopdata_name'), array('help' => 'wpsg_shopdata_name')); ?>
<?php echo wpsg_drawForm_Input('wpsg_shopdata_owner', __('Inhaber des Shops', 'wpsg'), $this->get_option('wpsg_shopdata_owner'), array('help' => 'wpsg_shopdata_owner')); ?>
+ <br />
<?php echo wpsg_drawForm_Input('wpsg_shopdata_tel', __('Telefonnummer', 'wpsg'), $this->get_option('wpsg_shopdata_tel'), array('help' => 'wpsg_shopdata_tel')); ?>
<?php echo wpsg_drawForm_Input('wpsg_shopdata_fax', __('Faxnummer', 'wpsg'), $this->get_option('wpsg_shopdata_fax'), array('help' => 'wpsg_shopdata_fax')); ?>
<?php echo wpsg_drawForm_Input('wpsg_shopdata_email', __('E-Mail', 'wpsg'), $this->get_option('wpsg_shopdata_email'), array('help' => 'wpsg_shopdata_email')); ?>
@@ -42,16 +49,10 @@
<h3 class="panel-title"><?php echo __('Anschrift', 'wpsg'); ?></h3>
</div>
<div class="panel-body">
-
<?php echo wpsg_drawForm_Input('wpsg_shopdata_street', __('Straße', 'wpsg'), $this->get_option('wpsg_shopdata_street'), array('help' => 'wpsg_shopdata_street')); ?>
<?php echo wpsg_drawForm_Input('wpsg_shopdata_zip', __('Postleitzahl', 'wpsg'), $this->get_option('wpsg_shopdata_zip'), array('help' => 'wpsg_shopdata_zip')); ?>
- <?php echo wpsg_drawForm_Input('wpsg_shopdata_city', __('Ort', 'wpsg'), $this->get_option('wpsg_shopdata_city'), array('help' => 'wpsg_shopdata_city')); ?>
- <?php echo wpsg_drawForm_Select('wpsg_shopdata_eu', __('Hauptsitz des Shopbetreiber befindet sich:', 'wpsg'), Array(
- wpsg_AdminController::SHOPDATA_EU_GERMANY => __('in Deutschland', 'wpsg'),
- wpsg_AdminController::SHOPDATA_EU_EU => __('innerhalb der EU', 'wpsg'),
- wpsg_AdminController::SHOPDATA_EU_WORLD => __('im europäischen Ausland', 'wpsg')
- ), $this->get_option('wpsg_shopdata_eu'), array('help' => 'wpsg_shopdata_eu')); ?>
-
+ <?php echo wpsg_drawForm_Input('wpsg_shopdata_city', __('Ort', 'wpsg'), $this->get_option('wpsg_shopdata_city'), array('help' => 'wpsg_shopdata_city')); ?>
+ <?php echo wpsg_drawForm_Select('wpsg_shopdata_country', __('Land', 'wpsg'), $countrys, $this->get_option('wpsg_shopdata_country'), array('help' => 'wpsg_shopdata_country')); ?>
</div>
</div>
@@ -60,16 +61,17 @@
<h3 class="panel-title"><?php echo __('Zweigstelle', 'wpsg'); ?></h3>
</div>
<div class="panel-body">
- <?php echo wpsg_drawForm_Checkbox('wpsg_shopdata_2', __('Zweigstelle vorhanden', 'wpsg'), $this->get_option('wpsg_shopdata_2')); ?>
- <div class="wpsg_shopdata_2_activ" style="display:none;">
- <?php echo wpsg_drawForm_Input('wpsg_shopdata_2_street', __('Straße', 'wpsg'), $this->get_option('wpsg_shopdata_2_street'), array('help' => 'wpsg_shopdata_2_street')); ?>
- <?php echo wpsg_drawForm_Input('wpsg_shopdata_2_zip', __('Postleitzahl', 'wpsg'), $this->get_option('wpsg_shopdata_2_zip'), array('help' => 'wpsg_shopdata_2_zip')); ?>
- <?php echo wpsg_drawForm_Input('wpsg_shopdata_2_city', __('Ort', 'wpsg'), $this->get_option('wpsg_shopdata_2_city'), array('help' => 'wpsg_shopdata_2_city')); ?>
- <?php echo wpsg_drawForm_Input('wpsg_shopdata_2_country', __('Land', 'wpsg'), $this->get_option('wpsg_shopdata_2_country'), array('help' => 'wpsg_shopdata_2_country')); ?>
- <?php echo wpsg_drawForm_Input('wpsg_shopdata_2_tel', __('Telefon', 'wpsg'), $this->get_option('wpsg_shopdata_2_tel'), array('help' => 'wpsg_shopdata_2_tel')); ?>
- <?php echo wpsg_drawForm_Input('wpsg_shopdata_2_fax', __('Fax', 'wpsg'), $this->get_option('wpsg_shopdata_2_fax'), array('help' => 'wpsg_shopdata_2_fax')); ?>
- <?php echo wpsg_drawForm_Input('wpsg_shopdata_2_email', __('E-Mail', 'wpsg'), $this->get_option('wpsg_shopdata_2_email'), array('help' => 'wpsg_shopdata_2_email')); ?>
- </div>
+ <?php echo wpsg_drawForm_Checkbox('wpsg_shopdata_2', __('Zweigstelle vorhanden', 'wpsg'), $this->get_option('wpsg_shopdata_2'), array('help' => 'wpsg_shopdata_2')); ?>
+ <div class="wpsg_shopdata_2_activ" style="display:none;">
+ <?php echo wpsg_drawForm_Input('wpsg_shopdata_2_street', __('Straße', 'wpsg'), $this->get_option('wpsg_shopdata_2_street')); ?>
+ <?php echo wpsg_drawForm_Input('wpsg_shopdata_2_zip', __('Postleitzahl', 'wpsg'), $this->get_option('wpsg_shopdata_2_zip')); ?>
+ <?php echo wpsg_drawForm_Input('wpsg_shopdata_2_city', __('Ort', 'wpsg'), $this->get_option('wpsg_shopdata_2_city')); ?>
+ <?php echo wpsg_drawForm_Select('wpsg_shopdata_2_country', __('Land', 'wpsg'), $countrys, $this->get_option('wpsg_shopdata_2_country')); ?>
+ <br />
+ <?php echo wpsg_drawForm_Input('wpsg_shopdata_2_tel', __('Telefon', 'wpsg'), $this->get_option('wpsg_shopdata_2_tel')); ?>
+ <?php echo wpsg_drawForm_Input('wpsg_shopdata_2_fax', __('Fax', 'wpsg'), $this->get_option('wpsg_shopdata_2_fax')); ?>
+ <?php echo wpsg_drawForm_Input('wpsg_shopdata_2_email', __('E-Mail', 'wpsg'), $this->get_option('wpsg_shopdata_2_email')); ?>
+ </div>
</div>
</div>
@@ -78,32 +80,32 @@
<h3 class="panel-title"><?php echo __('Bankdaten', 'wpsg'); ?></h3>
</div>
<div class="panel-body">
-
<?php echo wpsg_drawForm_Input('wpsg_shopdata_bank_name', __('Name der Bank', 'wpsg'), $this->get_option('wpsg_shopdata_bank_name'), array('help' => 'wpsg_shopdata_bank_name')); ?>
<?php echo wpsg_drawForm_Input('wpsg_shopdata_bank_owner', __('Kontoinhaber', 'wpsg'), $this->get_option('wpsg_shopdata_bank_owner'), array('help' => 'wpsg_shopdata_bank_owner')); ?>
<?php echo wpsg_drawForm_Input('wpsg_shopdata_bank_iban', __('IBAN Nummer', 'wpsg'), $this->get_option('wpsg_shopdata_bank_iban'), array('help' => 'wpsg_shopdata_bank_iban')); ?>
+ <?php echo wpsg_drawForm_Input('wpsg_shopdata_bank_qriban', __('QR-IBAN Nummer', 'wpsg'), $this->get_option('wpsg_shopdata_bank_qriban'), array('help' => 'wpsg_shopdata_bank_qriban')); ?>
<?php echo wpsg_drawForm_Input('wpsg_shopdata_bank_bic', __('BIC Nummer', 'wpsg'), $this->get_option('wpsg_shopdata_bank_bic'), array('help' => 'wpsg_shopdata_bank_bic')); ?>
-
+ <?php echo wpsg_drawForm_Input('wpsg_shopdata_bank_besr', __('BESR-ID', 'wpsg'), $this->get_option('wpsg_shopdata_bank_besr'), array('help' => 'wpsg_shopdata_bank_besr')); ?>
</div>
</div>
- <?php /* only Standort = Ausland */ ?>
- <div class="wpsg_shopdata_eu wpsg_shopdata_eu_<?php echo wpsg_AdminController::SHOPDATA_EU_WORLD; ?>" style="display:<?php echo (($this->get_option('wpsg_shopdata_eu') == wpsg_AdminController::SHOPDATA_EU_WORLD || $this->get_option('wpsg_shopdata_eu') === false)?'block':'none'); ?>;">
- <div class="panel panel-default">
- <div class="panel-heading clearfix">
- <h3 class="panel-title"><?php echo __('EU-Vertreter', 'wpsg'); ?></h3>
- </div>
- <div class="panel-body">
- <?php echo wpsg_drawForm_Input('wpsg_shopdata_eu_name', __('Name des EU-Vertreters', 'wpsg'), $this->get_option('wpsg_shopdata_eu_name'), array('help' => 'wpsg_shopdata_eu_name')); ?>
+ <div class="panel panel-default">
+ <div class="panel-heading clearfix">
+ <h3 class="panel-title"><?php echo __('EU-Vertreter', 'wpsg'); ?></h3>
+ </div>
+ <div class="panel-body">
+ <?php echo wpsg_drawForm_Checkbox('wpsg_shopdata_3', __('EU-Vertreter vorhanden', 'wpsg'), $this->get_option('wpsg_shopdata_3'), array('help' => 'wpsg_shopdata_3')); ?>
+ <div class="wpsg_shopdata_3_activ" style="display:none;">
+ <?php echo wpsg_drawForm_Input('wpsg_shopdata_eu_name', __('Name des EU-Vertreters', 'wpsg'), $this->get_option('wpsg_shopdata_eu_name')); ?>
<br />
- <?php echo wpsg_drawForm_Input('wpsg_shopdata_eu_street', __('Straße', 'wpsg'), $this->get_option('wpsg_shopdata_eu_street'), array('help' => 'wpsg_shopdata_eu_street')); ?>
- <?php echo wpsg_drawForm_Input('wpsg_shopdata_eu_zip', __('Postleitzahl', 'wpsg'), $this->get_option('wpsg_shopdata_eu_zip'), array('help' => 'wpsg_shopdata_eu_zip')); ?>
- <?php echo wpsg_drawForm_Input('wpsg_shopdata_eu_city', __('Stadt', 'wpsg'), $this->get_option('wpsg_shopdata_eu_city'), array('help' => 'wpsg_shopdata_eu_city')); ?>
- <?php echo wpsg_drawForm_Input('wpsg_shopdata_eu_country', __('Land', 'wpsg'), $this->get_option('wpsg_shopdata_eu_country'), array('help' => 'wpsg_shopdata_eu_country')); ?>
+ <?php echo wpsg_drawForm_Input('wpsg_shopdata_eu_street', __('Straße', 'wpsg'), $this->get_option('wpsg_shopdata_eu_street')); ?>
+ <?php echo wpsg_drawForm_Input('wpsg_shopdata_eu_zip', __('Postleitzahl', 'wpsg'), $this->get_option('wpsg_shopdata_eu_zip')); ?>
+ <?php echo wpsg_drawForm_Input('wpsg_shopdata_eu_city', __('Stadt', 'wpsg'), $this->get_option('wpsg_shopdata_eu_city')); ?>
+ <?php echo wpsg_drawForm_Select('wpsg_shopdata_eu_country', __('Land', 'wpsg'), $countrys, $this->get_option('wpsg_shopdata_eu_country')); ?>
<br />
- <?php echo wpsg_drawForm_Input('wpsg_shopdata_eu_tel', __('Telefonnummer', 'wpsg'), $this->get_option('wpsg_shopdata_eu_tel'), array('help' => 'wpsg_shopdata_eu_tel')); ?>
- <?php echo wpsg_drawForm_Input('wpsg_shopdata_eu_fax', __('Faxnummer', 'wpsg'), $this->get_option('wpsg_shopdata_eu_fax'), array('help' => 'wpsg_shopdata_eu_fax')); ?>
- <?php echo wpsg_drawForm_Input('wpsg_shopdata_eu_email', __('E-Mail', 'wpsg'), $this->get_option('wpsg_shopdata_eu_email'), array('help' => 'wpsg_shopdata_eu_email')); ?>
+ <?php echo wpsg_drawForm_Input('wpsg_shopdata_eu_tel', __('Telefonnummer', 'wpsg'), $this->get_option('wpsg_shopdata_eu_tel')); ?>
+ <?php echo wpsg_drawForm_Input('wpsg_shopdata_eu_fax', __('Faxnummer', 'wpsg'), $this->get_option('wpsg_shopdata_eu_fax')); ?>
+ <?php echo wpsg_drawForm_Input('wpsg_shopdata_eu_email', __('E-Mail', 'wpsg'), $this->get_option('wpsg_shopdata_eu_email')); ?>
</div>
</div>
</div>
@@ -121,6 +123,12 @@
} ).change();
+ jQuery('#wpsg_shopdata_3').bind('change', function() {
+
+ if (jQuery(this).is(':checked')) jQuery('.wpsg_shopdata_3_activ').show();
+ else jQuery('.wpsg_shopdata_3_activ').hide();
+
+ } ).change();
} );
diff --git a/views/mailtemplates/html/customer.phtml b/views/mailtemplates/html/customer.phtml
index b3a2e7d..4441268 100644
--- a/views/mailtemplates/html/customer.phtml
+++ b/views/mailtemplates/html/customer.phtml
@@ -169,11 +169,27 @@
require_once WPSG_PATH_LIB.'phpgirocode.class.php';
- if (isset($this->view['mod_prepayment']['subject'])) {
+ if (isset($this->view['mod_prepayment']['subject']) && ($this->get_option('wpsg_mod_prepayment_qrcode') == true)) {
if (in_array('kundenmail.phtml', $this->arTemplateStack)) {
+
- echo $this->callMod('wpsg_mod_prepayment', 'genQRCode', array($this->view['o_id'], $this->view['mod_prepayment']['subject'], $this->view['basket']['sum']['preis_gesamt_brutto'], 3, PhpGirocode::OUTPUT_FILE));
+ if ($this->get_option('wpsg_mod_prepayment_qrcode_country') == '0') {
+
+ $qrcodes = array();
+ $qrcodes = $this->callMod('wpsg_mod_prepayment', 'genQRCode', array($this->view['o_id'], $this->view['wpsg_mod_prepayment']['subject'], $this->view['basket']['sum']['preis_gesamt_brutto'], 3, PhpGirocode::OUTPUT_FILE, $this->get_option('wpsg_mod_prepayment_qrcode_country'), $this->view['basket']));
+
+ foreach ($qrcodes as $qr) echo $qr;
+
+ } else if ($this->get_option('wpsg_mod_prepayment_qrcode_country') == '1') {
+
+ echo $this->callMod('wpsg_mod_prepayment', 'genQRCode', array($this->view['o_id'], $this->view['mod_prepayment']['subject'], $this->view['basket']['sum']['preis_gesamt_brutto'], 3, PhpGirocode::OUTPUT_FILE, $this->get_option('wpsg_mod_prepayment_qrcode_country'), $this->view['basket']));
+
+ } else if ($this->get_option('wpsg_mod_prepayment_qrcode_country') == '2') {
+
+ echo $this->callMod('wpsg_mod_prepayment', 'genQRCode', array($this->view['o_id'], $this->view['mod_prepayment']['subject'], $this->view['basket']['sum']['preis_gesamt_brutto'], 3, PhpGirocode::OUTPUT_FILE, $this->get_option('wpsg_mod_prepayment_qrcode_country'), $this->view['basket']));
+
+ }
}
diff --git a/views/mods/mod_prepayment/order_done.phtml b/views/mods/mod_prepayment/order_done.phtml
index d1505d4..dfd6c4b 100644
--- a/views/mods/mod_prepayment/order_done.phtml
+++ b/views/mods/mod_prepayment/order_done.phtml
@@ -21,15 +21,55 @@
<p>
<?php echo __('Wenn Ihre Banking-App Girocode unterstützt, können Sie diesen QRCode scannen.', 'wpsg'); ?>
</p>
-
- <?php
-
- require_once WPSG_PATH_LIB.'phpgirocode.class.php';
-
- $img = $this->callMod('wpsg_mod_prepayment', 'genQRCode', array($this->view['o_id'], $this->view['wpsg_mod_prepayment']['subject'], $this->view['basket']['sum']['preis_gesamt_brutto'], 8, PhpGirocode::OUTPUT_BASE64));
-
- echo '<img src="data:image/png;base64,'.$img.'" />';
+
+ <?php require_once WPSG_PATH_LIB.'phpgirocode.class.php'; ?>
+
+ <?php if ($this->get_option('wpsg_mod_prepayment_qrcode_country') == '0') { ?>
- ?>
+ <!-- QR-CODE für EPC und SWISS -->
+
+ <?php
+
+ $img = array();
+ $img = $this->callMod('wpsg_mod_prepayment', 'genQRCode', array($this->view['o_id'], $this->view['wpsg_mod_prepayment']['subject'], $this->view['basket']['sum']['preis_gesamt_brutto'], 10, PhpGirocode::OUTPUT_BASE64, $this->get_option('wpsg_mod_prepayment_qrcode_country'), $this->view['basket']));
+
+ echo '<div style="display: flex; justify-content: center; flex; gap: 20px;">';
+ foreach ($img as $i) {
+
+ echo '<div>';
+ echo '<h4 style="margin-bottom: -15px; font-weight: bold;">'.$i['title'].':'.'<h4>';
+ echo '<div class="order_done_qrcode"><img style="width: 240px; height:240px; border: solid 1px; padding: 25px;" src="data:image/png;base64,'.$i['hash'].'" /></div>';
+ echo '</div>';
+
+ }
+ echo '</div>'
+
+ ?>
+
+ <?php } else if ($this->get_option('wpsg_mod_prepayment_qrcode_country') == '1') { ?>
+
+ <!-- QR-CODE für EPC -->
+
+ <?php
+
+ $img = $this->callMod('wpsg_mod_prepayment', 'genQRCode', array($this->view['o_id'], $this->view['wpsg_mod_prepayment']['subject'], $this->view['basket']['sum']['preis_gesamt_brutto'], 10, PhpGirocode::OUTPUT_BASE64, $this->get_option('wpsg_mod_prepayment_qrcode_country')));
+
+ echo '<img style="width: 320px; height:320px;" src="data:image/png;base64,'.$img.'" />';
+
+ ?>
+
+ <?php } else if ($this->get_option('wpsg_mod_prepayment_qrcode_country') == '2') { ?>
+
+ <!-- QR-CODE für SWISS -->
+
+ <?php
+
+ $img = $this->callMod('wpsg_mod_prepayment', 'genQRCode', array($this->view['o_id'], $this->view['wpsg_mod_prepayment']['subject'], $this->view['basket']['sum']['preis_gesamt_brutto'], 10, PhpGirocode::OUTPUT_BASE64, $this->get_option('wpsg_mod_prepayment_qrcode_country'), $this->view['basket']));
+
+ echo '<img style="width: 320px; height:320px;" src="data:image/png;base64,'.$img.'" />';
+
+ ?>
+
+ <?php } ?>
<?php } ?> \ No newline at end of file
diff --git a/views/mods/mod_prepayment/settings_edit.phtml b/views/mods/mod_prepayment/settings_edit.phtml
index 7d07c93..0f46150 100644
--- a/views/mods/mod_prepayment/settings_edit.phtml
+++ b/views/mods/mod_prepayment/settings_edit.phtml
@@ -8,8 +8,14 @@
<?php echo wpsg_drawForm_Input('wpsg_mod_prepayment_bezeichnung', __('Bezeichnung', 'wpsg'), $this->get_option('wpsg_mod_prepayment_bezeichnung'), array('help' => 'wpsg_mod_prepayment_bezeichnung')); ?>
<?php echo wpsg_drawForm_Checkbox('wpsg_mod_prepayment_aktiv', __('Aktiv', 'wpsg'), $this->get_option('wpsg_mod_prepayment_aktiv'), array('help' => 'wpsg_mod_prepayment_aktiv')); ?>
-<?php echo wpsg_drawForm_Checkbox('wpsg_mod_prepayment_qrcode', __('QR-Code auf Bestellabschlussseite anzeigen', 'wpsg'), $this->get_option('wpsg_mod_prepayment_qrcode'), array('help' => 'wpsg_mod_prepayment_qrcode')); ?>
-
+<?php echo wpsg_drawForm_Checkbox('wpsg_mod_prepayment_qrcode', __('QR-Code anzeigen', 'wpsg'), $this->get_option('wpsg_mod_prepayment_qrcode'), array('help' => 'wpsg_mod_prepayment_qrcode')); ?>
+<div id="wpsg_mod_prepayment_qrcode_country_layer" style="display: none;">
+ <?php echo wpsg_drawForm_Select('wpsg_mod_prepayment_qrcode_country', __('QR-Code für', 'wpsg'), Array(
+ wpsg_mod_prepayment::QRCODE_BOTH => __('Beide', 'wpsg'),
+ wpsg_mod_prepayment::QRCODE_EPC => __('EPC QR-Code', 'wpsg'),
+ wpsg_mod_prepayment::QRCODE_SWISS => __('Swiss QR-Code', 'wpsg')
+ ), $this->get_option('wpsg_mod_prepayment_qrcode_country'), array('help' => 'wpsg_mod_prepayment_qrcode_country')); ?>
+</div>
<?php echo wpsg_drawForm_Textarea('wpsg_mod_prepayment_hint', __('Hinweistext', 'wpsg'), $this->get_option('wpsg_mod_prepayment_hint'), array('help' => 'wpsg_mod_prepayment_hint')); ?>
<?php echo wpsg_drawForm_Input('wpsg_mod_prepayment_subject', __('Betreff für Überweisungen', 'wpsg'), $this->get_option('wpsg_mod_prepayment_subject'), array('help' => 'mod_prepayment_subject')); ?>
@@ -23,4 +29,34 @@
<?php echo wpsg_drawForm_Input('wpsg_mod_prepayment_kinhaber', __('Kontoinhaber', 'wpsg'), $this->get_option('wpsg_mod_prepayment_kinhaber'), array('help' => 'wpsg_mod_prepayment_kinhaber')); ?>
<?php echo wpsg_drawForm_Input('wpsg_mod_prepayment_bank', __('Bank', 'wpsg'), $this->get_option('wpsg_mod_prepayment_bank'), array('help' => 'wpsg_mod_prepayment_bank')); ?>
<?php echo wpsg_drawForm_Input('wpsg_mod_prepayment_iban', __('IBAN', 'wpsg'), $this->get_option('wpsg_mod_prepayment_iban'), array('help' => 'wpsg_mod_prepayment_iban')); ?>
-<?php echo wpsg_drawForm_Input('wpsg_mod_prepayment_swift', __('BIC-/SWIFT Code', 'wpsg'), $this->get_option('wpsg_mod_prepayment_swift'), array('help' => 'wpsg_mod_prepayment_swift')); ?> \ No newline at end of file
+<?php echo wpsg_drawForm_Input('wpsg_mod_prepayment_qriban', __('QR-IBAN', 'wpsg'), $this->get_option('wpsg_mod_prepayment_qriban'), array('help' => 'wpsg_mod_prepayment_qriban')); ?>
+<?php echo wpsg_drawForm_Input('wpsg_mod_prepayment_swift', __('BIC-/SWIFT Code', 'wpsg'), $this->get_option('wpsg_mod_prepayment_swift'), array('help' => 'wpsg_mod_prepayment_swift')); ?>
+<?php echo wpsg_drawForm_Input('wpsg_mod_prepayment_besr', __('BESR-ID', 'wpsg'), $this->get_option('wpsg_mod_prepayment_besr'), array('help' => 'wpsg_mod_prepayment_besr')); ?>
+
+<script>
+
+ document.addEventListener("DOMContentLoaded", function() {
+
+ var qrcodeAktiveCheckbox = document.getElementById('wpsg_mod_prepayment_qrcode');
+ var qrcodeSelectDiv = document.getElementById('wpsg_mod_prepayment_qrcode_country_layer');
+
+
+ function toggleDivVisibility(checkbox, div)
+ {
+
+ if (checkbox.checked) div.style.display = "block";
+ else div.style.display = "none";
+
+ }
+
+ // Event Listener für die Checkboxen
+ qrcodeAktiveCheckbox.addEventListener("change", function() {
+ toggleDivVisibility(qrcodeAktiveCheckbox, qrcodeSelectDiv);
+ });
+
+ // Überprüfen und Initialisieren des Anfangszustands der Checkboxen
+ toggleDivVisibility(qrcodeAktiveCheckbox, qrcodeSelectDiv);
+
+ });
+
+</script>