diff --git a/src/main/java/au/com/royalpay/payment/manage/bdprize/core/impls/BDPrizeServiceImpl.java b/src/main/java/au/com/royalpay/payment/manage/bdprize/core/impls/BDPrizeServiceImpl.java index 8670ec2f6..e5624ca50 100644 --- a/src/main/java/au/com/royalpay/payment/manage/bdprize/core/impls/BDPrizeServiceImpl.java +++ b/src/main/java/au/com/royalpay/payment/manage/bdprize/core/impls/BDPrizeServiceImpl.java @@ -121,7 +121,7 @@ public class BDPrizeServiceImpl implements BDPrizeService { List trades = transactionMapper.listTransactionsForBDPrize(now.get(Calendar.YEAR), now.get(Calendar.MONTH) + 1, channel); List clientsWithBDAway = clientBDMapper.clientsWithBDAway(); List rateConfig = getRateConfig(); - BDPrizeCalculator calculator = new BDPrizeCalculatorDefaultImpl(trades, now.getTime()).clientBDMapper(clientBDMapper) + BDPrizeCalculator calculator = new BDPrizeCalculatorDefaultImpl(trades, now.getTime()).clientBDMapper(clientBDMapper,transactionMapper) .clientsWithBDAwayDeterminor(new DefaultClientWithBDAwayDeterminor(clientsWithBDAway)).rateConfig(rateConfig); calculator.calculate(); List report = calculator.getReport(now.get(Calendar.YEAR),now.get(Calendar.MONTH) + 1); diff --git a/src/main/java/au/com/royalpay/payment/manage/bdprize/support/impls/BDPrizeCalculatorDefaultImpl.java b/src/main/java/au/com/royalpay/payment/manage/bdprize/support/impls/BDPrizeCalculatorDefaultImpl.java index be9df684f..08f842b21 100644 --- a/src/main/java/au/com/royalpay/payment/manage/bdprize/support/impls/BDPrizeCalculatorDefaultImpl.java +++ b/src/main/java/au/com/royalpay/payment/manage/bdprize/support/impls/BDPrizeCalculatorDefaultImpl.java @@ -38,8 +38,9 @@ public class BDPrizeCalculatorDefaultImpl implements BDPrizeCalculator { this.month = month; } - public BDPrizeCalculatorDefaultImpl clientBDMapper(ClientBDMapper clientBDMapper) { + public BDPrizeCalculatorDefaultImpl clientBDMapper(ClientBDMapper clientBDMapper,TransactionMapper transactionMapper) { this.clientBDMapper = clientBDMapper; + this.transactionMapper = transactionMapper; return this; }