public ControllerResponse <IEnumerable <DoctorDto> > GetAllDoctorsByProfession(int professionId) { if (!professionId.ValidationId()) { return(ControllerResponse <IEnumerable <DoctorDto> > .Warning( "Профессия врача указана некорректно или произошел сбой, повторите запрос")); } return(ControllerResponse <IEnumerable <DoctorDto> > .Ok(_commonServices .GetDoctorsByProfession(professionId).Select(d => new DoctorDto(d)))); }