summaryrefslogtreecommitdiff
path: root/views/mods/mod_prepayment/settings_edit.phtml
blob: 238b14f2bd8c388822394866ba715ff6c29e1045 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
<?php 

	/**
	 * Templatedatei für die Einstellungen des Vorkasse Moduls
	 */

?>

<?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 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 => __('Girocode', 'wpsg'),
					wpsg_mod_prepayment::QRCODE_SWISS => __('QR-Rechnung', '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')); ?>

<br />
<?php echo wpsg_drawForm_Input('wpsg_mod_prepayment_gebuehr', __('Gebühr/Rabatt', 'wpsg'), wpsg_ff($this->get_option('wpsg_mod_prepayment_gebuehr'), true), array('help' => 'wpsg_mod_prepayment_gebuehr','unit' => $this->get_option('wpsg_currency').' / %')); ?>
<?php echo wpsg_drawForm_Select('wpsg_mod_prepayment_mwst', __('Mehrwertsteuersatz', 'wpsg'), wpsg_tax_groups(), $this->get_option('wpsg_mod_prepayment_mwst'), array('help' => 'wpsg_mod_prepayment_mwst')); ?>
<?php echo wpsg_drawForm_Checkbox('wpsg_mod_prepayment_mwstland', __('Keine MwSt. wenn Land steuerfrei', 'wpsg'), $this->get_option('wpsg_mod_prepayment_mwstland'), array('help' => 'wpsg_mod_prepayment_mwstland')); ?>

<br />
<?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')); ?>
<?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_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>