$(function(){var $bookingPlace=$("#booking-form-place");$("#adminForm").detach().insertAfter($bookingPlace);$bookingPlace.remove();$("#event-type").change(function(){var $this=$(this);var roomsString=$this.find("option:selected").attr("data-rooms");if(roomsString){var rooms=roomsString.split("|");if(rooms.length){$("#room-select li").stop(true,true).slideUp(DEFAULT_ANIMATION_TIME);$("#room-select :checkbox").removeAttr("checked").change();var i=0;while(i<rooms.length){$("#"+rooms[i]).closest("li").stop(true,true).slideDown(DEFAULT_ANIMATION_TIME);i++}setTimeout(function(){$("#room-select li:visible :checkbox").eq(0).click().change()},DEFAULT_ANIMATION_TIME)}}}).change();$("#room-select :checkbox").bind("click change",function(){var $this=$(this);var $relation=$("#"+$this.attr("data-rel"));if($relation.length){if($this.get(0).checked){$relation.show();$relation.find("li:eq(0)").click()}else{$relation.hide();$relation.find(":radio").removeAttr("checked")}}}).eq(0).change();$(".Scheme").each(function(){var $list=$(this).find("li");$list.click(function(){var $this=$(this);$this.addClass("Active").siblings(".Active").removeClass("Active").find(":radio").removeAttr("checked");$this.find(":radio").attr("checked","checked")})});$("#sended-popup").detach().appendTo($("#body")).fadeIn(DEFAULT_ANIMATION_TIME).delay(7000).fadeOut(DEFAULT_ANIMATION_TIME)});
