angelboxes commented on a change in pull request #571: FINERACT-689
URL: https://github.com/apache/fineract/pull/571#discussion_r294898273
##########
File path:
fineract-provider/src/main/java/org/apache/fineract/portfolio/interestratechart/data/InterestRateChartSlabDataValidator.java
##########
@@ -249,7 +249,8 @@ public void validateChartSlabsUpdate(final JsonElement
element, final DataValida
if
(this.fromApiJsonHelper.parameterExists(annualInterestRateParamName, element)) {
final BigDecimal annualInterestRate =
this.fromApiJsonHelper.extractBigDecimalNamed(annualInterestRateParamName,
element,
locale);
-
baseDataValidator.reset().parameter(annualInterestRateParamName).value(annualInterestRate).notNull().zeroOrPositiveAmount();
+ //Change made to not to allow interest rate more than 100%
+
baseDataValidator.reset().parameter(annualInterestRateParamName).value(annualInterestRate).notNull().zeroOrPositiveAmount()value(annualInterestRate).notNull().zeroOrPositiveAmount().notGreaterThanMax(new
BigDecimal(100));
Review comment:
I think there's something missing or extra around
zeroOrPositiveAmount()value, there are some repeated function calls here, it
should be fixed just by removing them.
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[email protected]
With regards,
Apache Git Services