Example #1
0
        public IEnumerable <Appointment> GetAppointmentsFutureMedic(string medicId)
        {
            Guid medicIdGuid = Guid.Empty;

            if (!Guid.TryParse(medicId, out medicIdGuid))
            {
                throw new Exception("Invalid Guid Format");
            }
            var medic = medicRepository.GetMedicByUserId(medicIdGuid);

            if (medic == null)
            {
                throw new EntityNotFoundException(medicIdGuid);
            }

            return(appointmentRepository.GetAppointmentsFutureMedic(medicIdGuid));
        }