public async Task <IActionResult> GetSchoolYear(int id) { var grade = await gradeRepository.Get(id); if (grade == null) { return(NotFound(new { status = ResultStatus.STATUS_NOT_FOUND, message = "Không tìm thấy nghề nghiệp" })); } return(Ok(new { status = ResultStatus.STATUS_OK, data = grade })); }
public Grade GetGrade(string id) { try { var grade = _repository.Get(id); return(grade); } catch (Exception) { return(new Grade()); } }