Пример #1
0
 public override GetAttorneyInfoResult GetExceptionResult(Query message, Exception ex)
 {
     Log.Error(ex, ex.Message);
     message.Result.SystemInfo.Status = Mapper.Map <StatusInfo>(_systemInfoHelper.StatusInfoFail(ex));
     _systemInfoHelper.SaveAnswer(Mapper.Map <SystemInfoDto>(message.Result.SystemInfo), message.LogAction);
     return(message.Result);
 }
Пример #2
0
 public override CustomerPatentValidityResponce GetExceptionResult(Query message, Exception ex)
 {
     Log.Error(ex, ex.Message);
     message.Responce.StatusInfo = Mapper.Map <StatusInfo>(_systemInfoHelper.StatusInfoFail(ex));
     _systemInfoHelper.SaveAnswer(Mapper.Map <SystemInfoDto>(message.Responce), message.LogAction);
     return(message.Responce);
 }
Пример #3
0
 public override CheckPatentStatementResult GetExceptionResult(Query message, Exception ex)
 {
     Log.Error(ex, ex.Message);
     message.Result.IsSuccess         = false;
     message.Result.StatusRu          = "Ошибка: " + Environment.NewLine + ex.Message;
     message.Result.SystemInfo.Status = Mapper.Map <StatusInfo>(_systemInfoHelper.StatusInfoFail(ex));
     _systemInfoHelper.SaveAnswer(Mapper.Map <SystemInfoDto>(message.Result.SystemInfo), message.LogAction);
     return(message.Result);
 }
Пример #4
0
            public override GetBtBasePatentListResult GetExceptionResult(Query message, Exception ex)
            {
                Log.Error(ex, ex.Message);
                message.Result.List = null;
                var statusFail = _systemInfoHelper.StatusInfoFail(ex);

                message.Result.SystemInfo.Status = Mapper.Map <StatusInfo>(statusFail);
                _systemInfoHelper.SaveAnswer(Mapper.Map <SystemInfoDto>(message.Result.SystemInfo), message.LogAction);
                return(message.Result);
            }
Пример #5
0
 public override MessageSendResult GetExceptionResult(Command message, Exception ex)
 {
     Log.Error(ex, ex.Message);
     message.Result.SystemInfo.Status = Mapper.Map <StatusInfo>(_systemInfoHelper.StatusInfoFail(ex));
     _systemInfoHelper.SaveAnswer(Mapper.Map <SystemInfoDto>(message.Result.SystemInfo), message.LogAction);
     message.Result.DocumentNumber = null;
     message.Result.DocumentDate   = null;
     message.Result.DocumentUID    = -1;
     return(message.Result);
 }
Пример #6
0
            public override RequisitionSendResult GetExceptionResult(Command message, Exception ex)
            {
                var errorMessage = ex.InnerException?.Message ?? ex.Message;

                Log.Error(ex.InnerException ?? ex, errorMessage);
                message.Result.SystemInfo.Status = Mapper.Map <StatusInfo>(_systemInfoHelper.StatusInfoFail(ex));
                _systemInfoHelper.SaveAnswer(Mapper.Map <SystemInfoDto>(message.Result.SystemInfo), message.LogAction);
                message.Result.RequisitionStatus = -1;
                message.Result.DocumentID        = -1;
                message.Result.DocumentNumber    = string.Empty;
                return(message.Result);
            }