Inheritance: IDomainEvent
        public void When(AccountOpened @event)
        {
            var accountModel = new AccountModel
            {
                AccountNumber = @event.AccountNumber.Id,
                ClientId = @event.ClientId.Id,
                AccountStatusId = (int)AccountStatusType.Active,
                Recency = Recency.UpToDate().Value
            };

            repository.Add(accountModel);
        }
 public void When(AccountOpened @event)
 {
     var clientModel = FetchModel(@event.ClientId);
     clientModel.AccountNumber = @event.AccountNumber.Id;
 }
Beispiel #3
0
 void IHandleAccountStateTransitions.When(AccountOpened @event)
 {
     Identity = @event.AccountNumber;
     clientId = @event.ClientId;
 }
Beispiel #4
0
 void IAccountState.When(AccountOpened @event)
 {
     Identity = @event.AccountNumber;
     clientId = @event.ClientId;
 }