예제 #1
0
        public DeletePatientDataResponse DeletePatient(DeletePatientDataRequest request)
        {
            DeletePatientDataResponse response = null;

            try
            {
                response = new DeletePatientDataResponse();

                IPatientRepository patientRepo = Factory.GetRepository(request, RepositoryType.Patient);
                patientRepo.Delete(request);
                response.DeletedId = request.Id;
                response.Success   = true;
                return(response);
            }
            catch (Exception ex) { throw ex; }
        }
예제 #2
0
        public void DeletePatient()
        {
            PatientDataManager pm = new PatientDataManager {
                Factory = new PatientRepositoryFactory()
            };
            DeletePatientDataRequest request = new DeletePatientDataRequest
            {
                Version        = 1.0,
                UserId         = "000000000000000000000000",
                ContractNumber = "InHealth001",
                Context        = "NG",
                Id             = "5325db1ad6a4850adcbba83a"
            };
            DeletePatientDataResponse response = pm.DeletePatient(request);

            Assert.IsNotNull(response);
        }
예제 #3
0
        public DeletePatientDataResponse Delete(DeletePatientDataRequest request)
        {
            DeletePatientDataResponse response = new DeletePatientDataResponse();

            try
            {
                if (string.IsNullOrEmpty(request.UserId))
                {
                    throw new UnauthorizedAccessException("PatientDD:PatientDelete()::Unauthorized Access");
                }

                response         = PatientManager.DeletePatient(request);
                response.Version = request.Version;
            }
            catch (Exception ex)
            {
                CommonFormatterUtil.FormatExceptionResponse(response, base.Response, ex);

                string aseProcessID = ConfigurationManager.AppSettings.Get("ASEProcessID") ?? "0";
                Helpers.LogException(int.Parse(aseProcessID), ex);
            }
            return(response);
        }
예제 #4
0
 DeletePatientDataResponse IPatientDataManager.DeletePatient(DeletePatientDataRequest request)
 {
     throw new NotImplementedException();
 }