New screen (Deposits menu, repurposing the dead "FD Maturity Report" shell button): every active Fixed Deposit positioned against its own maturity date (Matured / Due Soon / Upcoming / On Track), computed client-side from maturityDate so it can never drift out of step with the account. Reads the new lean maturity-dashboard backend endpoint. A matured, renewable row (no maturity instruction chosen at account-opening, or an explicit Reinvest instruction still waiting on its product's grace period) gets a Renew action wired to the account's own Payment dialog -- see the FD account-view commit for that side of it. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
211 lines
7.6 KiB
TypeScript
211 lines
7.6 KiB
TypeScript
/**
|
|
* 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/.
|
|
*/
|
|
|
|
/** Angular Imports */
|
|
import { NgModule } from '@angular/core';
|
|
import { BrowserModule } from '@angular/platform-browser';
|
|
import { BrowserAnimationsModule } from '@angular/platform-browser/animations';
|
|
import {
|
|
HttpBackend,
|
|
HttpClient,
|
|
provideHttpClient,
|
|
withInterceptorsFromDi,
|
|
HTTP_INTERCEPTORS
|
|
} from '@angular/common/http';
|
|
|
|
/** Environment Configuration */
|
|
|
|
/** Main Component */
|
|
import { WebAppComponent } from './web-app.component';
|
|
|
|
/** Not Found Component */
|
|
import { NotFoundComponent } from './not-found/not-found.component';
|
|
|
|
/** Custom Modules */
|
|
import { CoreModule } from './core/core.module';
|
|
import { HomeModule } from './home/home.module';
|
|
import { LoginModule } from './login/login.module';
|
|
import { SettingsModule } from './settings/settings.module';
|
|
import { NavigationModule } from './navigation/navigation.module';
|
|
import { ClientsModule } from './clients/clients.module';
|
|
import { GroupsModule } from './groups/groups.module';
|
|
import { CentersModule } from './centers/centers.module';
|
|
import { AccountingModule } from './accounting/accounting.module';
|
|
import { ChequeBookModule } from './chequebook/chequebook.module';
|
|
import { CtsClearingModule } from './ctsclearing/ctsclearing.module';
|
|
import { NachClearingModule } from './nachclearing/nachclearing.module';
|
|
import { SystemModule } from './system/system.module';
|
|
import { ProductsModule } from './products/products.module';
|
|
import { OrganizationModule } from './organization/organization.module';
|
|
import { CashierModule } from './cashier/cashier.module';
|
|
import { TemplatesModule } from './templates/templates.module';
|
|
import { UsersModule } from './users/users.module';
|
|
import { ReportsModule } from './reports/reports.module';
|
|
import { SearchModule } from './search/search.module';
|
|
import { NotificationsModule } from './notifications/notifications.module';
|
|
import { CollectionsModule } from './collections/collections.module';
|
|
import { ProfileModule } from './profile/profile.module';
|
|
import { AccessControlModule } from './access-control/access-control.module';
|
|
import { OtpAuditLogsModule } from './otp-audit-logs/otp-audit-logs.module';
|
|
import { TasksModule } from './tasks/tasks.module';
|
|
import { ConfigurationWizardModule } from './configuration-wizard/configuration-wizard.module';
|
|
import { RemittancesModule } from './remittances/remittances.module';
|
|
import { SupersetAnalyticsModule } from './superset-analytics/superset-analytics.module';
|
|
import { CkycModule } from './ckyc/ckyc.module';
|
|
import { KycManagementModule } from './kyc-management/kyc-management.module';
|
|
import { RbiCircularsModule } from './rbi-circulars/rbi-circulars.module';
|
|
import { CfcfrmsModule } from './cfcfrms/cfcfrms.module';
|
|
import { BankCalendarModule } from './bank-calendar/bank-calendar.module';
|
|
import { DeafModule } from './deaf/deaf.module';
|
|
import { SavingsDailyInterestModule } from './savings-daily-interest/savings-daily-interest.module';
|
|
import { FdDashboardModule } from './fd-dashboard/fd-dashboard.module';
|
|
import { DicgcModule } from './dicgc/dicgc.module';
|
|
import { FiuModule } from './fiu/fiu.module';
|
|
import { GlReportsModule } from './gl-reports/gl-reports.module';
|
|
import { SftModule } from './sft/sft.module';
|
|
import { InvestmentModule } from './investment/investment.module';
|
|
import { NpaModule } from './npa/npa.module';
|
|
import { ReconciliationModule } from './reconciliation/reconciliation.module';
|
|
import { LoanOriginationModule } from './loan-origination/loan-origination.module';
|
|
import { DigitalModule } from './digital/digital.module';
|
|
import { LetterMgmtModule } from './letter-mgmt/letter-mgmt.module';
|
|
import { AccountsModule } from './accounts/accounts.module';
|
|
import { ElectionModule } from './election/election.module';
|
|
import { SponsorDDModule } from './sponsor-dd/sponsor-dd.module';
|
|
import { SponsorDDReconciliationModule } from './sponsor-dd-reconciliation/sponsor-dd-reconciliation.module';
|
|
import { PortalModule } from '@angular/cdk/portal';
|
|
|
|
/** Main Routing Module */
|
|
import { AppRoutingModule } from './app-routing.module';
|
|
import { DatePipe, LocationStrategy } from '@angular/common';
|
|
import {
|
|
TranslateLoader,
|
|
TranslateModule,
|
|
MissingTranslationHandler,
|
|
MissingTranslationHandlerParams
|
|
} from '@ngx-translate/core';
|
|
import { TranslateHttpLoader } from '@ngx-translate/http-loader';
|
|
|
|
import { AuthenticationInterceptor as TokenInterceptor } from './core/authentication/authentication.interceptor';
|
|
import { TokenInterceptor as ZitadelTokenInterceptor } from './zitadel/token.interceptor';
|
|
import { AuthService } from './zitadel/auth.service';
|
|
import { environment } from '../environments/environment';
|
|
import { CallbackComponent } from './zitadel/callback/callback.component';
|
|
import { OAuthModule } from 'angular-oauth2-oidc';
|
|
|
|
export class CustomMissingTranslationHandler implements MissingTranslationHandler {
|
|
handle(params: MissingTranslationHandlerParams): string {
|
|
// For missing keys, extract the last segment as a readable fallback
|
|
const key = params.key;
|
|
const lastDot = key.lastIndexOf('.');
|
|
if (lastDot !== -1) {
|
|
return key.substring(lastDot + 1);
|
|
}
|
|
return key.replace('labels.catalogs.', '');
|
|
}
|
|
}
|
|
|
|
/**
|
|
* App Module
|
|
*
|
|
* Core module and all feature modules should be imported here in proper order.
|
|
*/
|
|
|
|
export function HttpLoaderFactory(http: HttpClient) {
|
|
return new TranslateHttpLoader(http);
|
|
}
|
|
|
|
@NgModule({
|
|
declarations: [WebAppComponent],
|
|
bootstrap: [WebAppComponent],
|
|
imports: [
|
|
TranslateModule.forRoot({
|
|
loader: {
|
|
provide: TranslateLoader,
|
|
useFactory: (httpBackend: HttpBackend, locationStrategy: LocationStrategy) => {
|
|
const http = new HttpClient(httpBackend);
|
|
return new TranslateHttpLoader(http, `/assets/translations/`, '.json');
|
|
},
|
|
deps: [
|
|
HttpBackend,
|
|
LocationStrategy
|
|
]
|
|
},
|
|
missingTranslationHandler: { provide: MissingTranslationHandler, useClass: CustomMissingTranslationHandler }
|
|
}),
|
|
BrowserModule,
|
|
BrowserAnimationsModule,
|
|
PortalModule,
|
|
CoreModule,
|
|
HomeModule,
|
|
LoginModule,
|
|
ProfileModule,
|
|
AccessControlModule,
|
|
OtpAuditLogsModule,
|
|
SettingsModule,
|
|
NavigationModule,
|
|
ClientsModule,
|
|
ReportsModule,
|
|
GroupsModule,
|
|
CentersModule,
|
|
AccountingModule,
|
|
ChequeBookModule,
|
|
CtsClearingModule,
|
|
NachClearingModule,
|
|
SystemModule,
|
|
ProductsModule,
|
|
OrganizationModule,
|
|
CashierModule,
|
|
TemplatesModule,
|
|
UsersModule,
|
|
NotificationsModule,
|
|
SearchModule,
|
|
CollectionsModule,
|
|
TasksModule,
|
|
ConfigurationWizardModule,
|
|
RemittancesModule,
|
|
SupersetAnalyticsModule,
|
|
CkycModule,
|
|
KycManagementModule,
|
|
RbiCircularsModule,
|
|
CfcfrmsModule,
|
|
BankCalendarModule,
|
|
DeafModule,
|
|
SavingsDailyInterestModule,
|
|
FdDashboardModule,
|
|
DicgcModule,
|
|
FiuModule,
|
|
GlReportsModule,
|
|
SftModule,
|
|
InvestmentModule,
|
|
NpaModule,
|
|
ReconciliationModule,
|
|
LoanOriginationModule,
|
|
DigitalModule,
|
|
LetterMgmtModule,
|
|
AccountsModule,
|
|
ElectionModule,
|
|
SponsorDDModule,
|
|
SponsorDDReconciliationModule,
|
|
AppRoutingModule,
|
|
NotFoundComponent,
|
|
CallbackComponent,
|
|
OAuthModule.forRoot()
|
|
],
|
|
providers: [
|
|
DatePipe,
|
|
AuthService,
|
|
{
|
|
provide: HTTP_INTERCEPTORS,
|
|
useClass: !environment.OIDC.oidcServerEnabled ? TokenInterceptor : ZitadelTokenInterceptor,
|
|
multi: true
|
|
}
|
|
]
|
|
})
|
|
export class AppModule {}
|