// Front page booking

if ($('.step_front').length) {
	$('#vehicle_yes').click(function() {
		$('#vehicle_info').show();
	});
	
	$('#vehicle_no').click(function() {
		$('#vehicle_info').hide();
	});
	
	$('#return').click(function() {		SubmitForm();	});
	$('#single').click(function() {		SubmitForm();	});

	$('#vehicle_type').change(function() {		SubmitForm();	});
	
	$('#Outbound_journey').change(function() {		SubmitForm();	});
	$('#Outbound_month').change(function() {		SubmitForm();	});
	
	$('#Return_journey').change(function() {		SubmitForm();	});
	$('#Return_month').change(function() {		SubmitForm();	});
	
	function setDate(tag, direction, date) {
		$('.'+direction+'_calendar .date.active').removeClass('active');
		tag.parent().addClass('active');
		$('#'+direction+'_date').val(date);
		if (direction == "Outbound") {
			var out = $('#Outbound_date').val().split('-');
			var ret = $('#Return_date').val().split('-');
			if (out[0]+out[1] == ret[0]+ret[1]) SubmitForm();
		}
		return false;
	}

} else {
	$('#amountcabins').change(function() { SubmitForm(); });
}