/// <summary>
/// Processes the selection.
/// </summary>
/// <param name="person">The person.</param>
/// <param name="schedule">The schedule.</param>
/// <returns></returns>
protected bool ProcessSelection( CheckInPerson person, CheckInSchedule schedule )
{
if ( person != null )
{
if ( !ProcessSelection(
maWarning,
() => person.SelectedGroupTypes( schedule )
.SelectMany( t => t.SelectedGroups( schedule )
.SelectMany( g => g.SelectedLocations( schedule )
.SelectMany( l => l.ValidSchedules( schedule ) ) ) )
.Count() <= 0,
"<p>Sorry, based on your selection, there are currently not any available times that can be checked into.</p>",
CurrentCheckInState.CheckInType.TypeOfCheckin == TypeOfCheckin.Family ) )
{
ClearSelection();
}
else
{
return true;
}
}
return false;
}