示例#1
0
        public async Task <ResponceModel> Get(int id)
        {
            try
            {
                var entry = await _entryService.Get(id);

                return(new ResponceModel(200, "OK", entry, null));
            }
            catch (Exception ex)
            {
                await _logService.Add(new SystemLog()
                {
                    Content = ex.Message, CreateDate = DateTime.Now, UserId = 0, EntityName = _entryService.GetType().Name
                });

                return(new ResponceModel(500, "ERROR", null, new string[] { "Veri getirilirken bir hata oluştu." }));
            }
        }
示例#2
0
 protected override void ExecuteTest()
 {
     try
     {
         var service = new EntryService(userEntryProvider);
         actualModel = service.Get(EntryRequest.Create(suppliedLocalEducationAgencyId, suppliedSchoolId));
     }
     catch (Exception ex)
     {
         actualException = ex;
     }
 }
示例#3
0
 protected override void ExecuteTest()
 {
     var service = new EntryService(userEntryProvider);
     actualUrl = service.Get(EntryRequest.Create(suppliedLocalEducationAgencyId, null));
 }