public void Execute(ApproveMainOrderCommand command)
        {
            _log.InfoFormat("Execute {1} - Command Id {0} ", command.CommandId, command.GetType().ToString());
            try
            {

                if (!DocumentExists(command.DocumentId))
                    return;
                ApproveDocument(command.DocumentId);
               
            }
            catch (Exception ex)
            {
                _log.ErrorFormat("Error Execute {1} - Command Id {0} ", command.CommandId, command.GetType().ToString());
                _log.Error("ApproveMainOrderCommandHandler exception", ex);
                throw;
            }
        }
Пример #2
0
 public void Handle(ApproveMainOrderCommand command)
 {
     var order = GetOrder();
     order.ProcessingStatus = ProcessingStatus.Approved;
 }