Exemplo n.º 1
0
 public Task <AsyncTaskResult> HandleAsync(TransferOutPreparationConfirmedEvent evnt)
 {
     return(_commandService.SendAsync(new AddTransactionPreparationCommand(
                                          evnt.TransactionInfo.TargetAccountId,
                                          evnt.AggregateRootId,
                                          TransactionType.TransferTransaction,
                                          PreparationType.CreditPreparation,
                                          evnt.TransactionInfo.Amount)));
 }
Exemplo n.º 2
0
        private void Handle(TransferOutPreparationConfirmedEvent @event)
        {
            this.State.TransferOutPreparationConfirmed   = true;
            this.State.TransferOutPreparationConfirmedAt = @event.UTCTimestamp;

            if (this.State.TransferInPreparationConfirmed)
            {
                this.State.Status = TransactionStatus.PreparationCompleted;
            }
        }
 public async Task HandleAsync(TransferOutPreparationConfirmedEvent evnt)
 {
     await _commandService.SendAsync(new AddTransactionPreparationCommand(
                                         evnt.TransactionInfo.TargetAccountId,
                                         evnt.AggregateRootId,
                                         TransactionType.TransferTransaction,
                                         PreparationType.CreditPreparation,
                                         evnt.TransactionInfo.Amount)
     {
         Id    = evnt.Id,
         Items = evnt.Items
     });
 }
Exemplo n.º 4
0
 public Task <AsyncTaskResult> HandleAsync(TransferOutPreparationConfirmedEvent evnt)
 {
     Console.WriteLine("预转出确认成功,交易ID:{0},账户:{1}", evnt.AggregateRootId, evnt.TransactionInfo.SourceAccountId);
     return(Task.FromResult(AsyncTaskResult.Success));
 }
Exemplo n.º 5
0
 public Task HandleAsync(TransferOutPreparationConfirmedEvent evnt)
 {
     _logger.InfoFormat("预转出确认成功,交易ID:{0},账户:{1}", evnt.AggregateRootId, evnt.TransactionInfo.SourceAccountId);
     return(Task.CompletedTask);
 }