feat(fixed-deposits): maturity approval UI, scoped to deposits with no closure instruction
Adds the FD Maturity Reports screen (due-without-report, generate/ approve, branch and head-office scope, detail with closure instruction and estimated interest per deposit), a nav entry, the route, and Branch Day Closing's maturing-today section and approval-pending warning banner. Adds "Matured automatically" to the maturity screen: deposits that settled via their own Transfer-to-Savings or Reinvest instruction, needing no approval, listed for visibility with product totals and per-deposit detail. Adds "Product summary" to the FD Interest Posting Reports screen (head office): interest by product and scheme — posted through the report, still pending, and posted directly at maturity instead — added up to what each product has paid out in total over a period. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
This commit is contained in:
@@ -28,6 +28,11 @@
|
||||
<button class="fd-btn" (click)="openOutsideApproval()" [disabled]="outsideApprovalLoading">
|
||||
<fa-icon icon="bolt"></fa-icon>Posted outside approval
|
||||
</button>
|
||||
@if (isHeadOffice) {
|
||||
<button class="fd-btn" (click)="openProductSummary()" [disabled]="productSummaryLoading">
|
||||
<fa-icon icon="table"></fa-icon>Product summary
|
||||
</button>
|
||||
}
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@@ -376,6 +381,108 @@
|
||||
</div>
|
||||
}
|
||||
|
||||
@if (showProductSummary) {
|
||||
<div class="fd-card">
|
||||
<div class="fd-detail-head">
|
||||
<div>
|
||||
<h3>Interest by product</h3>
|
||||
<div class="muted">
|
||||
Posted through this report, still awaiting approval or posting, and posted directly at maturity instead —
|
||||
added up to what the product has paid out in total over the period.
|
||||
</div>
|
||||
</div>
|
||||
<div class="fd-total">
|
||||
<span>Total, all products</span>
|
||||
<strong>₹{{ productSummaryGrandTotal.total | number: '1.2-2' }}</strong>
|
||||
</div>
|
||||
</div>
|
||||
<div
|
||||
style="
|
||||
display: flex;
|
||||
flex-wrap: wrap;
|
||||
align-items: flex-end;
|
||||
gap: 10px;
|
||||
padding: 14px 20px;
|
||||
border-bottom: 1px solid var(--fd-border-soft);
|
||||
"
|
||||
>
|
||||
<label class="fd-date">
|
||||
From
|
||||
<input type="date" [(ngModel)]="productSummaryFrom" (change)="loadProductSummary()" />
|
||||
</label>
|
||||
<label class="fd-date">
|
||||
To
|
||||
<input type="date" [(ngModel)]="productSummaryTo" (change)="loadProductSummary()" />
|
||||
</label>
|
||||
<button class="fd-btn fd-btn--slim" (click)="loadProductSummary()" [disabled]="productSummaryLoading">
|
||||
<fa-icon icon="undo"></fa-icon>Refresh
|
||||
</button>
|
||||
<button class="fd-btn fd-btn--slim" (click)="closeProductSummary()">
|
||||
<fa-icon icon="times"></fa-icon>Close
|
||||
</button>
|
||||
</div>
|
||||
@if (productSummaryLoading) {
|
||||
<div class="fd-empty">Adding up interest by product…</div>
|
||||
} @else {
|
||||
<div class="fd-table-wrap">
|
||||
<table class="fd-table">
|
||||
<thead>
|
||||
<tr>
|
||||
<th>Product</th>
|
||||
<th>Scheme</th>
|
||||
<th>Posting period</th>
|
||||
<th class="num">Posted (report)</th>
|
||||
<th class="num">Pending approval</th>
|
||||
<th class="num">Posted at maturity</th>
|
||||
<th class="num">Total</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
@for (row of productSummaryRows; track row.productId) {
|
||||
<tr>
|
||||
<td>
|
||||
<strong>{{ row.productName }}</strong>
|
||||
</td>
|
||||
<td>
|
||||
<span class="fd-chip" [ngClass]="fdTypeClass(row.fdType)">{{ fdTypeShort(row.fdType) }}</span>
|
||||
</td>
|
||||
<td class="fd-sub">{{ row.postingPeriodLabel || '—' }}</td>
|
||||
<td class="num">₹{{ row.posted | number: '1.2-2' }}</td>
|
||||
<td class="num">₹{{ row.pending | number: '1.2-2' }}</td>
|
||||
<td class="num">₹{{ row.maturityPosted | number: '1.2-2' }}</td>
|
||||
<td class="num">
|
||||
<strong>₹{{ row.total | number: '1.2-2' }}</strong>
|
||||
</td>
|
||||
</tr>
|
||||
} @empty {
|
||||
<tr>
|
||||
<td colspan="7" class="fd-empty">No fixed deposit interest in this period.</td>
|
||||
</tr>
|
||||
}
|
||||
</tbody>
|
||||
<tfoot>
|
||||
<tr>
|
||||
<td colspan="3"><strong>Total</strong></td>
|
||||
<td class="num">
|
||||
<strong>₹{{ productSummaryGrandTotal.posted | number: '1.2-2' }}</strong>
|
||||
</td>
|
||||
<td class="num">
|
||||
<strong>₹{{ productSummaryGrandTotal.pending | number: '1.2-2' }}</strong>
|
||||
</td>
|
||||
<td class="num">
|
||||
<strong>₹{{ productSummaryGrandTotal.maturityPosted | number: '1.2-2' }}</strong>
|
||||
</td>
|
||||
<td class="num">
|
||||
<strong>₹{{ productSummaryGrandTotal.total | number: '1.2-2' }}</strong>
|
||||
</td>
|
||||
</tr>
|
||||
</tfoot>
|
||||
</table>
|
||||
</div>
|
||||
}
|
||||
</div>
|
||||
}
|
||||
|
||||
<div class="fd-card">
|
||||
<div class="fd-card-h">
|
||||
<h2>Reports{{ postingDate ? ' for ' + postingDate : '' }}</h2>
|
||||
|
||||
Reference in New Issue
Block a user