/* wenn man zum checkout geht, eine EU-TaxVat eingegeben hat (außer DE), dann wieder zurückgeht und die TaxVat löscht, speichert Magento die Änderung nicht. Mit diesem Handler wird sichergestellt, dass die Löschung gespeichert wird. "Keine" ist keine gültige TaxVat. TaxVat = USt-IdNr. */
function checkEmptyTaxVat(event) {
	if($('billing:taxvat').getValue() == "") {
		$('billing:taxvat').setValue('keine');
	}
}
	
document.observe("dom:loaded", function() {
	$('nav').insert({top:'<li class="level0 nav-"><a href="/"><span>Startseite</span></a></li>'});

	// ust-id-handling
	if($('billing:taxvat')) {
		$('billing:taxvat').observe('change', checkEmptyTaxVat);
	}

	// rechnungsadresse = versandadresse standard
	if($('billing:use_for_shipping_yes') && $('billing:email') && $('billing:email').value == "") {
		$('billing:use_for_shipping_yes').checked = true;
	}

	// qty ist default 1 
	if($('qty') && $('qty').getValue() == "") {
		$('qty').setValue('1');
	}
});
