コード例 #1
0
        public async Task <ExameViewModel> AddExameAsync(ExameViewModel exameVM)
        {
            try
            {
                Exame objExame = exameVM.ConvertExameViewModel(exameVM);
                await _unitOfWork.GenericRepository <Exame>().AddAsync(objExame);

                _unitOfWork.Save();
            }
            catch (Exception ex)
            {
                return(null);
            }
            return(exameVM);
        }