FINERACT-2070: Use generic product names
This commit is contained in:
+1
-1
@@ -20,7 +20,7 @@ package org.apache.fineract.test.data.loanproduct;
|
||||
|
||||
public enum DefaultLoanProduct implements LoanProduct {
|
||||
|
||||
PIN30, PIN30_DUE_DATE, PIN30_INTEREST_FLAT, PIN30_INTEREST_DECLINING_BALANCE_PERIOD_SAME_AS_PAYMENT, PIN30_INTEREST_DECLINING_BALANCE_PERIOD_DAILY, PIN30_1MONTH_INTEREST_DECLINING_BALANCE_DAILY_RECALCULATION_COMPOUNDING_MONTHLY, PIN30_INTEREST_DECLINING_BALANCE_DAILY_RECALCULATION_COMPOUNDING_NONE, PIN30_INTEREST_DECLINING_BALANCE_DAILY_RECALCULATION_COMPOUNDING_NONE_RESCHEDULE_REDUCE_NR_INST, PIN30_INTEREST_DECLINING_BALANCE_DAILY_RECALCULATION_COMPOUNDING_NONE_RESCHEDULE_RESCH_NEXT_REP, PIN30_INTEREST_DECLINING_BALANCE_DAILY_RECALCULATION_SAME_AS_REPAYMENT_COMPOUNDING_NONE, PIN30_INTEREST_DECLINING_BALANCE_SAR_RECALCULATION_SAME_AS_REPAYMENT_COMPOUNDING_NONE_MULTIDISB, PIN30_PAYMENT_STRATEGY_DUE_IN_ADVANCE, PIN30_PAYMENT_STRATEGY_DUE_IN_ADVANCE_INTEREST_FLAT, PIN30_PAYMENT_STRATEGY_DUE_IN_ADVANCE_PENALTY_INTEREST_PRINCIPAL_FEE, PIN30_PAYMENT_STRATEGY_DUE_IN_ADVANCE_PENALTY_INTEREST_PRINCIPAL_FEE_INTEREST_FLAT, PIN30_INTEREST_FLAT_OVERDUE_FROM_AMOUNT, PIN30_INTEREST_FLAT_OVERDUE_FROM_AMOUNT_INTEREST, PIN4_DOWNPAYMENT, PIN4_DOWNPAYMENT_AUTO, PIN4_DOWNPAYMENT_AUTO_ADVANCED_PAYMENT_ALLOCATION, PIN4_DOWNPAYMENT_ADVANCED_PAYMENT_ALLOCATION, PIN4_DOWNPAYMENT_INTEREST, PIN4_DOWNPAYMENT_INTEREST_AUTO, PIN4_DOWNPAYMENT_ADV_PMT_ALLOC_PROGRESSIVE_LOAN_SCHEDULE_HORIZONTAL, PIN4_DOWNPAYMENT_ADV_PMT_ALLOC_PROGRESSIVE_LOAN_SCHEDULE_VERTICAL, PIN4_DOWNPAYMENT_ADV_PMT_ALLOC_PROGRESSIVE_LOAN_SCHEDULE_HORIZONTAL_INSTALLMENT_LEVEL_DELINQUENCY, PIN4_DOWNPAYMENT_ADV_PMT_ALLOC_PROG_SCHEDULE_HOR_INST_LVL_DELINQUENCY_CREDIT_ALLOCATION, PIN4_DOWNPAYMENT_ADV_PMT_ALLOC_FIXED_LENGTH;
|
||||
LP1, LP1_DUE_DATE, LP1_INTEREST_FLAT, LP1_INTEREST_DECLINING_BALANCE_PERIOD_SAME_AS_PAYMENT, LP1_INTEREST_DECLINING_BALANCE_PERIOD_DAILY, LP1_1MONTH_INTEREST_DECLINING_BALANCE_DAILY_RECALCULATION_COMPOUNDING_MONTHLY, LP1_INTEREST_DECLINING_BALANCE_DAILY_RECALCULATION_COMPOUNDING_NONE, LP1_INTEREST_DECLINING_BALANCE_DAILY_RECALCULATION_COMPOUNDING_NONE_RESCHEDULE_REDUCE_NR_INST, LP1_INTEREST_DECLINING_BALANCE_DAILY_RECALCULATION_COMPOUNDING_NONE_RESCHEDULE_RESCH_NEXT_REP, LP1_INTEREST_DECLINING_BALANCE_DAILY_RECALCULATION_SAME_AS_REPAYMENT_COMPOUNDING_NONE, LP1_INTEREST_DECLINING_BALANCE_SAR_RECALCULATION_SAME_AS_REPAYMENT_COMPOUNDING_NONE_MULTIDISB, LP1_PAYMENT_STRATEGY_DUE_IN_ADVANCE, LP1_PAYMENT_STRATEGY_DUE_IN_ADVANCE_INTEREST_FLAT, LP1_PAYMENT_STRATEGY_DUE_IN_ADVANCE_PENALTY_INTEREST_PRINCIPAL_FEE, LP1_PAYMENT_STRATEGY_DUE_IN_ADVANCE_PENALTY_INTEREST_PRINCIPAL_FEE_INTEREST_FLAT, LP1_INTEREST_FLAT_OVERDUE_FROM_AMOUNT, LP1_INTEREST_FLAT_OVERDUE_FROM_AMOUNT_INTEREST, LP2_DOWNPAYMENT, LP2_DOWNPAYMENT_AUTO, LP2_DOWNPAYMENT_AUTO_ADVANCED_PAYMENT_ALLOCATION, LP2_DOWNPAYMENT_ADVANCED_PAYMENT_ALLOCATION, LP2_DOWNPAYMENT_INTEREST, LP2_DOWNPAYMENT_INTEREST_AUTO, LP2_DOWNPAYMENT_ADV_PMT_ALLOC_PROGRESSIVE_LOAN_SCHEDULE_HORIZONTAL, LP2_DOWNPAYMENT_ADV_PMT_ALLOC_PROGRESSIVE_LOAN_SCHEDULE_VERTICAL, LP2_DOWNPAYMENT_ADV_PMT_ALLOC_PROGRESSIVE_LOAN_SCHEDULE_HORIZONTAL_INSTALLMENT_LEVEL_DELINQUENCY, LP2_DOWNPAYMENT_ADV_PMT_ALLOC_PROG_SCHEDULE_HOR_INST_LVL_DELINQUENCY_CREDIT_ALLOCATION, LP2_DOWNPAYMENT_ADV_PMT_ALLOC_FIXED_LENGTH;
|
||||
|
||||
@Override
|
||||
public String getName() {
|
||||
|
||||
+21
-21
@@ -58,23 +58,23 @@ public class LoanProductsRequestFactory {
|
||||
private final PaymentTypeResolver paymentTypeResolver;
|
||||
private final AccountTypeResolver accountTypeResolver;
|
||||
|
||||
public static final String NAME_PREFIX = "Pin30-";
|
||||
public static final String NAME_PREFIX_PIN4 = "Pin4-";
|
||||
public static final String NAME_PREFIX_INTEREST_FLAT = "Pin30InterestFlat-";
|
||||
public static final String NAME_PREFIX_INTEREST_FLAT_PIN4 = "Pin4InterestFlat-";
|
||||
public static final String NAME_PREFIX_INTEREST_DECLINING = "Pin30InterestDeclining-";
|
||||
public static final String NAME_PREFIX_INTEREST_DECLINING_RECALCULATION = "Pin30InterestDecliningRecalculation-";
|
||||
public static final String NAME_PREFIX = "LP1-";
|
||||
public static final String NAME_PREFIX_LP2 = "LP2-";
|
||||
public static final String NAME_PREFIX_INTEREST_FLAT = "LP1InterestFlat-";
|
||||
public static final String NAME_PREFIX_INTEREST_FLAT_LP2 = "LP2InterestFlat-";
|
||||
public static final String NAME_PREFIX_INTEREST_DECLINING = "LP1InterestDeclining-";
|
||||
public static final String NAME_PREFIX_INTEREST_DECLINING_RECALCULATION = "LP1InterestDecliningRecalculation-";
|
||||
public static final String SHORT_NAME_PREFIX = "p";
|
||||
public static final String SHORT_NAME_PREFIX_INTEREST = "i";
|
||||
public static final String DATE_FORMAT = "dd MMMM yyyy";
|
||||
public static final String LOCALE_EN = "en";
|
||||
public static final String DESCRIPTION = "Pay in 30 days product";
|
||||
public static final String DESCRIPTION_PIN4 = "Pay in 4 product";
|
||||
public static final String DESCRIPTION_LP2 = "Pay in 4 product";
|
||||
public static final String DESCRIPTION_INTEREST_FLAT = "Pay in 30 days product with 12% interest - FLAT";
|
||||
public static final String DESCRIPTION_INTEREST_FLAT_PIN4 = "Pay in 4 product with 12% interest - FLAT";
|
||||
public static final String DESCRIPTION_INTEREST_FLAT_LP2 = "Pay in 4 product with 12% interest - FLAT";
|
||||
public static final String DESCRIPTION_INTEREST_DECLINING = "Pay in 30 days product with 12% interest - DECLINING BALANCE";
|
||||
public static final String DESCRIPTION_INTEREST_DECLINING_BALANCE_DAILY_RECALCULATION_COMPOUNDING_MONTHLY = "PIN30-1MONTH with 12% DECLINING BALANCE interest, interest period: Daily, Interest recalculation-Monthly, Compounding:Interest";
|
||||
public static final String DESCRIPTION_INTEREST_DECLINING_BALANCE_DAILY_RECALCULATION_COMPOUNDING_NONE = "PIN30 with 12% DECLINING BALANCE interest, interest period: Daily, Interest recalculation-Daily, Compounding:none";
|
||||
public static final String DESCRIPTION_INTEREST_DECLINING_BALANCE_DAILY_RECALCULATION_COMPOUNDING_MONTHLY = "LP1-1MONTH with 12% DECLINING BALANCE interest, interest period: Daily, Interest recalculation-Monthly, Compounding:Interest";
|
||||
public static final String DESCRIPTION_INTEREST_DECLINING_BALANCE_DAILY_RECALCULATION_COMPOUNDING_NONE = "LP1 with 12% DECLINING BALANCE interest, interest period: Daily, Interest recalculation-Daily, Compounding:none";
|
||||
public static final Long FUND_ID = FundId.LENDER_A.value;
|
||||
public static final String CURRENCY_CODE = "EUR";
|
||||
public static final Integer INTEREST_RATE_FREQUENCY_TYPE_MONTH = InterestRateFrequencyType.MONTH.value;
|
||||
@@ -102,7 +102,7 @@ public class LoanProductsRequestFactory {
|
||||
public static final Integer FREQUENCY_FOR_RECALCULATE_OUTSTANDING_PRINCIPAL_SAME_AS_REPAYMENT = RecalculationRestFrequencyType.SAME_AS_REPAYMENT.value;
|
||||
public static final Integer FREQUENCY_FOR_RECALCULATE_OUTSTANDING_DAILY = RecalculationRestFrequencyType.DAILY.value;
|
||||
|
||||
public PostLoanProductsRequest defaultLoanProductsRequestPin30() {
|
||||
public PostLoanProductsRequest defaultLoanProductsRequestLP1() {
|
||||
String name = Utils.randomNameGenerator(NAME_PREFIX, 4);
|
||||
String shortName = Utils.randomNameGenerator(SHORT_NAME_PREFIX, 3);
|
||||
|
||||
@@ -212,7 +212,7 @@ public class LoanProductsRequestFactory {
|
||||
.incomeFromChargeOffPenaltyAccountId(accountTypeResolver.resolve(DefaultAccountType.FEE_CHARGE_OFF));//
|
||||
}
|
||||
|
||||
public PostLoanProductsRequest defaultLoanProductsRequestPin30InterestFlat() {
|
||||
public PostLoanProductsRequest defaultLoanProductsRequestLP1InterestFlat() {
|
||||
String name = Utils.randomNameGenerator(NAME_PREFIX_INTEREST_FLAT, 4);
|
||||
String shortName = Utils.randomNameGenerator(SHORT_NAME_PREFIX_INTEREST, 3);
|
||||
|
||||
@@ -320,7 +320,7 @@ public class LoanProductsRequestFactory {
|
||||
.incomeFromChargeOffPenaltyAccountId(accountTypeResolver.resolve(DefaultAccountType.FEE_CHARGE_OFF));//
|
||||
}
|
||||
|
||||
public PostLoanProductsRequest defaultLoanProductsRequestPin30InterestDeclining() {
|
||||
public PostLoanProductsRequest defaultLoanProductsRequestLP1InterestDeclining() {
|
||||
String name = Utils.randomNameGenerator(NAME_PREFIX_INTEREST_DECLINING, 4);
|
||||
String shortName = Utils.randomNameGenerator(SHORT_NAME_PREFIX_INTEREST, 3);
|
||||
|
||||
@@ -428,7 +428,7 @@ public class LoanProductsRequestFactory {
|
||||
.incomeFromChargeOffPenaltyAccountId(accountTypeResolver.resolve(DefaultAccountType.FEE_CHARGE_OFF));//
|
||||
}
|
||||
|
||||
public PostLoanProductsRequest defaultLoanProductsRequestPin301MonthInterestDecliningBalanceDailyRecalculationCompoundingMonthly() {
|
||||
public PostLoanProductsRequest defaultLoanProductsRequestLP11MonthInterestDecliningBalanceDailyRecalculationCompoundingMonthly() {
|
||||
String name = Utils.randomNameGenerator(NAME_PREFIX_INTEREST_DECLINING_RECALCULATION, 4);
|
||||
String shortName = Utils.randomNameGenerator(SHORT_NAME_PREFIX_INTEREST, 3);
|
||||
|
||||
@@ -541,7 +541,7 @@ public class LoanProductsRequestFactory {
|
||||
.recalculationCompoundingFrequencyOnDayType(1);//
|
||||
}
|
||||
|
||||
public PostLoanProductsRequest defaultLoanProductsRequestPin30InterestDecliningBalanceDailyRecalculationCompoundingNone() {
|
||||
public PostLoanProductsRequest defaultLoanProductsRequestLP1InterestDecliningBalanceDailyRecalculationCompoundingNone() {
|
||||
String name = Utils.randomNameGenerator(NAME_PREFIX_INTEREST_DECLINING_RECALCULATION, 4);
|
||||
String shortName = Utils.randomNameGenerator(SHORT_NAME_PREFIX_INTEREST, 3);
|
||||
|
||||
@@ -651,8 +651,8 @@ public class LoanProductsRequestFactory {
|
||||
.recalculationRestFrequencyInterval(1);//
|
||||
}
|
||||
|
||||
public PostLoanProductsRequest defaultLoanProductsRequestPin4() {
|
||||
String name = Utils.randomNameGenerator(NAME_PREFIX_PIN4, 4);
|
||||
public PostLoanProductsRequest defaultLoanProductsRequestLP2() {
|
||||
String name = Utils.randomNameGenerator(NAME_PREFIX_LP2, 4);
|
||||
String shortName = Utils.randomNameGenerator(SHORT_NAME_PREFIX, 3);
|
||||
|
||||
List<Integer> principalVariationsForBorrowerCycle = new ArrayList<>();
|
||||
@@ -671,7 +671,7 @@ public class LoanProductsRequestFactory {
|
||||
return new PostLoanProductsRequest()//
|
||||
.name(name)//
|
||||
.shortName(shortName)//
|
||||
.description(DESCRIPTION_PIN4)//
|
||||
.description(DESCRIPTION_LP2)//
|
||||
.enableDownPayment(true)//
|
||||
.enableAutoRepaymentForDownPayment(true)//
|
||||
.disbursedAmountPercentageForDownPayment(new BigDecimal(25))//
|
||||
@@ -764,8 +764,8 @@ public class LoanProductsRequestFactory {
|
||||
.incomeFromChargeOffPenaltyAccountId(accountTypeResolver.resolve(DefaultAccountType.FEE_CHARGE_OFF));//
|
||||
}
|
||||
|
||||
public PostLoanProductsRequest defaultLoanProductsRequestPin4InterestFlat() {
|
||||
String name = Utils.randomNameGenerator(NAME_PREFIX_INTEREST_FLAT_PIN4, 4);
|
||||
public PostLoanProductsRequest defaultLoanProductsRequestLP2InterestFlat() {
|
||||
String name = Utils.randomNameGenerator(NAME_PREFIX_INTEREST_FLAT_LP2, 4);
|
||||
String shortName = Utils.randomNameGenerator(SHORT_NAME_PREFIX_INTEREST, 3);
|
||||
|
||||
List<Integer> principalVariationsForBorrowerCycle = new ArrayList<>();
|
||||
@@ -784,7 +784,7 @@ public class LoanProductsRequestFactory {
|
||||
return new PostLoanProductsRequest()//
|
||||
.name(name)//
|
||||
.shortName(shortName)//
|
||||
.description(DESCRIPTION_INTEREST_FLAT_PIN4)//
|
||||
.description(DESCRIPTION_INTEREST_FLAT_LP2)//
|
||||
.enableDownPayment(true)//
|
||||
.enableAutoRepaymentForDownPayment(true)//
|
||||
.disbursedAmountPercentageForDownPayment(new BigDecimal(25))//
|
||||
|
||||
+1
-1
@@ -51,7 +51,7 @@ public class LoanRequestFactory {
|
||||
|
||||
public static final String DATE_FORMAT = "dd MMMM yyyy";
|
||||
public static final String DEFAULT_LOCALE = "en";
|
||||
public static final DefaultLoanProduct DEFAULT_LOAN_PRODUCT = DefaultLoanProduct.valueOf("PIN30");
|
||||
public static final DefaultLoanProduct DEFAULT_LOAN_PRODUCT = DefaultLoanProduct.valueOf("LP1");
|
||||
public static final Double DEFAULT_PAYMENT_TRANSACTION_AMOUNT = 200.00;
|
||||
public static final Double DEFAULT_UNDO_TRANSACTION_AMOUNT = 0.0;
|
||||
public static final Double DEFAULT_REPAYMENT_TRANSACTION_AMOUNT = 200.00;
|
||||
|
||||
+139
-141
@@ -55,82 +55,82 @@ public class LoanProductGlobalInitializerStep implements FineractGlobalInitializ
|
||||
|
||||
@Override
|
||||
public void initialize() throws Exception {
|
||||
// PIN30
|
||||
String name = DefaultLoanProduct.PIN30.getName();
|
||||
PostLoanProductsRequest loanProductsRequest = loanProductsRequestFactory.defaultLoanProductsRequestPin30().name(name);
|
||||
// LP1
|
||||
String name = DefaultLoanProduct.LP1.getName();
|
||||
PostLoanProductsRequest loanProductsRequest = loanProductsRequestFactory.defaultLoanProductsRequestLP1().name(name);
|
||||
Response<PostLoanProductsResponse> response = loanProductsApi.createLoanProduct(loanProductsRequest).execute();
|
||||
TestContext.INSTANCE.set(TestContextKey.DEFAULT_LOAN_PRODUCT_CREATE_RESPONSE_PIN30, response);
|
||||
TestContext.INSTANCE.set(TestContextKey.DEFAULT_LOAN_PRODUCT_CREATE_RESPONSE_LP1, response);
|
||||
|
||||
// PIN30 product with due date and overdue date for repayment in config
|
||||
// (PIN30_DUE_DATE)
|
||||
PostLoanProductsRequest loanProductsRequestDueDate = loanProductsRequestFactory.defaultLoanProductsRequestPin30()//
|
||||
.name(DefaultLoanProduct.PIN30_DUE_DATE.getName())//
|
||||
// LP1 product with due date and overdue date for repayment in config
|
||||
// (LP1_DUE_DATE)
|
||||
PostLoanProductsRequest loanProductsRequestDueDate = loanProductsRequestFactory.defaultLoanProductsRequestLP1()//
|
||||
.name(DefaultLoanProduct.LP1_DUE_DATE.getName())//
|
||||
.dueDaysForRepaymentEvent(3)//
|
||||
.overDueDaysForRepaymentEvent(3);//
|
||||
Response<PostLoanProductsResponse> responseDueDate = loanProductsApi.createLoanProduct(loanProductsRequestDueDate).execute();
|
||||
TestContext.INSTANCE.set(TestContextKey.DEFAULT_LOAN_PRODUCT_CREATE_RESPONSE_PIN30_DUE_DATE, responseDueDate);
|
||||
TestContext.INSTANCE.set(TestContextKey.DEFAULT_LOAN_PRODUCT_CREATE_RESPONSE_LP1_DUE_DATE, responseDueDate);
|
||||
|
||||
// PIN30 with 12% FLAT interest
|
||||
// (PIN30_INTEREST_FLAT)
|
||||
String name2 = DefaultLoanProduct.PIN30_INTEREST_FLAT.getName();
|
||||
PostLoanProductsRequest loanProductsRequestInterestFlat = loanProductsRequestFactory.defaultLoanProductsRequestPin30InterestFlat()
|
||||
// LP1 with 12% FLAT interest
|
||||
// (LP1_INTEREST_FLAT)
|
||||
String name2 = DefaultLoanProduct.LP1_INTEREST_FLAT.getName();
|
||||
PostLoanProductsRequest loanProductsRequestInterestFlat = loanProductsRequestFactory.defaultLoanProductsRequestLP1InterestFlat()
|
||||
.name(name2);
|
||||
Response<PostLoanProductsResponse> responseInterestFlat = loanProductsApi.createLoanProduct(loanProductsRequestInterestFlat)
|
||||
.execute();
|
||||
TestContext.INSTANCE.set(TestContextKey.DEFAULT_LOAN_PRODUCT_CREATE_RESPONSE_PIN30_INTEREST_FLAT, responseInterestFlat);
|
||||
TestContext.INSTANCE.set(TestContextKey.DEFAULT_LOAN_PRODUCT_CREATE_RESPONSE_LP1_INTEREST_FLAT, responseInterestFlat);
|
||||
|
||||
// PIN30 with 12% DECLINING BALANCE interest, interest period: Same as payment period
|
||||
// (PIN30_INTEREST_DECLINING_BALANCE_PERIOD_SAME_AS_PAYMENT)
|
||||
String name3 = DefaultLoanProduct.PIN30_INTEREST_DECLINING_BALANCE_PERIOD_SAME_AS_PAYMENT.getName();
|
||||
// LP1 with 12% DECLINING BALANCE interest, interest period: Same as payment period
|
||||
// (LP1_INTEREST_DECLINING_BALANCE_PERIOD_SAME_AS_PAYMENT)
|
||||
String name3 = DefaultLoanProduct.LP1_INTEREST_DECLINING_BALANCE_PERIOD_SAME_AS_PAYMENT.getName();
|
||||
PostLoanProductsRequest loanProductsRequestInterestDecliningPeriodSameAsPayment = loanProductsRequestFactory
|
||||
.defaultLoanProductsRequestPin30InterestDeclining().name(name3);
|
||||
.defaultLoanProductsRequestLP1InterestDeclining().name(name3);
|
||||
Response<PostLoanProductsResponse> responseInterestDecliningPeriodSameAsPayment = loanProductsApi
|
||||
.createLoanProduct(loanProductsRequestInterestDecliningPeriodSameAsPayment).execute();
|
||||
TestContext.INSTANCE.set(TestContextKey.DEFAULT_LOAN_PRODUCT_CREATE_RESPONSE_PIN30_INTEREST_DECLINING_PERIOD_SAME_AS_PAYMENT,
|
||||
TestContext.INSTANCE.set(TestContextKey.DEFAULT_LOAN_PRODUCT_CREATE_RESPONSE_LP1_INTEREST_DECLINING_PERIOD_SAME_AS_PAYMENT,
|
||||
responseInterestDecliningPeriodSameAsPayment);
|
||||
|
||||
// PIN30 with 12% DECLINING BALANCE interest, interest period: Daily
|
||||
// (PIN30_INTEREST_DECLINING_BALANCE_PERIOD_DAILY)
|
||||
String name4 = DefaultLoanProduct.PIN30_INTEREST_DECLINING_BALANCE_PERIOD_DAILY.getName();
|
||||
// LP1 with 12% DECLINING BALANCE interest, interest period: Daily
|
||||
// (LP1_INTEREST_DECLINING_BALANCE_PERIOD_DAILY)
|
||||
String name4 = DefaultLoanProduct.LP1_INTEREST_DECLINING_BALANCE_PERIOD_DAILY.getName();
|
||||
PostLoanProductsRequest loanProductsRequestInterestDecliningPeriodDaily = loanProductsRequestFactory
|
||||
.defaultLoanProductsRequestPin30InterestDeclining().name(name4)
|
||||
.defaultLoanProductsRequestLP1InterestDeclining().name(name4)
|
||||
.interestCalculationPeriodType(InterestCalculationPeriodTime.DAILY.value).allowPartialPeriodInterestCalcualtion(false);
|
||||
Response<PostLoanProductsResponse> responseInterestDecliningPeriodDaily = loanProductsApi
|
||||
.createLoanProduct(loanProductsRequestInterestDecliningPeriodDaily).execute();
|
||||
TestContext.INSTANCE.set(TestContextKey.DEFAULT_LOAN_PRODUCT_CREATE_RESPONSE_PIN30_INTEREST_DECLINING_PERIOD_DAILY,
|
||||
TestContext.INSTANCE.set(TestContextKey.DEFAULT_LOAN_PRODUCT_CREATE_RESPONSE_LP1_INTEREST_DECLINING_PERIOD_DAILY,
|
||||
responseInterestDecliningPeriodDaily);
|
||||
|
||||
// PIN30-1MONTH with 12% DECLINING BALANCE interest, interest period: Daily, Interest recalculation-Monthly,
|
||||
// LP1-1MONTH with 12% DECLINING BALANCE interest, interest period: Daily, Interest recalculation-Monthly,
|
||||
// Compounding:Interest
|
||||
// (PIN30_1MONTH_INTEREST_DECLINING_BALANCE_DAILY_RECALCULATION_COMPOUNDING_MONTHLY)
|
||||
String name5 = DefaultLoanProduct.PIN30_1MONTH_INTEREST_DECLINING_BALANCE_DAILY_RECALCULATION_COMPOUNDING_MONTHLY.getName();
|
||||
// (LP1_1MONTH_INTEREST_DECLINING_BALANCE_DAILY_RECALCULATION_COMPOUNDING_MONTHLY)
|
||||
String name5 = DefaultLoanProduct.LP1_1MONTH_INTEREST_DECLINING_BALANCE_DAILY_RECALCULATION_COMPOUNDING_MONTHLY.getName();
|
||||
PostLoanProductsRequest loanProductsRequestInterestDecliningBalanceDailyRecalculationCompoundingMonthly = loanProductsRequestFactory
|
||||
.defaultLoanProductsRequestPin301MonthInterestDecliningBalanceDailyRecalculationCompoundingMonthly().name(name5);
|
||||
.defaultLoanProductsRequestLP11MonthInterestDecliningBalanceDailyRecalculationCompoundingMonthly().name(name5);
|
||||
Response<PostLoanProductsResponse> responseInterestDecliningBalanceDailyRecalculationCompoundingMonthly = loanProductsApi
|
||||
.createLoanProduct(loanProductsRequestInterestDecliningBalanceDailyRecalculationCompoundingMonthly).execute();
|
||||
TestContext.INSTANCE.set(
|
||||
TestContextKey.DEFAULT_LOAN_PRODUCT_CREATE_RESPONSE_PIN30_1MONTH_INTEREST_DECLINING_BALANCE_DAILY_RECALCULATION_COMPOUNDING_MONTHLY,
|
||||
TestContextKey.DEFAULT_LOAN_PRODUCT_CREATE_RESPONSE_LP1_1MONTH_INTEREST_DECLINING_BALANCE_DAILY_RECALCULATION_COMPOUNDING_MONTHLY,
|
||||
responseInterestDecliningBalanceDailyRecalculationCompoundingMonthly);
|
||||
|
||||
// PIN30 with 12% DECLINING BALANCE interest, interest period: Daily, Interest
|
||||
// LP1 with 12% DECLINING BALANCE interest, interest period: Daily, Interest
|
||||
// recalculation-Daily, Compounding:none
|
||||
// (PIN30_INTEREST_DECLINING_BALANCE_DAILY_RECALCULATION_COMPOUNDING_NONE)
|
||||
String name6 = DefaultLoanProduct.PIN30_INTEREST_DECLINING_BALANCE_DAILY_RECALCULATION_COMPOUNDING_NONE.getName();
|
||||
// (LP1_INTEREST_DECLINING_BALANCE_DAILY_RECALCULATION_COMPOUNDING_NONE)
|
||||
String name6 = DefaultLoanProduct.LP1_INTEREST_DECLINING_BALANCE_DAILY_RECALCULATION_COMPOUNDING_NONE.getName();
|
||||
PostLoanProductsRequest loanProductsRequestInterestDecliningBalanceDailyRecalculationCompoundingNone = loanProductsRequestFactory
|
||||
.defaultLoanProductsRequestPin30InterestDecliningBalanceDailyRecalculationCompoundingNone().name(name6);
|
||||
.defaultLoanProductsRequestLP1InterestDecliningBalanceDailyRecalculationCompoundingNone().name(name6);
|
||||
Response<PostLoanProductsResponse> responseInterestDecliningBalanceDailyRecalculationCompoundingNone = loanProductsApi
|
||||
.createLoanProduct(loanProductsRequestInterestDecliningBalanceDailyRecalculationCompoundingNone).execute();
|
||||
TestContext.INSTANCE.set(
|
||||
TestContextKey.DEFAULT_LOAN_PRODUCT_CREATE_RESPONSE_PIN30_INTEREST_DECLINING_BALANCE_DAILY_RECALCULATION_COMPOUNDING_NONE,
|
||||
TestContextKey.DEFAULT_LOAN_PRODUCT_CREATE_RESPONSE_LP1_INTEREST_DECLINING_BALANCE_DAILY_RECALCULATION_COMPOUNDING_NONE,
|
||||
responseInterestDecliningBalanceDailyRecalculationCompoundingNone);
|
||||
|
||||
// PIN30 with 12% DECLINING BALANCE interest, interest period: Daily, Interest
|
||||
// LP1 with 12% DECLINING BALANCE interest, interest period: Daily, Interest
|
||||
// recalculation-Daily, Compounding:none, rescheduleStrategyMethod:Reduce number of installments
|
||||
// (PIN30_INTEREST_DECLINING_BALANCE_DAILY_RECALCULATION_COMPOUNDING_NONE_RESCHEDULE_REDUCE_NR_INST)
|
||||
String name7 = DefaultLoanProduct.PIN30_INTEREST_DECLINING_BALANCE_DAILY_RECALCULATION_COMPOUNDING_NONE_RESCHEDULE_REDUCE_NR_INST
|
||||
// (LP1_INTEREST_DECLINING_BALANCE_DAILY_RECALCULATION_COMPOUNDING_NONE_RESCHEDULE_REDUCE_NR_INST)
|
||||
String name7 = DefaultLoanProduct.LP1_INTEREST_DECLINING_BALANCE_DAILY_RECALCULATION_COMPOUNDING_NONE_RESCHEDULE_REDUCE_NR_INST
|
||||
.getName();
|
||||
PostLoanProductsRequest loanProductsRequestInterestDecliningBalanceDailyRecalculationCompoundingNoneRescheduleReduceNrInstallments = loanProductsRequestFactory
|
||||
.defaultLoanProductsRequestPin30InterestDecliningBalanceDailyRecalculationCompoundingNone()//
|
||||
.defaultLoanProductsRequestLP1InterestDecliningBalanceDailyRecalculationCompoundingNone()//
|
||||
.name(name7)//
|
||||
.rescheduleStrategyMethod(AdvancePaymentsAdjustmentType.REDUCE_NUMBER_OF_INSTALLMENTS.value);//
|
||||
Response<PostLoanProductsResponse> responseInterestDecliningBalanceDailyRecalculationCompoundingNoneRescheduleReduceNrInstallments = loanProductsApi
|
||||
@@ -138,16 +138,16 @@ public class LoanProductGlobalInitializerStep implements FineractGlobalInitializ
|
||||
loanProductsRequestInterestDecliningBalanceDailyRecalculationCompoundingNoneRescheduleReduceNrInstallments)
|
||||
.execute();
|
||||
TestContext.INSTANCE.set(
|
||||
TestContextKey.DEFAULT_LOAN_PRODUCT_CREATE_RESPONSE_PIN30_INTEREST_DECLINING_BALANCE_DAILY_RECALCULATION_COMPOUNDING_NONE_RESCHEDULE_REDUCE_NR_INSTALLMENTS,
|
||||
TestContextKey.DEFAULT_LOAN_PRODUCT_CREATE_RESPONSE_LP1_INTEREST_DECLINING_BALANCE_DAILY_RECALCULATION_COMPOUNDING_NONE_RESCHEDULE_REDUCE_NR_INSTALLMENTS,
|
||||
responseInterestDecliningBalanceDailyRecalculationCompoundingNoneRescheduleReduceNrInstallments);
|
||||
|
||||
// PIN30 with 12% DECLINING BALANCE interest, interest period: Daily, Interest
|
||||
// LP1 with 12% DECLINING BALANCE interest, interest period: Daily, Interest
|
||||
// recalculation-Daily, Compounding:none, rescheduleStrategyMethod:Reschedule next repayments
|
||||
// (PIN30_INTEREST_DECLINING_BALANCE_DAILY_RECALCULATION_COMPOUNDING_NONE_RESCHEDULE_RESCH_NEXT_REP)
|
||||
String name8 = DefaultLoanProduct.PIN30_INTEREST_DECLINING_BALANCE_DAILY_RECALCULATION_COMPOUNDING_NONE_RESCHEDULE_RESCH_NEXT_REP
|
||||
// (LP1_INTEREST_DECLINING_BALANCE_DAILY_RECALCULATION_COMPOUNDING_NONE_RESCHEDULE_RESCH_NEXT_REP)
|
||||
String name8 = DefaultLoanProduct.LP1_INTEREST_DECLINING_BALANCE_DAILY_RECALCULATION_COMPOUNDING_NONE_RESCHEDULE_RESCH_NEXT_REP
|
||||
.getName();
|
||||
PostLoanProductsRequest loanProductsRequestInterestDecliningBalanceDailyRecalculationCompoundingNoneRescheduleRescheduleNextRepayments = loanProductsRequestFactory
|
||||
.defaultLoanProductsRequestPin30InterestDecliningBalanceDailyRecalculationCompoundingNone()//
|
||||
.defaultLoanProductsRequestLP1InterestDecliningBalanceDailyRecalculationCompoundingNone()//
|
||||
.name(name8)//
|
||||
.rescheduleStrategyMethod(AdvancePaymentsAdjustmentType.RESCHEDULE_NEXT_REPAYMENTS.value);//
|
||||
Response<PostLoanProductsResponse> responseInterestDecliningBalanceDailyRecalculationCompoundingNoneRescheduleRescheduleNextRepayments = loanProductsApi
|
||||
@@ -155,31 +155,31 @@ public class LoanProductGlobalInitializerStep implements FineractGlobalInitializ
|
||||
loanProductsRequestInterestDecliningBalanceDailyRecalculationCompoundingNoneRescheduleRescheduleNextRepayments)
|
||||
.execute();
|
||||
TestContext.INSTANCE.set(
|
||||
TestContextKey.DEFAULT_LOAN_PRODUCT_CREATE_RESPONSE_PIN30_INTEREST_DECLINING_BALANCE_DAILY_RECALCULATION_COMPOUNDING_NONE_RESCHEDULE_NEXT_REPAYMENTS,
|
||||
TestContextKey.DEFAULT_LOAN_PRODUCT_CREATE_RESPONSE_LP1_INTEREST_DECLINING_BALANCE_DAILY_RECALCULATION_COMPOUNDING_NONE_RESCHEDULE_NEXT_REPAYMENTS,
|
||||
responseInterestDecliningBalanceDailyRecalculationCompoundingNoneRescheduleRescheduleNextRepayments);
|
||||
|
||||
// PIN30 with 12% DECLINING BALANCE interest, interest period: Daily, Interest
|
||||
// LP1 with 12% DECLINING BALANCE interest, interest period: Daily, Interest
|
||||
// recalculation-Daily, Compounding:none, Interest Recalculation Frequency: Same as Repayment Period
|
||||
// (PIN30_INTEREST_DECLINING_BALANCE_DAILY_RECALCULATION_SAME_AS_REPAYMENT_COMPOUNDING_NONE)
|
||||
String name9 = DefaultLoanProduct.PIN30_INTEREST_DECLINING_BALANCE_DAILY_RECALCULATION_SAME_AS_REPAYMENT_COMPOUNDING_NONE.getName();
|
||||
// (LP1_INTEREST_DECLINING_BALANCE_DAILY_RECALCULATION_SAME_AS_REPAYMENT_COMPOUNDING_NONE)
|
||||
String name9 = DefaultLoanProduct.LP1_INTEREST_DECLINING_BALANCE_DAILY_RECALCULATION_SAME_AS_REPAYMENT_COMPOUNDING_NONE.getName();
|
||||
PostLoanProductsRequest loanProductsRequestInterestDecliningBalanceDailyRecalculationSameAsRepaymentCompoundingNone = loanProductsRequestFactory
|
||||
.defaultLoanProductsRequestPin30InterestDecliningBalanceDailyRecalculationCompoundingNone()//
|
||||
.defaultLoanProductsRequestLP1InterestDecliningBalanceDailyRecalculationCompoundingNone()//
|
||||
.name(name9)//
|
||||
.recalculationRestFrequencyType(RecalculationRestFrequencyType.SAME_AS_REPAYMENT.value);//
|
||||
Response<PostLoanProductsResponse> responseInterestDecliningBalanceDailyRecalculationSameAsRepaymentCompoundingNone = loanProductsApi
|
||||
.createLoanProduct(loanProductsRequestInterestDecliningBalanceDailyRecalculationSameAsRepaymentCompoundingNone).execute();
|
||||
TestContext.INSTANCE.set(
|
||||
TestContextKey.DEFAULT_LOAN_PRODUCT_CREATE_RESPONSE_PIN30_INTEREST_DECLINING_BALANCE_DAILY_RECALCULATION_SAME_AS_REPAYMENT_COMPOUNDING_NONE,
|
||||
TestContextKey.DEFAULT_LOAN_PRODUCT_CREATE_RESPONSE_LP1_INTEREST_DECLINING_BALANCE_DAILY_RECALCULATION_SAME_AS_REPAYMENT_COMPOUNDING_NONE,
|
||||
responseInterestDecliningBalanceDailyRecalculationSameAsRepaymentCompoundingNone);
|
||||
|
||||
// PIN30 with 12% DECLINING BALANCE interest, interest period: Daily, Interest
|
||||
// LP1 with 12% DECLINING BALANCE interest, interest period: Daily, Interest
|
||||
// recalculation-Daily, Compounding:none, Interest Recalculation Frequency: Same as Repayment Period,
|
||||
// Multi-disbursement
|
||||
// (PIN30_INTEREST_DECLINING_BALANCE_SAR_RECALCULATION_SAME_AS_REPAYMENT_COMPOUNDING_NONE_MULTIDISB)
|
||||
String name10 = DefaultLoanProduct.PIN30_INTEREST_DECLINING_BALANCE_SAR_RECALCULATION_SAME_AS_REPAYMENT_COMPOUNDING_NONE_MULTIDISB
|
||||
// (LP1_INTEREST_DECLINING_BALANCE_SAR_RECALCULATION_SAME_AS_REPAYMENT_COMPOUNDING_NONE_MULTIDISB)
|
||||
String name10 = DefaultLoanProduct.LP1_INTEREST_DECLINING_BALANCE_SAR_RECALCULATION_SAME_AS_REPAYMENT_COMPOUNDING_NONE_MULTIDISB
|
||||
.getName();
|
||||
PostLoanProductsRequest loanProductsRequestInterestDecliningBalanceSaRRecalculationSameAsRepaymentCompoundingNoneMultiDisbursement = loanProductsRequestFactory
|
||||
.defaultLoanProductsRequestPin30InterestDecliningBalanceDailyRecalculationCompoundingNone()//
|
||||
.defaultLoanProductsRequestLP1InterestDecliningBalanceDailyRecalculationCompoundingNone()//
|
||||
.name(name10)//
|
||||
.interestCalculationPeriodType(InterestCalculationPeriodTime.SAME_AS_REPAYMENT_PERIOD.value)//
|
||||
.recalculationRestFrequencyType(RecalculationRestFrequencyType.SAME_AS_REPAYMENT.value)//
|
||||
@@ -193,115 +193,115 @@ public class LoanProductGlobalInitializerStep implements FineractGlobalInitializ
|
||||
loanProductsRequestInterestDecliningBalanceSaRRecalculationSameAsRepaymentCompoundingNoneMultiDisbursement)
|
||||
.execute();
|
||||
TestContext.INSTANCE.set(
|
||||
TestContextKey.DEFAULT_LOAN_PRODUCT_CREATE_RESPONSE_PIN30_INTEREST_DECLINING_BALANCE_SAR_RECALCULATION_SAME_AS_REPAYMENT_COMPOUNDING_NONE_MULTI_DISBURSEMENT,
|
||||
TestContextKey.DEFAULT_LOAN_PRODUCT_CREATE_RESPONSE_LP1_INTEREST_DECLINING_BALANCE_SAR_RECALCULATION_SAME_AS_REPAYMENT_COMPOUNDING_NONE_MULTI_DISBURSEMENT,
|
||||
responseInterestDecliningBalanceSaRRecalculationSameAsRepaymentCompoundingNoneMultiDisbursement);
|
||||
|
||||
// PIN30 with new due-penalty-fee-interest-principal-in-advance-principal-penalty-fee-interest-strategy payment
|
||||
// LP1 with new due-penalty-fee-interest-principal-in-advance-principal-penalty-fee-interest-strategy payment
|
||||
// strategy
|
||||
// (PIN30_PAYMENT_STRATEGY_DUE_IN_ADVANCE)
|
||||
String name11 = DefaultLoanProduct.PIN30_PAYMENT_STRATEGY_DUE_IN_ADVANCE.getName();
|
||||
PostLoanProductsRequest loanProductsRequestDueInAdvance = loanProductsRequestFactory.defaultLoanProductsRequestPin30()//
|
||||
// (LP1_PAYMENT_STRATEGY_DUE_IN_ADVANCE)
|
||||
String name11 = DefaultLoanProduct.LP1_PAYMENT_STRATEGY_DUE_IN_ADVANCE.getName();
|
||||
PostLoanProductsRequest loanProductsRequestDueInAdvance = loanProductsRequestFactory.defaultLoanProductsRequestLP1()//
|
||||
.name(name11)//
|
||||
.transactionProcessingStrategyCode(
|
||||
TransactionProcessingStrategyCode.DUE_PENALTY_FEE_INTEREST_PRINCIPAL_IN_ADVANCE_PRINCIPAL_PENALTY_FEE_INTEREST.value);//
|
||||
Response<PostLoanProductsResponse> responseDueInAdvance = loanProductsApi.createLoanProduct(loanProductsRequestDueInAdvance)
|
||||
.execute();
|
||||
TestContext.INSTANCE.set(TestContextKey.DEFAULT_LOAN_PRODUCT_CREATE_RESPONSE_PIN30_PAYMENT_STRATEGY_DUE_IN_ADVANCE,
|
||||
TestContext.INSTANCE.set(TestContextKey.DEFAULT_LOAN_PRODUCT_CREATE_RESPONSE_LP1_PAYMENT_STRATEGY_DUE_IN_ADVANCE,
|
||||
responseDueInAdvance);
|
||||
|
||||
// PIN30 with new due-penalty-fee-interest-principal-in-advance-principal-penalty-fee-interest-strategy payment
|
||||
// LP1 with new due-penalty-fee-interest-principal-in-advance-principal-penalty-fee-interest-strategy payment
|
||||
// strategy and with 12% FLAT interest
|
||||
// (PIN30_PAYMENT_STRATEGY_DUE_IN_ADVANCE_INTEREST_FLAT)
|
||||
String name12 = DefaultLoanProduct.PIN30_PAYMENT_STRATEGY_DUE_IN_ADVANCE_INTEREST_FLAT.getName();
|
||||
// (LP1_PAYMENT_STRATEGY_DUE_IN_ADVANCE_INTEREST_FLAT)
|
||||
String name12 = DefaultLoanProduct.LP1_PAYMENT_STRATEGY_DUE_IN_ADVANCE_INTEREST_FLAT.getName();
|
||||
PostLoanProductsRequest loanProductsRequestDueInAdvanceInterestFlat = loanProductsRequestFactory
|
||||
.defaultLoanProductsRequestPin30InterestFlat()//
|
||||
.defaultLoanProductsRequestLP1InterestFlat()//
|
||||
.name(name12)//
|
||||
.transactionProcessingStrategyCode(
|
||||
TransactionProcessingStrategyCode.DUE_PENALTY_FEE_INTEREST_PRINCIPAL_IN_ADVANCE_PRINCIPAL_PENALTY_FEE_INTEREST.value);//
|
||||
Response<PostLoanProductsResponse> responseDueInAdvanceInterestFlat = loanProductsApi
|
||||
.createLoanProduct(loanProductsRequestDueInAdvanceInterestFlat).execute();
|
||||
TestContext.INSTANCE.set(TestContextKey.DEFAULT_LOAN_PRODUCT_CREATE_RESPONSE_PIN30_PAYMENT_STRATEGY_DUE_IN_ADVANCE_INTEREST_FLAT,
|
||||
TestContext.INSTANCE.set(TestContextKey.DEFAULT_LOAN_PRODUCT_CREATE_RESPONSE_LP1_PAYMENT_STRATEGY_DUE_IN_ADVANCE_INTEREST_FLAT,
|
||||
responseDueInAdvanceInterestFlat);
|
||||
|
||||
// PIN30 with new due-penalty-interest-principal-fee-in-advance-penalty-interest-principal-fee-strategy payment
|
||||
// LP1 with new due-penalty-interest-principal-fee-in-advance-penalty-interest-principal-fee-strategy payment
|
||||
// strategy
|
||||
// (PIN30_PAYMENT_STRATEGY_DUE_IN_ADVANCE_PENALTY_INTEREST_PRINCIPAL_FEE)
|
||||
PostLoanProductsRequest loanProductsRequestDueInAdvance2 = loanProductsRequestFactory.defaultLoanProductsRequestPin30()//
|
||||
.name(DefaultLoanProduct.PIN30_PAYMENT_STRATEGY_DUE_IN_ADVANCE_PENALTY_INTEREST_PRINCIPAL_FEE.getName())//
|
||||
// (LP1_PAYMENT_STRATEGY_DUE_IN_ADVANCE_PENALTY_INTEREST_PRINCIPAL_FEE)
|
||||
PostLoanProductsRequest loanProductsRequestDueInAdvance2 = loanProductsRequestFactory.defaultLoanProductsRequestLP1()//
|
||||
.name(DefaultLoanProduct.LP1_PAYMENT_STRATEGY_DUE_IN_ADVANCE_PENALTY_INTEREST_PRINCIPAL_FEE.getName())//
|
||||
.transactionProcessingStrategyCode(
|
||||
TransactionProcessingStrategyCode.DUE_PENALTY_INTEREST_PRINCIPAL_FEE_IN_ADVANCE_PENALTY_INTEREST_PRINCIPAL_FEE.value);//
|
||||
Response<PostLoanProductsResponse> responseDueInAdvance2 = loanProductsApi.createLoanProduct(loanProductsRequestDueInAdvance2)
|
||||
.execute();
|
||||
TestContext.INSTANCE.set(
|
||||
TestContextKey.DEFAULT_LOAN_PRODUCT_CREATE_RESPONSE_PIN30_PAYMENT_STRATEGY_DUE_IN_ADVANCE_PENALTY_INTEREST_PRINCIPAL_FEE,
|
||||
TestContextKey.DEFAULT_LOAN_PRODUCT_CREATE_RESPONSE_LP1_PAYMENT_STRATEGY_DUE_IN_ADVANCE_PENALTY_INTEREST_PRINCIPAL_FEE,
|
||||
responseDueInAdvance2);
|
||||
|
||||
// PIN30 with new due-penalty-interest-principal-fee-in-advance-penalty-interest-principal-fee-strategy payment
|
||||
// LP1 with new due-penalty-interest-principal-fee-in-advance-penalty-interest-principal-fee-strategy payment
|
||||
// strategy and with 12% FLAT interest
|
||||
// (PIN30_PAYMENT_STRATEGY_DUE_IN_ADVANCE_PENALTY_INTEREST_PRINCIPAL_FEE_INTEREST_FLAT)
|
||||
// (LP1_PAYMENT_STRATEGY_DUE_IN_ADVANCE_PENALTY_INTEREST_PRINCIPAL_FEE_INTEREST_FLAT)
|
||||
PostLoanProductsRequest loanProductsRequestDueInAdvanceInterestFlat2 = loanProductsRequestFactory
|
||||
.defaultLoanProductsRequestPin30InterestFlat()//
|
||||
.name(DefaultLoanProduct.PIN30_PAYMENT_STRATEGY_DUE_IN_ADVANCE_PENALTY_INTEREST_PRINCIPAL_FEE_INTEREST_FLAT.getName())//
|
||||
.defaultLoanProductsRequestLP1InterestFlat()//
|
||||
.name(DefaultLoanProduct.LP1_PAYMENT_STRATEGY_DUE_IN_ADVANCE_PENALTY_INTEREST_PRINCIPAL_FEE_INTEREST_FLAT.getName())//
|
||||
.transactionProcessingStrategyCode(
|
||||
TransactionProcessingStrategyCode.DUE_PENALTY_INTEREST_PRINCIPAL_FEE_IN_ADVANCE_PENALTY_INTEREST_PRINCIPAL_FEE.value);//
|
||||
Response<PostLoanProductsResponse> responseDueInAdvanceInterestFlat2 = loanProductsApi
|
||||
.createLoanProduct(loanProductsRequestDueInAdvanceInterestFlat2).execute();
|
||||
TestContext.INSTANCE.set(
|
||||
TestContextKey.DEFAULT_LOAN_PRODUCT_CREATE_RESPONSE_PIN30_PAYMENT_STRATEGY_DUE_IN_ADVANCE_PENALTY_INTEREST_PRINCIPAL_FEE_INTEREST_FLAT,
|
||||
TestContextKey.DEFAULT_LOAN_PRODUCT_CREATE_RESPONSE_LP1_PAYMENT_STRATEGY_DUE_IN_ADVANCE_PENALTY_INTEREST_PRINCIPAL_FEE_INTEREST_FLAT,
|
||||
responseDueInAdvanceInterestFlat2);
|
||||
|
||||
// PIN30 with 12% FLAT interest with % overdue fee for amount
|
||||
// (PIN30_INTEREST_FLAT_OVERDUE_FROM_AMOUNT)
|
||||
String name13 = DefaultLoanProduct.PIN30_INTEREST_FLAT_OVERDUE_FROM_AMOUNT.getName();
|
||||
// LP1 with 12% FLAT interest with % overdue fee for amount
|
||||
// (LP1_INTEREST_FLAT_OVERDUE_FROM_AMOUNT)
|
||||
String name13 = DefaultLoanProduct.LP1_INTEREST_FLAT_OVERDUE_FROM_AMOUNT.getName();
|
||||
List<ChargeData> charges = new ArrayList<>();
|
||||
charges.add(new ChargeData().id(ChargeProductType.LOAN_PERCENTAGE_LATE_FEE.value));
|
||||
PostLoanProductsRequest loanProductsRequestInterestFlatOverdueFeeAmount = loanProductsRequestFactory
|
||||
.defaultLoanProductsRequestPin30InterestFlat()//
|
||||
.defaultLoanProductsRequestLP1InterestFlat()//
|
||||
.name(name13)//
|
||||
.charges(charges);//
|
||||
Response<PostLoanProductsResponse> responseInterestFlatOverdueFeeAmount = loanProductsApi
|
||||
.createLoanProduct(loanProductsRequestInterestFlatOverdueFeeAmount).execute();
|
||||
TestContext.INSTANCE.set(TestContextKey.DEFAULT_LOAN_PRODUCT_CREATE_RESPONSE_PIN30_INTEREST_FLAT_OVERDUE_FROM_AMOUNT,
|
||||
TestContext.INSTANCE.set(TestContextKey.DEFAULT_LOAN_PRODUCT_CREATE_RESPONSE_LP1_INTEREST_FLAT_OVERDUE_FROM_AMOUNT,
|
||||
responseInterestFlatOverdueFeeAmount);
|
||||
|
||||
// PIN30 with 12% FLAT interest with % overdue fee for amount+interest
|
||||
// (PIN30_INTEREST_FLAT_OVERDUE_FROM_AMOUNT_INTEREST)
|
||||
String name14 = DefaultLoanProduct.PIN30_INTEREST_FLAT_OVERDUE_FROM_AMOUNT_INTEREST.getName();
|
||||
// LP1 with 12% FLAT interest with % overdue fee for amount+interest
|
||||
// (LP1_INTEREST_FLAT_OVERDUE_FROM_AMOUNT_INTEREST)
|
||||
String name14 = DefaultLoanProduct.LP1_INTEREST_FLAT_OVERDUE_FROM_AMOUNT_INTEREST.getName();
|
||||
List<ChargeData> chargesInterest = new ArrayList<>();
|
||||
chargesInterest.add(new ChargeData().id(ChargeProductType.LOAN_PERCENTAGE_LATE_FEE_AMOUNT_PLUS_INTEREST.value));
|
||||
PostLoanProductsRequest loanProductsRequestInterestFlatOverdueFeeAmountInterest = loanProductsRequestFactory
|
||||
.defaultLoanProductsRequestPin30InterestFlat()//
|
||||
.defaultLoanProductsRequestLP1InterestFlat()//
|
||||
.name(name14)//
|
||||
.charges(chargesInterest);//
|
||||
Response<PostLoanProductsResponse> responseInterestFlatOverdueFeeAmountInterest = loanProductsApi
|
||||
.createLoanProduct(loanProductsRequestInterestFlatOverdueFeeAmountInterest).execute();
|
||||
TestContext.INSTANCE.set(TestContextKey.DEFAULT_LOAN_PRODUCT_CREATE_RESPONSE_PIN30_INTEREST_FLAT_OVERDUE_FROM_AMOUNT_INTEREST,
|
||||
TestContext.INSTANCE.set(TestContextKey.DEFAULT_LOAN_PRODUCT_CREATE_RESPONSE_LP1_INTEREST_FLAT_OVERDUE_FROM_AMOUNT_INTEREST,
|
||||
responseInterestFlatOverdueFeeAmountInterest);
|
||||
|
||||
// PIN4 with Down-payment
|
||||
// (PIN4_DOWNPAYMENT)
|
||||
String name15 = DefaultLoanProduct.PIN4_DOWNPAYMENT.getName();
|
||||
PostLoanProductsRequest loanProductsRequestDownPayment = loanProductsRequestFactory.defaultLoanProductsRequestPin4()//
|
||||
// LP2 with Down-payment
|
||||
// (LP2_DOWNPAYMENT)
|
||||
String name15 = DefaultLoanProduct.LP2_DOWNPAYMENT.getName();
|
||||
PostLoanProductsRequest loanProductsRequestDownPayment = loanProductsRequestFactory.defaultLoanProductsRequestLP2()//
|
||||
.name(name15)//
|
||||
.enableAutoRepaymentForDownPayment(false);//
|
||||
Response<PostLoanProductsResponse> responseDownPayment = loanProductsApi.createLoanProduct(loanProductsRequestDownPayment)
|
||||
.execute();
|
||||
TestContext.INSTANCE.set(TestContextKey.DEFAULT_LOAN_PRODUCT_CREATE_RESPONSE_PIN4_DOWNPAYMENT, responseDownPayment);
|
||||
TestContext.INSTANCE.set(TestContextKey.DEFAULT_LOAN_PRODUCT_CREATE_RESPONSE_LP2_DOWNPAYMENT, responseDownPayment);
|
||||
|
||||
// PIN4 with Down-payment+autopayment
|
||||
// (PIN4_DOWNPAYMENT_AUTO)
|
||||
String name16 = DefaultLoanProduct.PIN4_DOWNPAYMENT_AUTO.getName();
|
||||
PostLoanProductsRequest loanProductsRequestDownPaymentAuto = loanProductsRequestFactory.defaultLoanProductsRequestPin4()
|
||||
// LP2 with Down-payment+autopayment
|
||||
// (LP2_DOWNPAYMENT_AUTO)
|
||||
String name16 = DefaultLoanProduct.LP2_DOWNPAYMENT_AUTO.getName();
|
||||
PostLoanProductsRequest loanProductsRequestDownPaymentAuto = loanProductsRequestFactory.defaultLoanProductsRequestLP2()
|
||||
.name(name16);
|
||||
Response<PostLoanProductsResponse> responseDownPaymentAuto = loanProductsApi.createLoanProduct(loanProductsRequestDownPaymentAuto)
|
||||
.execute();
|
||||
TestContext.INSTANCE.set(TestContextKey.DEFAULT_LOAN_PRODUCT_CREATE_RESPONSE_PIN4_DOWNPAYMENT_AUTO, responseDownPaymentAuto);
|
||||
TestContext.INSTANCE.set(TestContextKey.DEFAULT_LOAN_PRODUCT_CREATE_RESPONSE_LP2_DOWNPAYMENT_AUTO, responseDownPaymentAuto);
|
||||
|
||||
// PIN4 with Down-payment+autopayment + advanced payment allocation
|
||||
// (PIN4_DOWNPAYMENT_AUTO_ADVANCED_PAYMENT_ALLOCATION)
|
||||
String name17 = DefaultLoanProduct.PIN4_DOWNPAYMENT_AUTO_ADVANCED_PAYMENT_ALLOCATION.getName();
|
||||
// LP2 with Down-payment+autopayment + advanced payment allocation
|
||||
// (LP2_DOWNPAYMENT_AUTO_ADVANCED_PAYMENT_ALLOCATION)
|
||||
String name17 = DefaultLoanProduct.LP2_DOWNPAYMENT_AUTO_ADVANCED_PAYMENT_ALLOCATION.getName();
|
||||
PostLoanProductsRequest loanProductsRequestDownPaymentAutoAdvPaymentAllocation = loanProductsRequestFactory
|
||||
.defaultLoanProductsRequestPin4()//
|
||||
.defaultLoanProductsRequestLP2()//
|
||||
.name(name17)//
|
||||
.transactionProcessingStrategyCode(ADVANCED_PAYMENT_ALLOCATION.getValue())//
|
||||
.loanScheduleType("PROGRESSIVE") //
|
||||
@@ -312,14 +312,14 @@ public class LoanProductGlobalInitializerStep implements FineractGlobalInitializ
|
||||
createPaymentAllocation("PAYOUT_REFUND", "NEXT_INSTALLMENT")));//
|
||||
Response<PostLoanProductsResponse> responseLoanProductsRequestDownPaymentAutoAdvPaymentAllocation = loanProductsApi
|
||||
.createLoanProduct(loanProductsRequestDownPaymentAutoAdvPaymentAllocation).execute();
|
||||
TestContext.INSTANCE.set(TestContextKey.DEFAULT_LOAN_PRODUCT_CREATE_RESPONSE_PIN4_DOWNPAYMENT_AUTO_ADVANCED_PAYMENT_ALLOCATION,
|
||||
TestContext.INSTANCE.set(TestContextKey.DEFAULT_LOAN_PRODUCT_CREATE_RESPONSE_LP2_DOWNPAYMENT_AUTO_ADVANCED_PAYMENT_ALLOCATION,
|
||||
responseLoanProductsRequestDownPaymentAutoAdvPaymentAllocation);
|
||||
|
||||
// PIN4 with Down-payment + advanced payment allocation - no auto downpayment
|
||||
// (PIN4_DOWNPAYMENT_ADVANCED_PAYMENT_ALLOCATION)
|
||||
String name24 = DefaultLoanProduct.PIN4_DOWNPAYMENT_ADVANCED_PAYMENT_ALLOCATION.getName();
|
||||
// LP2 with Down-payment + advanced payment allocation - no auto downpayment
|
||||
// (LP2_DOWNPAYMENT_ADVANCED_PAYMENT_ALLOCATION)
|
||||
String name24 = DefaultLoanProduct.LP2_DOWNPAYMENT_ADVANCED_PAYMENT_ALLOCATION.getName();
|
||||
PostLoanProductsRequest loanProductsRequestDownPaymentAdvPaymentAllocation = loanProductsRequestFactory
|
||||
.defaultLoanProductsRequestPin4()//
|
||||
.defaultLoanProductsRequestLP2()//
|
||||
.name(name24)//
|
||||
.enableAutoRepaymentForDownPayment(false)//
|
||||
.transactionProcessingStrategyCode(ADVANCED_PAYMENT_ALLOCATION.getValue())//
|
||||
@@ -331,36 +331,35 @@ public class LoanProductGlobalInitializerStep implements FineractGlobalInitializ
|
||||
createPaymentAllocation("PAYOUT_REFUND", "NEXT_INSTALLMENT")));//
|
||||
Response<PostLoanProductsResponse> responseLoanProductsRequestDownPaymentAdvPaymentAllocation = loanProductsApi
|
||||
.createLoanProduct(loanProductsRequestDownPaymentAdvPaymentAllocation).execute();
|
||||
TestContext.INSTANCE.set(TestContextKey.DEFAULT_LOAN_PRODUCT_CREATE_RESPONSE_PIN4_DOWNPAYMENT_ADVANCED_PAYMENT_ALLOCATION,
|
||||
TestContext.INSTANCE.set(TestContextKey.DEFAULT_LOAN_PRODUCT_CREATE_RESPONSE_LP2_DOWNPAYMENT_ADVANCED_PAYMENT_ALLOCATION,
|
||||
responseLoanProductsRequestDownPaymentAdvPaymentAllocation);
|
||||
|
||||
// PIN4 with Down-payment and interest
|
||||
// (PIN4_DOWNPAYMENT_INTEREST)
|
||||
String name18 = DefaultLoanProduct.PIN4_DOWNPAYMENT_INTEREST.getName();
|
||||
// LP2 with Down-payment and interest
|
||||
// (LP2_DOWNPAYMENT_INTEREST)
|
||||
String name18 = DefaultLoanProduct.LP2_DOWNPAYMENT_INTEREST.getName();
|
||||
PostLoanProductsRequest loanProductsRequestDownPaymentInterest = loanProductsRequestFactory
|
||||
.defaultLoanProductsRequestPin4InterestFlat()//
|
||||
.defaultLoanProductsRequestLP2InterestFlat()//
|
||||
.name(name18)//
|
||||
.enableAutoRepaymentForDownPayment(false);//
|
||||
Response<PostLoanProductsResponse> responseDownPaymentInterest = loanProductsApi
|
||||
.createLoanProduct(loanProductsRequestDownPaymentInterest).execute();
|
||||
TestContext.INSTANCE.set(TestContextKey.DEFAULT_LOAN_PRODUCT_CREATE_RESPONSE_PIN4_DOWNPAYMENT_INTEREST,
|
||||
responseDownPaymentInterest);
|
||||
TestContext.INSTANCE.set(TestContextKey.DEFAULT_LOAN_PRODUCT_CREATE_RESPONSE_LP2_DOWNPAYMENT_INTEREST, responseDownPaymentInterest);
|
||||
|
||||
// PIN4 with Down-payment and interest
|
||||
// (PIN4_DOWNPAYMENT_INTEREST_AUTO)
|
||||
String name19 = DefaultLoanProduct.PIN4_DOWNPAYMENT_INTEREST_AUTO.getName();
|
||||
// LP2 with Down-payment and interest
|
||||
// (LP2_DOWNPAYMENT_INTEREST_AUTO)
|
||||
String name19 = DefaultLoanProduct.LP2_DOWNPAYMENT_INTEREST_AUTO.getName();
|
||||
PostLoanProductsRequest loanProductsRequestDownPaymentInterestAuto = loanProductsRequestFactory
|
||||
.defaultLoanProductsRequestPin4InterestFlat().name(name19);
|
||||
.defaultLoanProductsRequestLP2InterestFlat().name(name19);
|
||||
Response<PostLoanProductsResponse> responseDownPaymentInterestAuto = loanProductsApi
|
||||
.createLoanProduct(loanProductsRequestDownPaymentInterestAuto).execute();
|
||||
TestContext.INSTANCE.set(TestContextKey.DEFAULT_LOAN_PRODUCT_CREATE_RESPONSE_PIN4_DOWNPAYMENT_INTEREST_AUTO,
|
||||
TestContext.INSTANCE.set(TestContextKey.DEFAULT_LOAN_PRODUCT_CREATE_RESPONSE_LP2_DOWNPAYMENT_INTEREST_AUTO,
|
||||
responseDownPaymentInterestAuto);
|
||||
|
||||
// PIN4 with Down-payment + advanced payment allocation + progressive loan schedule + horizontal
|
||||
// (PIN4_DOWNPAYMENT_ADV_PMT_ALLOC_PROGRESSIVE_LOAN_SCHEDULE_HORIZONTAL)
|
||||
String name20 = DefaultLoanProduct.PIN4_DOWNPAYMENT_ADV_PMT_ALLOC_PROGRESSIVE_LOAN_SCHEDULE_HORIZONTAL.getName();
|
||||
// LP2 with Down-payment + advanced payment allocation + progressive loan schedule + horizontal
|
||||
// (LP2_DOWNPAYMENT_ADV_PMT_ALLOC_PROGRESSIVE_LOAN_SCHEDULE_HORIZONTAL)
|
||||
String name20 = DefaultLoanProduct.LP2_DOWNPAYMENT_ADV_PMT_ALLOC_PROGRESSIVE_LOAN_SCHEDULE_HORIZONTAL.getName();
|
||||
PostLoanProductsRequest loanProductsRequestDownPaymentAdvPaymentAllocationProgressiveLoanSchedule = loanProductsRequestFactory
|
||||
.defaultLoanProductsRequestPin4()//
|
||||
.defaultLoanProductsRequestLP2()//
|
||||
.name(name20)//
|
||||
.transactionProcessingStrategyCode(ADVANCED_PAYMENT_ALLOCATION.getValue())//
|
||||
.loanScheduleType("PROGRESSIVE") //
|
||||
@@ -375,14 +374,14 @@ public class LoanProductGlobalInitializerStep implements FineractGlobalInitializ
|
||||
Response<PostLoanProductsResponse> responseLoanProductsRequestDownPaymentAdvPaymentAllocationProgressiveLoanSchedule = loanProductsApi
|
||||
.createLoanProduct(loanProductsRequestDownPaymentAdvPaymentAllocationProgressiveLoanSchedule).execute();
|
||||
TestContext.INSTANCE.set(
|
||||
TestContextKey.DEFAULT_LOAN_PRODUCT_CREATE_RESPONSE_PIN4_DOWNPAYMENT_ADVANCED_PAYMENT_ALLOCATION_PROGRESSIVE_LOAN_SCHEDULE,
|
||||
TestContextKey.DEFAULT_LOAN_PRODUCT_CREATE_RESPONSE_LP2_DOWNPAYMENT_ADVANCED_PAYMENT_ALLOCATION_PROGRESSIVE_LOAN_SCHEDULE,
|
||||
responseLoanProductsRequestDownPaymentAdvPaymentAllocationProgressiveLoanSchedule);
|
||||
|
||||
// PIN4 with Down-payment + advanced payment allocation + progressive loan schedule + vertical
|
||||
// (PIN4_DOWNPAYMENT_ADV_PMT_ALLOC_PROGRESSIVE_LOAN_SCHEDULE_VERTICAL)
|
||||
String name21 = DefaultLoanProduct.PIN4_DOWNPAYMENT_ADV_PMT_ALLOC_PROGRESSIVE_LOAN_SCHEDULE_VERTICAL.getName();
|
||||
// LP2 with Down-payment + advanced payment allocation + progressive loan schedule + vertical
|
||||
// (LP2_DOWNPAYMENT_ADV_PMT_ALLOC_PROGRESSIVE_LOAN_SCHEDULE_VERTICAL)
|
||||
String name21 = DefaultLoanProduct.LP2_DOWNPAYMENT_ADV_PMT_ALLOC_PROGRESSIVE_LOAN_SCHEDULE_VERTICAL.getName();
|
||||
PostLoanProductsRequest loanProductsRequestDownPaymentAdvPaymentAllocationProgressiveLoanScheduleVertical = loanProductsRequestFactory
|
||||
.defaultLoanProductsRequestPin4()//
|
||||
.defaultLoanProductsRequestLP2()//
|
||||
.name(name21)//
|
||||
.transactionProcessingStrategyCode(ADVANCED_PAYMENT_ALLOCATION.getValue())//
|
||||
.loanScheduleType("PROGRESSIVE") //
|
||||
@@ -397,16 +396,16 @@ public class LoanProductGlobalInitializerStep implements FineractGlobalInitializ
|
||||
Response<PostLoanProductsResponse> responseLoanProductsRequestDownPaymentAdvPaymentAllocationProgressiveLoanScheduleVertical = loanProductsApi
|
||||
.createLoanProduct(loanProductsRequestDownPaymentAdvPaymentAllocationProgressiveLoanScheduleVertical).execute();
|
||||
TestContext.INSTANCE.set(
|
||||
TestContextKey.DEFAULT_LOAN_PRODUCT_CREATE_RESPONSE_PIN4_DOWNPAYMENT_ADVANCED_PAYMENT_ALLOCATION_PROGRESSIVE_LOAN_SCHEDULE_VERTICAL,
|
||||
TestContextKey.DEFAULT_LOAN_PRODUCT_CREATE_RESPONSE_LP2_DOWNPAYMENT_ADVANCED_PAYMENT_ALLOCATION_PROGRESSIVE_LOAN_SCHEDULE_VERTICAL,
|
||||
responseLoanProductsRequestDownPaymentAdvPaymentAllocationProgressiveLoanScheduleVertical);
|
||||
|
||||
// PIN4 with Down-payment + advanced payment allocation + progressive loan schedule + horizontal + installment
|
||||
// LP2 with Down-payment + advanced payment allocation + progressive loan schedule + horizontal + installment
|
||||
// level delinquency
|
||||
// (PIN4_DOWNPAYMENT_ADV_PMT_ALLOC_PROGRESSIVE_LOAN_SCHEDULE_HORIZONTAL_INSTALLMENT_LEVEL_DELINQUENCY)
|
||||
String name22 = DefaultLoanProduct.PIN4_DOWNPAYMENT_ADV_PMT_ALLOC_PROGRESSIVE_LOAN_SCHEDULE_HORIZONTAL_INSTALLMENT_LEVEL_DELINQUENCY
|
||||
// (LP2_DOWNPAYMENT_ADV_PMT_ALLOC_PROGRESSIVE_LOAN_SCHEDULE_HORIZONTAL_INSTALLMENT_LEVEL_DELINQUENCY)
|
||||
String name22 = DefaultLoanProduct.LP2_DOWNPAYMENT_ADV_PMT_ALLOC_PROGRESSIVE_LOAN_SCHEDULE_HORIZONTAL_INSTALLMENT_LEVEL_DELINQUENCY
|
||||
.getName();
|
||||
PostLoanProductsRequest loanProductsRequestDownPaymentAdvPaymentAllocationProgressiveLoanScheduleInstLvlDelinquency = loanProductsRequestFactory
|
||||
.defaultLoanProductsRequestPin4()//
|
||||
.defaultLoanProductsRequestLP2()//
|
||||
.name(name22)//
|
||||
.transactionProcessingStrategyCode(ADVANCED_PAYMENT_ALLOCATION.getValue())//
|
||||
.loanScheduleType("PROGRESSIVE") //
|
||||
@@ -422,16 +421,15 @@ public class LoanProductGlobalInitializerStep implements FineractGlobalInitializ
|
||||
Response<PostLoanProductsResponse> responseLoanProductsRequestDownPaymentAdvPaymentAllocationProgressiveLoanScheduleInstLvlDelinquency = loanProductsApi
|
||||
.createLoanProduct(loanProductsRequestDownPaymentAdvPaymentAllocationProgressiveLoanScheduleInstLvlDelinquency).execute();
|
||||
TestContext.INSTANCE.set(
|
||||
TestContextKey.DEFAULT_LOAN_PRODUCT_CREATE_RESPONSE_PIN4_DOWNPAYMENT_ADVANCED_PAYMENT_ALLOCATION_PROGRESSIVE_LOAN_SCHEDULE_INSTALLMENT_LEVEL_DELINQUENCY,
|
||||
TestContextKey.DEFAULT_LOAN_PRODUCT_CREATE_RESPONSE_LP2_DOWNPAYMENT_ADVANCED_PAYMENT_ALLOCATION_PROGRESSIVE_LOAN_SCHEDULE_INSTALLMENT_LEVEL_DELINQUENCY,
|
||||
responseLoanProductsRequestDownPaymentAdvPaymentAllocationProgressiveLoanScheduleInstLvlDelinquency);
|
||||
|
||||
// PIN4 with Down-payment + advanced payment allocation + progressive loan schedule + horizontal + installment
|
||||
// LP2 with Down-payment + advanced payment allocation + progressive loan schedule + horizontal + installment
|
||||
// level delinquency + creditAllocation
|
||||
// (PIN4_DOWNPAYMENT_ADV_PMT_ALLOC_PROGRESSIVE_LOAN_SCHEDULE_HORIZONTAL_INSTALLMENT_LEVEL_DELINQUENCY)
|
||||
String name23 = DefaultLoanProduct.PIN4_DOWNPAYMENT_ADV_PMT_ALLOC_PROG_SCHEDULE_HOR_INST_LVL_DELINQUENCY_CREDIT_ALLOCATION
|
||||
.getName();
|
||||
// (LP2_DOWNPAYMENT_ADV_PMT_ALLOC_PROGRESSIVE_LOAN_SCHEDULE_HORIZONTAL_INSTALLMENT_LEVEL_DELINQUENCY)
|
||||
String name23 = DefaultLoanProduct.LP2_DOWNPAYMENT_ADV_PMT_ALLOC_PROG_SCHEDULE_HOR_INST_LVL_DELINQUENCY_CREDIT_ALLOCATION.getName();
|
||||
PostLoanProductsRequest loanProductsRequestDownPaymentAdvPmtAllocProgSchedInstLvlDelinquencyCreditAllocation = loanProductsRequestFactory
|
||||
.defaultLoanProductsRequestPin4()//
|
||||
.defaultLoanProductsRequestLP2()//
|
||||
.name(name23)//
|
||||
.transactionProcessingStrategyCode(ADVANCED_PAYMENT_ALLOCATION.getValue())//
|
||||
.loanScheduleType("PROGRESSIVE") //
|
||||
@@ -450,15 +448,15 @@ public class LoanProductGlobalInitializerStep implements FineractGlobalInitializ
|
||||
Response<PostLoanProductsResponse> responseLoanProductsRequestDownPaymentAdvPmtAllocProgSchedInstLvlDelinquencyCreditAllocation = loanProductsApi
|
||||
.createLoanProduct(loanProductsRequestDownPaymentAdvPmtAllocProgSchedInstLvlDelinquencyCreditAllocation).execute();
|
||||
TestContext.INSTANCE.set(
|
||||
TestContextKey.DEFAULT_LOAN_PRODUCT_CREATE_RESPONSE_PIN4_DOWNPAYMENT_ADV_PMT_ALLOC_PROG_SCHEDULE_HOR_INST_LVL_DELINQUENCY_CREDIT_ALLOCATION,
|
||||
TestContextKey.DEFAULT_LOAN_PRODUCT_CREATE_RESPONSE_LP2_DOWNPAYMENT_ADV_PMT_ALLOC_PROG_SCHEDULE_HOR_INST_LVL_DELINQUENCY_CREDIT_ALLOCATION,
|
||||
responseLoanProductsRequestDownPaymentAdvPmtAllocProgSchedInstLvlDelinquencyCreditAllocation);
|
||||
|
||||
// PIN4 with Down-payment + advanced payment allocation + progressive loan schedule + horizontal + installment
|
||||
// LP2 with Down-payment + advanced payment allocation + progressive loan schedule + horizontal + installment
|
||||
// level delinquency + creditAllocation + fixed length (90)
|
||||
// (PIN4_DOWNPAYMENT_ADV_PMT_ALLOC_FIXED_LENGTH)
|
||||
String name25 = DefaultLoanProduct.PIN4_DOWNPAYMENT_ADV_PMT_ALLOC_FIXED_LENGTH.getName();
|
||||
// (LP2_DOWNPAYMENT_ADV_PMT_ALLOC_FIXED_LENGTH)
|
||||
String name25 = DefaultLoanProduct.LP2_DOWNPAYMENT_ADV_PMT_ALLOC_FIXED_LENGTH.getName();
|
||||
PostLoanProductsRequest loanProductsRequestDownPaymentAdvPmtAllocFixedLength = loanProductsRequestFactory
|
||||
.defaultLoanProductsRequestPin4()//
|
||||
.defaultLoanProductsRequestLP2()//
|
||||
.name(name25)//
|
||||
.transactionProcessingStrategyCode(ADVANCED_PAYMENT_ALLOCATION.getValue())//
|
||||
.loanScheduleType("PROGRESSIVE") //
|
||||
@@ -476,7 +474,7 @@ public class LoanProductGlobalInitializerStep implements FineractGlobalInitializ
|
||||
createPaymentAllocation("PAYOUT_REFUND", "NEXT_INSTALLMENT")));//
|
||||
Response<PostLoanProductsResponse> responseLoanProductsRequestDownPaymentAdvPmtAllocFixedLength = loanProductsApi
|
||||
.createLoanProduct(loanProductsRequestDownPaymentAdvPmtAllocFixedLength).execute();
|
||||
TestContext.INSTANCE.set(TestContextKey.DEFAULT_LOAN_PRODUCT_CREATE_RESPONSE_PIN4_DOWNPAYMENT_ADV_PMT_ALLOC_FIXED_LENGTH,
|
||||
TestContext.INSTANCE.set(TestContextKey.DEFAULT_LOAN_PRODUCT_CREATE_RESPONSE_LP2_DOWNPAYMENT_ADV_PMT_ALLOC_FIXED_LENGTH,
|
||||
responseLoanProductsRequestDownPaymentAdvPmtAllocFixedLength);
|
||||
}
|
||||
|
||||
|
||||
+29
-29
@@ -48,35 +48,35 @@ public abstract class TestContextKey {
|
||||
public static final String LOAN_REAMORTIZATION_RESPONSE = "loanReAmortizationResponse";
|
||||
public static final String LOAN_REAMORTIZATION_UNDO_RESPONSE = "loanReAmortizationUndoResponse";
|
||||
public static final String BUSINESS_DATE_RESPONSE = "businessDateResponse";
|
||||
public static final String DEFAULT_LOAN_PRODUCT_CREATE_RESPONSE_PIN30 = "loanProductCreateResponsePin30";
|
||||
public static final String DEFAULT_LOAN_PRODUCT_CREATE_RESPONSE_PIN30_DUE_DATE = "loanProductCreateResponsePin30DueDate";
|
||||
public static final String DEFAULT_LOAN_PRODUCT_CREATE_RESPONSE_PIN30_PAYMENT_STRATEGY_DUE_IN_ADVANCE = "loanProductCreateResponsePin30PaymentStrategyDueInAdvance";
|
||||
public static final String DEFAULT_LOAN_PRODUCT_CREATE_RESPONSE_PIN30_PAYMENT_STRATEGY_DUE_IN_ADVANCE_INTEREST_FLAT = "loanProductCreateResponsePin30PaymentStrategyDueInAdvanceInterestFlat";
|
||||
public static final String DEFAULT_LOAN_PRODUCT_CREATE_RESPONSE_PIN30_PAYMENT_STRATEGY_DUE_IN_ADVANCE_PENALTY_INTEREST_PRINCIPAL_FEE = "loanProductCreateResponsePin30PaymentStrategyDueInAdvancePenaltyInterestPrincipalFee";
|
||||
public static final String DEFAULT_LOAN_PRODUCT_CREATE_RESPONSE_PIN30_PAYMENT_STRATEGY_DUE_IN_ADVANCE_PENALTY_INTEREST_PRINCIPAL_FEE_INTEREST_FLAT = "loanProductCreateResponsePin30PaymentStrategyDueInAdvancePenaltyInterestPrincipalFeeInterestFlat";
|
||||
public static final String DEFAULT_LOAN_PRODUCT_CREATE_RESPONSE_PIN30_INTEREST_FLAT = "loanProductCreateResponsePin30InterestFlat";
|
||||
public static final String DEFAULT_LOAN_PRODUCT_CREATE_RESPONSE_PIN30_INTEREST_FLAT_OVERDUE_FROM_AMOUNT = "loanProductCreateResponsePin30InterestFlatOverdueFromAmount";
|
||||
public static final String DEFAULT_LOAN_PRODUCT_CREATE_RESPONSE_PIN30_INTEREST_FLAT_OVERDUE_FROM_AMOUNT_INTEREST = "loanProductCreateResponsePin30InterestFlatOverdueFromAmountInterest";
|
||||
public static final String DEFAULT_LOAN_PRODUCT_CREATE_RESPONSE_PIN30_INTEREST_DECLINING_BALANCE_MULTI_DISBURSE = "loanProductCreateResponsePin30InterestFlatMultiDisburse";
|
||||
public static final String DEFAULT_LOAN_PRODUCT_CREATE_RESPONSE_PIN30_INTEREST_DECLINING_PERIOD_SAME_AS_PAYMENT = "loanProductCreateResponsePin30InterestDecliningPeriodSameAsPayment";
|
||||
public static final String DEFAULT_LOAN_PRODUCT_CREATE_RESPONSE_PIN30_1MONTH_INTEREST_DECLINING_BALANCE_DAILY_RECALCULATION_COMPOUNDING_MONTHLY = "loanProductCreateResponsePin30InterestDecliningPeriodSameAsPaymentRecalculation";
|
||||
public static final String DEFAULT_LOAN_PRODUCT_CREATE_RESPONSE_PIN30_INTEREST_DECLINING_BALANCE_DAILY_RECALCULATION_COMPOUNDING_NONE = "loanProductCreateResponsePin30InterestDecliningBalanceDailyRecalculationCompoundingNone";
|
||||
public static final String DEFAULT_LOAN_PRODUCT_CREATE_RESPONSE_PIN30_INTEREST_DECLINING_BALANCE_DAILY_RECALCULATION_SAME_AS_REPAYMENT_COMPOUNDING_NONE = "loanProductCreateResponsePin30InterestDecliningBalanceDailyRecalculationSameAsRepaymentCompoundingNone";
|
||||
public static final String DEFAULT_LOAN_PRODUCT_CREATE_RESPONSE_PIN30_INTEREST_DECLINING_BALANCE_SAR_RECALCULATION_SAME_AS_REPAYMENT_COMPOUNDING_NONE_MULTI_DISBURSEMENT = "loanProductCreateResponsePin30InterestDecliningBalanceDailyRecalculationSameAsRepaymentCompoundingNoneMultiDisbursement";
|
||||
public static final String DEFAULT_LOAN_PRODUCT_CREATE_RESPONSE_PIN30_INTEREST_DECLINING_BALANCE_DAILY_RECALCULATION_COMPOUNDING_NONE_RESCHEDULE_REDUCE_NR_INSTALLMENTS = "loanProductCreateResponsePin30InterestDecliningBalanceDailyRecalculationCompoundingNoneRescheduleReduceNrInstallments";
|
||||
public static final String DEFAULT_LOAN_PRODUCT_CREATE_RESPONSE_PIN30_INTEREST_DECLINING_BALANCE_DAILY_RECALCULATION_COMPOUNDING_NONE_RESCHEDULE_NEXT_REPAYMENTS = "loanProductCreateResponsePin30InterestDecliningBalanceDailyRecalculationCompoundingNoneRescheduleNextRepayments";
|
||||
public static final String DEFAULT_LOAN_PRODUCT_CREATE_RESPONSE_PIN30_INTEREST_DECLINING_PERIOD_DAILY = "loanProductCreateResponsePin30InterestDecliningPeriodDaily";
|
||||
public static final String DEFAULT_LOAN_PRODUCT_CREATE_RESPONSE_PIN4_DOWNPAYMENT_AUTO_ADVANCED_PAYMENT_ALLOCATION = "loanProductCreateResponsePin4DownPaymentAutoAdvancedPaymentAllocation";
|
||||
public static final String DEFAULT_LOAN_PRODUCT_CREATE_RESPONSE_PIN4_DOWNPAYMENT_ADVANCED_PAYMENT_ALLOCATION = "loanProductCreateResponsePin4DownPaymentAdvancedPaymentAllocation";
|
||||
public static final String DEFAULT_LOAN_PRODUCT_CREATE_RESPONSE_PIN4_DOWNPAYMENT = "loanProductCreateResponsePin4DownPayment";
|
||||
public static final String DEFAULT_LOAN_PRODUCT_CREATE_RESPONSE_PIN4_DOWNPAYMENT_INTEREST = "loanProductCreateResponsePin4DownPaymentInterest";
|
||||
public static final String DEFAULT_LOAN_PRODUCT_CREATE_RESPONSE_PIN4_DOWNPAYMENT_INTEREST_AUTO = "loanProductCreateResponsePin4DownPaymentInterestAuto";
|
||||
public static final String DEFAULT_LOAN_PRODUCT_CREATE_RESPONSE_PIN4_DOWNPAYMENT_AUTO = "loanProductCreateResponsePin4DownPaymentAuto";
|
||||
public static final String DEFAULT_LOAN_PRODUCT_CREATE_RESPONSE_PIN4_DOWNPAYMENT_ADVANCED_PAYMENT_ALLOCATION_PROGRESSIVE_LOAN_SCHEDULE = "loanProductCreateResponsePin4DownPaymentProgressiveLoanSchedule";
|
||||
public static final String DEFAULT_LOAN_PRODUCT_CREATE_RESPONSE_PIN4_DOWNPAYMENT_ADVANCED_PAYMENT_ALLOCATION_PROGRESSIVE_LOAN_SCHEDULE_VERTICAL = "loanProductCreateResponsePin4DownPaymentProgressiveLoanScheduleVertical";
|
||||
public static final String DEFAULT_LOAN_PRODUCT_CREATE_RESPONSE_PIN4_DOWNPAYMENT_ADVANCED_PAYMENT_ALLOCATION_PROGRESSIVE_LOAN_SCHEDULE_INSTALLMENT_LEVEL_DELINQUENCY = "loanProductCreateResponsePin4DownPaymentProgressiveLoanScheduleInstallmentLevelDelinquency";
|
||||
public static final String DEFAULT_LOAN_PRODUCT_CREATE_RESPONSE_PIN4_DOWNPAYMENT_ADV_PMT_ALLOC_PROG_SCHEDULE_HOR_INST_LVL_DELINQUENCY_CREDIT_ALLOCATION = "loanProductCreateResponsePin4DownPaymentProgressiveLoanScheduleHorizontalInstallmentLevelDelinquencyCreditAllocation";
|
||||
public static final String DEFAULT_LOAN_PRODUCT_CREATE_RESPONSE_PIN4_DOWNPAYMENT_ADV_PMT_ALLOC_FIXED_LENGTH = "loanProductCreateResponsePin4DownPaymentProgressiveLoanScheduleFixedLength";
|
||||
public static final String DEFAULT_LOAN_PRODUCT_CREATE_RESPONSE_LP1 = "loanProductCreateResponseLP1";
|
||||
public static final String DEFAULT_LOAN_PRODUCT_CREATE_RESPONSE_LP1_DUE_DATE = "loanProductCreateResponseLP1DueDate";
|
||||
public static final String DEFAULT_LOAN_PRODUCT_CREATE_RESPONSE_LP1_PAYMENT_STRATEGY_DUE_IN_ADVANCE = "loanProductCreateResponseLP1PaymentStrategyDueInAdvance";
|
||||
public static final String DEFAULT_LOAN_PRODUCT_CREATE_RESPONSE_LP1_PAYMENT_STRATEGY_DUE_IN_ADVANCE_INTEREST_FLAT = "loanProductCreateResponseLP1PaymentStrategyDueInAdvanceInterestFlat";
|
||||
public static final String DEFAULT_LOAN_PRODUCT_CREATE_RESPONSE_LP1_PAYMENT_STRATEGY_DUE_IN_ADVANCE_PENALTY_INTEREST_PRINCIPAL_FEE = "loanProductCreateResponseLP1PaymentStrategyDueInAdvancePenaltyInterestPrincipalFee";
|
||||
public static final String DEFAULT_LOAN_PRODUCT_CREATE_RESPONSE_LP1_PAYMENT_STRATEGY_DUE_IN_ADVANCE_PENALTY_INTEREST_PRINCIPAL_FEE_INTEREST_FLAT = "loanProductCreateResponseLP1PaymentStrategyDueInAdvancePenaltyInterestPrincipalFeeInterestFlat";
|
||||
public static final String DEFAULT_LOAN_PRODUCT_CREATE_RESPONSE_LP1_INTEREST_FLAT = "loanProductCreateResponseLP1InterestFlat";
|
||||
public static final String DEFAULT_LOAN_PRODUCT_CREATE_RESPONSE_LP1_INTEREST_FLAT_OVERDUE_FROM_AMOUNT = "loanProductCreateResponseLP1InterestFlatOverdueFromAmount";
|
||||
public static final String DEFAULT_LOAN_PRODUCT_CREATE_RESPONSE_LP1_INTEREST_FLAT_OVERDUE_FROM_AMOUNT_INTEREST = "loanProductCreateResponseLP1InterestFlatOverdueFromAmountInterest";
|
||||
public static final String DEFAULT_LOAN_PRODUCT_CREATE_RESPONSE_LP1_INTEREST_DECLINING_BALANCE_MULTI_DISBURSE = "loanProductCreateResponseLP1InterestFlatMultiDisburse";
|
||||
public static final String DEFAULT_LOAN_PRODUCT_CREATE_RESPONSE_LP1_INTEREST_DECLINING_PERIOD_SAME_AS_PAYMENT = "loanProductCreateResponseLP1InterestDecliningPeriodSameAsPayment";
|
||||
public static final String DEFAULT_LOAN_PRODUCT_CREATE_RESPONSE_LP1_1MONTH_INTEREST_DECLINING_BALANCE_DAILY_RECALCULATION_COMPOUNDING_MONTHLY = "loanProductCreateResponseLP1InterestDecliningPeriodSameAsPaymentRecalculation";
|
||||
public static final String DEFAULT_LOAN_PRODUCT_CREATE_RESPONSE_LP1_INTEREST_DECLINING_BALANCE_DAILY_RECALCULATION_COMPOUNDING_NONE = "loanProductCreateResponseLP1InterestDecliningBalanceDailyRecalculationCompoundingNone";
|
||||
public static final String DEFAULT_LOAN_PRODUCT_CREATE_RESPONSE_LP1_INTEREST_DECLINING_BALANCE_DAILY_RECALCULATION_SAME_AS_REPAYMENT_COMPOUNDING_NONE = "loanProductCreateResponseLP1InterestDecliningBalanceDailyRecalculationSameAsRepaymentCompoundingNone";
|
||||
public static final String DEFAULT_LOAN_PRODUCT_CREATE_RESPONSE_LP1_INTEREST_DECLINING_BALANCE_SAR_RECALCULATION_SAME_AS_REPAYMENT_COMPOUNDING_NONE_MULTI_DISBURSEMENT = "loanProductCreateResponseLP1InterestDecliningBalanceDailyRecalculationSameAsRepaymentCompoundingNoneMultiDisbursement";
|
||||
public static final String DEFAULT_LOAN_PRODUCT_CREATE_RESPONSE_LP1_INTEREST_DECLINING_BALANCE_DAILY_RECALCULATION_COMPOUNDING_NONE_RESCHEDULE_REDUCE_NR_INSTALLMENTS = "loanProductCreateResponseLP1InterestDecliningBalanceDailyRecalculationCompoundingNoneRescheduleReduceNrInstallments";
|
||||
public static final String DEFAULT_LOAN_PRODUCT_CREATE_RESPONSE_LP1_INTEREST_DECLINING_BALANCE_DAILY_RECALCULATION_COMPOUNDING_NONE_RESCHEDULE_NEXT_REPAYMENTS = "loanProductCreateResponseLP1InterestDecliningBalanceDailyRecalculationCompoundingNoneRescheduleNextRepayments";
|
||||
public static final String DEFAULT_LOAN_PRODUCT_CREATE_RESPONSE_LP1_INTEREST_DECLINING_PERIOD_DAILY = "loanProductCreateResponseLP1InterestDecliningPeriodDaily";
|
||||
public static final String DEFAULT_LOAN_PRODUCT_CREATE_RESPONSE_LP2_DOWNPAYMENT_AUTO_ADVANCED_PAYMENT_ALLOCATION = "loanProductCreateResponseLP2DownPaymentAutoAdvancedPaymentAllocation";
|
||||
public static final String DEFAULT_LOAN_PRODUCT_CREATE_RESPONSE_LP2_DOWNPAYMENT_ADVANCED_PAYMENT_ALLOCATION = "loanProductCreateResponseLP2DownPaymentAdvancedPaymentAllocation";
|
||||
public static final String DEFAULT_LOAN_PRODUCT_CREATE_RESPONSE_LP2_DOWNPAYMENT = "loanProductCreateResponseLP2DownPayment";
|
||||
public static final String DEFAULT_LOAN_PRODUCT_CREATE_RESPONSE_LP2_DOWNPAYMENT_INTEREST = "loanProductCreateResponseLP2DownPaymentInterest";
|
||||
public static final String DEFAULT_LOAN_PRODUCT_CREATE_RESPONSE_LP2_DOWNPAYMENT_INTEREST_AUTO = "loanProductCreateResponseLP2DownPaymentInterestAuto";
|
||||
public static final String DEFAULT_LOAN_PRODUCT_CREATE_RESPONSE_LP2_DOWNPAYMENT_AUTO = "loanProductCreateResponseLP2DownPaymentAuto";
|
||||
public static final String DEFAULT_LOAN_PRODUCT_CREATE_RESPONSE_LP2_DOWNPAYMENT_ADVANCED_PAYMENT_ALLOCATION_PROGRESSIVE_LOAN_SCHEDULE = "loanProductCreateResponseLP2DownPaymentProgressiveLoanSchedule";
|
||||
public static final String DEFAULT_LOAN_PRODUCT_CREATE_RESPONSE_LP2_DOWNPAYMENT_ADVANCED_PAYMENT_ALLOCATION_PROGRESSIVE_LOAN_SCHEDULE_VERTICAL = "loanProductCreateResponseLP2DownPaymentProgressiveLoanScheduleVertical";
|
||||
public static final String DEFAULT_LOAN_PRODUCT_CREATE_RESPONSE_LP2_DOWNPAYMENT_ADVANCED_PAYMENT_ALLOCATION_PROGRESSIVE_LOAN_SCHEDULE_INSTALLMENT_LEVEL_DELINQUENCY = "loanProductCreateResponseLP2DownPaymentProgressiveLoanScheduleInstallmentLevelDelinquency";
|
||||
public static final String DEFAULT_LOAN_PRODUCT_CREATE_RESPONSE_LP2_DOWNPAYMENT_ADV_PMT_ALLOC_PROG_SCHEDULE_HOR_INST_LVL_DELINQUENCY_CREDIT_ALLOCATION = "loanProductCreateResponseLP2DownPaymentProgressiveLoanScheduleHorizontalInstallmentLevelDelinquencyCreditAllocation";
|
||||
public static final String DEFAULT_LOAN_PRODUCT_CREATE_RESPONSE_LP2_DOWNPAYMENT_ADV_PMT_ALLOC_FIXED_LENGTH = "loanProductCreateResponseLP2DownPaymentProgressiveLoanScheduleFixedLength";
|
||||
public static final String CHARGE_FOR_LOAN_PERCENT_LATE_CREATE_RESPONSE = "ChargeForLoanPercentLateCreateResponse";
|
||||
public static final String CHARGE_FOR_LOAN_PERCENT_LATE_AMOUNT_PLUS_INTEREST_CREATE_RESPONSE = "ChargeForLoanPercentLateAmountPlusInterestCreateResponse";
|
||||
public static final String CHARGE_FOR_LOAN_PERCENT_PROCESSING_CREATE_RESPONSE = "ChargeForLoanPercentProcessingCreateResponse";
|
||||
|
||||
Reference in New Issue
Block a user