added preselected time logic