feat: updates for tds services, rbi reserve config, and cashier api resources
This commit is contained in:
+23
@@ -795,6 +795,29 @@ public class SavingsAccount extends AbstractAuditableWithUTCDateTimeCustom<Long>
|
||||
return false;
|
||||
}
|
||||
|
||||
/**
|
||||
* Deducts TDS from this savings account on FD/RD interest that has just been credited to it.
|
||||
*
|
||||
* <p>
|
||||
* Whether anything is due, and how much, is decided outside the entity - the threshold is tested on
|
||||
* the customer's interest across the bank and a declaration on record switches it off. This only
|
||||
* posts the withhold-tax debit and brings the running balances and summary up to date, as any other
|
||||
* transaction on the account would.
|
||||
*
|
||||
* @param taxSplit
|
||||
* the amount per tax component; the component's credit account is where the accounting
|
||||
* entry sends the tax
|
||||
*/
|
||||
public SavingsAccountTransaction deductTds(final LocalDate date, final BigDecimal amount, final Map<TaxComponent, BigDecimal> taxSplit) {
|
||||
final SavingsAccountTransaction tds = SavingsAccountTransaction.withHoldTax(this, office(), date, Money.of(this.currency, amount),
|
||||
taxSplit);
|
||||
addTransaction(tds);
|
||||
final LocalDate businessDate = DateUtils.getBusinessLocalDate();
|
||||
recalculateDailyBalances(Money.zero(this.currency), DateUtils.isAfter(date, businessDate) ? date : businessDate, false, false);
|
||||
this.summary.updateSummary(this.currency, this.savingsAccountTransactionSummaryWrapper, this.transactions);
|
||||
return tds;
|
||||
}
|
||||
|
||||
protected SavingsAccountTransaction findInterestPostingTransactionFor(final LocalDate postingDate) {
|
||||
SavingsAccountTransaction postingTransation = null;
|
||||
List<SavingsAccountTransaction> trans = getTransactions();
|
||||
|
||||
Reference in New Issue
Block a user