implement date range validation