add missed translation for products module

This commit is contained in:
Omar-Nabil
2024-05-31 15:58:52 -06:00
committed by Jose Alberto Hernandez
parent f903bc2c0a
commit 4e48bc982c
60 changed files with 440 additions and 331 deletions
@@ -97,21 +97,21 @@
*ngIf="paymentChannelToFundSourceMappings.value.length !== 0">
<ng-container matColumnDef="paymentTypeId">
<th mat-header-cell *matHeaderCellDef> Payment Type </th>
<th mat-header-cell *matHeaderCellDef> {{'labels.heading.Payment Type' | translate}} </th>
<td mat-cell *matCellDef="let paymentFundSource">
{{ paymentFundSource.paymentTypeId | find:paymentTypeData:'id':'name' }}
</td>
</ng-container>
<ng-container matColumnDef="fundSourceAccountId">
<th mat-header-cell *matHeaderCellDef> Fund Source </th>
<th mat-header-cell *matHeaderCellDef> {{'labels.inputs.Fund Source' | translate}} </th>
<td mat-cell *matCellDef="let paymentFundSource">
{{ paymentFundSource.fundSourceAccountId | find:assetAccountData:'id':'name' }}
</td>
</ng-container>
<ng-container matColumnDef="actions">
<th mat-header-cell *matHeaderCellDef> Actions </th>
<th mat-header-cell *matHeaderCellDef> {{'labels.buttons.Actions' | translate}} </th>
<td mat-cell *matCellDef="let paymentFundSource; let i = index">
<button mat-icon-button color="primary"
(click)="edit('PaymentFundSource', paymentChannelToFundSourceMappings, i)">
@@ -144,21 +144,21 @@
*ngIf="feeToIncomeAccountMappings.value.length !== 0">
<ng-container matColumnDef="chargeId">
<th mat-header-cell *matHeaderCellDef> Fees </th>
<th mat-header-cell *matHeaderCellDef> {{'labels.catalogs.Fees' | translate}} </th>
<td mat-cell *matCellDef="let feesIncome">
{{ feesIncome.chargeId | find:chargeData:'id':'name' }}
</td>
</ng-container>
<ng-container matColumnDef="incomeAccountId">
<th mat-header-cell *matHeaderCellDef> Income Account </th>
<th mat-header-cell *matHeaderCellDef> {{'labels.inputs.Income Account' | translate}} </th>
<td mat-cell *matCellDef="let feesIncome">
{{ feesIncome.incomeAccountId | find:incomeAccountData:'id':'name' }}
</td>
</ng-container>
<ng-container matColumnDef="actions">
<th mat-header-cell *matHeaderCellDef> Actions </th>
<th mat-header-cell *matHeaderCellDef> {{'labels.buttons.Actions' | translate}} </th>
<td mat-cell *matCellDef="let feesIncome; let i = index">
<button mat-icon-button color="primary" (click)="edit('FeesIncome', feeToIncomeAccountMappings, i)">
<fa-icon icon="edit"></fa-icon>
@@ -193,21 +193,21 @@
*ngIf="penaltyToIncomeAccountMappings.value.length !== 0">
<ng-container matColumnDef="chargeId">
<th mat-header-cell *matHeaderCellDef> Penalty </th>
<th mat-header-cell *matHeaderCellDef> {{'labels.inputs.Penalty' | translate}} </th>
<td mat-cell *matCellDef="let penaltyIncome">
{{ penaltyIncome.chargeId | find:penaltyData:'id':'name' }}
</td>
</ng-container>
<ng-container matColumnDef="incomeAccountId">
<th mat-header-cell *matHeaderCellDef> Income Account </th>
<th mat-header-cell *matHeaderCellDef> {{'labels.inputs.Income Account' | translate}} </th>
<td mat-cell *matCellDef="let penaltyIncome">
{{ penaltyIncome.incomeAccountId | find:incomeAccountData:'id':'name' }}
</td>
</ng-container>
<ng-container matColumnDef="actions">
<th mat-header-cell *matHeaderCellDef> Actions </th>
<th mat-header-cell *matHeaderCellDef> {{'labels.buttons.Actions' | translate}} </th>
<td mat-cell *matCellDef="let penaltyIncome; let i = index">
<button mat-icon-button color="primary"
(click)="edit('PenaltyIncome', penaltyToIncomeAccountMappings, i)">
@@ -242,4 +242,4 @@
</button>
</div>
</form>
</form>
@@ -1,13 +1,14 @@
import { Component, OnInit, Input } from '@angular/core';
import { UntypedFormGroup, UntypedFormBuilder, UntypedFormArray, Validators, UntypedFormControl } from '@angular/forms';
import { Component, Input, OnInit } from '@angular/core';
import { UntypedFormArray, UntypedFormBuilder, UntypedFormControl, UntypedFormGroup, Validators } from '@angular/forms';
import { MatDialog } from '@angular/material/dialog';
import { FormDialogComponent } from 'app/shared/form-dialog/form-dialog.component';
import { DeleteDialogComponent } from 'app/shared/delete-dialog/delete-dialog.component';
import { FormDialogComponent } from 'app/shared/form-dialog/form-dialog.component';
import { TranslateService } from '@ngx-translate/core';
import { Accounting } from 'app/core/utils/accounting';
import { FormfieldBase } from 'app/shared/form-dialog/formfield/model/formfield-base';
import { SelectBase } from 'app/shared/form-dialog/formfield/model/select-base';
import { Accounting } from 'app/core/utils/accounting';
@Component({
selector: 'mifosx-fixed-deposit-product-accounting-step',
@@ -35,7 +36,8 @@ export class FixedDepositProductAccountingStepComponent implements OnInit {
constructor(private formBuilder: UntypedFormBuilder,
public dialog: MatDialog,
private accounting: Accounting) {
private accounting: Accounting,
private translateService: TranslateService) {
this.createfixedDepositProductAccountingForm();
this.setConditionalControls();
}
@@ -206,7 +208,7 @@ export class FixedDepositProductAccountingStepComponent implements OnInit {
delete(formArray: UntypedFormArray, index: number) {
const dialogRef = this.dialog.open(DeleteDialogComponent, {
data: { deleteContext: `this` }
data: { deleteContext: this.translateService.instant('labels.text.this') }
});
dialogRef.afterClosed().subscribe((response: any) => {
if (response.delete) {
@@ -1,7 +1,8 @@
import { Component, OnInit, Input } from '@angular/core';
import { MatDialog } from '@angular/material/dialog';
import { Component, Input, OnInit } from '@angular/core';
import { UntypedFormControl } from '@angular/forms';
import { MatDialog } from '@angular/material/dialog';
import { TranslateService } from '@ngx-translate/core';
import { DeleteDialogComponent } from 'app/shared/delete-dialog/delete-dialog.component';
@Component({
@@ -19,7 +20,8 @@ export class FixedDepositProductChargesStepComponent implements OnInit {
chargesDataSource: {}[];
displayedColumns: string[] = ['name', 'chargeCalculationType', 'amount', 'chargeTimeType', 'action'];
constructor(public dialog: MatDialog) {
constructor(public dialog: MatDialog,
private translateService: TranslateService) {
}
ngOnInit() {
@@ -39,7 +41,7 @@ export class FixedDepositProductChargesStepComponent implements OnInit {
deleteCharge(charge: any) {
const deleteChargeDialogRef = this.dialog.open(DeleteDialogComponent, {
data: { deleteContext: `charge ${charge.name}` }
data: { deleteContext: this.translateService.instant('labels.inputs.Charge') + ' ' + charge.name }
});
deleteChargeDialogRef.afterClosed().subscribe((response: any) => {
if (response.delete) {
@@ -39,7 +39,7 @@
<mat-datepicker-toggle matSuffix [for]="validFromDatePicker"></mat-datepicker-toggle>
<mat-datepicker #validFromDatePicker></mat-datepicker>
<mat-error>
Valid from Date {{'labels.commons.is' | translate}} <strong>{{'labels.commons.required' | translate}}</strong>
{{'labels.inputs.Valid from Date' | translate}} {{'labels.commons.is' | translate}} <strong>{{'labels.commons.required' | translate}}</strong>
</mat-error>
</mat-form-field>
@@ -1,24 +1,23 @@
/** Angular Imports */
import { Component, OnInit, Input } from '@angular/core';
import { UntypedFormGroup, UntypedFormBuilder, Validators, UntypedFormArray } from '@angular/forms';
import { MatDialog } from '@angular/material/dialog';
import { animate, state, style, transition, trigger } from '@angular/animations';
import { TooltipPosition } from '@angular/material/tooltip';
import { Component, Input, OnInit } from '@angular/core';
import { UntypedFormArray, UntypedFormBuilder, UntypedFormGroup, Validators } from '@angular/forms';
import { MatDialog } from '@angular/material/dialog';
/** Custom Components */
import { FormDialogComponent } from 'app/shared/form-dialog/form-dialog.component';
import { DepositProductIncentiveFormDialogComponent } from 'app/products/deposit-product-incentive-form-dialog/deposit-product-incentive-form-dialog.component';
import { DeleteDialogComponent } from 'app/shared/delete-dialog/delete-dialog.component';
import { FormDialogComponent } from 'app/shared/form-dialog/form-dialog.component';
/** Dialog Components */
import { FormfieldBase } from 'app/shared/form-dialog/formfield/model/formfield-base';
import { SelectBase } from 'app/shared/form-dialog/formfield/model/select-base';
import { InputBase } from 'app/shared/form-dialog/formfield/model/input-base';
import { SelectBase } from 'app/shared/form-dialog/formfield/model/select-base';
/** Custom Services */
import { SettingsService } from 'app/settings/settings.service';
import { Dates } from 'app/core/utils/dates';
import { TranslateService } from '@ngx-translate/core';
import { Dates } from 'app/core/utils/dates';
import { SettingsService } from 'app/settings/settings.service';
@Component({
selector: 'mifosx-fixed-deposit-product-interest-rate-chart-step',
@@ -284,7 +283,7 @@ export class FixedDepositProductInterestRateChartStepComponent implements OnInit
}
editChartSlab(chartSlabs: UntypedFormArray, chartSlabIndex: number) {
const data = { ...this.getData('Slab', chartSlabs.at(chartSlabIndex).value), layout: { addButtonText: 'Edit' } };
const data = { ...this.getData('Slab', chartSlabs.at(chartSlabIndex).value), layout: { addButtonText: this.translateService.instant('labels.text.this') } };
const dialogRef = this.dialog.open(FormDialogComponent, { data });
dialogRef.afterClosed().subscribe((response: any) => {
if (response.data) {
@@ -294,7 +293,7 @@ export class FixedDepositProductInterestRateChartStepComponent implements OnInit
}
editIncentive(incentives: UntypedFormArray, incentiveIndex: number) {
const data = { ...this.getData('Incentive', incentives.at(incentiveIndex).value), layout: { addButtonText: 'Edit' } };
const data = { ...this.getData('Incentive', incentives.at(incentiveIndex).value), layout: { addButtonText: this.translateService.instant('labels.text.this') } };
const dialogRef = this.dialog.open(DepositProductIncentiveFormDialogComponent, { data });
dialogRef.afterClosed().subscribe((response: any) => {
if (response.data) {
@@ -305,7 +304,7 @@ export class FixedDepositProductInterestRateChartStepComponent implements OnInit
delete(formArray: UntypedFormArray, index: number) {
const dialogRef = this.dialog.open(DeleteDialogComponent, {
data: { deleteContext: `this` }
data: { deleteContext: this.translateService.instant('labels.text.this') }
});
dialogRef.afterClosed().subscribe((response: any) => {
if (response.delete) {
@@ -42,8 +42,8 @@
</div>
<ng-template #templateButtonCreateFixedProduct let-popover="popover">
<h2>Create fixed deposit product</h2>
<p class="mw300">This option allows you to create new fixed deposit product.</p>
<h2>{{'labels.buttons.Create Fixed Deposit Product' | translate}}</h2>
<p class="mw300">{{'labels.text.Allows you to create new fixed deposit product' | translate}}</p>
<div fxLayout="row" fxLayoutAlign="end" fxLayoutGap="2%" fxLayout.lt-md="column">
<button mat-raised-button color="warn" (click)="popover.close();configurationWizardService.closeConfigWizard()">{{'labels.buttons.Close' | translate}}</button>
<button mat-raised-button color="primary" (click)="popover.close();previousStep()">{{'labels.buttons.Back' | translate}}</button>
@@ -52,7 +52,7 @@
</ng-template>
<ng-template #templateFilter let-popover="popover">
<h4>Search bar to filter fixed deposit products.</h4>
<h4>{{'labels.text.Search bar to filter fixed deposit products.' | translate}}</h4>
<div fxLayout="row" fxLayoutAlign="end" fxLayoutGap="2%" fxLayout.lt-md="column">
<button mat-raised-button color="warn" (click)="popover.close();configurationWizardService.closeConfigWizard()">{{'labels.buttons.Close' | translate}}</button>
<button mat-raised-button color="primary" (click)="popover.close();showPopover(templateButtonCreateFixedProduct,buttonCreateFixedProduct , 'bottom', true)">{{'labels.buttons.Back' | translate}}</button>
@@ -61,7 +61,7 @@
</ng-template>
<ng-template #templateFixedProductsTable let-popover="popover">
<h4 class="mw300">List of fixed deposit products in the organization. For more details click: <a href="https://mifosforge.jira.com/wiki/spaces/docs/pages/102629544/Fixed+Deposit+Products" target="_blank">{{'labels.inputs.Fixed Deposit Products' | translate}}</a></h4>
<h4 class="mw300">{{'labels.text.List of fixed deposit products in the organization' | translate}}: <a href="https://mifosforge.jira.com/wiki/spaces/docs/pages/102629544/Fixed+Deposit+Products" target="_blank">{{'labels.inputs.Fixed Deposit Products' | translate}}</a></h4>
<div fxLayout="row" fxLayoutAlign="end" fxLayoutGap="2%" fxLayout.lt-md="column">
<button mat-raised-button color="warn" (click)="popover.close();configurationWizardService.closeConfigWizard()">{{'labels.buttons.Close' | translate}}</button>
<button mat-raised-button color="primary" (click)="popover.close();showPopover(templateFilter,filter, 'bottom', true)">{{'labels.buttons.Back' | translate}}</button>
@@ -9,20 +9,19 @@
<div fxLayout="row wrap" fxLayout.lt-md="column" fxLayoutGap="4%">
<mat-form-field fxFlex="30%">
<mat-label>Floating Rate Name</mat-label>
<mat-label>{{'labels.inputs.Floating Rate Name' | translate}}</mat-label>
<input matInput required matTooltip="Unique name for the floating rate scheme." formControlName="name">
<mat-error *ngIf="floatingRateForm.controls.name.hasError('required')">
Floating Rate Name is <strong>required</strong>
{{'labels.inputs.Floating Rate Name' | translate}} {{"labels.commons.is" | translate}} <strong>{{"labels.commons.required" | translate}}</strong>
</mat-error>
</mat-form-field>
<div class="checkbox-wrapper" fxFlex="30%">
<mat-checkbox formControlName="isBaseLendingRate" matTooltip="Check if this floating rate scheme is to be considered base lending rate for the organisation" class="checkbox" labelPosition="before">Is Base Lending
Rate?</mat-checkbox>
<mat-checkbox formControlName="isBaseLendingRate" matTooltip="Check if this floating rate scheme is to be considered base lending rate for the organisation" class="checkbox" labelPosition="before">{{'labels.inputs.Is Base Lending Rate' | translate}}?</mat-checkbox>
</div>
<div class="checkbox-wrapper" fxFlex="30%">
<mat-checkbox formControlName="isActive" matTooltip="Check if this floating rate scheme to be activated" class="checkbox" labelPosition="before">Active</mat-checkbox>
<mat-checkbox formControlName="isActive" matTooltip="Check if this floating rate scheme to be activated" class="checkbox" labelPosition="before">{{'labels.inputs.Active' | translate}}</mat-checkbox>
</div>
</div>
@@ -35,7 +34,7 @@
<div fxLayout="row wrap" fxLayoutGap="70%" fxLayoutGap.lt-md="0px" class="m-b-10" fxLayout.lt-md="column">
<p fxFlex="25%" class="mat-title">Floating Rate Periods <i class="fas fa-question" matTooltip="Floating interest rate and start date for this floating rate scheme"></i></p>
<p fxFlex="25%" class="mat-title">{{'labels.inputs.Floating Rate Periods' | translate}} <i class="fas fa-question" matTooltip="Floating interest rate and start date for this floating rate scheme"></i></p>
<button mat-mini-fab type="button" color="primary" (click)="addFloatingRatePeriod()">
<fa-icon icon="plus"></fa-icon>
@@ -46,17 +45,17 @@
<table mat-table [dataSource]="dataSource" matSort>
<ng-container matColumnDef="fromDate">
<th mat-header-cell *matHeaderCellDef matTooltip="Interest effective from date" mat-sort-header> From Date </th>
<th mat-header-cell *matHeaderCellDef matTooltip="Interest effective from date" mat-sort-header> {{'labels.inputs.From Date' | translate}} </th>
<td mat-cell *matCellDef="let floatingRatePeriod"> {{ floatingRatePeriod.fromDate | dateFormat }} </td>
</ng-container>
<ng-container matColumnDef="interestRate">
<th mat-header-cell *matHeaderCellDef matTooltip="Annualised Interest rate" mat-sort-header> Interest Rate </th>
<th mat-header-cell *matHeaderCellDef matTooltip="Annualised Interest rate" mat-sort-header> {{'labels.inputs.Interest Rate' | translate}} </th>
<td mat-cell *matCellDef="let floatingRatePeriod"> {{ floatingRatePeriod.interestRate | formatNumber }} </td>
</ng-container>
<ng-container matColumnDef="isDifferential">
<th mat-header-cell *matHeaderCellDef matTooltip="If checked, Interest rate mentioned is added to base lending rate as of the from date of this period, absolute otherwise" mat-sort-header> Is Differential? </th>
<th mat-header-cell *matHeaderCellDef matTooltip="If checked, Interest rate mentioned is added to base lending rate as of the from date of this period, absolute otherwise" mat-sort-header> {{'labels.inputs.Is Differential' | translate}}? </th>
<td mat-cell *matCellDef="let floatingRate">
<fa-icon *ngIf="floatingRate.isDifferentialToBaseLendingRate" icon="check-circle" size="lg"
class="is-differential" matTooltip="Yes" matTooltipPosition="right"></fa-icon>
@@ -66,7 +65,7 @@
</ng-container>
<ng-container matColumnDef="actions">
<th mat-header-cell *matHeaderCellDef> Actions </th>
<th mat-header-cell *matHeaderCellDef> {{'labels.inputs.Actions' | translate}} </th>
<td mat-cell *matCellDef="let floatingRatePeriod" fxLayoutGap="15%">
<button type="button" fxFlex="8%" color="primary" mat-icon-button matTooltip="Edit Period" matTooltipPosition="left"
(click)="editFloatingRatePeriod(floatingRatePeriod)">
@@ -89,8 +88,8 @@
</mat-card-content>
<mat-card-actions fxLayout="row" fxLayout.xs="column" fxLayoutAlign="center" fxLayoutGap="5px">
<button type="button" mat-raised-button [routerLink]="['../']">Cancel</button>
<button mat-raised-button type="submit" color="primary" [disabled]="!floatingRateForm.valid" *mifosxHasPermission="'CREATE_FLOATINGRATE'">Submit</button>
<button type="button" mat-raised-button [routerLink]="['../']">{{'labels.buttons.Cancel' | translate}}</button>
<button mat-raised-button type="submit" color="primary" [disabled]="!floatingRateForm.valid" *mifosxHasPermission="'CREATE_FLOATINGRATE'">{{'labels.buttons.Submit' | translate}}</button>
</mat-card-actions>
</form>
@@ -1,21 +1,21 @@
/** Angular Imports */
import { Component, OnInit, ViewChild } from '@angular/core';
import { Router, ActivatedRoute } from '@angular/router';
import { UntypedFormBuilder, UntypedFormGroup, Validators, FormArray } from '@angular/forms';
import { UntypedFormBuilder, UntypedFormGroup, Validators } from '@angular/forms';
import { MatDialog } from '@angular/material/dialog';
import { MatPaginator } from '@angular/material/paginator';
import { MatSort } from '@angular/material/sort';
import { MatTableDataSource } from '@angular/material/table';
import { TooltipPosition } from '@angular/material/tooltip';
import { ActivatedRoute, Router } from '@angular/router';
/** Custom Services */
import { ProductsService } from '../../products.service';
import { SettingsService } from 'app/settings/settings.service';
import { ProductsService } from '../../products.service';
/** Custom Components */
import { FloatingRatePeriodDialogComponent } from '../floating-rate-period-dialog/floating-rate-period-dialog.component';
import { DeleteDialogComponent } from 'app/shared/delete-dialog/delete-dialog.component';
import { TranslateService } from '@ngx-translate/core';
import { Dates } from 'app/core/utils/dates';
import { DeleteDialogComponent } from 'app/shared/delete-dialog/delete-dialog.component';
import { FloatingRatePeriodDialogComponent } from '../floating-rate-period-dialog/floating-rate-period-dialog.component';
/**
* Create Floating Rate Component.
@@ -53,6 +53,7 @@ export class CreateFloatingRateComponent implements OnInit {
* @param {Dates} dateUtils Date Utils.
* @param {MatDialog} dialog Dialog reference.
* @param {SettingsService} settingsService Settings Service.
* @param {TranslateService} translateService Translate Service.
*/
constructor(private router: Router,
private formBuilder: UntypedFormBuilder,
@@ -60,7 +61,8 @@ export class CreateFloatingRateComponent implements OnInit {
private route: ActivatedRoute,
private dateUtils: Dates,
private dialog: MatDialog,
private settingsService: SettingsService) { }
private settingsService: SettingsService,
private translateService:TranslateService) { }
/**
* Sets the floating rate periods table.
@@ -158,7 +160,7 @@ export class CreateFloatingRateComponent implements OnInit {
*/
deleteFloatingRatePeriod(ratePeriod: any) {
const deleteFloatingRatePeriodRef = this.dialog.open(DeleteDialogComponent, {
data: { deleteContext: `floating rate period with from date as ${ratePeriod.fromDate}` }
data: { deleteContext: this.translateService.instant('labels.inputs.floating rate period with from date as') + ' ' + ratePeriod.fromDate }
});
deleteFloatingRatePeriodRef.afterClosed().subscribe((response: any) => {
if (response.delete) {
@@ -9,22 +9,22 @@
<div fxLayout="row wrap" fxLayout.lt-md="column" fxLayoutGap="15%">
<mat-form-field fxFlex="25%">
<mat-label>Floating Rate Name</mat-label>
<mat-label>{{'labels.inputs.Floating Rate Name' | translate}}</mat-label>
<input matInput required matTooltip="Unique name for the floating rate scheme." formControlName="name">
<mat-error *ngIf="floatingRateForm.controls.name.hasError('required')">
Floating Rate Name is <strong>required</strong>
{{'labels.inputs.Floating Rate Name' | translate}} {{"labels.commons.is" | translate}} <strong>{{"labels.commons.required" | translate}}</strong>
</mat-error>
</mat-form-field>
<div class="checkbox-wrapper" fxFlex="25%">
<mat-checkbox formControlName="isBaseLendingRate" matTooltip="Check if this floating rate scheme is to be considered base lending rate for the organisation" class="checkbox" labelPosition="before">
Is Base Lending Rate?
{{'labels.inputs.Is Base Lending Rate' | translate}}?
</mat-checkbox>
</div>
<div class="checkbox-wrapper" fxFlex="15%">
<mat-checkbox formControlName="isActive" matTooltip="Check if this floating rate scheme to be activated" class="checkbox" labelPosition="before">
Active
{{'labels.inputs.Active' | translate}}
</mat-checkbox>
</div>
@@ -38,7 +38,7 @@
<div fxLayout="row wrap" fxLayoutGap="70%" fxLayoutGap.lt-md="0px" class="m-b-10" fxLayout.lt-md="column">
<p fxFlex="25%" class="mat-title">Floating Rate Periods <i class="fas fa-question" matTooltip="Floating interest rate and start date for this floating rate scheme"></i></p>
<p fxFlex="25%" class="mat-title">{{'labels.inputs.Floating Rate Periods' | translate}} <i class="fas fa-question" matTooltip="Floating interest rate and start date for this floating rate scheme"></i></p>
<button mat-mini-fab type="button" color="primary" (click)="addFloatingRatePeriod()">
<fa-icon icon="plus"></fa-icon>
@@ -49,17 +49,17 @@
<table mat-table [dataSource]="dataSource" matSort>
<ng-container matColumnDef="fromDate">
<th mat-header-cell *matHeaderCellDef matTooltip="Interest effective from date" mat-sort-header> From Date </th>
<th mat-header-cell *matHeaderCellDef matTooltip="Interest effective from date" mat-sort-header> {{'labels.inputs.From Date' | translate}} </th>
<td mat-cell *matCellDef="let floatingRatePeriod"> {{ floatingRatePeriod.fromDate | dateFormat }} </td>
</ng-container>
<ng-container matColumnDef="interestRate">
<th mat-header-cell *matHeaderCellDef matTooltip="Annualised Interest rate" mat-sort-header> Interest Rate </th>
<th mat-header-cell *matHeaderCellDef matTooltip="Annualised Interest rate" mat-sort-header> {{'labels.inputs.Interest Rate' | translate}} </th>
<td mat-cell *matCellDef="let floatingRatePeriod"> {{ floatingRatePeriod.interestRate }} </td>
</ng-container>
<ng-container matColumnDef="isDifferential">
<th mat-header-cell *matHeaderCellDef matTooltip="If checked, Interest rate mentioned is added to base lending rate as of the from date of this period, absolute otherwise" mat-sort-header> Is Differential? </th>
<th mat-header-cell *matHeaderCellDef matTooltip="If checked, Interest rate mentioned is added to base lending rate as of the from date of this period, absolute otherwise" mat-sort-header> {{'labels.inputs.Is Differential' | translate}}? </th>
<td mat-cell *matCellDef="let floatingRate">
<fa-icon *ngIf="floatingRate.isDifferentialToBaseLendingRate" icon="check-circle" size="lg"
class="is-differential" matTooltip="Yes" matTooltipPosition="right"></fa-icon>
@@ -69,7 +69,7 @@
</ng-container>
<ng-container matColumnDef="actions">
<th mat-header-cell *matHeaderCellDef> Actions </th>
<th mat-header-cell *matHeaderCellDef> {{'labels.inputs.Actions' | translate}} </th>
<td mat-cell *matCellDef="let floatingRatePeriod">
<button type="button" color="primary" mat-icon-button
(click)="editFloatingRatePeriod(floatingRatePeriod)">
@@ -92,9 +92,9 @@
</mat-card-content>
<mat-card-actions fxLayout="row" fxLayout.xs="column" fxLayoutAlign="center" fxLayoutGap="5px">
<button type="button" mat-raised-button [routerLink]="['../']">Cancel</button>
<button type="button" mat-raised-button [routerLink]="['../']">{{'labels.buttons.Cancel' | translate}}</button>
<button mat-raised-button type="submit" color="primary" [disabled]="!floatingRateForm.valid || floatingRateForm.pristine && isFloatingRateFormPristine">
Submit
{{'labels.buttons.Submit' | translate}}
</button>
</mat-card-actions>
@@ -1,21 +1,21 @@
/** Angular Imports */
import { Component, OnInit, ViewChild } from '@angular/core';
import { Router, ActivatedRoute } from '@angular/router';
import { UntypedFormBuilder, UntypedFormGroup, Validators, FormArray } from '@angular/forms';
import { UntypedFormBuilder, UntypedFormGroup, Validators } from '@angular/forms';
import { MatDialog } from '@angular/material/dialog';
import { MatPaginator } from '@angular/material/paginator';
import { MatSort } from '@angular/material/sort';
import { MatTableDataSource } from '@angular/material/table';
import { TooltipPosition } from '@angular/material/tooltip';
import { ActivatedRoute, Router } from '@angular/router';
/** Custom Services */
import { ProductsService } from '../../products.service';
import { SettingsService } from 'app/settings/settings.service';
import { ProductsService } from '../../products.service';
/** Custom Components */
import { FloatingRatePeriodDialogComponent } from '../floating-rate-period-dialog/floating-rate-period-dialog.component';
import { DeleteDialogComponent } from 'app/shared/delete-dialog/delete-dialog.component';
import { TranslateService } from '@ngx-translate/core';
import { Dates } from 'app/core/utils/dates';
import { DeleteDialogComponent } from 'app/shared/delete-dialog/delete-dialog.component';
import { FloatingRatePeriodDialogComponent } from '../floating-rate-period-dialog/floating-rate-period-dialog.component';
/**
* Edit Floating Rate Component.
@@ -58,6 +58,7 @@ export class EditFloatingRateComponent implements OnInit {
* @param {Dates} dateUtils Date Utils.
* @param {MatDialog} dialog Dialog reference.
* @param {SettingsService} settingsService Settings Service.
* @param {TranslateService} translateService Translate Service.
*/
constructor(private router: Router,
private formBuilder: UntypedFormBuilder,
@@ -65,7 +66,8 @@ export class EditFloatingRateComponent implements OnInit {
private route: ActivatedRoute,
private dateUtils: Dates,
private dialog: MatDialog,
private settingsService: SettingsService) {
private settingsService: SettingsService,
private translateService:TranslateService) {
this.route.data.subscribe((data: { floatingRate: any }) => {
this.floatingRateData = data.floatingRate;
this.floatingRatePeriodsData = data.floatingRate.ratePeriods ? data.floatingRate.ratePeriods : [];
@@ -155,7 +157,7 @@ export class EditFloatingRateComponent implements OnInit {
*/
deleteFloatingRatePeriod(ratePeriod: any) {
const deleteFloatingRatePeriodRef = this.dialog.open(DeleteDialogComponent, {
data: { deleteContext: `floating rate period with from date as ${ratePeriod.fromDate}` }
data: { deleteContext: this.translateService.instant('labels.inputs.floating rate period with from date as') + ' ' + ratePeriod.fromDate }
});
deleteFloatingRatePeriodRef.afterClosed().subscribe((response: any) => {
if (response.delete) {
@@ -1,4 +1,4 @@
<h1 mat-dialog-title>Floating Rate Period</h1>
<h1 mat-dialog-title>{{'labels.inputs.Floating Rate Periods' | translate}}</h1>
<mat-dialog-content>
@@ -7,25 +7,25 @@
<div fxLayout="column">
<mat-form-field (click)="fromDatePicker.open()">
<mat-label>From Date</mat-label>
<mat-label>{{'labels.inputs.From Date' | translate}}</mat-label>
<input required matInput formControlName="fromDate" [min]="minDate" [matDatepicker]="fromDatePicker">
<mat-datepicker-toggle matSuffix [for]="fromDatePicker"></mat-datepicker-toggle>
<mat-datepicker #fromDatePicker></mat-datepicker>
<mat-error *ngIf="floatingRatePeriodForm.controls.fromDate.hasError('required')">
From Date is <strong>required</strong>
{{'labels.inputs.From Date' | translate}} {{"labels.commons.is" | translate}} <strong>{{"labels.commons.required" | translate}}</strong>
</mat-error>
</mat-form-field>
<mat-form-field>
<mat-label>Interest Rate</mat-label>
<mat-label>{{'labels.inputs.Interest Rate' | translate}}</mat-label>
<input matInput type="number" required formControlName="interestRate">
<mat-error *ngIf="floatingRatePeriodForm.controls.interestRate.hasError('required')">
Interest Rate is <strong>required</strong>
{{'labels.inputs.Interest Rate' | translate}} {{"labels.commons.is" | translate}} <strong>{{"labels.commons.required" | translate}}</strong>
</mat-error>
</mat-form-field>
<mat-checkbox class="is-differential" formControlName="isDifferentialToBaseLendingRate" labelPosition="after">
Is Differential?
{{'labels.inputs.Is Differential' | translate}}?
</mat-checkbox>
</div>
@@ -35,7 +35,7 @@
</mat-dialog-content>
<mat-dialog-actions align="end">
<button mat-button mat-dialog-close>Cancel</button>
<button mat-button mat-dialog-close>{{'labels.buttons.Cancel' | translate}}</button>
<button mat-raised-button color="primary"
[disabled]="!floatingRatePeriodForm.valid || floatingRatePeriodForm.pristine" (click)="submit()">Submit</button>
[disabled]="!floatingRatePeriodForm.valid || floatingRatePeriodForm.pristine" (click)="submit()">{{'labels.buttons.Submit' | translate}}</button>
</mat-dialog-actions>
@@ -1,7 +1,7 @@
<div class="container m-b-20" fxLayout="row" fxLayoutAlign="end" fxLayoutGap="20px">
<button mat-raised-button color="primary" [routerLink]="['create']" *mifosxHasPermission="'CREATE_FLOATINGRATE'">
<fa-icon icon="plus" class="m-r-10"></fa-icon>
Create Floating Rate
{{'labels.buttons.Create Floating Rate' | translate}}
</button>
</div>
@@ -19,17 +19,17 @@
<table mat-table [dataSource]="dataSource" matSort>
<ng-container matColumnDef="name">
<th mat-header-cell *matHeaderCellDef mat-sort-header> Name </th>
<th mat-header-cell *matHeaderCellDef mat-sort-header> {{'labels.inputs.Name' | translate}} </th>
<td mat-cell *matCellDef="let floatingRate"> {{ floatingRate.name }} </td>
</ng-container>
<ng-container matColumnDef="createdBy">
<th mat-header-cell *matHeaderCellDef mat-sort-header> Created By </th>
<th mat-header-cell *matHeaderCellDef mat-sort-header> {{'labels.inputs.Created By' | translate}} </th>
<td mat-cell *matCellDef="let floatingRate"> {{ floatingRate.createdBy }} </td>
</ng-container>
<ng-container matColumnDef="isBaseLendingRate">
<th mat-header-cell *matHeaderCellDef mat-sort-header> Is base lending rate? </th>
<th mat-header-cell *matHeaderCellDef mat-sort-header> {{'labels.inputs.Is Base Lending Rate' | translate}}? </th>
<td mat-cell *matCellDef="let floatingRate">
<fa-icon *ngIf="floatingRate.isBaseLendingRate" icon="check-circle" size="lg" class="is-base-lending-rate-or-active" matTooltip="Yes" matTooltipPosition="right"></fa-icon>
<fa-icon *ngIf="!floatingRate.isBaseLendingRate" icon="times-circle" size="lg" class="not-is-base-lending-rate-or-active" matTooltip="No" matTooltipPosition="right"></fa-icon>
@@ -37,7 +37,7 @@
</ng-container>
<ng-container matColumnDef="isActive">
<th mat-header-cell *matHeaderCellDef mat-sort-header> Active </th>
<th mat-header-cell *matHeaderCellDef mat-sort-header> {{'labels.catalogs.Active' | translate}} </th>
<td mat-cell *matCellDef="let floatingRate">
<fa-icon *ngIf="floatingRate.isActive" icon="check-circle" size="lg" class="is-base-lending-rate-or-active" matTooltip="Yes" matTooltipPosition="right"></fa-icon>
<fa-icon *ngIf="!floatingRate.isActive" icon="times-circle" size="lg" class="not-is-base-lending-rate-or-active" matTooltip="No" matTooltipPosition="right"></fa-icon>
@@ -2,7 +2,7 @@
<button mat-raised-button color="primary" [routerLink]="['edit']" *mifosxHasPermission="'UPDATE_FLOATINGRATE'">
<fa-icon icon="edit" class="m-r-10"></fa-icon>
Edit
{{'labels.buttons.Edit' | translate}}
</button>
</div>
@@ -16,7 +16,7 @@
<div fxLayout="row wrap" class="content" fxLayout.lt-md="column">
<div fxFlex="18%" class="mat-body-strong">
Floating Rate Name:
{{'labels.inputs.Floating Rate Name' | translate}}:
</div>
<div fxFlex="18%">
@@ -24,7 +24,7 @@
</div>
<div fxFlex="20%" class="mat-body-strong">
Is Base Lending Rate:
{{'labels.inputs.Is Base Lending Rate' | translate}}:
</div>
<div fxFlex="10%">
@@ -32,7 +32,7 @@
</div>
<div fxFlex="14%" class="mat-body-strong">
Is Active:
{{'labels.inputs.Is Active' | translate}}:
</div>
<div fxFlex="10%">
@@ -47,24 +47,24 @@
<br>
<p class="mat-title">Floating Rate Periods</p>
<p class="mat-title">{{'labels.inputs.Floating Rate Periods' | translate}}</p>
<div class="mat-elevation-z8">
<table mat-table [dataSource]="dataSource" matSort>
<ng-container matColumnDef="fromDate">
<th mat-header-cell *matHeaderCellDef mat-sort-header> From Date </th>
<th mat-header-cell *matHeaderCellDef mat-sort-header> {{'labels.inputs.From Date' | translate}} </th>
<td mat-cell *matCellDef="let floatingRate"> {{ floatingRate.fromDate | dateFormat }} </td>
</ng-container>
<ng-container matColumnDef="interestRate">
<th mat-header-cell *matHeaderCellDef mat-sort-header> Interest Rate </th>
<th mat-header-cell *matHeaderCellDef mat-sort-header> {{'labels.inputs.Interest Rate' | translate}} </th>
<td mat-cell *matCellDef="let floatingRate"> {{ floatingRate.interestRate | number }} </td>
</ng-container>
<ng-container matColumnDef="isDifferential">
<th mat-header-cell *matHeaderCellDef mat-sort-header> Is Differential? </th>
<th mat-header-cell *matHeaderCellDef mat-sort-header> {{'labels.inputs.Is Differential' | translate}}? </th>
<td mat-cell *matCellDef="let floatingRate">
<fa-icon *ngIf="floatingRate.isDifferentialToBaseLendingRate" icon="check-circle" size="lg"
class="is-differential" matTooltip="Yes" matTooltipPosition="right"></fa-icon>
@@ -289,7 +289,7 @@
<span fxFlex="47%">{{ 'labels.inputs.Repay Every' | translate}}:</span>
<span fxFlex="53%">{{ loanProduct.repaymentEvery }} {{ loanProduct.repaymentFrequencyType.value | translateCatalog }}</span>
</div>
<div fxFlexFill *ngIf="loanProduct.fixedLength">
<span fxFlex="47%">{{ 'labels.inputs.Fixed Length' | translate}}:</span>
<span fxFlex="53%">{{ loanProduct.fixedLength }} {{ loanProduct.repaymentFrequencyType.value | translateCatalog }}</span>
@@ -537,7 +537,7 @@
<span fxFlex="47%">{{ 'labels.inputs.Frequency Interval for recalculation' | translate}}:</span>
<span fxFlex="53%">{{ loanProduct.interestRecalculationData.recalculationRestFrequencyInterval }}</span>
<div fxFlexFill *ngIf="loanProduct.recalculationRestFrequencyDate">
<span fxFlex="47%">Rest Frequency Date:</span>
<span fxFlex="47%">{{ 'labels.inputs.Rest Frequency Date' | translate}}:</span>
<span fxFlex="53%">{{ loanProduct.interestRecalculationData.recalculationRestFrequencyDate }}</span>
</div>
</div>
@@ -811,27 +811,27 @@
*ngIf="isAdvancedAccountingEnabled()"
fxFlexFill fxLayout="row wrap" fxLayout.lt-md="column">
<h3 class="mat-h3" fxFlexFill>Advanced Accounting Rules</h3>
<h3 class="mat-h3" fxFlexFill>{{'labels.heading.Advanced Accounting Rules' | translate}}</h3>
<mat-divider [inset]="true"></mat-divider>
<div *ngIf="paymentChannelToFundSourceMappings.length" fxFlexFill fxLayout="row wrap"
fxLayout.lt-md="column">
<h4 class="mat-h4" fxFlexFill>Fund Sources for Payment Channels</h4>
<h4 class="mat-h4" fxFlexFill>{{'labels.heading.Configure Fund Sources for Payment Channels' | translate}}</h4>
<table fxFlexFill class="mat-elevation-z1" mat-table
[dataSource]="paymentChannelToFundSourceMappings">
<ng-container matColumnDef="paymentTypeId">
<th mat-header-cell *matHeaderCellDef> Payment Type </th>
<th mat-header-cell *matHeaderCellDef> {{'labels.heading.Payment Type' | translate}} </th>
<td mat-cell *matCellDef="let paymentFundSource">
{{ paymentFundSource.paymentType.name }}
</td>
</ng-container>
<ng-container matColumnDef="fundSourceAccountId">
<th mat-header-cell *matHeaderCellDef> Fund Source </th>
<th mat-header-cell *matHeaderCellDef> {{'labels.inputs.Fund Source' | translate}} </th>
<td mat-cell *matCellDef="let paymentFundSource">
{{ paymentFundSource.fundSourceAccount.name }}
</td>
@@ -847,19 +847,19 @@
<div *ngIf="feeToIncomeAccountMappings.length" fxFlexFill fxLayout="row wrap"
fxLayout.lt-md="column">
<h4 class="mat-h4" fxFlexFill>Fees to Specific Income Accounts</h4>
<h4 class="mat-h4" fxFlexFill>{{'labels.heading.Map Fees to Specific Income Accounts' | translate}}</h4>
<table fxFlexFill class="mat-elevation-z1" mat-table [dataSource]="feeToIncomeAccountMappings">
<ng-container matColumnDef="chargeId">
<th mat-header-cell *matHeaderCellDef> Fees </th>
<th mat-header-cell *matHeaderCellDef> {{'labels.catalogs.Fees' | translate}} </th>
<td mat-cell *matCellDef="let feesIncome">
{{ feesIncome.charge.name }}
</td>
</ng-container>
<ng-container matColumnDef="incomeAccountId">
<th mat-header-cell *matHeaderCellDef> Income Account </th>
<th mat-header-cell *matHeaderCellDef> {{'labels.inputs.Income Account' | translate}} </th>
<td mat-cell *matCellDef="let feesIncome">
<span *ngIf="feesIncome.incomeAccount">
{{ feesIncome.incomeAccount.name }}
@@ -877,19 +877,19 @@
<div *ngIf="penaltyToIncomeAccountMappings.length" fxFlexFill fxLayout="row wrap"
fxLayout.lt-md="column">
<h4 class="mat-h4" fxFlexFill>Penalties to Specific Income Accounts</h4>
<h4 class="mat-h4" fxFlexFill>{{'labels.heading.Map Penalties to Specific Income Accounts' | translate}}</h4>
<table fxFlexFill class="mat-elevation-z1" mat-table [dataSource]="penaltyToIncomeAccountMappings">
<ng-container matColumnDef="chargeId">
<th mat-header-cell *matHeaderCellDef> Penalty </th>
<th mat-header-cell *matHeaderCellDef> {{'labels.inputs.Penalty' | translate}} </th>
<td mat-cell *matCellDef="let penaltyIncome">
{{ penaltyIncome.charge.name }}
</td>
</ng-container>
<ng-container matColumnDef="incomeAccountId">
<th mat-header-cell *matHeaderCellDef> Income Account </th>
<th mat-header-cell *matHeaderCellDef> {{'labels.inputs.Income Account' | translate}} </th>
<td mat-cell *matCellDef="let penaltyIncome">
{{ penaltyIncome.incomeAccount.name }}
</td>
@@ -1,10 +1,11 @@
import { Component, OnInit, Input } from '@angular/core';
import { UntypedFormGroup, UntypedFormBuilder, UntypedFormArray, Validators, UntypedFormControl } from '@angular/forms';
import { Component, Input, OnInit } from '@angular/core';
import { UntypedFormArray, UntypedFormBuilder, UntypedFormControl, UntypedFormGroup, Validators } from '@angular/forms';
import { MatDialog } from '@angular/material/dialog';
import { FormDialogComponent } from 'app/shared/form-dialog/form-dialog.component';
import { DeleteDialogComponent } from 'app/shared/delete-dialog/delete-dialog.component';
import { FormDialogComponent } from 'app/shared/form-dialog/form-dialog.component';
import { TranslateService } from '@ngx-translate/core';
import { FormfieldBase } from 'app/shared/form-dialog/formfield/model/formfield-base';
import { SelectBase } from 'app/shared/form-dialog/formfield/model/select-base';
@@ -35,7 +36,8 @@ export class LoanProductAccountingStepComponent implements OnInit {
feesPenaltyIncomeDisplayedColumns: string[] = ['chargeId', 'incomeAccountId', 'actions'];
constructor(private formBuilder: UntypedFormBuilder,
public dialog: MatDialog) {
public dialog: MatDialog,
private translateService: TranslateService) {
this.createLoanProductAccountingForm();
this.setConditionalControls();
}
@@ -218,7 +220,7 @@ export class LoanProductAccountingStepComponent implements OnInit {
delete(formArray: UntypedFormArray, index: number) {
const dialogRef = this.dialog.open(DeleteDialogComponent, {
data: { deleteContext: `this` }
data: { deleteContext: this.translateService.instant('labels.text.this') }
});
dialogRef.afterClosed().subscribe((response: any) => {
if (response.delete) {
@@ -1,8 +1,8 @@
import { Component, OnInit, Input } from '@angular/core';
import { MatDialog } from '@angular/material/dialog';
import { Component, Input, OnInit } from '@angular/core';
import { UntypedFormControl } from '@angular/forms';
import { TooltipPosition } from '@angular/material/tooltip';
import { MatDialog } from '@angular/material/dialog';
import { TranslateService } from '@ngx-translate/core';
import { DeleteDialogComponent } from 'app/shared/delete-dialog/delete-dialog.component';
@Component({
@@ -24,7 +24,8 @@ export class LoanProductChargesStepComponent implements OnInit {
pristine = true;
constructor(public dialog: MatDialog) {
constructor(public dialog: MatDialog,
private translateService: TranslateService) {
}
ngOnInit() {
@@ -48,7 +49,7 @@ export class LoanProductChargesStepComponent implements OnInit {
deleteCharge(charge: any) {
const deleteChargeDialogRef = this.dialog.open(DeleteDialogComponent, {
data: { deleteContext: `charge ${charge.name}` }
data: { deleteContext: this.translateService.instant('labels.inputs.Charge') + ' ' + charge.name }
});
deleteChargeDialogRef.afterClosed().subscribe((response: any) => {
if (response.delete) {
@@ -1,10 +1,11 @@
import { Component, EventEmitter, Input, OnInit, Output, ViewChild } from '@angular/core';
import { AdvancedCreditAllocation, 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';
import { Component, EventEmitter, Input, OnInit, Output, ViewChild } from '@angular/core';
import { UntypedFormControl, Validators } from '@angular/forms';
import { MatDialog } from '@angular/material/dialog';
import { MatTable } from '@angular/material/table';
import { TranslateService } from '@ngx-translate/core';
import { DeleteDialogComponent } from 'app/shared/delete-dialog/delete-dialog.component';
import { AdvancedCreditAllocation, AdvancedPaymentAllocation, AdvancedPaymentStrategy, CreditAllocationOrder, FutureInstallmentAllocationRule, PaymentAllocationOrder, PaymentAllocationTransactionType } from '../payment-allocation-model';
@Component({
selector: 'mifosx-advance-payment-allocation-tab',
@@ -30,7 +31,8 @@ export class AdvancePaymentAllocationTabComponent implements OnInit {
@ViewChild('table') table: MatTable<any>;
constructor(private dialog: MatDialog,
private advancedPaymentStrategy: AdvancedPaymentStrategy) { }
private advancedPaymentStrategy: AdvancedPaymentStrategy,
private translateService:TranslateService) { }
ngOnInit(): void {
if (this.advancedCreditAllocation) {
@@ -88,7 +90,7 @@ export class AdvancePaymentAllocationTabComponent implements OnInit {
transaction.credit = true;
}
const dialogRef = this.dialog.open(DeleteDialogComponent, {
data: { deleteContext: ` the Transaction Type ${transaction.value}` }
data: { deleteContext: this.translateService.instant('labels.dialogContext.the Transaction Type') + ' ' + transaction.value }
});
dialogRef.afterClosed().subscribe((response: any) => {
if (response.delete) {
@@ -24,7 +24,7 @@
<mat-tab disabled>
<ng-template mat-tab-label>
<button mat-icon-button (click)="addTransaction()">
<mat-icon>add</mat-icon>
<mat-icon>{{ 'labels.buttons.Add' | translate}}</mat-icon>
</button>
</ng-template>
</mat-tab>
@@ -8,7 +8,7 @@
<mat-label>{{'labels.inputs.Minimum' | translate}}</mat-label>
<input type="number" matInput formControlName="minPrincipal" [min]="0">
<mat-error>
Minimum Value must be <strong>greater equal to than 0</strong>
{{'labels.commons.Minimum Value must be' | translate}} <strong>{{'labels.commons.greater equal to than 0' | translate}}</strong>
</mat-error>
</mat-form-field>
@@ -24,7 +24,7 @@
<mat-label>{{'labels.inputs.Maximum' | translate}}</mat-label>
<input type="number" matInput formControlName="maxPrincipal" [min]="0">
<mat-error>
Maximum Value must be <strong>greater equal to than 0</strong> and must be greater than <strong>Minimum Principal</strong>
{{'labels.commons.Minimum Value must be' | translate}} <strong>{{'labels.commons.greater equal to than 0' | translate}}</strong> {{'labels.commons.and must be greater than' | translate}} <strong>{{'labels.commons.Minimum Principal' | translate}}</strong>
</mat-error>
</mat-form-field>
@@ -63,7 +63,7 @@
<mat-label>{{'labels.inputs.Minimum' | translate}}</mat-label>
<input type="number" matInput formControlName="minNumberOfRepayments" [min]="1">
<mat-error>
Minimum Value must be <strong>greater equal to than 0</strong>
{{'labels.commons.Minimum Value must be' | translate}} <strong>{{'labels.commons.greater equal to than 0' | translate}}</strong>
</mat-error>
</mat-form-field>
@@ -79,7 +79,7 @@
<mat-label>{{'labels.inputs.Maximum' | translate}}</mat-label>
<input type="number" matInput formControlName="maxNumberOfRepayments" [min]="0">
<mat-error>
{{'labels.inputs.Maximum' | translate}} Value must be <strong>greater equal to than 0</strong> and must be greater than <strong>Minimum Principal</strong>
{{'labels.commons.Maximum Value must be' | translate}} <strong>{{'labels.commons.greater equal to than 0' | translate}}</strong> {{'labels.commons.and must be greater than' | translate}} <strong>{{'labels.commons.Minimum Principal' | translate}}</strong>
</mat-error>
</mat-form-field>
@@ -103,7 +103,7 @@
<mat-label>{{'labels.inputs.Minimum' | translate}}</mat-label>
<input type="number" matInput formControlName="minInterestRatePerPeriod" [min]="0" [attr.disabled]="isZeroInterest()">
<mat-error>
Minimum Value must be <strong>greater than 0</strong>
{{'labels.commons.Minimum Value must be' | translate}} <strong>{{'labels.commons.greater equal to than 0' | translate}}</strong>
</mat-error>
</mat-form-field>
@@ -119,7 +119,7 @@
<mat-label>{{'labels.inputs.Maximum' | translate}}</mat-label>
<input type="number" matInput formControlName="maxInterestRatePerPeriod" [min]="0" [attr.disabled]="isZeroInterest()">
<mat-error>
{{'labels.inputs.Maximum' | translate}} Value must be <strong>greater equal to than 0</strong> and must be greater than <strong>Minimum Principal</strong>
{{'labels.commons.Maximum Value must be' | translate}} <strong>{{'labels.commons.greater equal to than 0' | translate}}</strong> {{'labels.commons.and must be greater than' | translate}} <strong>{{'labels.commons.Minimum Principal' | translate}}</strong>
</mat-error>
</mat-form-field>
@@ -416,7 +416,7 @@
</mat-error>
</mat-form-field>
<h4 fxFlex="33%" class="mat-h4" *ngIf="allowFixedLength()">{{'labels.inputs.Fixed Length' | translate}} <i class="fas fa-question"
<h4 fxFlex="33%" class="mat-h4" *ngIf="allowFixedLength()">{{'labels.inputs.Fixed Length' | translate}} <i class="fas fa-question"
matTooltip="Due to regulatory requirements in some countries, the loans cannot exceed X days, the Fineract SOR needs to be extended to support defining that a loan has a maximum length and the maximum length of that loan defines the length of the last installment which will be a shorter period than the first installments."></i></h4>
<mat-form-field fxFlex="30%" *ngIf="allowFixedLength()">
@@ -424,7 +424,7 @@
<input type="number" matInput formControlName="fixedLength">
</mat-form-field>
<span fxFlex="30%" *ngIf="allowFixedLength()" class="label-field">{{ loanProductTermsForm.value.repaymentFrequencyType | find:repaymentFrequencyTypeData:'id':'value' | translateCatalog }}</span>
<mat-form-field fxFlex="48%">
<mat-label>{{'labels.inputs.Minimum days between disbursal and first repayment date' | translate}}</mat-label>
<input type="number" matInput formControlName="minimumDaysBetweenDisbursalAndFirstRepayment">
@@ -57,7 +57,7 @@
<ng-template #templateButtonCreateLoanProduct let-popover="popover">
<h2>{{'labels.heading.Create Loan Product' | translate}}t</h2>
<p class="mw300">This option allows you to create new loan product.</p>
<p class="mw300">{{'labels.text.This option allows you to create new loan product.' | translate}}</p>
<div fxLayout="row" fxLayoutAlign="end" fxLayoutGap="2%" fxLayout.lt-md="column">
<button mat-raised-button color="warn" (click)="popover.close();configurationWizardService.closeConfigWizard()">{{'labels.buttons.Close' | translate}}</button>
<button mat-raised-button color="primary" (click)="popover.close();previousStep()">{{'labels.buttons.Back' | translate}}</button>
@@ -75,7 +75,7 @@
</ng-template>
<ng-template #templateLoanProductsTable let-popover="popover">
<h4 class="mw300">List of loan products in the organization. For more details click: <a href="https://mifosforge.jira.com/wiki/spaces/docs/pages/102039585/Loan+Products" target="_blank">Loan Products</a></h4>
<h4 class="mw300">{{'labels.heading.List of loan products in the organization' | translate}}: <a href="https://mifosforge.jira.com/wiki/spaces/docs/pages/102039585/Loan+Products" target="_blank">Loan Products</a></h4>
<div fxLayout="row" fxLayoutAlign="end" fxLayoutGap="2%" fxLayout.lt-md="column">
<button mat-raised-button color="warn" (click)="popover.close();configurationWizardService.closeConfigWizard()">{{'labels.buttons.Close' | translate}}</button>
<button mat-raised-button color="primary" (click)="popover.close();showPopover(templateFilter,filter, 'bottom', true)">{{'labels.buttons.Back' | translate}}</button>
@@ -9,44 +9,44 @@
<div fxLayout="row wrap" fxLayoutGap="2%" fxLayout.lt-md="column">
<mat-form-field fxFlex="100%">
<mat-label>Name</mat-label>
<mat-label>{{"labels.inputs.Name" | translate}}</mat-label>
<input matInput required formControlName="name">
<mat-error *ngIf="bucketForm.controls.name.hasError('required')">
Name is <strong>required</strong>
{{"labels.inputs.Name" | translate}} {{"labels.commons.is" | translate}} <strong>{{"labels.commons.required" | translate}}</strong>
</mat-error>
</mat-form-field>
<h3 fxFlex="40%" class="mat-h3">Delinquency Ranges</h3>
<h3 fxFlex="40%" class="mat-h3">{{'labels.heading.Delinquency Ranges' | translate }}</h3>
<div fxFlex="40%" fxLayout="row" fxLayoutAlign="start center">
<button type="button" mat-raised-button color="primary" (click)="addDelinquencyRange()">
<fa-icon icon="plus" class="m-r-10"></fa-icon>
Add
{{"labels.buttons.Add" | translate}}
</button>
</div>
<table mat-table [dataSource]="rangesDataSource" [hidden]="rangesDataSource.length === 0">
<ng-container matColumnDef="classification">
<th mat-header-cell *matHeaderCellDef> Classification </th>
<th mat-header-cell *matHeaderCellDef> {{"labels.inputs.Classification" | translate}} </th>
<td mat-cell *matCellDef="let row">
{{ row.rangeId | find: delinquencyRangesData:'id':'classification'}} </td>
</ng-container>
<ng-container matColumnDef="minimumAgeDays">
<th mat-header-cell *matHeaderCellDef> Days From </th>
<th mat-header-cell *matHeaderCellDef> {{"labels.inputs.Days From" | translate}} </th>
<td mat-cell *matCellDef="let row">
{{ row.rangeId | find: delinquencyRangesData:'id':'minimumAgeDays'}} </td>
</ng-container>
<ng-container matColumnDef="maximumAgeDays">
<th mat-header-cell *matHeaderCellDef> Days Till </th>
<th mat-header-cell *matHeaderCellDef> {{"labels.inputs.Days Till" | translate}} </th>
<td mat-cell *matCellDef="let row">
{{ row.rangeId | find: delinquencyRangesData:'id':'maximumAgeDays'}} </td>
</ng-container>
<ng-container matColumnDef="actions">
<th mat-header-cell *matHeaderCellDef> Actions </th>
<th mat-header-cell *matHeaderCellDef> {{ 'labels.inputs.Actions' | translate }} </th>
<td mat-cell *matCellDef="let row; let rowIndex = index">
<button type="button" mat-icon-button color="warn"
(click)="deleteDelinquencyRange(rowIndex)" matTooltip="Delete"
@@ -66,8 +66,8 @@
</mat-card-content>
<mat-card-actions fxLayout="row" fxLayout.xs="column" fxLayoutAlign="center" fxLayoutGap="5px">
<button type="button" mat-raised-button [routerLink]="['../']">Cancel</button>
<button mat-raised-button color="primary" [disabled]="!bucketForm.valid" *mifosxHasPermission="'CREATE_DELINQUENCY_BUCKET'">Submit</button>
<button type="button" mat-raised-button [routerLink]="['../']">{{'labels.buttons.Cancel' | translate }}</button>
<button mat-raised-button color="primary" [disabled]="!bucketForm.valid" *mifosxHasPermission="'CREATE_DELINQUENCY_BUCKET'">{{'labels.buttons.Submit' | translate }}</button>
</mat-card-actions>
</form>
@@ -2,6 +2,7 @@ import { Component, OnInit } from '@angular/core';
import { UntypedFormBuilder, UntypedFormGroup, Validators } from '@angular/forms';
import { MatDialog } from '@angular/material/dialog';
import { ActivatedRoute, Router } from '@angular/router';
import { TranslateService } from '@ngx-translate/core';
import { ProductsService } from 'app/products/products.service';
import { DeleteDialogComponent } from 'app/shared/delete-dialog/delete-dialog.component';
import { FormDialogComponent } from 'app/shared/form-dialog/form-dialog.component';
@@ -31,7 +32,8 @@ export class CreateBucketComponent implements OnInit {
private productsService: ProductsService,
private router: Router,
private route: ActivatedRoute,
public dialog: MatDialog) {
public dialog: MatDialog,
private translateService:TranslateService) {
this.route.data.subscribe((data: { delinquencyRanges: any }) => {
this.delinquencyRangesData = data.delinquencyRanges;
this.delinquencyRangesData = this.delinquencyRangesData.sort(
@@ -92,7 +94,7 @@ export class CreateBucketComponent implements OnInit {
*/
deleteDelinquencyRange(index: number) {
const dialogRef = this.dialog.open(DeleteDialogComponent, {
data: { deleteContext: `this` }
data: { deleteContext: this.translateService.instant('labels.text.this')}
});
dialogRef.afterClosed().subscribe((response: any) => {
if (response.delete) {
@@ -1,7 +1,7 @@
<div class="container m-b-20" fxLayout="row" fxLayoutAlign="end" fxLayoutGap="20px">
<button mat-raised-button color="primary" [routerLink]="['create']" *mifosxHasPermission="'CREATE_DELINQUENCY_BUCKET'">
<fa-icon icon="plus" class="m-r-10"></fa-icon>
Create Delinquency Bucket
{{'labels.buttons.Create Delinquency Bucket' | translate }}
</button>
</div>
@@ -19,7 +19,7 @@
<table mat-table [dataSource]="dataSource" matSort>
<ng-container matColumnDef="name">
<th mat-header-cell *matHeaderCellDef mat-sort-header> Name </th>
<th mat-header-cell *matHeaderCellDef mat-sort-header> {{"labels.inputs.Name" | translate}} </th>
<td mat-cell *matCellDef="let delinquencyBucket"> {{ delinquencyBucket.name }} </td>
</ng-container>
@@ -9,47 +9,47 @@
<div fxLayout="row wrap" fxLayoutGap="2%" fxLayout.lt-md="column">
<mat-form-field fxFlex="100%">
<mat-label>Name</mat-label>
<mat-label>{{"labels.inputs.Name" | translate}}</mat-label>
<input matInput required formControlName="name">
<mat-error *ngIf="bucketForm.controls.name.hasError('required')">
Name is <strong>required</strong>
{{"labels.inputs.Name" | translate}} {{"labels.commons.is" | translate}} <strong>{{"labels.commons.required" |translate}}</strong>
</mat-error>
</mat-form-field>
<h3 fxFlex="40%" class="mat-h3">Delinquency Ranges</h3>
<h3 fxFlex="40%" class="mat-h3">{{'labels.heading.Delinquency Ranges' | translate }}</h3>
<div fxFlex="40%" fxLayout="row" fxLayoutAlign="start center">
<button type="button" mat-raised-button color="primary" (click)="addDelinquencyRange()">
<fa-icon icon="plus" class="m-r-10"></fa-icon>
Add
{{"labels.buttons.Add" | translate}}
</button>
</div>
<table mat-table [dataSource]="rangesDataSource" [hidden]="rangesDataSource.length === 0">
<ng-container matColumnDef="classification">
<th mat-header-cell *matHeaderCellDef> Classification </th>
<th mat-header-cell *matHeaderCellDef> {{"labels.inputs.Classification" | translate}} </th>
<td mat-cell *matCellDef="let row"> {{ row.classification }}</td>
<td mat-cell *matCellDef="let row">
{{ row.rangeId | find: delinquencyRangesData:'id':'classification'}} </td>
</ng-container>
<ng-container matColumnDef="minimumAgeDays">
<th mat-header-cell *matHeaderCellDef> Days From </th>
<th mat-header-cell *matHeaderCellDef> {{"labels.inputs.Days From" | translate}}</th>
<td mat-cell *matCellDef="let row"> {{ row.minimumAgeDays }}</td>
<td mat-cell *matCellDef="let row">
{{ row.rangeId | find: delinquencyRangesData:'id':'minimumAgeDays'}} </td>
</ng-container>
<ng-container matColumnDef="maximumAgeDays">
<th mat-header-cell *matHeaderCellDef> Days Till </th>
<th mat-header-cell *matHeaderCellDef> {{"labels.inputs.Days Till" | translate}} </th>
<td mat-cell *matCellDef="let row"> {{ row.maximumAgeDays }}</td>
<td mat-cell *matCellDef="let row">
{{ row.rangeId | find: delinquencyRangesData:'id':'maximumAgeDays'}} </td>
</ng-container>
<ng-container matColumnDef="actions">
<th mat-header-cell *matHeaderCellDef> Actions </th>
<th mat-header-cell *matHeaderCellDef> {{ 'labels.inputs.Actions' | translate }} </th>
<td mat-cell *matCellDef="let row; let rowIndex = index">
<button type="button" mat-icon-button color="warn"
(click)="deleteDelinquencyRange(rowIndex)" matTooltip="Delete"
@@ -69,8 +69,8 @@
</mat-card-content>
<mat-card-actions fxLayout="row" fxLayout.xs="column" fxLayoutAlign="center" fxLayoutGap="5px">
<button type="button" mat-raised-button [routerLink]="['../']">Cancel</button>
<button mat-raised-button color="primary" [disabled]="!dataWasChanged" *mifosxHasPermission="'UPDATE_DELINQUENCY_BUCKET'">Submit</button>
<button type="button" mat-raised-button [routerLink]="['../']">{{'labels.buttons.Cancel' | translate }}</button>
<button mat-raised-button color="primary" [disabled]="!dataWasChanged" *mifosxHasPermission="'UPDATE_DELINQUENCY_BUCKET'">{{'labels.buttons.Submit' | translate }}</button>
</mat-card-actions>
</form>
@@ -2,6 +2,7 @@ import { Component, OnInit } from '@angular/core';
import { UntypedFormBuilder, UntypedFormGroup, Validators } from '@angular/forms';
import { MatDialog } from '@angular/material/dialog';
import { ActivatedRoute, Router } from '@angular/router';
import { TranslateService } from '@ngx-translate/core';
import { ProductsService } from 'app/products/products.service';
import { DeleteDialogComponent } from 'app/shared/delete-dialog/delete-dialog.component';
import { FormDialogComponent } from 'app/shared/form-dialog/form-dialog.component';
@@ -37,7 +38,8 @@ export class EditBucketComponent implements OnInit {
private productsService: ProductsService,
private router: Router,
private route: ActivatedRoute,
public dialog: MatDialog) {
public dialog: MatDialog,
private translateService:TranslateService) {
this.route.data.subscribe((data: { delinquencyBucket: any, delinquencyRanges: any }) => {
this.delinquencyRangesData = data.delinquencyRanges;
this.rangesDataSource = [];
@@ -109,7 +111,7 @@ export class EditBucketComponent implements OnInit {
*/
deleteDelinquencyRange(index: number) {
const dialogRef = this.dialog.open(DeleteDialogComponent, {
data: { deleteContext: `this` }
data: { deleteContext: this.translateService.instant('labels.text.this') }
});
dialogRef.afterClosed().subscribe((response: any) => {
if (response.delete) {
@@ -1,11 +1,11 @@
<div class="container m-b-20" fxLayout="row" fxLayout.lt-md="column" fxLayoutAlign="end" fxLayoutGap="2%">
<button mat-raised-button color="primary" [routerLink]="['edit']" *mifosxHasPermission="'UPDATE_DELINQUENCY_BUCKET'">
<fa-icon icon="edit" class="m-r-10"></fa-icon>
Edit
{{'labels.buttons.Edit' | translate }}
</button>
<button mat-raised-button color="warn" (click)="deleteDelinquencyBucket()" *mifosxHasPermission="'DELETE_DELINQUENCY_BUCKET'">
<fa-icon icon="trash" class="m-r-10"></fa-icon>
Delete
{{'labels.buttons.Delete' | translate }}
</button>
</div>
@@ -18,7 +18,7 @@
<div fxLayout="row wrap" class="content">
<div fxFlex="50%" class="mat-body-strong">
Name
{{"labels.inputs.Name" | translate}}
</div>
<div fxFlex="50%">
@@ -26,15 +26,15 @@
</div>
<div fxFlex="50%" class="mat-body-strong">
Classification Name
{{"labels.inputs.Classification" | translate}} {{"labels.inputs.Name" | translate}}
</div>
<div fxFlex="25%" class="mat-body-strong">
Days From
{{"labels.inputs.Days From" | translate}}
</div>
<div fxFlex="25%" class="mat-body-strong">
Days Till
{{"labels.inputs.Days Till" | translate}}
</div>
</div>
@@ -9,23 +9,23 @@
<div fxLayout="column">
<mat-form-field>
<mat-label>Classification</mat-label>
<mat-label>{{"labels.inputs.Classification" | translate}}</mat-label>
<input matInput required formControlName="classification">
<mat-error *ngIf="delinquencyRangeForm.controls.classification.hasError('required')">
Classification is <strong>required</strong>
{{"labels.inputs.Classification" | translate}} {{"labels.commons.is" | translate}} <strong>{{"labels.commons.required" | translate}}</strong>
</mat-error>
</mat-form-field>
<mat-form-field>
<mat-label>Days From</mat-label>
<mat-label>{{"labels.inputs.Days From" | translate}}</mat-label>
<input matInput type="number" required formControlName="minimumAgeDays">
<mat-error *ngIf="delinquencyRangeForm.controls.minimumAgeDays.hasError('required')">
Days From is <strong>required</strong>
{{"labels.inputs.Days From" | translate}} {{"labels.commons.is" | translate}} <strong>{{"labels.commons.required" | translate}}</strong>
</mat-error>
</mat-form-field>
<mat-form-field>
<mat-label>Days Till</mat-label>
<mat-label>{{"labels.inputs.Days Till" | translate}}</mat-label>
<input matInput type="number" formControlName="maximumAgeDays">
</mat-form-field>
@@ -34,8 +34,8 @@
</mat-card-content>
<mat-card-actions fxLayout="row" fxLayout.xs="column" fxLayoutAlign="center" fxLayoutGap="5px">
<button type="button" mat-raised-button [routerLink]="['../']">Cancel</button>
<button mat-raised-button color="primary" [disabled]="!delinquencyRangeForm.valid" *mifosxHasPermission="'CREATE_DELINQUENCY_RANGE'">Submit</button>
<button type="button" mat-raised-button [routerLink]="['../']">{{'labels.buttons.Cancel' | translate }}</button>
<button mat-raised-button color="primary" [disabled]="!delinquencyRangeForm.valid" *mifosxHasPermission="'CREATE_DELINQUENCY_RANGE'">{{'labels.buttons.Submit' | translate }}</button>
</mat-card-actions>
</form>
@@ -1,7 +1,7 @@
<div class="container m-b-20" fxLayout="row" fxLayoutAlign="end" fxLayoutGap="20px">
<button mat-raised-button color="primary" [routerLink]="['create']" *mifosxHasPermission="'CREATE_DELINQUENCY_RANGE'">
<fa-icon icon="plus" class="m-r-10"></fa-icon>
Create Delinquency Range
{{'labels.text.Create Delinquency Range' | translate }}
</button>
</div>
@@ -19,17 +19,17 @@
<table mat-table [dataSource]="dataSource" matSort>
<ng-container matColumnDef="classification">
<th mat-header-cell *matHeaderCellDef mat-sort-header="classification"> Classification </th>
<th mat-header-cell *matHeaderCellDef mat-sort-header="classification"> {{"labels.inputs.Classification" | translate}} </th>
<td mat-cell *matCellDef="let delinquencyRange"> {{ delinquencyRange.classification }} </td>
</ng-container>
<ng-container matColumnDef="minimumAgeDays">
<th mat-header-cell *matHeaderCellDef mat-sort-header="minimumAgeDays"> Days From </th>
<th mat-header-cell *matHeaderCellDef mat-sort-header="minimumAgeDays">{{"labels.inputs.Days From" | translate}} </th>
<td mat-cell *matCellDef="let delinquencyRange"> {{ delinquencyRange.minimumAgeDays }} </td>
</ng-container>
<ng-container matColumnDef="maximumAgeDays">
<th mat-header-cell *matHeaderCellDef mat-sort-header="maximumAgeDays"> Days Till </th>
<th mat-header-cell *matHeaderCellDef mat-sort-header="maximumAgeDays"> {{"labels.inputs.Days Till" | translate}} </th>
<td mat-cell *matCellDef="let delinquencyRange"> {{ delinquencyRange.maximumAgeDays }} </td>
</ng-container>
@@ -9,23 +9,23 @@
<div fxLayout="column">
<mat-form-field>
<mat-label>Classification</mat-label>
<mat-label>{{"labels.inputs.Classification" | translate}}</mat-label>
<input matInput required formControlName="classification">
<mat-error *ngIf="delinquencyRangeForm.controls.classification.hasError('required')">
Classification is <strong>required</strong>
{{"labels.inputs.Classification" | translate}} {{"labels.commons.is" | translate}} <strong>{{"labels.commons.required" | translate}}</strong>
</mat-error>
</mat-form-field>
<mat-form-field>
<mat-label>Days From</mat-label>
<mat-label>{{"labels.inputs.Days From" | translate}}</mat-label>
<input matInput type="number" required formControlName="minimumAgeDays">
<mat-error *ngIf="delinquencyRangeForm.controls.minimumAgeDays.hasError('required')">
Days From is <strong>required</strong>
{{"labels.inputs.Days From" | translate}} {{"labels.commons.is" | translate}} <strong>{{"labels.commons.required" | translate}}</strong>
</mat-error>
</mat-form-field>
<mat-form-field>
<mat-label>Days Till</mat-label>
<mat-label>{{"labels.inputs.Days Till" | translate}}</mat-label>
<input matInput type="number" formControlName="maximumAgeDays">
</mat-form-field>
@@ -34,8 +34,8 @@
</mat-card-content>
<mat-card-actions fxLayout="row" fxLayout.xs="column" fxLayoutAlign="center" fxLayoutGap="5px">
<button type="button" mat-raised-button [routerLink]="['../']">Cancel</button>
<button mat-raised-button color="primary" [disabled]="!delinquencyRangeForm.valid" *mifosxHasPermission="'UPDATE_DELINQUENCY_RANGE'">Submit</button>
<button type="button" mat-raised-button [routerLink]="['../']">{{'labels.buttons.Cancel' | translate }}</button>
<button mat-raised-button color="primary" [disabled]="!delinquencyRangeForm.valid" *mifosxHasPermission="'UPDATE_DELINQUENCY_RANGE'">{{'labels.buttons.Submit' | translate }}</button>
</mat-card-actions>
</form>
@@ -1,11 +1,11 @@
<div class="container m-b-20" fxLayout="row" fxLayout.lt-md="column" fxLayoutAlign="end" fxLayoutGap="2%">
<button mat-raised-button color="primary" [routerLink]="['edit']" *mifosxHasPermission="'UPDATE_DELINQUENCY_RANGE'">
<fa-icon icon="edit" class="m-r-10"></fa-icon>
Edit
{{'labels.buttons.Edit' | translate }}
</button>
<button mat-raised-button color="warn" (click)="deleteDelinquencyRange()" *mifosxHasPermission="'DELETE_DELINQUENCY_RANGE'">
<fa-icon icon="trash" class="m-r-10"></fa-icon>
Delete
{{'labels.buttons.Delete' | translate }}
</button>
</div>
@@ -18,7 +18,7 @@
<div fxLayout="row wrap" class="content">
<div fxFlex="50%" class="mat-body-strong">
Classification
{{"labels.inputs.Classification" | translate}}
</div>
<div fxFlex="50%">
@@ -26,7 +26,7 @@
</div>
<div fxFlex="50%" class="mat-body-strong">
Days From
{{"labels.inputs.Days From" | translate}}
</div>
<div fxFlex="50%">
@@ -34,7 +34,7 @@
</div>
<div fxFlex="50%" class="mat-body-strong">
Days Till
{{"labels.inputs.Days Till" | translate}}
</div>
<div fxFlex="50%">
@@ -12,8 +12,8 @@
<mat-icon matListIcon>
<fa-icon icon="building" size="sm"></fa-icon>
</mat-icon>
<h4 matLine>Manage Delinquency Ranges</h4>
<p matLine>Define delinquency day ranges</p>
<h4 matLine>{{'labels.heading.Manage Delinquency Ranges' | translate}}</h4>
<p matLine>{{'labels.text.Define delinquency day ranges' | translate}}</p>
</mat-list-item>
</mat-nav-list>
@@ -28,8 +28,8 @@
<mat-icon matListIcon>
<fa-icon icon="building" size="sm"></fa-icon>
</mat-icon>
<h4 matLine>Manage Delinquency Buckets</h4>
<p matLine>Define delinquency bucket as set of ranges</p>
<h4 matLine>{{'labels.heading.Manage Delinquency Buckets' | translate}}</h4>
<p matLine>{{'labels.text.Define delinquency bucket as set of ranges' | translate}}</p>
</mat-list-item>
</mat-nav-list>
@@ -26,7 +26,7 @@
</mat-error>
<mat-error *ngIf="taxComponentForm.controls.percentage.hasError('pattern') ||
taxComponentForm.controls.percentage.hasError('max')">
{{'labels.inputs.Percentage' | translate}} <strong>should</strong> be larger than 0 and at most 100
{{'labels.inputs.Percentage' | translate}} <strong>{{'labels.commons.should' | translate}}</strong> {{'labels.commons.be larger than 0 and at most 100' | translate}}
</mat-error>
</mat-form-field>
@@ -84,4 +84,4 @@
</mat-card>
</div>
</div>
@@ -1,20 +1,21 @@
/** Angular Imports */
import { Component, OnInit } from '@angular/core';
import { UntypedFormGroup, UntypedFormBuilder, Validators, FormControl, FormArray } from '@angular/forms';
import { Router, ActivatedRoute } from '@angular/router';
import { UntypedFormBuilder, UntypedFormGroup, Validators } from '@angular/forms';
import { MatDialog } from '@angular/material/dialog';
import { ActivatedRoute, Router } from '@angular/router';
/** Custom Services */
import { ProductsService } from '../../products.service';
import { SettingsService } from 'app/settings/settings.service';
import { ProductsService } from '../../products.service';
/** Dialog Components */
import { TranslateService } from '@ngx-translate/core';
import { Dates } from 'app/core/utils/dates';
import { DeleteDialogComponent } from 'app/shared/delete-dialog/delete-dialog.component';
import { FormDialogComponent } from 'app/shared/form-dialog/form-dialog.component';
import { DatepickerBase } from 'app/shared/form-dialog/formfield/model/datepicker-base';
import { FormfieldBase } from 'app/shared/form-dialog/formfield/model/formfield-base';
import { SelectBase } from 'app/shared/form-dialog/formfield/model/select-base';
import { DatepickerBase } from 'app/shared/form-dialog/formfield/model/datepicker-base';
import { FormDialogComponent } from 'app/shared/form-dialog/form-dialog.component';
import { DeleteDialogComponent } from 'app/shared/delete-dialog/delete-dialog.component';
import { Dates } from 'app/core/utils/dates';
/**
* Edit Tax Group component.
@@ -51,6 +52,7 @@ export class EditTaxGroupComponent implements OnInit {
* @param {Dates} dateUtils Date Utils to format date.
* @param {MatDialog} dialog Dialog reference.
* @param {SettingsService} settingsService Settings Service.
* @param {TranslateService} translateService translate Service.
*/
constructor(private formBuilder: UntypedFormBuilder,
private productsService: ProductsService,
@@ -58,7 +60,8 @@ export class EditTaxGroupComponent implements OnInit {
private router: Router,
private dateUtils: Dates,
public dialog: MatDialog,
private settingsService: SettingsService) {
private settingsService: SettingsService,
private translateService:TranslateService) {
this.route.data.subscribe((data: { taxGroup: any }) => {
this.taxGroupData = data.taxGroup;
this.taxComponentOptions = this.taxGroupData.taxComponents;
@@ -182,7 +185,7 @@ export class EditTaxGroupComponent implements OnInit {
*/
delete(index: number) {
const dialogRef = this.dialog.open(DeleteDialogComponent, {
data: { deleteContext: `this` }
data: { deleteContext: this.translateService.instant('labels.text.this') }
});
dialogRef.afterClosed().subscribe((response: any) => {
if (response.delete) {
@@ -9,26 +9,26 @@
<div fxLayout="column">
<mat-form-field>
<mat-label>Product</mat-label>
<mat-label>{{ 'labels.inputs.Product' | translate }}</mat-label>
<mat-select required formControlName="productId">
<mat-option *ngFor="let productOption of productOptionData" [value]="productOption.id">
{{ productOption.name }}
</mat-option>
</mat-select>
<mat-error *ngIf="productMixForm.controls.productId.hasError('required')">
Product is <strong>required</strong>
{{ 'labels.inputs.Product' | translate }} {{'labels.commons.is' | translate}} <strong>{{'labels.commons.required' | translate}}</strong>
</mat-error>
</mat-form-field>
<mat-form-field *ngIf="productData">
<mat-label>Restricted products</mat-label>
<mat-label>{{ 'labels.inputs.Restricted products' | translate }}</mat-label>
<mat-select required formControlName="restrictedProducts" multiple>
<mat-option *ngFor="let product of productData" [value]="product.id">
{{ product.name }}
</mat-option>
</mat-select>
<mat-error *ngIf="productMixForm.controls.restrictedProducts.hasError('required')" >
At least one restricted product <strong>must be selected</strong>
{{'labels.commons.At least one restricted product' | translate }} <strong>{{'labels.commons.must be selected' | translate }}</strong>
</mat-error>
</mat-form-field>
</div>
@@ -36,8 +36,8 @@
</mat-card-content>
<mat-card-actions fxLayout="row" fxLayout.xs="column" fxLayoutAlign="center" fxLayoutGap="5px">
<button type="button" mat-raised-button [routerLink]="['../']">Cancel</button>
<button mat-raised-button color="primary" [disabled]="!productMixForm.valid" *mifosxHasPermission="'CREATE_PRODUCTMIX'">Submit</button>
<button type="button" mat-raised-button [routerLink]="['../']">{{'labels.buttons.Cancel' | translate }}</button>
<button mat-raised-button color="primary" [disabled]="!productMixForm.valid" *mifosxHasPermission="'CREATE_PRODUCTMIX'">{{'labels.buttons.Submit' | translate }}</button>
</mat-card-actions>
</form>
@@ -9,19 +9,19 @@
<div fxLayout="column">
<mat-form-field>
<mat-label>Product</mat-label>
<mat-label>{{ 'labels.inputs.Product' | translate }}</mat-label>
<input matInput formControlName="productId">
</mat-form-field>
<mat-form-field *ngIf="productData">
<mat-label>Restricted products</mat-label>
<mat-label>{{ 'labels.inputs.Restricted products' | translate }}</mat-label>
<mat-select required formControlName="restrictedProducts" multiple>
<mat-option *ngFor="let product of productData" [value]="product.id">
{{ product.name }}
</mat-option>
</mat-select>
<mat-error *ngIf="productMixForm.controls.restrictedProducts.hasError('required')">
At least one restricted product <strong>must be selected</strong>
{{'labels.commons.At least one restricted product' | translate }} <strong>{{'labels.commons.must be selected' |translate }}</strong>
</mat-error>
</mat-form-field>
</div>
@@ -29,8 +29,8 @@
</mat-card-content>
<mat-card-actions fxLayout="row" fxLayout.xs="column" fxLayoutAlign="center" fxLayoutGap="5px">
<button type="button" mat-raised-button [routerLink]="['../']">Cancel</button>
<button mat-raised-button color="primary" [disabled]="!productMixForm.valid" *mifosxHasPermission="'UPDATE_PRODUCTMIX'">Submit</button>
<button type="button" mat-raised-button [routerLink]="['../']">{{'labels.buttons.Cancel' | translate }}</button>
<button mat-raised-button color="primary" [disabled]="!productMixForm.valid" *mifosxHasPermission="'UPDATE_PRODUCTMIX'">{{'labels.buttons.Submit' | translate }}</button>
</mat-card-actions>
</form>
@@ -1,6 +1,6 @@
<div fxLayout="row" fxLayoutAlign="end" class="container m-b-20">
<button mat-raised-button color="primary" [routerLink]="['create']" *mifosxHasPermission="'CREATE_PRODUCTMIX'">
<fa-icon icon="plus" class="m-r-10"></fa-icon>Add
<fa-icon icon="plus" class="m-r-10"></fa-icon>{{'labels.buttons.Add' | translate}}
</button>
</div>
@@ -18,7 +18,7 @@
<table mat-table [dataSource]="dataSource" matSort>
<ng-container matColumnDef="productName">
<th mat-header-cell *matHeaderCellDef mat-sort-header> Product Name </th>
<th mat-header-cell *matHeaderCellDef mat-sort-header> {{ 'labels.inputs.Product Name' | translate }} </th>
<td mat-cell *matCellDef="let productMix"> {{ productMix.productName }} </td>
</ng-container>
@@ -1,11 +1,11 @@
<div class="container m-b-20" fxLayout="row" fxLayout.lt-md="column" fxLayoutAlign="end" fxLayoutGap="20px">
<button mat-raised-button color="primary" [routerLink]="['edit']" *mifosxHasPermission="'UPDATE_PRODUCTMIX'">
<fa-icon icon="edit" class="m-r-10"></fa-icon>
Edit
{{ 'labels.buttons.Edit' | translate}}
</button>
<button mat-raised-button color="warn" (click)="delete()" *mifosxHasPermission="'DELETE_PRODUCTMIX'">
<fa-icon icon="trash" class="m-r-10"></fa-icon>
Delete
{{ 'labels.buttons.Delete' | translate}}
</button>
</div>
@@ -16,7 +16,7 @@
<table mat-table [dataSource]="allowedProductsDatasource" matSort>
<ng-container matColumnDef="name">
<th mat-header-cell *matHeaderCellDef mat-sort-header [ngClass]="'customWidthClass'"> Allowed Products </th>
<th mat-header-cell *matHeaderCellDef mat-sort-header [ngClass]="'customWidthClass'">{{ 'labels.inputs.Allowed Products' | translate}}</th>
<td mat-cell *matCellDef="let product" [ngClass]="'customWidthClass'"> {{ product.name }} </td>
</ng-container>
@@ -33,7 +33,7 @@
<table mat-table [dataSource]="restrictedProductsDatasource" matSort>
<ng-container matColumnDef="name">
<th mat-header-cell *matHeaderCellDef mat-sort-header> Restricted Products </th>
<th mat-header-cell *matHeaderCellDef mat-sort-header> {{ 'labels.inputs.Restricted products' | translate }}</th>
<td mat-cell *matCellDef="let product"> {{ product.name }} </td>
</ng-container>
@@ -1,13 +1,14 @@
/** Angular Imports */
import { Component, OnInit, ViewChild } from '@angular/core';
import { ActivatedRoute, Router } from '@angular/router';
import { MatDialog } from '@angular/material/dialog';
import { MatPaginator } from '@angular/material/paginator';
import { MatSort } from '@angular/material/sort';
import { MatDialog } from '@angular/material/dialog';
import { MatPaginator } from '@angular/material/paginator';
import { MatSort } from '@angular/material/sort';
import { MatTableDataSource } from '@angular/material/table';
import { ActivatedRoute, Router } from '@angular/router';
import { DeleteDialogComponent } from 'app/shared/delete-dialog/delete-dialog.component';
/** Custom Services */
import { TranslateService } from '@ngx-translate/core';
import { ProductsService } from 'app/products/products.service';
/**
@@ -43,11 +44,13 @@ export class ViewProductMixComponent implements OnInit {
/**
* Retrieves the product mix data from `resolve`.
* @param {ActivatedRoute} route Activated Route.
* @param {TranslateService} translateService Translate Service.
*/
constructor(private route: ActivatedRoute,
private dialog: MatDialog,
private productsService: ProductsService,
private router: Router ) {
private router: Router,
private translateService:TranslateService ) {
this.route.data.subscribe((data: { productMix: any }) => {
this.productMixData = data.productMix;
});
@@ -84,7 +87,7 @@ export class ViewProductMixComponent implements OnInit {
*/
delete() {
const deleteProductMixDialogRef = this.dialog.open(DeleteDialogComponent, {
data: { deleteContext: `the productmix component with id ${this.productMixData.productId}` }
data: { deleteContext: this.translateService.instant('labels.dialogContext.the productmix component with id') + ' ' + this.productMixData.productId}
});
deleteProductMixDialogRef.afterClosed().subscribe((response: any) => {
if (response.delete) {
+29 -29
View File
@@ -127,61 +127,61 @@
</div>
<ng-template #templateCharges let-popover="popover">
<h2>Charges</h2>
<p class="mw400">Mifos supports two types of charges—fees and penalties.Fees are charged for services—for example, membership fees, loan disbursement fees, withdrawal fees. Penalties are charged to discourage clients from deviating from the terms of a product</p>
<h2>{{'labels.heading.Charges' | translate}}</h2>
<p class="mw400">{{'labels.text.Two types of charges—fees and penalties' | translate}}</p>
<div fxLayout="row" fxLayoutAlign="end" fxLayoutGap="2%" fxLayout.lt-md="column">
<button mat-raised-button color="warn" (click)="popover.close();configurationWizardService.closeConfigWizard()">Close</button>
<button mat-raised-button color="primary" (click)="popover.close();previousStepCharges()">Back</button>
<button mat-raised-button color="primary" (click)="popover.close();nextStepCharges()">Next</button>
<button mat-raised-button color="primary" (click)="popover.close();previousStepCharges()">{{'labels.buttons.Back' | translate}}</button>
<button mat-raised-button color="primary" (click)="popover.close();nextStepCharges()">{{'labels.buttons.Next' | translate }}</button>
</div>
</ng-template>
<ng-template #templateLoanProducts let-popover="popover">
<h2>Loan Products</h2>
<p class="mw400">Loan products define the rules, default settings, and constraints for a financial institution's lending offerings. A loan product provides a template for multiple loan accounts for the financial institution's clients.</p>
<h2>{{'labels.heading.Loan Products' | translate}}</h2>
<p class="mw400">{{'labels.text.Loan products define the rules, default settings' | translate}}</p>
<div fxLayout="row" fxLayoutAlign="end" fxLayoutGap="2%" fxLayout.lt-md="column">
<button mat-raised-button color="warn" (click)="popover.close();configurationWizardService.closeConfigWizard()">Close</button>
<button mat-raised-button color="primary" (click)="popover.close();previousStepLoanProducts()">Back</button>
<button mat-raised-button color="primary" (click)="popover.close();nextStepLoanProducts()">Next</button>
<button mat-raised-button color="warn" (click)="popover.close();configurationWizardService.closeConfigWizard()">{{'labels.buttons.Close' | translate }}</button>
<button mat-raised-button color="primary" (click)="popover.close();previousStepLoanProducts()">{{'labels.buttons.Back' | translate}}</button>
<button mat-raised-button color="primary" (click)="popover.close();nextStepLoanProducts()">{{'labels.buttons.Next' | translate }}</button>
</div>
</ng-template>
<ng-template #templateSavingsProducts let-popover="popover">
<h2>Savings Products</h2>
<p class="mw400">Savings products define the rules, default settings, and constraints for a financial institution's current/checking and passbook savings accounts. A saving product provides a template for multiple accounts that are or will be held by the financial institution's clients, groups and centers.</p>
<h2>{{'labels.heading.Savings Products' | translate}}</h2>
<p class="mw400">{{'labels.text.Savings products define the rules, default settings' | translate}}</p>
<div fxLayout="row" fxLayoutAlign="end" fxLayoutGap="2%" fxLayout.lt-md="column">
<button mat-raised-button color="warn" (click)="popover.close();configurationWizardService.closeConfigWizard()">Close</button>
<button mat-raised-button color="primary" (click)="popover.close();previousStepSavingsProducts()">Back</button>
<button mat-raised-button color="primary" (click)="popover.close();nextStepSavingsProducts()">Next</button>
<button mat-raised-button color="warn" (click)="popover.close();configurationWizardService.closeConfigWizard()">{{'labels.buttons.Close' | translate }}</button>
<button mat-raised-button color="primary" (click)="popover.close();previousStepSavingsProducts()">{{'labels.buttons.Back' | translate}}</button>
<button mat-raised-button color="primary" (click)="popover.close();nextStepSavingsProducts()">{{'labels.buttons.Next' | translate }}</button>
</div>
</ng-template>
<ng-template #templateShareProducts let-popover="popover">
<h2>Share Products</h2>
<p class="mw400">Share products define the rules, default settings, and constraints for a financial institution's Shares and dividends. A share product provides a template for multiple accounts that are or will be held by the financial institution's clients.</p>
<h2>{{'labels.heading.Share Products' | translate}}</h2>
<p class="mw400">{{'labels.text.Share products define the rules, default settings' | translate}}</p>
<div fxLayout="row" fxLayoutAlign="end" fxLayoutGap="2%" fxLayout.lt-md="column">
<button mat-raised-button color="warn" (click)="popover.close();configurationWizardService.closeConfigWizard()">Close</button>
<button mat-raised-button color="primary" (click)="popover.close();previousStepShareProducts()">Back</button>
<button mat-raised-button color="primary" (click)="popover.close();nextStepShareProducts()">Next</button>
<button mat-raised-button color="warn" (click)="popover.close();configurationWizardService.closeConfigWizard()">{{'labels.buttons.Close' | translate }}</button>
<button mat-raised-button color="primary" (click)="popover.close();previousStepShareProducts()">{{'labels.buttons.Back' | translate}}</button>
<button mat-raised-button color="primary" (click)="popover.close();nextStepShareProducts()">{{'labels.buttons.Next' | translate }}</button>
</div>
</ng-template>
<ng-template #templateFixedDepositProducts let-popover="popover">
<h2>Fixed Deposit Products</h2>
<p class="mw400">Fixed Deposit Products defines the rules, default settings, and constraints for a financial institution's <br> fixed deposit offerings (also referred to as term deposits). A fixed deposit product provides a template for multiple fixed deposit accounts for the financial institution's clients.</p>
<h2>{{'labels.heading.Fixed Deposit Products' | translate}}</h2>
<p class="mw400">{{'labels.text.Fixed Deposit Products defines the rules, default settings' | translate}}</p>
<div fxLayout="row" fxLayoutAlign="end" fxLayoutGap="2%" fxLayout.lt-md="column">
<button mat-raised-button color="warn" (click)="popover.close();configurationWizardService.closeConfigWizard()">Close</button>
<button mat-raised-button color="primary" (click)="popover.close();previousStepFixedDepositProducts()">Back</button>
<button mat-raised-button color="primary" (click)="popover.close();nextStepFixedDepositProducts()">Next</button>
<button mat-raised-button color="warn" (click)="popover.close();configurationWizardService.closeConfigWizard()">{{'labels.buttons.Close' | translate }}</button>
<button mat-raised-button color="primary" (click)="popover.close();previousStepFixedDepositProducts()">{{'labels.buttons.Back' | translate}}</button>
<button mat-raised-button color="primary" (click)="popover.close();nextStepFixedDepositProducts()">{{'labels.buttons.Next' | translate }}</button>
</div>
</ng-template>
<ng-template #templateRecurringDepositProducts let-popover="popover">
<h2>Recurring Deposit Products</h2>
<p class="mw400">Recurring Deposit products define the rules, default settings, and constraints for a financial institution's recurring deposit offerings (a type of term deposit with recurring deposits). A recurring deposit product provides a template for multiple recurring deposit accounts for the financial institution's clients.</p>
<h2>{{'labels.heading.Recurring Deposit Products' | translate}}</h2>
<p class="mw400">{{'labels.text.Recurring Deposit products define the rules, default settings' | translate}}</p>
<div fxLayout="row" fxLayoutAlign="end" fxLayoutGap="2%" fxLayout.lt-md="column">
<button mat-raised-button color="warn" (click)="popover.close();configurationWizardService.closeConfigWizard()">Close</button>
<button mat-raised-button color="primary" (click)="popover.close();previousStepRecurringDepositProducts()">Back</button>
<button mat-raised-button color="primary" (click)="popover.close();nextStepRecurringDepositProducts()">Next</button>
<button mat-raised-button color="warn" (click)="popover.close();configurationWizardService.closeConfigWizard()">{{'labels.buttons.Close' | translate }}</button>
<button mat-raised-button color="primary" (click)="popover.close();previousStepRecurringDepositProducts()">{{'labels.buttons.Back' | translate}}</button>
<button mat-raised-button color="primary" (click)="popover.close();nextStepRecurringDepositProducts()">{{'labels.buttons.Next' | translate }}</button>
</div>
</ng-template>
@@ -1,7 +1,8 @@
import { Component, OnInit, Input } from '@angular/core';
import { MatDialog } from '@angular/material/dialog';
import { Component, Input, OnInit } from '@angular/core';
import { UntypedFormControl } from '@angular/forms';
import { MatDialog } from '@angular/material/dialog';
import { TranslateService } from '@ngx-translate/core';
import { DeleteDialogComponent } from 'app/shared/delete-dialog/delete-dialog.component';
@Component({
@@ -19,7 +20,8 @@ export class RecurringDepositProductChargesStepComponent implements OnInit {
chargesDataSource: {}[];
displayedColumns: string[] = ['name', 'chargeCalculationType', 'amount', 'chargeTimeType', 'action'];
constructor(public dialog: MatDialog) {
constructor(public dialog: MatDialog,
private translateService: TranslateService) {
}
ngOnInit() {
@@ -39,7 +41,7 @@ export class RecurringDepositProductChargesStepComponent implements OnInit {
deleteCharge(charge: any) {
const deleteChargeDialogRef = this.dialog.open(DeleteDialogComponent, {
data: { deleteContext: `charge ${charge.name}` }
data: { deleteContext: this.translateService.instant('labels.inputs.Charge') + ' ' + charge.name }
});
deleteChargeDialogRef.afterClosed().subscribe((response: any) => {
if (response.delete) {
@@ -43,8 +43,8 @@
</div>
<ng-template #templateButtonCreateRecurringProduct let-popover="popover">
<h2>Create recurring deposit product</h2>
<p class="mw300">This option allows you to create new recurring product.</p>
<h2>{{'labels.heading.Create recurring deposit product' | translate}}</h2>
<p class="mw300">{{'labels.text.This option allows you to create new recurring product.' | translate}}</p>
<div fxLayout="row" fxLayoutAlign="end" fxLayoutGap="2%" fxLayout.lt-md="column">
<button mat-raised-button color="warn" (click)="popover.close();configurationWizardService.closeConfigWizard()">{{'labels.buttons.Close' | translate}}</button>
<button mat-raised-button color="primary" (click)="popover.close();previousStep()">{{'labels.buttons.Back' | translate}}</button>
@@ -53,7 +53,7 @@
</ng-template>
<ng-template #templateFilter let-popover="popover">
<h4>Search bar to filter recurring deposit products.</h4>
<h4>{{'labels.heading.Search bar to filter recurring deposit products.' | translate}}</h4>
<div fxLayout="row" fxLayoutAlign="end" fxLayoutGap="2%" fxLayout.lt-md="column">
<button mat-raised-button color="warn" (click)="popover.close();configurationWizardService.closeConfigWizard()">{{'labels.buttons.Close' | translate}}</button>
<button mat-raised-button color="primary" (click)="popover.close();showPopover(templateButtonCreateRecurringProduct,buttonCreateRecurringProduct , 'bottom', true)">{{'labels.buttons.Back' | translate}}</button>
@@ -62,7 +62,7 @@
</ng-template>
<ng-template #templateRecurringProductsTable let-popover="popover">
<h4 class="mw300">List of recurring deposit products in the organization. For more details click: <a href="https://mifosforge.jira.com/wiki/spaces/docs/pages/102629552/Recurring+Deposit" target="_blank">{{'labels.heading.Recurring Deposit Products' | translate}}</a></h4>
<h4 class="mw300">{{'labels.heading.List of recurring deposit products in the organization' | translate}}: <a href="https://mifosforge.jira.com/wiki/spaces/docs/pages/102629552/Recurring+Deposit" target="_blank">{{'labels.heading.Recurring Deposit Products' | translate}}</a></h4>
<div fxLayout="row" fxLayoutAlign="end" fxLayoutGap="2%" fxLayout.lt-md="column">
<button mat-raised-button color="warn" (click)="popover.close();configurationWizardService.closeConfigWizard()">{{'labels.buttons.Close' | translate}}</button>
<button mat-raised-button color="primary" (click)="popover.close();showPopover(templateFilter,filter, 'bottom', true)">{{'labels.buttons.Back' | translate}}</button>
@@ -1,7 +1,8 @@
import { Component, OnInit, Input } from '@angular/core';
import { MatDialog } from '@angular/material/dialog';
import { Component, Input, OnInit } from '@angular/core';
import { UntypedFormControl } from '@angular/forms';
import { MatDialog } from '@angular/material/dialog';
import { TranslateService } from '@ngx-translate/core';
import { DeleteDialogComponent } from 'app/shared/delete-dialog/delete-dialog.component';
@Component({
@@ -21,7 +22,7 @@ export class SavingProductChargesStepComponent implements OnInit {
pristine = true;
constructor(public dialog: MatDialog) {
constructor(public dialog: MatDialog, private translateService:TranslateService) {
}
ngOnInit() {
@@ -41,7 +42,7 @@ export class SavingProductChargesStepComponent implements OnInit {
deleteCharge(charge: any) {
const deleteChargeDialogRef = this.dialog.open(DeleteDialogComponent, {
data: { deleteContext: `charge ${charge.name}` }
data: { deleteContext: this.translateService.instant('labels.inputs.Charge') + ' ' + charge.name }
});
deleteChargeDialogRef.afterClosed().subscribe((response: any) => {
if (response.delete) {
@@ -43,7 +43,7 @@
<ng-template #templateButtonSavingProduct let-popover="popover">
<h2>{{'labels.text.Create Savings Product' | translate}}</h2>
<p class="mw300">This option allows you to create new savings product.</p>
<p class="mw300">{{'labels.text.This option allows you to create new savings product.' | translate}}</p>
<div fxLayout="row" fxLayoutAlign="end" fxLayoutGap="2%" fxLayout.lt-md="column">
<button mat-raised-button color="warn" (click)="popover.close();configurationWizardService.closeConfigWizard()">{{'labels.buttons.Close' | translate}}</button>
<button mat-raised-button color="primary" (click)="popover.close();previousStep()">{{'labels.buttons.Back' | translate}}</button>
@@ -61,7 +61,7 @@
</ng-template>
<ng-template #templateSavingProductTable let-popover="popover">
<h4 class="mw300">List of saving products in the organization. For more details click: <a href="https://mifosforge.jira.com/wiki/spaces/docs/pages/102629497/Savings+Products" target="_blank">{{'labels.heading.Savings Products' | translate}}</a></h4>
<h4 class="mw300">{{'labels.heading.List of saving products in the organization' | translate}}: <a href="https://mifosforge.jira.com/wiki/spaces/docs/pages/102629497/Savings+Products" target="_blank">{{'labels.heading.Savings Products' | translate}}</a></h4>
<div fxLayout="row" fxLayoutAlign="end" fxLayoutGap="2%" fxLayout.lt-md="column">
<button mat-raised-button color="warn" (click)="popover.close();configurationWizardService.closeConfigWizard()">{{'labels.buttons.Close' | translate}}</button>
<button mat-raised-button color="primary" (click)="popover.close();showPopover(templateFilter,filter, 'bottom', true)">{{'labels.buttons.Back' | translate}}</button>
@@ -9,30 +9,30 @@
<div fxLayout="column">
<mat-form-field (click)="startDatePicker.open()">
<mat-label>Dividend Period Start Date</mat-label>
<mat-label>{{'labels.inputs.Dividend Period Start Date' | translate}}</mat-label>
<input matInput [min]="minDate" [max]="maxDate" [matDatepicker]="startDatePicker" required formControlName="dividendPeriodStartDate">
<mat-datepicker-toggle matSuffix [for]="startDatePicker"></mat-datepicker-toggle>
<mat-datepicker #startDatePicker></mat-datepicker>
<mat-error *ngIf="createDividendForm.controls.dividendPeriodStartDate.hasError('required')">
Starting date <strong>is required</strong>
{{'labels.inputs.Starting Date' | translate}} {{'labels.commons.is' | translate}} <strong>{{'labels.commons.required' | translate}}</strong>
</mat-error>
</mat-form-field>
<mat-form-field (click)="endDatePicker.open()">
<mat-label>Dividend Period End Date</mat-label>
<mat-label>{{'labels.inputs.Dividend Period End Date' | translate}}</mat-label>
<input matInput [min]="minDate" [max]="maxDate" [matDatepicker]="endDatePicker" required formControlName="dividendPeriodEndDate">
<mat-datepicker-toggle matSuffix [for]="endDatePicker"></mat-datepicker-toggle>
<mat-datepicker #endDatePicker></mat-datepicker>
<mat-error *ngIf="createDividendForm.controls.dividendPeriodEndDate.hasError('required')">
End date <strong>is required</strong>
{{'labels.inputs.End Date' | translate}} {{'labels.commons.is' | translate}} <strong>{{'labels.commons.required' | translate}}</strong>
</mat-error>
</mat-form-field>
<mat-form-field>
<mat-label>Dividend Amount</mat-label>
<mat-label>{{'labels.inputs.Dividend Amount' | translate}}</mat-label>
<input matInput required formControlName="dividendAmount">
<mat-error *ngIf="createDividendForm.controls.dividendAmount.hasError('required')">
Amount is <strong>required</strong>
{{ 'labels.inputs.Amount' | translate }} {{'labels.commons.is' | translate}} <strong>{{'labels.commons.required' | translate}}</strong>
</mat-error>
</mat-form-field>
@@ -41,8 +41,8 @@
</mat-card-content>
<mat-card-actions fxLayout="row" fxLayout.xs="column" fxLayoutAlign="center" fxLayoutGap="5px">
<button type="button" mat-raised-button [routerLink]="['../']">Cancel</button>
<button mat-raised-button color="primary" [disabled]="!createDividendForm.valid">Submit</button>
<button type="button" mat-raised-button [routerLink]="['../']">{{'labels.buttons.Cancel' | translate }}</button>
<button mat-raised-button color="primary" [disabled]="!createDividendForm.valid">{{'labels.buttons.Submit' | translate }}</button>
</mat-card-actions>
</form>
@@ -19,27 +19,27 @@
<table mat-table [dataSource]="dataSource" matSort>
<ng-container matColumnDef="name">
<th mat-header-cell *matHeaderCellDef mat-sort-header> Name </th>
<th mat-header-cell *matHeaderCellDef mat-sort-header> {{'labels.inputs.Name' | translate}} </th>
<td mat-cell *matCellDef="let dividend">{{ dividend.productData.name }}</td>
</ng-container>
<ng-container matColumnDef="dividendPeriodStartDate">
<th mat-header-cell *matHeaderCellDef mat-sort-header> Dividend Period Start Date </th>
<th mat-header-cell *matHeaderCellDef mat-sort-header> {{'labels.inputs.Dividend Period Start Date' | translate}} </th>
<td mat-cell *matCellDef="let dividend">{{ dividend.dividendPeriodStartDate | dateFormat }}</td>
</ng-container>
<ng-container matColumnDef="dividendPeriodEndDate">
<th mat-header-cell *matHeaderCellDef mat-sort-header> Dividend Period End Date </th>
<th mat-header-cell *matHeaderCellDef mat-sort-header> {{'labels.inputs.Dividend Period End Date' | translate}} </th>
<td mat-cell *matCellDef="let dividend">{{ dividend.dividendPeriodEndDate | dateFormat }}</td>
</ng-container>
<ng-container matColumnDef="amount">
<th mat-header-cell *matHeaderCellDef mat-sort-header> Amount </th>
<th mat-header-cell *matHeaderCellDef mat-sort-header> {{ 'labels.inputs.Amount' | translate }} </th>
<td mat-cell *matCellDef="let dividend"> {{ dividend.amount }}</td>
</ng-container>
<ng-container matColumnDef="status">
<th mat-header-cell *matHeaderCellDef mat-sort-header> Status </th>
<th mat-header-cell *matHeaderCellDef mat-sort-header> {{ 'labels.inputs.Status' | translate }} </th>
<td mat-cell *matCellDef="let dividend">{{ dividend.status.value }}</td>
</ng-container>
@@ -1,8 +1,8 @@
import { Component, OnInit, Input } from '@angular/core';
import { MatDialog } from '@angular/material/dialog';
import { Component, Input, OnInit } from '@angular/core';
import { UntypedFormControl } from '@angular/forms';
import { TooltipPosition } from '@angular/material/tooltip';
import { MatDialog } from '@angular/material/dialog';
import { TranslateService } from '@ngx-translate/core';
import { DeleteDialogComponent } from 'app/shared/delete-dialog/delete-dialog.component';
@Component({
@@ -22,7 +22,8 @@ export class ShareProductChargesStepComponent implements OnInit {
pristine = true;
constructor(public dialog: MatDialog) {
constructor(public dialog: MatDialog,
private translateService: TranslateService) {
}
ngOnInit() {
@@ -42,7 +43,7 @@ export class ShareProductChargesStepComponent implements OnInit {
deleteCharge(charge: any) {
const deleteChargeDialogRef = this.dialog.open(DeleteDialogComponent, {
data: { deleteContext: `charge ${charge.name}` }
data: { deleteContext: this.translateService.instant('labels.inputs.Charge') + ' ' + charge.name }
});
deleteChargeDialogRef.afterClosed().subscribe((response: any) => {
if (response.delete) {
@@ -48,7 +48,7 @@
<ng-template #templateButtonCreateShareProduct let-popover="popover">
<h2>{{ 'labels.buttons.Create Share Product' | translate }}</h2>
<p class="mw300">This option allows you to create new share product.</p>
<p class="mw300">{{'labels.text.This option allows you to create new share product.' | translate}}</p>
<div fxLayout="row" fxLayoutAlign="end" fxLayoutGap="2%" fxLayout.lt-md="column">
<button mat-raised-button color="warn" (click)="popover.close();configurationWizardService.closeConfigWizard()">{{ 'labels.buttons.Close' | translate }}</button>
<button mat-raised-button color="primary" (click)="popover.close();previousStep()">{{ 'labels.buttons.Back' | translate }}</button>
@@ -57,7 +57,7 @@
</ng-template>
<ng-template #templateFilter let-popover="popover">
<h4>Search bar to filter share products.</h4>
<h4>{{'labels.heading.Search bar to filter share products.' | translate}}</h4>
<div fxLayout="row" fxLayoutAlign="end" fxLayoutGap="2%" fxLayout.lt-md="column">
<button mat-raised-button color="warn" (click)="popover.close();configurationWizardService.closeConfigWizard()">{{ 'labels.buttons.Close' | translate }}</button>
<button mat-raised-button color="primary" (click)="popover.close();showPopover(templateButtonCreateShareProduct,buttonCreateShareProduct , 'bottom', true)">{{ 'labels.buttons.Back' | translate }}</button>
@@ -66,7 +66,7 @@
</ng-template>
<ng-template #templateShareProductsTable let-popover="popover">
<h4 class="mw300">List of share products in the organization. For more details click: <a href="https://mifosforge.jira.com/wiki/spaces/docs/pages/129531946/Share+products" target="_blank">{{ 'labels.buttons.Share Products' | translate }}</a></h4>
<h4 class="mw300">{{'labels.heading.List of share products in the organization' | translate}}: <a href="https://mifosforge.jira.com/wiki/spaces/docs/pages/129531946/Share+products" target="_blank">{{ 'labels.buttons.Share Products' | translate }}</a></h4>
<div fxLayout="row" fxLayoutAlign="end" fxLayoutGap="2%" fxLayout.lt-md="column">
<button mat-raised-button color="warn" (click)="popover.close();configurationWizardService.closeConfigWizard()">{{ 'labels.buttons.Close' | translate }}</button>
<button mat-raised-button color="primary" (click)="popover.close();showPopover(templateFilter,filter, 'bottom', true)">{{ 'labels.buttons.Back' | translate }}</button>
@@ -1,7 +1,7 @@
<div class="container m-b-20" fxLayout="row" fxLayoutAlign="end" fxLayoutGap="20px" *ngIf="!isdividendPosted">
<button mat-raised-button color="primary" *mifosxHasPermission='"POST_DIVIDENDS"' (click)="postDividends()">
<fa-icon icon="plus" class="m-r-10"></fa-icon>
Post Dividend
{{'labels.buttons.buttons' | translate}}
</button>
</div>
@@ -19,22 +19,22 @@
<table mat-table [dataSource]="dataSource" matSort>
<ng-container matColumnDef="clientName">
<th mat-header-cell *matHeaderCellDef mat-sort-header> Client Name </th>
<th mat-header-cell *matHeaderCellDef mat-sort-header> {{ 'labels.inputs.Client Name' | translate }} </th>
<td mat-cell *matCellDef="let dividend"> {{ dividend.accountData.clientName }} </td>
</ng-container>
<ng-container matColumnDef="shareAccount">
<th mat-header-cell *matHeaderCellDef mat-sort-header> Share Account </th>
<th mat-header-cell *matHeaderCellDef mat-sort-header> {{'labels.inputs.Share Account' | translate}} </th>
<td mat-cell *matCellDef="let dividend"> {{ dividend.accountData.accountNo }} </td>
</ng-container>
<ng-container matColumnDef="dividendAmount">
<th mat-header-cell *matHeaderCellDef mat-sort-header> Dividend Amount </th>
<th mat-header-cell *matHeaderCellDef mat-sort-header> {{'labels.inputs.Dividend Amount' | translate}} </th>
<td mat-cell *matCellDef="let dividend"> {{ dividend.amount }} </td>
</ng-container>
<ng-container matColumnDef="status">
<th mat-header-cell *matHeaderCellDef mat-sort-header> Status </th>
<th mat-header-cell *matHeaderCellDef mat-sort-header> {{ 'labels.inputs.Status' | translate }} </th>
<td mat-cell *matCellDef="let dividend"> {{ dividend.status.value }} </td>
</ng-container>