public string ChangeInterview(string infomation) { var log = new TmpLogServiceInfo { Time = DateTime.Now, Description = infomation, CallType = (int)CallType.UpdateChangeInterview, }; try { var input = JsonConvert.DeserializeObject <ChangeInterview>(infomation); var result = CheckInputChangeInterview(input); if (result.Code == 0) { CallHistoryRepository.UpdateChangeInterview(input.ContactId, input.StatusInterviewId, input.AppointmentDate, input.Notes, input.TeacherTypeId, input.TimeSlotId); //var entity = new AppointmentInterviewInfo // { // ContactId = input.ContactId, // } //AppointmentInterviewRepository.Create(); result.Code = 0; } var output = JsonConvert.SerializeObject(result); log.Description = result.Description + "_" + infomation; log.Status = result.Code; TmpLogServiceRepository.Create(log); return(output); } catch (Exception ex) { var result = new Result(); result.Code = 1; result.Description = "Hệ thống hiện tại bị lỗi, cập nhật thay đổi trạng thái phỏng vấn không thành công" + infomation; var output = JsonConvert.SerializeObject(result); log.Description = result.Description + "_" + infomation; log.Status = result.Code; TmpLogServiceRepository.Create(log); return(output); } }