FINERACT-2577: Allow adjust (modify) of Fixed Deposit transactions#5733
Open
AshharAhmadKhan wants to merge 1 commit intoapache:developfrom
Open
FINERACT-2577: Allow adjust (modify) of Fixed Deposit transactions#5733AshharAhmadKhan wants to merge 1 commit intoapache:developfrom
AshharAhmadKhan wants to merge 1 commit intoapache:developfrom
Conversation
DeathGun44
suggested changes
Apr 3, 2026
...java/org/apache/fineract/integrationtests/common/fixeddeposit/FixedDepositAccountHelper.java
Outdated
Show resolved
Hide resolved
355f132 to
22719df
Compare
Contributor
Author
|
Thanks for the review!
|
22719df to
d4339e2
Compare
Contributor
Author
|
Spotless applied, the remaining one check should also pass now. |
Contributor
Author
|
@adamsaghy same flaky E2E shard pattern as #5590 — |
Contributor
Author
|
@adamsaghy pinging you on this one as well , please take a look when you're free! Happy to make any changes if you need. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
Fixes a silently broken adjust (modify) transaction endpoint for Fixed Deposit accounts. The bug exists in the same 3-layer pattern as the undo bug fixed by PR #5590 (FINERACT-2463).
Layer 1 — Wrong command builder called:
FixedDepositAccountTransactionsApiResource.javawas callingbuilder.adjustSavingsAccountTransaction(), routing every FD modify request to theSAVINGSACCOUNTcommand handler instead ofFIXEDDEPOSITACCOUNT.Layer 2 — Missing builder method:
adjustFixedDepositAccountTransaction()did not exist inCommandWrapperBuilder.java. Added withactionName = "ADJUSTTRANSACTION"andentityName = "FIXEDDEPOSITACCOUNT".Layer 3 — Stub implementation replaced:
adjustFDTransaction()inDepositAccountWritePlatformServiceJpaRepositoryImpl.javawas an unconditional stub that always threwDepositAccountTransactionNotAllowedException(both params were@SuppressWarnings("unused")). Replaced with full implementation modelled on the savings account equivalent, with FD-specific behaviour:FixedDepositAccountcast,updateMaturityDateAndAmount(), 7-parampostInterest(), and no RD-only calls.FixedDepositTransactionAdjustmentCommandHandlerwas already correctly annotated — no changes needed.Files changed:
CommandWrapperBuilder.java— addedadjustFixedDepositAccountTransaction()FixedDepositAccountTransactionsApiResource.java— one-line fix, call FD-specific builder methodDepositAccountWritePlatformServiceJpaRepositoryImpl.java— full implementation replacing stubFixedDepositAccountHelper.java— addedadjustFixedDepositTransaction()using typed Feign clientFixedDepositTest.java— addedtestFixedDepositAccountAdjustTransaction()with CASH_BASED accounting, journal entry assertions, and reversal verificationNo Swagger changes needed — PR #5590 already added the required annotations.
Closes: https://issues.apache.org/jira/browse/FINERACT-2577