コード例 #1
0
 public DataModel.Response.FindItemReponse <DataModel.Model.EducationModel> FindByID(string id)
 {
     try
     {
         IEducationRepository educationRepository = RepositoryClassFactory.GetInstance().GetEducationRepository();
         Education            education           = educationRepository.FindByID(id);
         var _education = MapperUtil.CreateMapper().Mapper.Map <Education, EducationModel>(education);
         return(new FindItemReponse <EducationModel>
         {
             Item = _education,
             ErrorCode = (int)ErrorCode.None,
             Message = string.Empty
         });
     }
     catch (Exception ex)
     {
         return(new FindItemReponse <EducationModel>
         {
             ErrorCode = (int)ErrorCode.Error,
             Message = ex.Message
         });
     }
 }