Clerk submits a governed share redemption request (shares, Board Resolution No., Meeting Date, settlement Payment Type); Bank Manager reviews with a live backend-validated checklist (account/GL state, not just submit-time snapshot) before approving, which redeems the shares and settles the linked savings account in one transaction. Adds a Passbook tab to the Share Account view, a reusable search-select control, and a Savings Product "Map Payment Types to Specific Funds" fund-source override (only Loan Products had this before) so settlement can be GL-mapped correctly. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
259 lines
10 KiB
TypeScript
259 lines
10 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 { Routes, RouterModule } from '@angular/router';
|
|
|
|
/** Routing Imports */
|
|
import { Route } from '../core/route/route.service';
|
|
|
|
/** Custom Components */
|
|
import { CheckerInboxAndTasksComponent } from './checker-inbox-and-tasks/checker-inbox-and-tasks.component';
|
|
import { CheckerInboxComponent } from './checker-inbox-and-tasks-tabs/checker-inbox/checker-inbox.component';
|
|
import { WithdrawalRequestsComponent } from './checker-inbox-and-tasks-tabs/withdrawal-requests/withdrawal-requests.component';
|
|
import { ShareWithdrawalRequestsComponent } from './checker-inbox-and-tasks-tabs/share-withdrawal-requests/share-withdrawal-requests.component';
|
|
import { DepositRequestsComponent } from './checker-inbox-and-tasks-tabs/deposit-requests/deposit-requests.component';
|
|
import { DisbursementRequestsComponent } from './checker-inbox-and-tasks-tabs/disbursement-requests/disbursement-requests.component';
|
|
import { ClientApprovalComponent } from './checker-inbox-and-tasks-tabs/client-approval/client-approval.component';
|
|
import { LoanApprovalComponent } from './checker-inbox-and-tasks-tabs/loan-approval/loan-approval.component';
|
|
import { LoanDisbursalComponent } from './checker-inbox-and-tasks-tabs/loan-disbursal/loan-disbursal.component';
|
|
import { RescheduleLoanComponent } from './checker-inbox-and-tasks-tabs/reschedule-loan/reschedule-loan.component';
|
|
import { PendingAccountComponent } from './checker-inbox-and-tasks-tabs/pending-account/pending-account.component';
|
|
import { RejectedAccountComponent } from './checker-inbox-and-tasks-tabs/rejected-account/rejected-account.component';
|
|
import { TerminatedAccountComponent } from './checker-inbox-and-tasks-tabs/terminated-account/terminated-account.component';
|
|
import { PendingSavingsProductsComponent } from './checker-inbox-and-tasks-tabs/pending-savings-products/pending-savings-products.component';
|
|
import { ChequebookRequestsComponent } from './checker-inbox-and-tasks-tabs/chequebook-requests/chequebook-requests.component';
|
|
import { PendingSavingsAccountEditsComponent } from './checker-inbox-and-tasks-tabs/pending-savings-account-edits/pending-savings-account-edits.component';
|
|
import { PendingShareAccountEditsComponent } from './checker-inbox-and-tasks-tabs/pending-share-account-edits/pending-share-account-edits.component';
|
|
import { PendingClientEditsComponent } from './checker-inbox-and-tasks-tabs/pending-client-edits/pending-client-edits.component';
|
|
import { ViewCheckerInboxComponent } from './view-checker-inbox/view-checker-inbox.component';
|
|
|
|
/** Custom Resolvers */
|
|
import { GetMakerCheckers } from './common-resolvers/getmakercheckers.resolver';
|
|
import { GetOffices } from './common-resolvers/getOffices.resolver';
|
|
import { GetLoansToBeApproved } from './common-resolvers/getLoansToBeApproved.resolver';
|
|
import { GetLoansToBeDisbursed } from './common-resolvers/getLoansToBeDisbursed.resolver';
|
|
import { GetRescheduleLoans } from './common-resolvers/getRescheduleLoans.resolver';
|
|
import { MakerCheckerTemplate } from './common-resolvers/makerCheckerTemplate.resolver';
|
|
import { GetCheckerInboxDetailResolver } from './common-resolvers/getCheckerInboxDetail.resolver';
|
|
import { GetPendingAccounts } from './common-resolvers/getPendingAccounts.resolver';
|
|
import { GetRejectedAccounts } from './common-resolvers/getRejectedAccounts.resolver';
|
|
import { GetTerminatedAccounts } from './common-resolvers/getTerminatedAccounts.resolver';
|
|
import { GetPendingSavingsProducts } from './common-resolvers/getPendingSavingsProducts.resolver';
|
|
import { GetPendingSavingsAccountEdits } from './common-resolvers/getPendingSavingsAccountEdits.resolver';
|
|
import { GetPendingCurrentAccountEdits } from './common-resolvers/getPendingCurrentAccountEdits.resolver';
|
|
import { GetPendingShareAccountEdits } from './common-resolvers/getPendingShareAccountEdits.resolver';
|
|
|
|
/** Tasks Routes */
|
|
const routes: Routes = [
|
|
Route.withShell([
|
|
{
|
|
path: 'checker-inbox-and-tasks',
|
|
component: CheckerInboxAndTasksComponent,
|
|
data: { title: 'Checker Inbox & Tasks', breadcrumb: 'Checker Inbox & Tasks' },
|
|
children: [
|
|
{
|
|
path: 'checker-inbox',
|
|
component: CheckerInboxComponent,
|
|
data: { title: 'Checker Inbox' },
|
|
resolve: {
|
|
makerCheckerResource: GetMakerCheckers,
|
|
makerCheckerTemplate: MakerCheckerTemplate
|
|
}
|
|
},
|
|
{
|
|
path: 'client-approval',
|
|
component: ClientApprovalComponent,
|
|
data: { title: 'Client Approval' }
|
|
},
|
|
{
|
|
path: 'loan-approval',
|
|
component: LoanApprovalComponent,
|
|
data: { title: 'Laon Approval' },
|
|
resolve: {
|
|
officesData: GetOffices,
|
|
loansData: GetLoansToBeApproved
|
|
}
|
|
},
|
|
{
|
|
path: 'loan-disbursal',
|
|
component: LoanDisbursalComponent,
|
|
data: { title: 'Loan Disbursal' },
|
|
resolve: {
|
|
loansData: GetLoansToBeDisbursed
|
|
}
|
|
},
|
|
{
|
|
path: 'reschedule-loan',
|
|
component: RescheduleLoanComponent,
|
|
data: { title: 'Reschedule Loan' },
|
|
resolve: {
|
|
rescheduleLoansData: GetRescheduleLoans
|
|
}
|
|
},
|
|
{
|
|
path: 'pending-account',
|
|
component: PendingAccountComponent,
|
|
data: { title: 'Pending Account' },
|
|
resolve: {
|
|
pendingAccountsData: GetPendingAccounts
|
|
}
|
|
},
|
|
{
|
|
path: 'rejected-account',
|
|
component: RejectedAccountComponent,
|
|
data: { title: 'Rejected Account' },
|
|
resolve: {
|
|
rejectedAccountsData: GetRejectedAccounts
|
|
}
|
|
},
|
|
{
|
|
path: 'terminated-account',
|
|
component: TerminatedAccountComponent,
|
|
data: { title: 'Terminated Account' },
|
|
resolve: {
|
|
terminatedAccountsData: GetTerminatedAccounts
|
|
}
|
|
},
|
|
{
|
|
path: 'pending-savings-products',
|
|
component: PendingSavingsProductsComponent,
|
|
data: { title: 'Pending Savings Product Edits' },
|
|
resolve: {
|
|
pendingSavingsProductsData: GetPendingSavingsProducts
|
|
}
|
|
},
|
|
{
|
|
path: 'pending-savings-account-edits',
|
|
component: PendingSavingsAccountEditsComponent,
|
|
data: { title: 'Pending Account Edits' },
|
|
resolve: {
|
|
pendingSavingsAccountEditsData: GetPendingSavingsAccountEdits,
|
|
pendingCurrentAccountEditsData: GetPendingCurrentAccountEdits
|
|
}
|
|
},
|
|
{
|
|
path: 'pending-current-account-edits',
|
|
redirectTo: 'pending-savings-account-edits'
|
|
},
|
|
{
|
|
path: 'pending-share-account-edits',
|
|
component: PendingShareAccountEditsComponent,
|
|
data: { title: 'Pending Share Account Edits' },
|
|
resolve: {
|
|
pendingShareAccountEditsData: GetPendingShareAccountEdits
|
|
}
|
|
},
|
|
{
|
|
path: 'pending-client-edits',
|
|
component: PendingClientEditsComponent,
|
|
data: { title: 'Pending Client Edits' }
|
|
},
|
|
{
|
|
path: 'withdrawal-requests',
|
|
component: WithdrawalRequestsComponent,
|
|
data: { title: 'Withdrawal Requests' }
|
|
},
|
|
{
|
|
path: 'share-withdrawal-requests',
|
|
component: ShareWithdrawalRequestsComponent,
|
|
data: { title: 'Share Withdrawal Requests' }
|
|
},
|
|
{
|
|
path: 'deposit-requests',
|
|
component: DepositRequestsComponent,
|
|
data: { title: 'Deposit Requests' }
|
|
},
|
|
{
|
|
path: 'disbursement-requests',
|
|
component: DisbursementRequestsComponent,
|
|
data: { title: 'Disbursement Requests' }
|
|
},
|
|
{
|
|
path: 'chequebook-requests',
|
|
component: ChequebookRequestsComponent,
|
|
data: { title: 'Cheque Book Requests' }
|
|
}
|
|
]
|
|
},
|
|
{
|
|
path: 'checker-inbox-and-tasks/checker-inbox',
|
|
children: [
|
|
{
|
|
path: ':id/view',
|
|
component: ViewCheckerInboxComponent,
|
|
data: { title: 'View Checker Inbox Component', routeParamBreadcrumb: 'clientId' },
|
|
resolve: {
|
|
checkerInboxDetail: GetCheckerInboxDetailResolver
|
|
}
|
|
}
|
|
]
|
|
},
|
|
{
|
|
path: 'checker-inbox-and-tasks/withdrawal-requests',
|
|
children: [
|
|
{
|
|
path: ':id/review',
|
|
loadComponent: () =>
|
|
import('../clerk/withdrawal-review/withdrawal-review.component').then((m) => m.WithdrawalReviewComponent),
|
|
data: { title: 'Review Withdrawal Request', breadcrumb: 'Review Withdrawal' }
|
|
}
|
|
]
|
|
},
|
|
{
|
|
path: 'checker-inbox-and-tasks/share-withdrawal-requests',
|
|
children: [
|
|
{
|
|
path: ':id/review',
|
|
loadComponent: () =>
|
|
import('../clerk/share-withdrawal-request/share-withdrawal-request.component').then(
|
|
(m) => m.ShareWithdrawalRequestComponent
|
|
),
|
|
data: { title: 'Review Share Withdrawal Request', breadcrumb: 'Review Share Withdrawal', mode: 'review' }
|
|
}
|
|
]
|
|
},
|
|
{
|
|
path: 'checker-inbox-and-tasks/disbursement-requests',
|
|
children: [
|
|
{
|
|
path: ':id/review',
|
|
loadComponent: () =>
|
|
import('../clerk/disbursement-review/disbursement-review.component').then(
|
|
(m) => m.DisbursementReviewComponent
|
|
),
|
|
data: { title: 'Review Disbursement Request', breadcrumb: 'Review Disbursement' }
|
|
}
|
|
]
|
|
}
|
|
])
|
|
];
|
|
|
|
@NgModule({
|
|
imports: [RouterModule.forChild(routes)],
|
|
exports: [RouterModule],
|
|
providers: [
|
|
GetMakerCheckers,
|
|
GetOffices,
|
|
GetLoansToBeApproved,
|
|
GetLoansToBeDisbursed,
|
|
GetRescheduleLoans,
|
|
MakerCheckerTemplate,
|
|
GetCheckerInboxDetailResolver,
|
|
GetPendingAccounts,
|
|
GetRejectedAccounts,
|
|
GetTerminatedAccounts,
|
|
GetPendingSavingsProducts,
|
|
GetPendingSavingsAccountEdits,
|
|
GetPendingCurrentAccountEdits,
|
|
GetPendingShareAccountEdits
|
|
]
|
|
})
|
|
export class TasksRoutingModule {}
|