From 5d0e063be6d9a3b226dade72c9a5e1b5a92275e5 Mon Sep 17 00:00:00 2001 From: Jose Alberto Hernandez Date: Tue, 6 Feb 2024 06:52:14 -0500 Subject: [PATCH] Loan product with Advanced Credit Allocation --- .../loan-product-summary.component.html | 12 +++ .../loan-product-summary.component.ts | 19 ++-- .../create-loan-product.component.html | 4 + .../create-loan-product.component.ts | 7 ++ .../edit-loan-product.component.html | 4 + .../edit-loan-product.component.ts | 14 ++- ...ance-payment-allocation-tab.component.html | 40 +++++++-- ...dvance-payment-allocation-tab.component.ts | 61 +++++++++---- ...oduct-payment-strategy-step.component.html | 2 +- ...product-payment-strategy-step.component.ts | 90 +++++++++++++------ .../payment-allocation-model.ts | 77 +++++++++++++++- .../loan-product-preview-step.component.html | 1 + .../models/loan-product.model.ts | 5 +- .../general-tab/general-tab.component.html | 1 + ...-advance-paymeny-allocation.component.html | 45 ++++++++-- ...ew-advance-paymeny-allocation.component.ts | 5 +- src/assets/translations/cs-CS.json | 6 ++ src/assets/translations/de-DE.json | 6 ++ src/assets/translations/en-US.json | 6 ++ src/assets/translations/es-MX.json | 6 ++ src/assets/translations/fr-FR.json | 6 ++ src/assets/translations/it-IT.json | 6 ++ src/assets/translations/ko-KO.json | 6 ++ src/assets/translations/lt-LT.json | 6 ++ src/assets/translations/lv-LV.json | 6 ++ src/assets/translations/ne-NE.json | 6 ++ src/assets/translations/pt-PT.json | 6 ++ src/assets/translations/sw-SW.json | 6 ++ 28 files changed, 389 insertions(+), 70 deletions(-) diff --git a/src/app/products/loan-products/common/loan-product-summary/loan-product-summary.component.html b/src/app/products/loan-products/common/loan-product-summary/loan-product-summary.component.html index 5d1d44b65..455b49554 100644 --- a/src/app/products/loan-products/common/loan-product-summary/loan-product-summary.component.html +++ b/src/app/products/loan-products/common/loan-product-summary/loan-product-summary.component.html @@ -356,6 +356,18 @@ +
+ Advanced Credit Allocation Transactions: + + + + + + +
+

Down Payments

diff --git a/src/app/products/loan-products/common/loan-product-summary/loan-product-summary.component.ts b/src/app/products/loan-products/common/loan-product-summary/loan-product-summary.component.ts index 4d3436a8b..e2c97beed 100644 --- a/src/app/products/loan-products/common/loan-product-summary/loan-product-summary.component.ts +++ b/src/app/products/loan-products/common/loan-product-summary/loan-product-summary.component.ts @@ -1,7 +1,7 @@ import { Component, Input, OnChanges, OnInit, SimpleChanges } from '@angular/core'; import { DelinquencyBucket, LoanProduct } from '../../models/loan-product.model'; import { AccountingMapping, Charge, ChargeToIncomeAccountMapping, GLAccount, PaymentChannelToFundSourceMapping, PaymentType, PaymentTypeOption } from '../../../../shared/models/general.model'; -import { AdvancePaymentAllocationData, PaymentAllocation } from '../../loan-product-stepper/loan-product-payment-strategy-step/payment-allocation-model'; +import { AdvancePaymentAllocationData, CreditAllocation, PaymentAllocation } from '../../loan-product-stepper/loan-product-payment-strategy-step/payment-allocation-model'; import { LoanProducts } from '../../loan-products'; import { CodeName, OptionData } from '../../../../shared/models/option-data.model'; @@ -17,6 +17,7 @@ export class LoanProductSummaryComponent implements OnInit, OnChanges { @Input() loanProductsTemplate: any | null; @Input() useDueForRepaymentsConfigurations: boolean; @Input() paymentAllocations: PaymentAllocation | null; + @Input() creditAllocations: CreditAllocation | null; variationsDisplayedColumns: string[] = ['valueConditionType', 'borrowerCycleNumber', 'minValue', 'defaultValue', 'maxValue']; chargesDisplayedColumns: string[] = ['name', 'chargeCalculationType', 'amount', 'chargeTimeType']; @@ -185,15 +186,23 @@ export class LoanProductSummaryComponent implements OnInit, OnChanges { } if (this.loanProduct.advancedPaymentAllocationTransactionTypes) { + const advancedAllocationTransactionTypes: OptionData[] = this.loanProduct.advancedPaymentAllocationTransactionTypes + .concat(this.loanProduct.creditAllocationTransactionTypes); + const advancedPaymentAllocationTypes: OptionData[] = this.loanProduct.advancedPaymentAllocationTypes + .concat(this.loanProduct.creditAllocationAllocationTypes); this.advancePaymentAllocationData = { - transactionTypes: this.loanProduct.advancedPaymentAllocationTransactionTypes, - allocationTypes: this.loanProduct.advancedPaymentAllocationTypes, + transactionTypes: advancedAllocationTransactionTypes, + allocationTypes: advancedPaymentAllocationTypes, futureInstallmentAllocationRules: this.loanProduct.advancedPaymentAllocationFutureInstallmentAllocationRules }; } else { + const advancedAllocationTransactionTypes: OptionData[] = this.loanProductsTemplate.advancedPaymentAllocationTransactionTypes + .concat(this.loanProductsTemplate.creditAllocationTransactionTypes); + const advancedPaymentAllocationTypes: OptionData[] = this.loanProductsTemplate.advancedPaymentAllocationTypes + .concat(this.loanProductsTemplate.creditAllocationAllocationTypes); this.advancePaymentAllocationData = { - transactionTypes: this.loanProductsTemplate.advancedPaymentAllocationTransactionTypes, - allocationTypes: this.loanProductsTemplate.advancedPaymentAllocationTypes, + transactionTypes: advancedAllocationTransactionTypes, + allocationTypes: advancedPaymentAllocationTypes, futureInstallmentAllocationRules: this.loanProductsTemplate.advancedPaymentAllocationFutureInstallmentAllocationRules }; } diff --git a/src/app/products/loan-products/create-loan-product/create-loan-product.component.html b/src/app/products/loan-products/create-loan-product/create-loan-product.component.html index 6803e3e5b..b278329bc 100644 --- a/src/app/products/loan-products/create-loan-product/create-loan-product.component.html +++ b/src/app/products/loan-products/create-loan-product/create-loan-product.component.html @@ -65,9 +65,13 @@ diff --git a/src/app/products/loan-products/create-loan-product/create-loan-product.component.ts b/src/app/products/loan-products/create-loan-product/create-loan-product.component.ts index b43788157..cfb44012d 100644 --- a/src/app/products/loan-products/create-loan-product/create-loan-product.component.ts +++ b/src/app/products/loan-products/create-loan-product/create-loan-product.component.ts @@ -35,7 +35,9 @@ export class CreateLoanProductComponent implements OnInit { isAdvancedPaymentStrategy = false; paymentAllocation: PaymentAllocation[] = []; + creditAllocation: PaymentAllocation[] = []; advancedPaymentAllocations: AdvancedPaymentAllocation[] = []; + advancedCreditAllocations: AdvancedPaymentAllocation[] = []; /** * @param {ActivatedRoute} route Activated Route. @@ -90,6 +92,10 @@ export class CreateLoanProductComponent implements OnInit { this.paymentAllocation = paymentAllocation; } + setCreditAllocation(paymentAllocation: PaymentAllocation[]): void { + this.creditAllocation = paymentAllocation; + } + get loanProductSettingsForm() { return this.loanProductSettingsStep.loanProductSettingsForm; } @@ -119,6 +125,7 @@ export class CreateLoanProductComponent implements OnInit { }; if (this.isAdvancedPaymentStrategy) { loanProduct['paymentAllocation'] = this.paymentAllocation; + loanProduct['creditAllocation'] = this.creditAllocation; } return loanProduct; } diff --git a/src/app/products/loan-products/edit-loan-product/edit-loan-product.component.html b/src/app/products/loan-products/edit-loan-product/edit-loan-product.component.html index 6677f49d3..c4f18073b 100644 --- a/src/app/products/loan-products/edit-loan-product/edit-loan-product.component.html +++ b/src/app/products/loan-products/edit-loan-product/edit-loan-product.component.html @@ -65,9 +65,13 @@ diff --git a/src/app/products/loan-products/edit-loan-product/edit-loan-product.component.ts b/src/app/products/loan-products/edit-loan-product/edit-loan-product.component.ts index f8394f455..f7889656c 100644 --- a/src/app/products/loan-products/edit-loan-product/edit-loan-product.component.ts +++ b/src/app/products/loan-products/edit-loan-product/edit-loan-product.component.ts @@ -14,7 +14,7 @@ import { LoanProductAccountingStepComponent } from '../loan-product-stepper/loan import { ProductsService } from 'app/products/products.service'; import { GlobalConfiguration } from 'app/system/configurations/global-configurations-tab/configuration.model'; import { LoanProducts } from '../loan-products'; -import { AdvancedPaymentAllocation, AdvancedPaymentStrategy, PaymentAllocation, PaymentAllocationOrder, PaymentAllocationTransactionTypes } from '../loan-product-stepper/loan-product-payment-strategy-step/payment-allocation-model'; +import { AdvancedPaymentAllocation, AdvancedPaymentStrategy, CreditAllocation, PaymentAllocation, PaymentAllocationOrder, PaymentAllocationTransactionTypes } from '../loan-product-stepper/loan-product-payment-strategy-step/payment-allocation-model'; @Component({ selector: 'mifosx-edit-loan-product', @@ -37,7 +37,9 @@ export class EditLoanProductComponent implements OnInit { isAdvancedPaymentStrategy = false; wasPaymentAllocationChanged = false; paymentAllocation: PaymentAllocation[] = []; + creditAllocation: CreditAllocation[] = []; advancedPaymentAllocations: AdvancedPaymentAllocation[] = []; + advancedCreditAllocations: AdvancedPaymentAllocation[] = []; /** * @param {ActivatedRoute} route Activated Route. @@ -68,6 +70,7 @@ export class EditLoanProductComponent implements OnInit { this.advancePaymentStrategy(this.loanProductAndTemplate.transactionProcessingStrategyCode); if (this.isAdvancedPaymentStrategy) { this.paymentAllocation = this.loanProductAndTemplate.paymentAllocation; + this.creditAllocation = this.loanProductAndTemplate.creditAllocation; } } @@ -93,6 +96,8 @@ export class EditLoanProductComponent implements OnInit { buildAdvancedPaymentAllocation(): void { this.advancedPaymentAllocations = this.advancedPaymentStrategy.buildAdvancedPaymentAllocationList(this.loanProductAndTemplate); + this.advancedCreditAllocations = this.advancedPaymentStrategy.buildAdvancedCreditAllocationList(this.loanProductAndTemplate); + console.log(this.advancedCreditAllocations); } setPaymentAllocation(paymentAllocation: PaymentAllocation[]): void { @@ -100,6 +105,11 @@ export class EditLoanProductComponent implements OnInit { this.wasPaymentAllocationChanged = true; } + setCreditAllocation(creditAllocation: CreditAllocation[]): void { + this.creditAllocation = creditAllocation; + this.wasPaymentAllocationChanged = true; + } + paymentAllocationChanged(value: boolean): void { this.wasPaymentAllocationChanged = value; } @@ -138,8 +148,10 @@ export class EditLoanProductComponent implements OnInit { }; // Default empty array loanProduct['paymentAllocation'] = []; + loanProduct['creditAllocation'] = []; if (this.isAdvancedPaymentStrategy) { loanProduct['paymentAllocation'] = this.paymentAllocation; + loanProduct['creditAllocation'] = this.creditAllocation; } return loanProduct; } diff --git a/src/app/products/loan-products/loan-product-stepper/loan-product-payment-strategy-step/advance-payment-allocation-tab/advance-payment-allocation-tab.component.html b/src/app/products/loan-products/loan-product-stepper/loan-product-payment-strategy-step/advance-payment-allocation-tab/advance-payment-allocation-tab.component.html index c65a8c90b..489414f67 100644 --- a/src/app/products/loan-products/loan-product-stepper/loan-product-payment-strategy-step/advance-payment-allocation-tab/advance-payment-allocation-tab.component.html +++ b/src/app/products/loan-products/loan-product-stepper/loan-product-payment-strategy-step/advance-payment-allocation-tab/advance-payment-allocation-tab.component.html @@ -8,9 +8,9 @@ -
+
+ [cdkDropListData]="paymentAllocationsData" (cdkDropListDropped)="dropTable($event, false)"> @@ -20,12 +20,12 @@ - + - + @@ -34,12 +34,38 @@
Order {{ 'labels.inputs.Order' | translate }} {{ (rowIndex + 1) }} Payment Allocation {{ 'labels.inputs.Payment Allocation' | translate }} {{ paymentAllocation.value }}
- - Future Installment Allocation Rule +
+ + + + + + + + + + + + + + + + + + + +
+ + {{ 'labels.inputs.Order' | translate }} {{ (rowIndex + 1) }} {{ 'labels.inputs.Payment Allocation' | translate }} {{ creditAllocation.value }}
+
+ + + {{ 'labels.inputs.Future Installment Allocation Rule' | translate }} - {{ futureInstallmentAllocationRule.value | translate}} + {{ futureInstallmentAllocationRule.value | translate }} diff --git a/src/app/products/loan-products/loan-product-stepper/loan-product-payment-strategy-step/advance-payment-allocation-tab/advance-payment-allocation-tab.component.ts b/src/app/products/loan-products/loan-product-stepper/loan-product-payment-strategy-step/advance-payment-allocation-tab/advance-payment-allocation-tab.component.ts index 4ac91e235..6da2b901c 100644 --- a/src/app/products/loan-products/loan-product-stepper/loan-product-payment-strategy-step/advance-payment-allocation-tab/advance-payment-allocation-tab.component.ts +++ b/src/app/products/loan-products/loan-product-stepper/loan-product-payment-strategy-step/advance-payment-allocation-tab/advance-payment-allocation-tab.component.ts @@ -1,5 +1,5 @@ import { Component, EventEmitter, Input, OnInit, Output, ViewChild } from '@angular/core'; -import { AdvancedPaymentAllocation, AdvancedPaymentStrategy, FutureInstallmentAllocationRule, PaymentAllocationOrder, PaymentAllocationTransactionType } from '../payment-allocation-model'; +import { AdvancedPaymentAllocation, AdvancedPaymentStrategy, CreditAllocationOrder, FutureInstallmentAllocationRule, PaymentAllocationOrder, PaymentAllocationTransactionType } from '../payment-allocation-model'; import { CdkDragDrop, moveItemInArray } from '@angular/cdk/drag-drop'; import { MatTable } from '@angular/material/table'; import { MatDialog } from '@angular/material/dialog'; @@ -18,7 +18,8 @@ export class AdvancePaymentAllocationTabComponent implements OnInit { @Output() paymentAllocationChange = new EventEmitter(); @Output() transactionTypeRemoved = new EventEmitter(); - paymentAllocationsData: PaymentAllocationOrder[] = []; + paymentAllocationsData: PaymentAllocationOrder[] | null = null; + creditAllocationsData: CreditAllocationOrder[] | null = null; /** Columns to be displayed in the table. */ displayedColumns: string[] = ['actions', 'order', 'paymentAllocation']; @@ -31,29 +32,51 @@ export class AdvancePaymentAllocationTabComponent implements OnInit { private advancedPaymentStrategy: AdvancedPaymentStrategy) { } ngOnInit(): void { - this.paymentAllocationsData = this.advancedPaymentAllocation.paymentAllocationOrder; - this.futureInstallmentAllocationRule.patchValue(this.advancedPaymentAllocation.futureInstallmentAllocationRule.code); - this.futureInstallmentAllocationRule.valueChanges.subscribe((value: any) => { - this.advancedPaymentAllocation.futureInstallmentAllocationRules.forEach((item: FutureInstallmentAllocationRule) => { - if (value === item.code) { - this.advancedPaymentAllocation.futureInstallmentAllocationRule = item; - this.paymentAllocationChange.emit(true); - } + console.log(this.advancedPaymentAllocation); + if (this.advancedPaymentAllocation) { + if (this.advancedPaymentAllocation.creditAllocationOrder) { + this.creditAllocationsData = this.advancedPaymentAllocation.creditAllocationOrder; + } + if (this.advancedPaymentAllocation.paymentAllocationOrder) { + this.paymentAllocationsData = this.advancedPaymentAllocation.paymentAllocationOrder; + } + if (this.advancedPaymentAllocation.futureInstallmentAllocationRule) { + this.futureInstallmentAllocationRule.patchValue(this.advancedPaymentAllocation.futureInstallmentAllocationRule.code); + } + this.futureInstallmentAllocationRule.valueChanges.subscribe((value: any) => { + this.advancedPaymentAllocation.futureInstallmentAllocationRules.forEach((item: FutureInstallmentAllocationRule) => { + if (value === item.code) { + this.advancedPaymentAllocation.futureInstallmentAllocationRule = item; + this.paymentAllocationChange.emit(true); + } + }); }); - }); + } } - dropTable(event: CdkDragDrop) { - const prevIndex = this.paymentAllocationsData.findIndex((d: any) => d === event.item.data); - moveItemInArray(this.paymentAllocationsData, prevIndex, event.currentIndex); - this.paymentAllocationsData = [...this.paymentAllocationsData]; - this.advancedPaymentAllocation.paymentAllocationOrder = this.paymentAllocationsData; - this.table.renderRows(); - this.paymentAllocationChange.emit(true); + dropTable(event: CdkDragDrop, credit: boolean) { + if (!credit) { + const prevIndex = this.paymentAllocationsData.findIndex((d: any) => d === event.item.data); + moveItemInArray(this.paymentAllocationsData, prevIndex, event.currentIndex); + this.paymentAllocationsData = [...this.paymentAllocationsData]; + this.advancedPaymentAllocation.paymentAllocationOrder = this.paymentAllocationsData; + this.table.renderRows(); + this.paymentAllocationChange.emit(true); + } else { + const prevIndex = this.creditAllocationsData.findIndex((d: any) => d === event.item.data); + moveItemInArray(this.creditAllocationsData, prevIndex, event.currentIndex); + this.creditAllocationsData = [...this.creditAllocationsData]; + this.advancedPaymentAllocation.creditAllocationOrder = this.creditAllocationsData; + this.table.renderRows(); + this.paymentAllocationChange.emit(true); + } } isDefault(): boolean { - return this.advancedPaymentStrategy.isDefault(this.advancedPaymentAllocation.transaction); + if (this.advancedPaymentAllocation && this.advancedPaymentAllocation.transaction) { + return this.advancedPaymentStrategy.isDefault(this.advancedPaymentAllocation.transaction); + } + return false; } removeTransaction(): void { diff --git a/src/app/products/loan-products/loan-product-stepper/loan-product-payment-strategy-step/loan-product-payment-strategy-step.component.html b/src/app/products/loan-products/loan-product-stepper/loan-product-payment-strategy-step/loan-product-payment-strategy-step.component.html index a23953cf7..56f300dc2 100644 --- a/src/app/products/loan-products/loan-product-stepper/loan-product-payment-strategy-step/loan-product-payment-strategy-step.component.html +++ b/src/app/products/loan-products/loan-product-stepper/loan-product-payment-strategy-step/loan-product-payment-strategy-step.component.html @@ -1,7 +1,7 @@ - + {{advancedPaymentAllocation.transaction.code}} diff --git a/src/app/products/loan-products/loan-product-stepper/loan-product-payment-strategy-step/loan-product-payment-strategy-step.component.ts b/src/app/products/loan-products/loan-product-stepper/loan-product-payment-strategy-step/loan-product-payment-strategy-step.component.ts index 8c8441aa3..ff205a149 100644 --- a/src/app/products/loan-products/loan-product-stepper/loan-product-payment-strategy-step/loan-product-payment-strategy-step.component.ts +++ b/src/app/products/loan-products/loan-product-stepper/loan-product-payment-strategy-step/loan-product-payment-strategy-step.component.ts @@ -1,10 +1,11 @@ import { Component, EventEmitter, Input, OnInit, Output, ViewChild } from '@angular/core'; -import { AdvancedPaymentAllocation, AdvancedPaymentStrategy, PaymentAllocation, PaymentAllocationOrder, PaymentAllocationTransactionType } from './payment-allocation-model'; +import { AdvancedPaymentAllocation, AdvancedPaymentStrategy, CreditAllocation, PaymentAllocation, PaymentAllocationOrder, PaymentAllocationTransactionType } from './payment-allocation-model'; import { MatDialog } from '@angular/material/dialog'; import { FormfieldBase } from 'app/shared/form-dialog/formfield/model/formfield-base'; import { SelectBase } from 'app/shared/form-dialog/formfield/model/select-base'; import { FormDialogComponent } from 'app/shared/form-dialog/form-dialog.component'; import { MatTabGroup } from '@angular/material/tabs'; +import { TranslateService } from '@ngx-translate/core'; @Component({ selector: 'mifosx-loan-product-payment-strategy-step', @@ -13,30 +14,39 @@ import { MatTabGroup } from '@angular/material/tabs'; }) export class LoanProductPaymentStrategyStepComponent implements OnInit { + advancedAllocations: AdvancedPaymentAllocation[] = []; @Input() advancedPaymentAllocations: AdvancedPaymentAllocation[] = []; + @Input() advancedCreditAllocations: AdvancedPaymentAllocation[] = []; @Input() advancedPaymentAllocationTransactionTypes: PaymentAllocationTransactionType[] = []; @Input() paymentAllocationOrderDefault: PaymentAllocationOrder[]; + @Input() advancedCreditAllocationTransactionTypes: PaymentAllocationTransactionType[] = []; + @Input() creditAllocationOrderDefault: PaymentAllocationOrder[]; @Output() paymentAllocationChange = new EventEmitter(); @Output() setPaymentAllocation = new EventEmitter(); + @Output() setCreditAllocation = new EventEmitter(); @ViewChild(MatTabGroup) tabGroup: MatTabGroup; constructor(private dialog: MatDialog, - private advancedPaymentStrategy: AdvancedPaymentStrategy) { } + private advancedPaymentStrategy: AdvancedPaymentStrategy, + private translateService: TranslateService) { } ngOnInit(): void { - this.sendPaymentAllocation(); + this.advancedAllocations = this.advancedPaymentAllocations.concat(this.advancedCreditAllocations); + this.sendAllocations(); } - sendPaymentAllocation(): void { - const data = this.advancedPaymentStrategy.buildPaymentAllocations(this.advancedPaymentAllocations); - this.setPaymentAllocation.emit(data); + sendAllocations(): void { + this.setPaymentAllocation.emit(this.advancedPaymentStrategy.buildPaymentAllocations(this.advancedPaymentAllocations)); + if (this.advancedCreditAllocations?.length > 0) { + this.setCreditAllocation.emit(this.advancedPaymentStrategy.buildCreditAllocations(this.advancedCreditAllocations)); + } } paymentAllocationChanged(changed: boolean): void { this.paymentAllocationChange.emit(changed); - this.sendPaymentAllocation(); + this.sendAllocations(); } addTransaction(): void { @@ -44,10 +54,20 @@ export class LoanProductPaymentStrategyStepComponent implements OnInit { this.advancedPaymentAllocations.forEach((item: AdvancedPaymentAllocation) => { transactionTypesCurrent.push(item.transaction.code); }); + this.advancedCreditAllocations.forEach((item: AdvancedPaymentAllocation) => { + transactionTypesCurrent.push(item.transaction.code); + }); const transactionTypesOptions: PaymentAllocationTransactionType[] = []; this.advancedPaymentAllocationTransactionTypes.forEach((option: PaymentAllocationTransactionType) => { if (!this.advancedPaymentStrategy.isDefault(option) && transactionTypesCurrent.indexOf(option.code) < 0) { + option.credit = false; + transactionTypesOptions.push(option); + } + }); + this.advancedCreditAllocationTransactionTypes.forEach((option: PaymentAllocationTransactionType) => { + if (transactionTypesCurrent.indexOf(option.code) < 0) { + option.credit = true; transactionTypesOptions.push(option); } }); @@ -55,14 +75,17 @@ export class LoanProductPaymentStrategyStepComponent implements OnInit { const formfields: FormfieldBase[] = [ new SelectBase({ controlName: 'code', - label: 'Transaction Type', + label: this.translateService.instant('labels.inputs.Transaction Type'), options: { label: 'code', value: 'code', data: transactionTypesOptions }, order: 1 }) ]; const data = { - title: 'Advanced Payment Allocation Transaction Type', - layout: { addButtonText: 'Add' }, + title: this.translateService.instant('labels.inputs.Advanced Payment Allocation Transaction Type'), + layout: { + addButtonText: this.translateService.instant('labels.buttons.Add'), + cancelButtonText: this.translateService.instant('labels.buttons.Cancel') + }, formfields: formfields }; const transactionTypeDialogRef = this.dialog.open(FormDialogComponent, { data }); @@ -71,14 +94,20 @@ export class LoanProductPaymentStrategyStepComponent implements OnInit { const defaultPaymentAllocation: AdvancedPaymentAllocation = this.advancedPaymentAllocations[0]; transactionTypesOptions.forEach((transactionType: PaymentAllocationTransactionType) => { if (transactionType.code === response.data.value.code) { - this.advancedPaymentAllocations.push( - this.advancedPaymentStrategy.buildAdvancedPaymentAllocation(true, transactionType, - this.paymentAllocationOrderDefault, - defaultPaymentAllocation.futureInstallmentAllocationRules) - ); + if (!transactionType.credit) { + this.advancedPaymentAllocations.push( + this.advancedPaymentStrategy.buildAdvancedPaymentAllocation(true, transactionType, this.paymentAllocationOrderDefault, + defaultPaymentAllocation.futureInstallmentAllocationRules) + ); + } else { + this.advancedCreditAllocations.push( + this.advancedPaymentStrategy.buildAdvancedCreditAllocation(transactionType, this.creditAllocationOrderDefault) + ); + } this.paymentAllocationChange.emit(true); - this.tabGroup.selectedIndex = (this.advancedPaymentAllocations.length - 1); - this.sendPaymentAllocation(); + this.advancedAllocations = this.advancedPaymentAllocations.concat(this.advancedCreditAllocations); + this.tabGroup.selectedIndex = (this.advancedAllocations.length - 1); + this.sendAllocations(); } }); } @@ -86,14 +115,25 @@ export class LoanProductPaymentStrategyStepComponent implements OnInit { } transactionTypeRemoved(transaction: PaymentAllocationTransactionType): void { - this.advancedPaymentAllocations.forEach((item: AdvancedPaymentAllocation, index: number) => { - if (item.transaction.code === transaction.code) { - this.advancedPaymentAllocations.splice(index, 1); - this.paymentAllocationChange.emit(true); - this.tabGroup.selectedIndex = (index - 1); - this.sendPaymentAllocation(); - } - }); + if (!transaction.credit) { + this.advancedPaymentAllocations.forEach((item: AdvancedPaymentAllocation, index: number) => { + if (item.transaction.code === transaction.code) { + this.advancedPaymentAllocations.splice(index, 1); + this.paymentAllocationChange.emit(true); + this.tabGroup.selectedIndex = (index - 1); + this.sendAllocations(); + } + }); + } else { + this.advancedCreditAllocations.forEach((item: AdvancedPaymentAllocation, index: number) => { + if (item.transaction.code === transaction.code) { + this.advancedCreditAllocations.splice(index, 1); + this.paymentAllocationChange.emit(true); + this.tabGroup.selectedIndex = (index - 1); + this.sendAllocations(); + } + }); + } } } diff --git a/src/app/products/loan-products/loan-product-stepper/loan-product-payment-strategy-step/payment-allocation-model.ts b/src/app/products/loan-products/loan-product-stepper/loan-product-payment-strategy-step/payment-allocation-model.ts index 30989e404..aa3249525 100644 --- a/src/app/products/loan-products/loan-product-stepper/loan-product-payment-strategy-step/payment-allocation-model.ts +++ b/src/app/products/loan-products/loan-product-stepper/loan-product-payment-strategy-step/payment-allocation-model.ts @@ -4,6 +4,7 @@ export interface PaymentAllocationTransactionType { id: number; value: string; code: string; + credit?: boolean; } export interface PaymentAllocationType { @@ -30,15 +31,27 @@ export interface PaymentAllocation { futureInstallmentAllocationRule: string; } +export interface CreditAllocationOrder { + id?: number; + creditAllocationRule: string; + order: number; +} + +export interface CreditAllocation { + transactionType: string; + creditAllocationOrder: CreditAllocationOrder[]; +} + export class PaymentAllocationTransactionTypes { public static DEFAULT_TRANSACTION: PaymentAllocationTransactionType = { id: 1, value: 'Default', code: 'DEFAULT' }; } export class AdvancedPaymentAllocation { transaction: PaymentAllocationTransactionType; - paymentAllocationOrder: PaymentAllocationOrder[]; - futureInstallmentAllocationRule: FutureInstallmentAllocationRule; - futureInstallmentAllocationRules: FutureInstallmentAllocationRule[]; + paymentAllocationOrder?: PaymentAllocationOrder[]; + futureInstallmentAllocationRule?: FutureInstallmentAllocationRule; + futureInstallmentAllocationRules?: FutureInstallmentAllocationRule[]; + creditAllocationOrder?: CreditAllocationOrder[]; } export class AdvancePaymentAllocationData { @@ -52,6 +65,23 @@ export class AdvancePaymentAllocationData { }) export class AdvancedPaymentStrategy { + public buildAdvancedCreditAllocationList(loanProduct: any): AdvancedPaymentAllocation[] { + const advancedPaymentAllocation: AdvancedPaymentAllocation[] = []; + const advancedCreditAllocationTransactionTypes: PaymentAllocationTransactionType[] = + loanProduct.creditAllocationTransactionTypes; + const advancedPaymentAllocationTypes: CreditAllocationOrder[] = loanProduct.creditAllocationAllocationTypes; + if (loanProduct.creditAllocation) { + loanProduct.creditAllocation.forEach((item: CreditAllocation) => { + advancedPaymentAllocation.push({ + transaction: this.getItemByCode(item.transactionType, advancedCreditAllocationTransactionTypes), + creditAllocationOrder: this.buildCurrentCreditAllocationOrder(item.creditAllocationOrder, + advancedPaymentAllocationTypes), + }); + }); + } + return advancedPaymentAllocation; + } + public buildAdvancedPaymentAllocationList(loanProduct: any): AdvancedPaymentAllocation[] { const advancedPaymentAllocation: AdvancedPaymentAllocation[] = []; const advancedPaymentAllocationTransactionTypes: PaymentAllocationTransactionType[] = @@ -94,6 +124,14 @@ export class AdvancedPaymentStrategy { }; } + public buildAdvancedCreditAllocation(transaction: PaymentAllocationTransactionType, + currentItems: PaymentAllocationOrder[]): AdvancedPaymentAllocation { + return { + transaction: transaction, + paymentAllocationOrder: this.buildPaymentAllocationTransactionOrder(true, currentItems, currentItems) + }; + } + public buildPaymentAllocationTransactionOrder(forDefault: boolean, currentItems: PaymentAllocationOrder[], defaultItems: PaymentAllocationOrder[]): PaymentAllocationOrder[] { const paymentAllocationOrder: PaymentAllocationOrder[] = []; if (forDefault) { @@ -123,6 +161,18 @@ export class AdvancedPaymentStrategy { return paymentAllocations; } + public buildCreditAllocations(advancedCreditAllocations: AdvancedPaymentAllocation[]): CreditAllocation[] { + const creditAllocations: CreditAllocation[] = []; + advancedCreditAllocations.forEach((creditAllocation: AdvancedPaymentAllocation) => { + creditAllocations.push({ + transactionType: creditAllocation.transaction.code, + creditAllocationOrder: this.buildCreditAllocationOrder(creditAllocation.creditAllocationOrder) + }); + }); + + return creditAllocations; + } + public buildPaymentAllocationOrder(paymentAllocationOrder: PaymentAllocationOrder[]): PaymentAllocationOrder[] { const paymentAllocations: any[] = []; paymentAllocationOrder.forEach((item: any, index: number) => { @@ -135,6 +185,18 @@ export class AdvancedPaymentStrategy { return paymentAllocations; } + public buildCreditAllocationOrder(creditAllocationOrder: CreditAllocationOrder[]): CreditAllocationOrder[] { + const creditAllocations: CreditAllocationOrder[] = []; + creditAllocationOrder.forEach((item: any, index: number) => { + creditAllocations.push({ + order: (index + 1), + creditAllocationRule: item.code + }); + }); + + return creditAllocations; + } + public buildCurrentPaymentAllocationOrder(currentItems: any[], defaultItems: PaymentAllocationOrder[]): PaymentAllocationOrder[] { const paymentAllocationOrder: PaymentAllocationOrder[] = []; @@ -144,6 +206,15 @@ export class AdvancedPaymentStrategy { return paymentAllocationOrder; } + public buildCurrentCreditAllocationOrder(currentItems: any[], defaultItems: CreditAllocationOrder[]): + CreditAllocationOrder[] { + const creditAllocationOrder: CreditAllocationOrder[] = []; + currentItems.forEach((item: any) => { + creditAllocationOrder.push(this.getItemByCode(item.creditAllocationRule, defaultItems)); + }); + return creditAllocationOrder; + } + public getItemByCode(code: string, options: any[]): any { let transaction: any; diff --git a/src/app/products/loan-products/loan-product-stepper/loan-product-preview-step/loan-product-preview-step.component.html b/src/app/products/loan-products/loan-product-stepper/loan-product-preview-step/loan-product-preview-step.component.html index c80016c6a..94f2349bd 100644 --- a/src/app/products/loan-products/loan-product-stepper/loan-product-preview-step/loan-product-preview-step.component.html +++ b/src/app/products/loan-products/loan-product-stepper/loan-product-preview-step/loan-product-preview-step.component.html @@ -5,6 +5,7 @@ [loanProductsTemplate]="loanProductsTemplate" [useDueForRepaymentsConfigurations]="loanProduct.useDueForRepaymentsConfigurations" [paymentAllocations]="loanProduct.paymentAllocation" +[creditAllocations]="loanProduct.creditAllocation" > diff --git a/src/app/products/loan-products/models/loan-product.model.ts b/src/app/products/loan-products/models/loan-product.model.ts index 7c3397cbc..b83d2859c 100644 --- a/src/app/products/loan-products/models/loan-product.model.ts +++ b/src/app/products/loan-products/models/loan-product.model.ts @@ -1,6 +1,6 @@ import { AccountingMapping, ChargeToIncomeAccountMapping, Currency, PaymentChannelToFundSourceMapping } from 'app/shared/models/general.model'; import { OptionData } from 'app/shared/models/option-data.model'; -import { PaymentAllocation } from '../loan-product-stepper/loan-product-payment-strategy-step/payment-allocation-model'; +import { CreditAllocation, PaymentAllocation } from '../loan-product-stepper/loan-product-payment-strategy-step/payment-allocation-model'; export interface LoanProduct { id: number; @@ -41,6 +41,7 @@ export interface LoanProduct { transactionProcessingStrategyCode: string; transactionProcessingStrategyName: string; paymentAllocation?: PaymentAllocation[]; + creditAllocation?: CreditAllocation[]; daysInMonthType: OptionData; daysInYearType: OptionData; isInterestRecalculationEnabled: boolean; @@ -69,6 +70,8 @@ export interface LoanProduct { advancedPaymentAllocationTransactionTypes: OptionData[]; advancedPaymentAllocationFutureInstallmentAllocationRules: OptionData[]; advancedPaymentAllocationTypes: OptionData[]; + creditAllocationTransactionTypes: OptionData[]; + creditAllocationAllocationTypes: OptionData[]; multiDisburseLoan: boolean; maxTrancheCount: number; disallowExpectedDisbursements: boolean; diff --git a/src/app/products/loan-products/view-loan-product/general-tab/general-tab.component.html b/src/app/products/loan-products/view-loan-product/general-tab/general-tab.component.html index 6484246eb..00f9744e9 100644 --- a/src/app/products/loan-products/view-loan-product/general-tab/general-tab.component.html +++ b/src/app/products/loan-products/view-loan-product/general-tab/general-tab.component.html @@ -9,5 +9,6 @@ [loanProduct]="loanProduct" [useDueForRepaymentsConfigurations]="useDueForRepaymentsConfigurations" [paymentAllocations]="loanProduct.paymentAllocation" +[creditAllocations]="loanProduct.creditAllocation" > diff --git a/src/app/products/loan-products/view-loan-product/shared/view-advance-paymeny-allocation/view-advance-paymeny-allocation.component.html b/src/app/products/loan-products/view-loan-product/shared/view-advance-paymeny-allocation/view-advance-paymeny-allocation.component.html index d6751c78b..349b6ce32 100644 --- a/src/app/products/loan-products/view-loan-product/shared/view-advance-paymeny-allocation/view-advance-paymeny-allocation.component.html +++ b/src/app/products/loan-products/view-loan-product/shared/view-advance-paymeny-allocation/view-advance-paymeny-allocation.component.html @@ -1,8 +1,8 @@ - +
- Transaction Type: + {{ 'labels.inputs.Transaction Type' | translate }}: {{ transactionTypeValue(paymentAllocation.transactionType) }}
@@ -11,18 +11,18 @@
- Future Installment Allocation: + {{ 'labels.inputs.Future Installment Allocation Rule' | translate }}: {{ futureInstallmentRuleValue(paymentAllocation.futureInstallmentAllocationRule) }}
- Payment Allocation Order + {{ 'labels.inputs.Payment Allocation Order' | translate }} - - + + @@ -36,3 +36,36 @@ + + + +
+ {{ 'labels.inputs.Transaction Type' | translate }}: + {{ transactionTypeValue(creditAllocation.transactionType) }} +
+
+
+ +
+ +
+ {{ 'labels.inputs.Credit Allocation Order' | translate }} + +
OrderPayment Allocation Rule{{ 'labels.inputs.Order' | translate }}{{ 'labels.inputs.Payment Allocation Rule' | translate }}
+ + + + + + + + + + + + +
{{ 'labels.inputs.Order' | translate }}{{ 'labels.inputs.Credit Allocation Rule' | translate }}
{{ (idx + 1) }}{{ allocationRuleValue(creditAllocation.creditAllocationRule) }}
+
+
+
+
\ No newline at end of file diff --git a/src/app/products/loan-products/view-loan-product/shared/view-advance-paymeny-allocation/view-advance-paymeny-allocation.component.ts b/src/app/products/loan-products/view-loan-product/shared/view-advance-paymeny-allocation/view-advance-paymeny-allocation.component.ts index 2518c00c0..f659d8802 100644 --- a/src/app/products/loan-products/view-loan-product/shared/view-advance-paymeny-allocation/view-advance-paymeny-allocation.component.ts +++ b/src/app/products/loan-products/view-loan-product/shared/view-advance-paymeny-allocation/view-advance-paymeny-allocation.component.ts @@ -1,5 +1,5 @@ import { Component, Input, OnInit } from '@angular/core'; -import { AdvancePaymentAllocationData, PaymentAllocation } from 'app/products/loan-products/loan-product-stepper/loan-product-payment-strategy-step/payment-allocation-model'; +import { AdvancePaymentAllocationData, CreditAllocation, PaymentAllocation } from 'app/products/loan-products/loan-product-stepper/loan-product-payment-strategy-step/payment-allocation-model'; @Component({ selector: 'mifosx-view-advance-paymeny-allocation', @@ -8,7 +8,8 @@ import { AdvancePaymentAllocationData, PaymentAllocation } from 'app/products/lo }) export class ViewAdvancePaymenyAllocationComponent implements OnInit { - @Input() paymentAllocation: PaymentAllocation; + @Input() paymentAllocation: PaymentAllocation | null; + @Input() creditAllocation: CreditAllocation | null; @Input() advancePaymentAllocationData: AdvancePaymentAllocationData; constructor() { } diff --git a/src/assets/translations/cs-CS.json b/src/assets/translations/cs-CS.json index 54b9b7ed6..e1c48311e 100644 --- a/src/assets/translations/cs-CS.json +++ b/src/assets/translations/cs-CS.json @@ -925,6 +925,7 @@ "Adjust advance payments toward future installments": "Upravte zálohové platby směrem k budoucím splátkám", "Adjust interest rates for remainder of loan": "Upravte úrokové sazby pro zbytek půjčky", "Advance payments adjustment type": "Typ úpravy záloh", + "Advanced Payment Allocation Transaction Type": "Typ transakce pro pokročilé přidělování plateb", "Affected GL Entry (Credit)": "Dotčený záznam GL (kredit)", "Affected GL Entry (Credit) Rule Type": "Typ pravidla ovlivněného záznamu GL (kredit).", "Affected GL Entry (Debit)": "Dotčený záznam GL (debetní)", @@ -1122,6 +1123,8 @@ "Credit Account Name": "Název kreditního účtu", "Credit Account Type": "Typ kreditního účtu", "Credit Adjustments": "Úpravy úvěrů", + "Credit Allocation Order": "Příkaz k přidělování kreditu", + "Credit Allocation Rule": "Pravidlo přidělování kreditu", "Credit Amount": "Výše kreditu", "Credit Tags": "Kreditní štítky", "Cron Expression": "Cron Expression", @@ -1318,6 +1321,7 @@ "Fund": "Fond", "Fund Source": "Zdroj fondu", "Fund source": "Zdroj fondu", + "Future Installment Allocation Rule": "Pravidlo alokace budoucí splátky", "GCM End Point": "Koncový bod GCM", "GENERAL": "VŠEOBECNÉ", "GL Account Name or Code": "Název nebo kód účtu GL", @@ -1668,6 +1672,8 @@ "Passwords should be": "Hesla by měla být", "Past Due Days": "Dny po splatnosti", "Payload URL": "Adresa URL datové části", + "Payment Allocation Order": "Příkaz k přidělování plateb", + "Payment Allocation Rule": "Pravidlo přidělování plateb", "Payment Due At": "Splatnost platby v", "Payment Type": "Způsob platby", "Payment Type Id": "ID typu platby", diff --git a/src/assets/translations/de-DE.json b/src/assets/translations/de-DE.json index ef19018b2..235df531d 100644 --- a/src/assets/translations/de-DE.json +++ b/src/assets/translations/de-DE.json @@ -925,6 +925,7 @@ "Adjust advance payments toward future installments": "Passen Sie Vorauszahlungen an zukünftige Raten an", "Adjust interest rates for remainder of loan": "Passen Sie die Zinssätze für die Restlaufzeit des Darlehens an", "Advance payments adjustment type": "Art der Anpassung der Vorauszahlungen", + "Advanced Payment Allocation Transaction Type": "Fortgeschrittene Zahlungszuweisungstransaktionstyp", "Affected GL Entry (Credit)": "Betroffener FIBU-Eintrag (Gutschrift)", "Affected GL Entry (Credit) Rule Type": "Betroffener FIBU-Eintragsregeltyp (Kredit).", "Affected GL Entry (Debit)": "Betroffener FIBU-Eintrag (Soll)", @@ -1122,6 +1123,8 @@ "Credit Account Name": "Name des Kreditkontos", "Credit Account Type": "Kreditkontotyp", "Credit Adjustments": "Kreditanpassungen", + "Credit Allocation Order": "Kreditallokationsauftrag", + "Credit Allocation Rule": "Kreditzuweisungsregel", "Credit Amount": "Kreditbetrag", "Credit Tags": "Kredit-Tags", "Cron Expression": "Cron-Ausdruck", @@ -1318,6 +1321,7 @@ "Fund": "Fonds", "Fund Source": "Fondsquelle", "Fund source": "Finanzierungsquelle", + "Future Installment Allocation Rule": "Zukünftige Ratenzuweisungsregel", "GCM End Point": "GCM-Endpunkt", "GENERAL": "ALLGEMEIN", "GL Account Name or Code": "Name oder Code des Hauptbuchkontos", @@ -1668,6 +1672,8 @@ "Passwords should be": "Passwörter sollten sein", "Past Due Days": "Überfällige Tage", "Payload URL": "Payload-URL", + "Payment Allocation Order": "Zahlungszuweisungsbestellung", + "Payment Allocation Rule": "Zahlungszuweisungsregel", "Payment Due At": "Zahlung fällig am", "Payment Type": "Zahlungsart", "Payment Type Id": "Zahlungsart-ID", diff --git a/src/assets/translations/en-US.json b/src/assets/translations/en-US.json index f25c047a9..ea1d10f84 100644 --- a/src/assets/translations/en-US.json +++ b/src/assets/translations/en-US.json @@ -924,6 +924,7 @@ "Adjust advance payments toward future installments": "Adjust advance payments toward future installments", "Adjust interest rates for remainder of loan": "Adjust interest rates for remainder of loan", "Advance payments adjustment type": "Advance payments adjustment type", + "Advanced Payment Allocation Transaction Type": "Advanced Payment Allocation Transaction Type", "Affected GL Entry (Credit)": "Affected GL Entry (Credit)", "Affected GL Entry (Credit) Rule Type": "Affected GL Entry (Credit) Rule Type", "Affected GL Entry (Debit)": "Affected GL Entry (Debit)", @@ -1121,6 +1122,8 @@ "Credit Account Name": "Credit Account Name", "Credit Account Type": "Credit Account Type", "Credit Adjustments": "Credit Adjustments", + "Credit Allocation Order": "Credit Allocation Order", + "Credit Allocation Rule": "Credit Allocation Rule", "Credit Amount": "Credit Amount", "Credit Tags": "Credit Tags", "Cron Expression": "Cron Expression", @@ -1317,6 +1320,7 @@ "Fund": "Fund", "Fund Source": "Fund Source", "Fund source": "Fund source", + "Future Installment Allocation Rule": "Future Installment Allocation Rule", "GCM End Point": "GCM End Point", "GENERAL": "GENERAL", "GL Account Name or Code": "GL Account Name or Code", @@ -1667,6 +1671,8 @@ "Passwords should be": "Passwords should be", "Past Due Days": "Past Due Days", "Payload URL": "Payload URL", + "Payment Allocation Order": "Payment Allocation Order", + "Payment Allocation Rule": "Payment Allocation Rule", "Payment Due At": "Payment Due At", "Payment Type": "Payment Type", "Payment Type Id": "Payment Type Id", diff --git a/src/assets/translations/es-MX.json b/src/assets/translations/es-MX.json index 3fa8123fa..36b6d0d3e 100644 --- a/src/assets/translations/es-MX.json +++ b/src/assets/translations/es-MX.json @@ -925,6 +925,7 @@ "Adjust advance payments toward future installments": "Ajustar los pagos por adelantado a cuotas futuras", "Adjust interest rates for remainder of loan": "Ajustar las tasas de interés para el resto del Crédito", "Advance payments adjustment type": "Tipo de ajuste de pagos anticipados", + "Advanced Payment Allocation Transaction Type": "Tipo de transacción de asignación de pago avanzada", "Affected GL Entry (Credit)": "Entrada del libro mayor afectada (crédito)", "Affected GL Entry (Credit) Rule Type": "Tipo de regla de entrada de libro mayor (crédito) afectada", "Affected GL Entry (Debit)": "Entrada de libro mayor afectada (débito)", @@ -1122,6 +1123,8 @@ "Credit Account Name": "Nombre de la cuenta de crédito", "Credit Account Type": "Tipo de cuenta de crédito", "Credit Adjustments": "Ajustes de crédito", + "Credit Allocation Order": "Orden de asignación de crédito", + "Credit Allocation Rule": "Regla de asignación de crédito", "Credit Amount": "Monto de crédito", "Credit Tags": "Etiquetas de crédito", "Cron Expression": "Expresión cron", @@ -1318,6 +1321,7 @@ "Fund": "Fondo", "Fund Source": "Fuente del fondo", "Fund source": "Fuente de fondos", + "Future Installment Allocation Rule": "Regla de asignación de cuotas futuras", "GCM End Point": "Punto final del GCM", "GENERAL": "GENERAL", "GL Account Name or Code": "Nombre o código de cuenta del libro mayor", @@ -1668,6 +1672,8 @@ "Passwords should be": "Las contraseñas deben ser", "Past Due Days": "Días vencidos", "Payload URL": "URL de carga útil", + "Payment Allocation Order": "Orden de asignación de pagos", + "Payment Allocation Rule": "Regla de asignación de pagos", "Payment Due At": "Pago vencido en", "Payment Type": "Tipo de pago", "Payment Type Id": "Identificación del tipo de pago", diff --git a/src/assets/translations/fr-FR.json b/src/assets/translations/fr-FR.json index 65316e3d3..8f1301954 100644 --- a/src/assets/translations/fr-FR.json +++ b/src/assets/translations/fr-FR.json @@ -925,6 +925,7 @@ "Adjust advance payments toward future installments": "Ajuster les paiements anticipés aux versements futurs", "Adjust interest rates for remainder of loan": "Ajuster les taux d’intérêt pour le reste du prêt", "Advance payments adjustment type": "Type d'ajustement des acomptes", + "Advanced Payment Allocation Transaction Type": "Type de transaction d'allocation de paiement avancé", "Affected GL Entry (Credit)": "Écriture GL concernée (crédit)", "Affected GL Entry (Credit) Rule Type": "Type de règle d'entrée GL (crédit) concerné", "Affected GL Entry (Debit)": "Écriture GL concernée (débit)", @@ -1122,6 +1123,8 @@ "Credit Account Name": "Nom du compte de crédit", "Credit Account Type": "Type de compte de crédit", "Credit Adjustments": "Ajustements de crédit", + "Credit Allocation Rule": "Règle d'allocation de crédit", + "Credit Allocation Order": "Commande d'allocation de crédit", "Credit Amount": "Montant du crédit", "Credit Tags": "Étiquettes de crédit", "Cron Expression": "Expression Cron", @@ -1318,6 +1321,7 @@ "Fund": "Fonds", "Fund Source": "Source du fonds", "Fund source": "Source de financement", + "Future Installment Allocation Rule": "Règle de répartition future", "GCM End Point": "Point final GCM", "GENERAL": "GÉNÉRAL", "GL Account Name or Code": "Nom ou code du compte GL", @@ -1668,6 +1672,8 @@ "Passwords should be": "Les mots de passe doivent être", "Past Due Days": "Jours en souffrance", "Payload URL": "URL de charge utile", + "Payment Allocation Order": "Ordonnance d'allocation de paiement", + "Payment Allocation Rule": "Règle d'allocation de paiement", "Payment Due At": "Paiement dû à", "Payment Type": "Type de paiement", "Payment Type Id": "Identifiant du type de paiement", diff --git a/src/assets/translations/it-IT.json b/src/assets/translations/it-IT.json index 1901ab9db..334474c96 100644 --- a/src/assets/translations/it-IT.json +++ b/src/assets/translations/it-IT.json @@ -925,6 +925,7 @@ "Adjust advance payments toward future installments": "Adeguare gli anticipi alle rate future", "Adjust interest rates for remainder of loan": "Adeguare i tassi di interesse per il resto del prestito", "Advance payments adjustment type": "Tipo di aggiustamento dei pagamenti anticipati", + "Advanced Payment Allocation Transaction Type": "Tipo di transazione di allocazione dei pagamenti avanzati", "Affected GL Entry (Credit)": "Voce GL interessata (credito)", "Affected GL Entry (Credit) Rule Type": "Tipo di regola di voce GL interessata (credito).", "Affected GL Entry (Debit)": "Voce CoGe interessata (debito)", @@ -1122,6 +1123,8 @@ "Credit Account Name": "Nome del conto di credito", "Credit Account Type": "Tipo di conto di credito", "Credit Adjustments": "Adeguamenti del credito", + "Credit Allocation Order": "Ordine di allocazione del credito", + "Credit Allocation Rule": "Regola di allocazione del credito", "Credit Amount": "Ammontare del credito", "Credit Tags": "Tag di credito", "Cron Expression": "Espressione Cron", @@ -1318,6 +1321,7 @@ "Fund": "Finanziare", "Fund Source": "Fonte del fondo", "Fund source": "Fonte del fondo", + "Future Installment Allocation Rule": "Regola di allocazione delle rate future", "GCM End Point": "Punto finale GCM", "GENERAL": "GENERALE", "GL Account Name or Code": "Nome o codice account GL", @@ -1668,6 +1672,8 @@ "Passwords should be": "Le password dovrebbero essere", "Past Due Days": "Giorni scaduti", "Payload URL": "URL del carico utile", + "Payment Allocation Order": "Ordine di allocazione dei pagamenti", + "Payment Allocation Rule": "Regola di allocazione dei pagamenti", "Payment Due At": "Pagamento dovuto a", "Payment Type": "Modalità di pagamento", "Payment Type Id": "Identificativo tipo di pagamento", diff --git a/src/assets/translations/ko-KO.json b/src/assets/translations/ko-KO.json index 3fa7132a3..4dc19f02b 100644 --- a/src/assets/translations/ko-KO.json +++ b/src/assets/translations/ko-KO.json @@ -926,6 +926,7 @@ "Adjust advance payments toward future installments": "향후 할부에 대한 선불금 조정", "Adjust interest rates for remainder of loan": "남은 대출금에 대한 이자율 조정", "Advance payments adjustment type": "선지급 조정 유형", + "Advanced Payment Allocation Transaction Type": "고급 지불 할당 거래 유형", "Affected GL Entry (Credit)": "영향을 받는 GL 항목(대변)", "Affected GL Entry (Credit) Rule Type": "영향을 받는 GL 입력(대변) 규칙 유형", "Affected GL Entry (Debit)": "영향을 받는 GL 입력(차변)", @@ -1123,6 +1124,8 @@ "Credit Account Name": "신용 계좌 이름", "Credit Account Type": "신용 계좌 유형", "Credit Adjustments": "신용 조정", + "Credit Allocation Order": "신용 할당 명령", + "Credit Allocation Rule": "신용 할당 규칙", "Credit Amount": "크레딧 금액", "Credit Tags": "신용 태그", "Cron Expression": "크론 표현", @@ -1319,6 +1322,7 @@ "Fund": "축적", "Fund Source": "자금 출처", "Fund source": "자금 출처", + "Future Installment Allocation Rule": "향후 할부 할당 규칙", "GCM End Point": "GCM 끝점", "GENERAL": "일반적인", "GL Account Name or Code": "GL 계정 이름 또는 코드", @@ -1669,6 +1673,8 @@ "Passwords should be": "비밀번호는 다음과 같아야 합니다.", "Past Due Days": "연체일", "Payload URL": "페이로드 URL", + "Payment Allocation Order": "지불 할당 명령", + "Payment Allocation Rule": "지불 할당 규칙", "Payment Due At": "지불 기한", "Payment Type": "결제 유형", "Payment Type Id": "결제 유형 ID", diff --git a/src/assets/translations/lt-LT.json b/src/assets/translations/lt-LT.json index f147938a9..b02cda453 100644 --- a/src/assets/translations/lt-LT.json +++ b/src/assets/translations/lt-LT.json @@ -925,6 +925,7 @@ "Adjust advance payments toward future installments": "Koreguokite išankstinius mokėjimus būsimoms įmokoms", "Adjust interest rates for remainder of loan": "Pakoreguokite palūkanų normas likusiai paskolos daliai", "Advance payments adjustment type": "Avansinių mokėjimų koregavimo tipas", + "Advanced Payment Allocation Transaction Type": "Išplėstinės mokėjimo paskirstymo operacijos tipas", "Affected GL Entry (Credit)": "Paveiktas GL įėjimas (kreditas)", "Affected GL Entry (Credit) Rule Type": "Paveiktas GL įrašo (kredito) taisyklės tipas", "Affected GL Entry (Debit)": "Paveiktas GL įrašas (debetas)", @@ -1122,6 +1123,8 @@ "Credit Account Name": "Kredito sąskaitos pavadinimas", "Credit Account Type": "Kredito sąskaitos tipas", "Credit Adjustments": "Kredito koregavimas", + "Credit Allocation Order": "Kredito paskirstymo užsakymas", + "Credit Allocation Rule": "Kredito paskirstymo taisyklė", "Credit Amount": "Kredito suma", "Credit Tags": "Kredito žymos", "Cron Expression": "Krono išraiška", @@ -1318,6 +1321,7 @@ "Fund": "fondas", "Fund Source": "Fondo šaltinis", "Fund source": "Lėšų šaltinis", + "Future Installment Allocation Rule": "Būsimas įmokų paskirstymo taisyklė", "GCM End Point": "GCM pabaigos taškas", "GENERAL": "BENDROJI", "GL Account Name or Code": "GL sąskaitos pavadinimas arba kodas", @@ -1668,6 +1672,8 @@ "Passwords should be": "Slaptažodžiai turėtų būti", "Past Due Days": "Praėjusios termino dienos", "Payload URL": "Naudingos apkrovos URL", + "Payment Allocation Order": "Mokėjimo paskirstymo užsakymas", + "Payment Allocation Rule": "Mokėjimo paskirstymo taisyklė", "Payment Due At": "Mokėjimo terminas", "Payment Type": "Mokėjimo tipas", "Payment Type Id": "Mokėjimo tipo ID", diff --git a/src/assets/translations/lv-LV.json b/src/assets/translations/lv-LV.json index 27b4464a7..05f2f4e7c 100644 --- a/src/assets/translations/lv-LV.json +++ b/src/assets/translations/lv-LV.json @@ -925,6 +925,7 @@ "Adjust advance payments toward future installments": "Pielāgojiet avansa maksājumus turpmākajām iemaksām", "Adjust interest rates for remainder of loan": "Pielāgojiet procentu likmes atlikušajai aizdevuma daļai", "Advance payments adjustment type": "Avansa maksājumu korekcijas veids", + "Advanced Payment Allocation Transaction Type": "Papildu maksājuma sadales darījuma veids", "Affected GL Entry (Credit)": "Ietekmētā GL ieeja (kredīts)", "Affected GL Entry (Credit) Rule Type": "Ietekmētais GL ievades (kredīta) kārtulas veids", "Affected GL Entry (Debit)": "Ietekmētais GL ieraksts (debets)", @@ -1122,6 +1123,8 @@ "Credit Account Name": "Kredīta konta nosaukums", "Credit Account Type": "Kredīta konta veids", "Credit Adjustments": "Kredīta korekcijas", + "Credit Allocation Order": "Kredīta sadales pasūtījums", + "Credit Allocation Rule": "Kredīta piešķiršanas noteikums", "Credit Amount": "Kredīta summa", "Credit Tags": "Kredītbirkas", "Cron Expression": "Krona izteiksme", @@ -1318,6 +1321,7 @@ "Fund": "fonds", "Fund Source": "Fonda avots", "Fund source": "Līdzekļu avots", + "Future Installment Allocation Rule": "Nākotnes maksājuma sadales noteikums", "GCM End Point": "GMZ beigu punkts", "GENERAL": "VISPĀRĪGI", "GL Account Name or Code": "GL konta nosaukums vai kods", @@ -1668,6 +1672,8 @@ "Passwords should be": "Parolēm jābūt", "Past Due Days": "Pagājušās dienas", "Payload URL": "Kravas URL", + "Payment Allocation Order": "Maksājumu sadales pasūtījums", + "Payment Allocation Rule": "Maksājumu sadales noteikums", "Payment Due At": "Maksājuma termiņš plkst", "Payment Type": "Maksājuma veids", "Payment Type Id": "Maksājuma veida ID", diff --git a/src/assets/translations/ne-NE.json b/src/assets/translations/ne-NE.json index 24a9982bd..d64a7cae3 100644 --- a/src/assets/translations/ne-NE.json +++ b/src/assets/translations/ne-NE.json @@ -925,6 +925,7 @@ "Adjust advance payments toward future installments": "भविष्यका किस्ताहरूमा अग्रिम भुक्तानीहरू समायोजन गर्नुहोस्", "Adjust interest rates for remainder of loan": "बाँकी ऋणको लागि ब्याज दर समायोजन गर्नुहोस्", "Advance payments adjustment type": "अग्रिम भुक्तानी समायोजन प्रकार", + "Advanced Payment Allocation Transaction Type": "उन्नत भुक्तानी सम्झौता लेनदेन प्रकार", "Affected GL Entry (Credit)": "प्रभावित GL प्रविष्टि (क्रेडिट)", "Affected GL Entry (Credit) Rule Type": "प्रभावित GL प्रविष्टि (क्रेडिट) नियम प्रकार", "Affected GL Entry (Debit)": "प्रभावित GL प्रविष्टि (डेबिट)", @@ -1122,6 +1123,8 @@ "Credit Account Name": "क्रेडिट खाता नाम", "Credit Account Type": "क्रेडिट खाता प्रकार", "Credit Adjustments": "क्रेडिट समायोजन", + "Credit Allocation Order": "क्रेडिट विनियोजन अर्डर", + "Credit Allocation Rule": "क्रेडिट विनियोजन नियम", "Credit Amount": "क्रेडिट रकम", "Credit Tags": "क्रेडिट ट्यागहरू", "Cron Expression": "क्रोन अभिव्यक्ति", @@ -1318,6 +1321,7 @@ "Fund": "कोष", "Fund Source": "कोषको स्रोत", "Fund source": "कोषको स्रोत", + "Future Installment Allocation Rule": "भविष्यको किक्तान विनियोजन नियम", "GCM End Point": "GCM अन्त्य बिन्दु", "GENERAL": "सामान्य", "GL Account Name or Code": "GL खाता नाम वा कोड", @@ -1668,6 +1672,8 @@ "Passwords should be": "पासवर्ड हुनुपर्छ", "Past Due Days": "विगतका दिनहरू", "Payload URL": "पेलोड URL", + "Payment Allocation Order": "भुक्तानी सम्झौता अर्डर", + "Payment Allocation Rule": "भुक्तानी सम्झौता नियम", "Payment Due At": "भुक्तान बाँकी मा", "Payment Type": "भुक्तानी प्रकार", "Payment Type Id": "भुक्तानी प्रकार आईडी", diff --git a/src/assets/translations/pt-PT.json b/src/assets/translations/pt-PT.json index 4fa2692f2..ef8dae373 100644 --- a/src/assets/translations/pt-PT.json +++ b/src/assets/translations/pt-PT.json @@ -925,6 +925,7 @@ "Adjust advance payments toward future installments": "Ajustar pagamentos antecipados para parcelas futuras", "Adjust interest rates for remainder of loan": "Ajustar as taxas de juros para o restante do empréstimo", "Advance payments adjustment type": "Tipo de ajuste de adiantamento", + "Advanced Payment Allocation Transaction Type": "Tipo de transação de alocação avançada de pagamento", "Affected GL Entry (Credit)": "Entrada contábil afetada (crédito)", "Affected GL Entry (Credit) Rule Type": "Tipo de regra de entrada contábil (crédito) afetada", "Affected GL Entry (Debit)": "Entrada contábil afetada (débito)", @@ -1122,6 +1123,8 @@ "Credit Account Name": "Nome da conta de crédito", "Credit Account Type": "Tipo de conta de crédito", "Credit Adjustments": "Ajustes de crédito", + "Credit Allocation Order": "Ordem de alocação de crédito", + "Credit Allocation Rule": "Regra de alocação de crédito", "Credit Amount": "Quantidade de crédito", "Credit Tags": "Etiquetas de crédito", "Cron Expression": "Expressão Cron", @@ -1318,6 +1321,7 @@ "Fund": "Fundo", "Fund Source": "Fonte do Fundo", "Fund source": "Fonte de financiamento", + "Future Installment Allocation Rule": "Regra futura de alocação de parcelas", "GCM End Point": "Ponto final do GCM", "GENERAL": "EM GERAL", "GL Account Name or Code": "Nome ou código da conta GL", @@ -1668,6 +1672,8 @@ "Passwords should be": "As senhas devem ser", "Past Due Days": "Dias vencidos", "Payload URL": "URL de carga útil", + "Payment Allocation Order": "Ordem de alocação de pagamento", + "Payment Allocation Rule": "Regra de alocação de pagamento", "Payment Due At": "Pagamento devido em", "Payment Type": "Tipo de pagamento", "Payment Type Id": "ID do tipo de pagamento", diff --git a/src/assets/translations/sw-SW.json b/src/assets/translations/sw-SW.json index 9a44a213e..e99851faa 100644 --- a/src/assets/translations/sw-SW.json +++ b/src/assets/translations/sw-SW.json @@ -925,6 +925,7 @@ "Adjust advance payments toward future installments": "Rekebisha malipo ya awali kwa awamu zijazo", "Adjust interest rates for remainder of loan": "Rekebisha viwango vya riba kwa salio la mkopo", "Advance payments adjustment type": "Aina ya marekebisho ya malipo ya mapema", + "Advanced Payment Allocation Transaction Type": "Aina ya ununuzi wa ugawaji wa malipo ya hali ya juu", "Affected GL Entry (Credit)": "Ingizo la GL lililoathiriwa (Mikopo)", "Affected GL Entry (Credit) Rule Type": "Aina ya Kanuni ya Kuingiza (Mikopo) ya GL Iliyoathiriwa", "Affected GL Entry (Debit)": "Ingizo la GL Lililoathiriwa (Malipo)", @@ -1122,6 +1123,8 @@ "Credit Account Name": "Jina la Akaunti ya Mkopo", "Credit Account Type": "Aina ya Akaunti ya Mkopo", "Credit Adjustments": "Marekebisho ya Mikopo", + "Credit Allocation Order": "Agizo la mgao wa mkopo", + "Credit Allocation Rule": "Sheria ya Ugawaji wa Mikopo", "Credit Amount": "Kiasi cha Mkopo", "Credit Tags": "Lebo za Mikopo", "Cron Expression": "Usemi wa Cron", @@ -1318,6 +1321,7 @@ "Fund": "Mfuko", "Fund Source": "Chanzo cha Mfuko", "Fund source": "Chanzo cha fedha", + "Future Installment Allocation Rule": "Sheria ya Ugawaji wa Ufungaji wa baadaye", "GCM End Point": "Sehemu ya Mwisho ya GCM", "GENERAL": "JUMLA", "GL Account Name or Code": "Jina la Akaunti ya GL au Msimbo", @@ -1668,6 +1672,8 @@ "Passwords should be": "Nywila zinapaswa kuwa", "Past Due Days": "Siku Zilizopita", "Payload URL": "URL ya malipo", + "Payment Allocation Order": "Agizo la ugawaji wa malipo", + "Payment Allocation Rule": "Sheria ya Ugawaji wa Malipo", "Payment Due At": "Malipo Yanayodaiwa Saa", "Payment Type": "Aina ya malipo", "Payment Type Id": "Kitambulisho cha Aina ya Malipo",