public void Handle(Commands.ChangeType command) { var account = _uow.R <Account>().Get(command.AccountId); var accountType = _uow.R <Configuration.AccountType.AccountType>().Get(command.TypeId); account.ChangeType(accountType); }
public async Task Handle(Commands.ChangeType command, IMessageHandlerContext ctx) { var account = await _uow.For <Account>().Get(command.AccountId); var accountType = await _uow.For <Configuration.AccountType.AccountType>().Get(command.TypeId); account.ChangeType(accountType); }