@Test public void testHandleCreateReceived() throws Exception { CreateReceivedFeeCommand command = new CreateReceivedFeeCommand( feeTransactionId, receivedFeeId, FeeStatus.PENDING, sellCommissionAmount, FeeType.RECEIVE_COIN, BusinessType.TRADE_EXECUTED, tradeTime, dueDate, portfolioId.toString(), userId.toString(), orderTransactionId.toString(), receivedSource); receivedFixture.given() .when(command) .expectEvents( new ReceivedFeeCreatedEvent( receivedFeeId, FeeStatus.PENDING, sellCommissionAmount, FeeType.RECEIVE_COIN, tradeTime, dueDate, portfolioId.toString(), userId.toString(), BusinessType.TRADE_EXECUTED, orderTransactionId.toString(), receivedSource)); }
@CommandHandler public void handleCreateReceived(CreateReceivedFeeCommand command) { receivedFeeRepository.add(new ReceivedFee( command.getFeeId(), command.getFeeStatus(), command.getAmount(), command.getFeeType(), command.getDueDate(), command.getCreatedTime(), command.getPortfolioId(), command.getUserId(), command.getBusinessType(), command.getBusinessReferenceId(), command.getReceivedSource() )); }
ReceivedPaidFeeCommandHandler { @CommandHandler public void handleCreateReceived(CreateReceivedFeeCommand command) { receivedFeeRepository.add(new ReceivedFee( command.getFeeId(), command.getFeeStatus(), command.getAmount(), command.getFeeType(), command.getDueDate(), command.getCreatedTime(), command.getPortfolioId(), command.getUserId(), command.getBusinessType(), command.getBusinessReferenceId(), command.getReceivedSource() )); } }
ReceivedPaidFeeCommandHandler { @CommandHandler public void handleCreateReceived(CreateReceivedFeeCommand command) { receivedFeeRepository.add(new ReceivedFee( command.getFeeId(), command.getFeeStatus(), command.getAmount(), command.getFeeType(), command.getDueDate(), command.getCreatedTime(), command.getPortfolioId(), command.getUserId(), command.getBusinessType(), command.getBusinessReferenceId(), command.getReceivedSource() )); }  }
ReceivedPaidFeeCommandHandler { @CommandHandler public void handleCreateReceived(CreateReceivedFeeCommand command) { receivedFeeRepository.add(new ReceivedFee( command.getFeeId(), command.getFeeStatus(), command.getAmount(), command.getFeeType(), command.getDueDate(), command.getCreatedTime(), command.getPortfolioId(), command.getUserId(), command.getBusinessType(), command.getBusinessReferenceId(), command.getReceivedSource() )); }  @CommandHandler void handleCreateReceived(CreateReceivedFeeCommand command); @CommandHandler void handleConfirmReceived(ConfirmReceivedFeeCommand command); @CommandHandler void handleOffsetReceived(OffsetReceivedFeeCommand command); @CommandHandler void handleCancelReceived(CancelReceivedFeeCommand command); @CommandHandler void handleCreatePaid(CreatePaidFeeCommand command); @CommandHandler void handleConfirmPaid(ConfirmPaidFeeCommand command); @CommandHandler void handleOffsetPaid(OffsetPaidFeeCommand command); @CommandHandler void handleCancelPaid(CancelPaidFeeCommand command); @Resource(name = "receivedFeeRepository") void setReceivedFeeRepository(Repository<ReceivedFee> receivedFeeRepository); @Resource(name = "paidFeeRepository") void setPaidFeeRepository(Repository<PaidFee> paidFeeRepository); }
ReceivedPaidFeeCommandHandler { @CommandHandler public void handleCreateReceived(CreateReceivedFeeCommand command) { receivedFeeRepository.add(new ReceivedFee( command.getFeeId(), command.getFeeStatus(), command.getAmount(), command.getFeeType(), command.getDueDate(), command.getCreatedTime(), command.getPortfolioId(), command.getUserId(), command.getBusinessType(), command.getBusinessReferenceId(), command.getReceivedSource() )); }  @CommandHandler void handleCreateReceived(CreateReceivedFeeCommand command); @CommandHandler void handleConfirmReceived(ConfirmReceivedFeeCommand command); @CommandHandler void handleOffsetReceived(OffsetReceivedFeeCommand command); @CommandHandler void handleCancelReceived(CancelReceivedFeeCommand command); @CommandHandler void handleCreatePaid(CreatePaidFeeCommand command); @CommandHandler void handleConfirmPaid(ConfirmPaidFeeCommand command); @CommandHandler void handleOffsetPaid(OffsetPaidFeeCommand command); @CommandHandler void handleCancelPaid(CancelPaidFeeCommand command); @Resource(name = "receivedFeeRepository") void setReceivedFeeRepository(Repository<ReceivedFee> receivedFeeRepository); @Resource(name = "paidFeeRepository") void setPaidFeeRepository(Repository<PaidFee> paidFeeRepository);  }