-
Notifications
You must be signed in to change notification settings - Fork 2.2k
FINERACT-2398: Re-amortization Interest Handling configuration #5117
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
FINERACT-2398: Re-amortization Interest Handling configuration #5117
Conversation
f40850c to
b05ea7d
Compare
budaidev
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Check the naming and reaging references before submit
| * specific language governing permissions and limitations | ||
| * under the License. | ||
| */ | ||
| package org.apache.fineract.portfolio.loanaccount.domain.reaging; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Any reason for LoanReAmortizationInterestHandlingType to be in the reaging package instead of the reamortization package?
| import org.springframework.data.jpa.repository.JpaRepository; | ||
| import org.springframework.data.repository.query.Param; | ||
|
|
||
| public interface LoanReAgingParameterRepository extends JpaRepository<LoanReAmortizationParameter, Long> { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Doing only LoanReAmortizationParameter related operation in the LoanReAgingParameterRepository seems confusing
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done! I've updated the java package
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please rename from LoanReAgingParameterRepository to LoanReAmortizationParameterRepository
|
|
||
| CodeValue reasonCodeValue = null; | ||
| if (command.parameterExists(LoanReAgingApiConstants.reasonCodeValueIdParamName)) { | ||
| reasonCodeValue = codeValueRepository.findByCodeNameAndId(LoanApiConstants.REAGE_REASONS, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I might be wrong, but isn't it LoanApiConstants.REAMORTIZATION_REASONS?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done! Code updated
| } | ||
|
|
||
| CodeValue reasonCodeValue = null; | ||
| if (command.parameterExists(LoanReAgingApiConstants.reasonCodeValueIdParamName)) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Isn't it LoanReAmortizationApiConstants instead of LoanReAgingApiConstants?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done! Code updated
|
|
||
| private LoanReAmortizationValidator underTest = new LoanReAmortizationValidator(); | ||
| @InjectMocks | ||
| private LoanReAmortizationValidator underTest; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You changed here to InjectMocks instead of the creation, how we handle the CodeValueRepository which is injected inside the LoanReAmortizationValidator? Do we validate if it is correct?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@budaidev I am not changing the Test by Itself, I mean currently there is not a validation to include the CodeValueRepository, I don't know If I need to include this
b05ea7d to
34fff4b
Compare
adamsaghy
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please kindly see my review!
453c507 to
2a5c1fd
Compare
2a5c1fd to
74c04db
Compare
adamsaghy
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
Description
User should be able to do re-amortization on Interest bearing loan accounts as well (progressive strategy only)
User should be able to select the following Interest handling subtypes from the drop down during application of re-amortization to the loan account
FINERACT-2398
Checklist
Please make sure these boxes are checked before submitting your pull request - thanks!
FYI our guidelines for code reviews are at https://cwiki.apache.org/confluence/display/FINERACT/Code+Review+Guide.