feat: letter-mgmt module + digital UPI/IMPS/ATM-POS reports + header redesign

letter-mgmt (new module):
- Notice page: overdue loan list with filters, KPI strip, bulk actions,
  call disposition logging (Promise-to-Pay, Not Reachable, etc.), Speed
  Post dispatch dialog with consignment + post-office tracking,
  PDF preview + download, call-contact dialog with primary / alt /
  family / nominee numbers and per-contact disposition history.
- Certificates: Loan Interest, Share, Balance, Form 60 (no-PAN flow),
  Form 15G/H (auto age-based), Hypothecation, NOC - each with shared
  preview dialog (six tone variants) and jsPDF generator using a
  common letterhead / summary-grid / signature-seal helper.

digital:
- IMPS module: report (P2A/P2P/Aadhaar tabs) + entry form with
  MMID/mobile lookup, NPCI switch resolve-to-A/C+IFSC BANL flow,
  sender autocomplete, hide sender field for P2P/Aadhaar, charges +
  18% GST + waive checkbox, per-sender today-only history dialog.
- UPI report with app-mix tab and full transaction filtering.
- ATM/POS/ECOM hub with three ticket cards routing to today/status/cycle.
- NEFT/RTGS entry: sender-account autocomplete, charges + GST + waive,
  field reorder (sender before amount), NEFT cap / RTGS floor
  validation, History button opening per-sender today's transactions.
- NEFT/RTGS report: horizontal-bar trend leaderboard replacing tall bars.

shell + theme:
- Header redesigned with IBM Plex Sans 12/500 typography, 11-column grid
  per row, top-accent hover indicator, bordered cells via grid-gap.
- Live KPI ticker below menu (CASH, TXN TODAY, CLEARING IN/OUT, NPA,
  CASA, CD RATIO, RBI CIRC, REPO) with marquee scroll, pause-on-hover,
  brand-blue gradient, amber bottom strip, pulsing red LIVE chip.
- Sidebar 'KYC Management' -> 'KYC & ReKYC Management'.
- Letter Mgmt / certificate menu items wired with green icon hints for
  items that have a working page.

access-control:
- MFA card layout compacted; method header inlines back button + title.

icons:
- Register faTruck/TruckFast, faEllipsisV/H, faCommentDots.
- Add IBM Plex Sans Google Fonts import to index.html.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
This commit is contained in:
Aditya
2026-05-19 10:09:06 +05:30
co-authored by Claude Opus 4.7
parent 4322f37c6d
commit 325228c514
138 changed files with 27473 additions and 3997 deletions
@@ -0,0 +1,164 @@
<!--
Copyright since 2025 Mifos Initiative
This Source Code Form is subject to the terms of the Mozilla Public
License, v. 2.0. If a copy of the MPL was not distributed with this
file, You can obtain one at http://mozilla.org/MPL/2.0/.
-->
<div class="cert-root">
<!-- HEADER -->
<div class="cert-head">
<div class="cert-head-l">
<fa-icon icon="certificate" class="cert-head-ic"></fa-icon>
<div>
<h2 class="cert-head-t">Share Certificate</h2>
<div class="cert-head-s">
Issue, preview and download member share certificates with folio + share-number range.
</div>
</div>
</div>
</div>
<!-- KPI STRIP -->
<div class="cert-kpis">
<div class="cert-kpi cert-kpi--blue">
<fa-icon icon="certificate" class="cert-kpi-ic"></fa-icon>
<div>
<div class="cert-kpi-n">{{ filteredRecords.length | number }}</div>
<div class="cert-kpi-l">Certificates</div>
</div>
</div>
<div class="cert-kpi cert-kpi--teal">
<fa-icon icon="cube" class="cert-kpi-ic"></fa-icon>
<div>
<div class="cert-kpi-n">{{ totalShares() | number }}</div>
<div class="cert-kpi-l">Shares Held</div>
</div>
</div>
<div class="cert-kpi cert-kpi--green">
<fa-icon icon="coins" class="cert-kpi-ic"></fa-icon>
<div>
<div class="cert-kpi-n">₹{{ totalShareValue() | number: '1.0-0' }}</div>
<div class="cert-kpi-l">Total Face Value</div>
</div>
</div>
</div>
<!-- FILTERS -->
<div class="cert-filters">
<div class="cert-filter">
<label>Certificate / Folio / Member / PAN</label>
<div class="cert-input-ic">
<fa-icon icon="search"></fa-icon>
<input type="text" [(ngModel)]="search" placeholder="e.g. SC-2024-000123 or member name" />
</div>
</div>
<div class="cert-filter">
<label>Share class</label>
<select [(ngModel)]="classFilter">
<option value="">All classes</option>
@for (o of classOptions; track o.value) {
<option [value]="o.value">{{ o.label }}</option>
}
</select>
</div>
<div class="cert-filter">
<label>Branch</label>
<select [(ngModel)]="branchFilter">
<option value="">All branches</option>
@for (b of branchOptions; track b) {
<option [value]="b">{{ b }}</option>
}
</select>
</div>
@if (search || classFilter || branchFilter) {
<button type="button" class="cert-clear" (click)="clearFilters()"><fa-icon icon="times"></fa-icon> Clear</button>
}
</div>
<!-- TABLE -->
<div class="cert-card">
<div class="cert-table-wrap">
<table class="cert-table">
<thead>
<tr>
<th>Member · Folio</th>
<th>Certificate No.</th>
<th>Class</th>
<th>Branch</th>
<th class="num">Shares</th>
<th class="num">Face Value</th>
<th class="num">Total</th>
<th>Share Nos.</th>
<th>Issued</th>
<th class="col-actions">Actions</th>
</tr>
</thead>
<tbody>
@for (r of filteredRecords; track r.certificateNo) {
<tr>
<td>
<div class="cert-cust-name">{{ r.memberName }}</div>
<div class="mono small muted">
{{ r.memberId }} · Folio <span class="cert-folio">{{ r.folioNo }}</span> · PAN {{ r.memberPan }}
</div>
</td>
<td class="mono">{{ r.certificateNo }}</td>
<td>
<span
class="cert-pill"
[class.cert-pill--blue]="r.shareClass === 'ORDINARY'"
[class.cert-pill--amber]="r.shareClass === 'PREFERENCE'"
>
{{ classLabel(r.shareClass) }}
</span>
</td>
<td class="small">{{ r.branch }}</td>
<td class="num">
<strong class="cert-shares">{{ r.shareCount | number }}</strong>
</td>
<td class="num">₹{{ r.faceValue | number: '1.0-0' }}</td>
<td class="num">
<strong>₹{{ r.shareCount * r.faceValue | number: '1.0-0' }}</strong>
</td>
<td class="mono small">{{ r.shareNoFrom }}&ndash;{{ r.shareNoTo }}</td>
<td class="small">{{ r.issueDate | date: 'd MMM y' }}</td>
<td class="col-actions">
<div class="cert-row-actions">
<button
type="button"
class="cert-icon-btn primary"
(click)="viewCertificate(r)"
matTooltip="View / Print certificate"
>
<fa-icon icon="eye"></fa-icon>
</button>
<button
type="button"
class="cert-icon-btn"
(click)="downloadCertificate(r)"
matTooltip="Download PDF"
>
<fa-icon icon="download"></fa-icon>
</button>
</div>
</td>
</tr>
}
@if (filteredRecords.length === 0) {
<tr>
<td colspan="10" class="cert-empty">
<fa-icon icon="info-circle"></fa-icon>
No share certificates match the current filters.
</td>
</tr>
}
</tbody>
</table>
</div>
</div>
</div>
@@ -0,0 +1,263 @@
/**
* Copyright since 2025 Mifos Initiative
*
* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at http://mozilla.org/MPL/2.0/.
*/
import { Component, inject, OnInit } from '@angular/core';
import { CommonModule } from '@angular/common';
import { FormsModule } from '@angular/forms';
import { FaIconComponent } from '@fortawesome/angular-fontawesome';
import { MatDialog } from '@angular/material/dialog';
import { MatSnackBar } from '@angular/material/snack-bar';
import { MatTooltip } from '@angular/material/tooltip';
import { STANDALONE_SHARED_IMPORTS } from 'app/standalone-shared.module';
import {
CertificatePreviewDialogComponent,
CertificatePreviewDialogData
} from '../certificate-preview-dialog/certificate-preview-dialog.component';
import { downloadShareCertificatePdf } from '../certificate-pdf';
export type ShareClass = 'ORDINARY' | 'PREFERENCE';
export interface ShareCertificateRecord {
certificateNo: string;
folioNo: string;
memberId: string;
memberName: string;
memberPan: string;
memberAddress: string;
branch: string;
joiningDate: string;
shareClass: ShareClass;
shareCount: number;
faceValue: number;
issueDate: string;
/** Distinct numeric range of share numbers held (e.g. 1001–1100). */
shareNoFrom: number;
shareNoTo: number;
/** Total dividend received since joining. */
dividendYtd: number;
}
@Component({
selector: 'mifosx-share-certificate',
templateUrl: './share-certificate.component.html',
styleUrls: ['../certificates.shared.scss'],
imports: [
...STANDALONE_SHARED_IMPORTS,
CommonModule,
FormsModule,
FaIconComponent,
MatTooltip
]
})
export class ShareCertificateComponent implements OnInit {
private dialog = inject(MatDialog);
private snack = inject(MatSnackBar);
// ── Filters ──
search = '';
classFilter: '' | ShareClass = '';
branchFilter = '';
records: ShareCertificateRecord[] = [];
readonly classOptions: { value: ShareClass; label: string }[] = [
{ value: 'ORDINARY', label: 'Ordinary' },
{ value: 'PREFERENCE', label: 'Preference' }
];
ngOnInit(): void {
this.records = seedShareCertificates();
}
// ── Derived list ──
get filteredRecords(): ShareCertificateRecord[] {
const q = this.search.trim().toLowerCase();
const branch = this.branchFilter.trim().toLowerCase();
return this.records.filter((r) => {
if (this.classFilter && r.shareClass !== this.classFilter) return false;
if (branch && !r.branch.toLowerCase().includes(branch)) return false;
if (!q) return true;
return (
r.certificateNo.toLowerCase().includes(q) ||
r.folioNo.toLowerCase().includes(q) ||
r.memberId.toLowerCase().includes(q) ||
r.memberName.toLowerCase().includes(q) ||
r.memberPan.toLowerCase().includes(q)
);
});
}
get branchOptions(): string[] {
return Array.from(new Set(this.records.map((r) => r.branch))).sort();
}
classLabel(c: ShareClass): string {
return this.classOptions.find((o) => o.value === c)?.label || c;
}
totalShares(): number {
return this.filteredRecords.reduce((s, r) => s + r.shareCount, 0);
}
totalShareValue(): number {
return this.filteredRecords.reduce((s, r) => s + r.shareCount * r.faceValue, 0);
}
// ── Actions ──
clearFilters(): void {
this.search = '';
this.classFilter = '';
this.branchFilter = '';
}
viewCertificate(r: ShareCertificateRecord): void {
const data: CertificatePreviewDialogData = {
kind: 'share',
shareCertificate: r
};
this.dialog.open(CertificatePreviewDialogComponent, {
width: '880px',
maxWidth: '96vw',
maxHeight: '92vh',
autoFocus: false,
panelClass: 'cert-preview-dialog',
data
});
}
downloadCertificate(r: ShareCertificateRecord): void {
downloadShareCertificatePdf(r);
this.snack.open(`Share Certificate ${r.certificateNo} downloaded.`, 'OK', { duration: 2400 });
}
}
// ───────────────────── Mock seed (top-level export) ─────────────────────
export function seedShareCertificates(): ShareCertificateRecord[] {
return [
{
certificateNo: 'SC-2024-000123',
folioNo: 'F-00482',
memberId: 'MBR000482',
memberName: 'Rohan S. Mehta',
memberPan: 'ABCPM1234E',
memberAddress: 'Flat 902, Skyline Apt, Andheri (E), Mumbai 400069',
branch: 'Mumbai — Andheri (E)',
joiningDate: '2018-04-22',
shareClass: 'ORDINARY',
shareCount: 100,
faceValue: 100,
issueDate: '2018-04-22',
shareNoFrom: 48201,
shareNoTo: 48300,
dividendYtd: 7200
},
{
certificateNo: 'SC-2024-000124',
folioNo: 'F-00713',
memberId: 'MBR000713',
memberName: 'Anita Verma',
memberPan: 'EFGHV5678A',
memberAddress: 'B-12, Connaught Pl, New Delhi 110001',
branch: 'New Delhi — Connaught Place',
joiningDate: '2019-08-11',
shareClass: 'ORDINARY',
shareCount: 50,
faceValue: 100,
issueDate: '2019-08-11',
shareNoFrom: 71301,
shareNoTo: 71350,
dividendYtd: 3000
},
{
certificateNo: 'SC-2024-000125',
folioNo: 'F-01102',
memberId: 'MBR001102',
memberName: 'Karthik Rao',
memberPan: 'PQRSR2233Z',
memberAddress: '24, MG Road, Bengaluru 560001',
branch: 'Bengaluru — MG Road',
joiningDate: '2020-02-04',
shareClass: 'ORDINARY',
shareCount: 200,
faceValue: 100,
issueDate: '2020-02-04',
shareNoFrom: 110201,
shareNoTo: 110400,
dividendYtd: 14400
},
{
certificateNo: 'SC-2024-000126',
folioNo: 'F-01277',
memberId: 'MBR001277',
memberName: 'Madhavi Singh',
memberPan: 'TUVWS3344K',
memberAddress: 'D-5, Greater Kailash, New Delhi 110048',
branch: 'New Delhi — Connaught Place',
joiningDate: '2017-11-19',
shareClass: 'PREFERENCE',
shareCount: 75,
faceValue: 1000,
issueDate: '2017-11-19',
shareNoFrom: 12721,
shareNoTo: 12795,
dividendYtd: 67500
},
{
certificateNo: 'SC-2024-000127',
folioNo: 'F-01498',
memberId: 'MBR001498',
memberName: 'Vikram Joshi',
memberPan: 'LMNOJ9988X',
memberAddress: 'Office 3B, Koregaon Park Road, Pune 411001',
branch: 'Pune — Koregaon Park',
joiningDate: '2016-06-30',
shareClass: 'PREFERENCE',
shareCount: 250,
faceValue: 1000,
issueDate: '2016-06-30',
shareNoFrom: 14981,
shareNoTo: 15230,
dividendYtd: 225000
},
{
certificateNo: 'SC-2024-000128',
folioNo: 'F-01902',
memberId: 'MBR001902',
memberName: 'Lakshmi Naidu',
memberPan: 'XYZAN7788Q',
memberAddress: 'Plot 14, Road No. 3, Banjara Hills, Hyderabad 500034',
branch: 'Hyderabad — Banjara Hills',
joiningDate: '2021-03-15',
shareClass: 'ORDINARY',
shareCount: 30,
faceValue: 100,
issueDate: '2021-03-15',
shareNoFrom: 190201,
shareNoTo: 190230,
dividendYtd: 1800
},
{
certificateNo: 'SC-2024-000129',
folioNo: 'F-02011',
memberId: 'MBR002011',
memberName: 'Arjun Banerjee',
memberPan: 'TUVWB4455F',
memberAddress: '42, Park Street, Kolkata 700016',
branch: 'Kolkata — Park Street',
joiningDate: '2021-09-08',
shareClass: 'ORDINARY',
shareCount: 40,
faceValue: 100,
issueDate: '2021-09-08',
shareNoFrom: 201101,
shareNoTo: 201140,
dividendYtd: 2400
}
];
}