function checkVal(B){chOk=true;for(obj in B){if($("#"+B[obj]).attr("tagName")=="SELECT"){if($("#"+B[obj]).val()==""){chOk=false}}else{if($("#"+B[obj]).attr("tagName")=="INPUT"){if($("#"+B[obj]).attr("type")=="checkbox"){if(!$("#"+B[obj]).attr("checked")){chOk=false}}else{if($("#"+B[obj]).attr("type")=="text"){if($("#"+B[obj]).val()==""){chOk=false}}else{if($("#"+B[obj]).attr("type")=="password"){if($("#"+B[obj]).val().length<6){chOk=false}}else{chOk=false}}}}else{chOk=false}}}var A;if(A=$("#"+B[0]).parents().get(0)){if(chOk){$(".icon",A).attr("src",contextPath+"/img_rewirproduct/icon/checked.gif")}else{$(".icon",A).attr("src",contextPath+"/img_rewirproduct/icon/edit.gif")}}}$(document).ready(function(){$("#rewirnatur:not(:checked)").map(function(){var B;if(B=$(this).parents().get(0)){$("#rwCont,#rwNat",B).hide()}});$(".rewirnaturHide input,.rewirnaturHide label").click(function(){$("#rwNat,#rwCont").fadeOut("slow")});$("#rewirnaturShow input,#rewirnaturShow label").click(function(){$("#rwNat,#rwCont").fadeIn("slow")});$("#rc_rewirnatur:not(:checked)").map(function(){var B;if(B=$(this).parents().get(0)){$("#rc_rwNat,#rc_rwCont",B).hide()}});$(".rc_rewirnaturHide input,.rc_rewirnaturHide label").click(function(){$("#rc_rwNat,#rc_rwCont").fadeOut("slow")});$("#rc_rewirnaturShow input,#rc_rewirnaturShow label").click(function(){$("#rc_rwNat,#rc_rwCont").fadeIn("slow")});$(".hidden").hide();$(".slideable:not(:has(.invalidInput), .on)").hide();$("#zugangsdaten").hide();$(".neukundeSlide").hide();$(".bestandskundeSlide").hide();$(".neukunde").click(function(){$("#blockNeukunde").attr("checked",true).parent().nextAll("div.slideable").show();$("#zugangsdaten").show();$(".neukundeSlide").slideDown();$(".bestandskundeSlide").slideUp()});$(".bestandskunde").click(function(){$("#zugangsdaten").show();$(".bestandskundeSlide").slideDown();$(".neukundeSlide").slideUp()});$("#blockLogin").click(function(){$("#loginBestand .slideable").slideDown();$("#regBestand .slideable").slideUp()});$("#blockRegistrierung").click(function(){$("#regBestand .slideable").slideDown();$("#loginBestand .slideable").slideUp()});$("#zugangsdaten:has(.invalidInput)").show();$(".bestandskundeSlide:has(.invalidInput)").slideDown();$(".neukundeSlide:has(.invalidInput)").slideDown();var A;$(".slideable:not(.on),.slideOnOff").hide();A=$(".slide:checked").parents().get(1);if(A=$(".slide:checked").parents().get(1)){$(".slideable",A).show()}if(A=$(".slideOn:checked").parents().get(1)){$(".slideOnOff",A).show()}$(".required").map(function(){var B;if(B=$(this).parents().get(0)){$(B).show()}});$(".slide").click(function(){var C,B;B=$(this).parents().get(1);if(C=$(this).parents(".sliderGroup").get(0)){$(".slideable:visible",C).not($(".slideable:visible",B)).slideUp("slow")}if(B){$(".slideable:hidden",B).slideDown("slow")}});$(".slideOn").click(function(){var B;if(B=$(this).parents().get(1)){$(".slideOnOff",B).slideDown("slow")}});$(".slideOff").click(function(){var B;if(B=$(this).parents().get(1)){$(".slideOnOff",B).slideUp("slow")}});$(".typeText").map(function(){checkVal([$(this).attr("id")])});$(".typeCheckbox, .typeSelect").map(function(){checkVal([$(this).attr("id")])});$(".typeText, .typeSelect").keyup(function(){checkVal([$(this).attr("id")])});$(".typeCheckbox, .typeSelect").click(function(){checkVal([$(this).attr("id")])});$(".typeText").blur(function(){checkVal([$(this).attr("id")])});$(".invalidInput .icon").attr("src",contextPath+"/img_rewirproduct/icon/error.gif")});function clearPrefill(B,A){if(B.value==A){B.value=""}}function addPrefill(B,A){if(B.value==""){B.value=A}};
