autoclose datepicker