added translation of dialogContext
This commit is contained in:
committed by
Adam Saghy
parent
6e068189be
commit
927562a872
@@ -13,6 +13,7 @@ import { SettingsService } from 'app/settings/settings.service';
|
||||
/** Dialog Components */
|
||||
import { ConfirmationDialogComponent } from 'app/shared/confirmation-dialog/confirmation-dialog.component';
|
||||
import { Dates } from 'app/core/utils/dates';
|
||||
import { TranslateService } from '@ngx-translate/core';
|
||||
|
||||
@Component({
|
||||
selector: 'mifosx-checker-inbox',
|
||||
@@ -56,6 +57,7 @@ export class CheckerInboxComponent implements OnInit {
|
||||
private dialog: MatDialog,
|
||||
private dateUtils: Dates,
|
||||
private router: Router,
|
||||
private translateService: TranslateService,
|
||||
private tasksService: TasksService,
|
||||
private settingsService: SettingsService,
|
||||
private formBuilder: UntypedFormBuilder) {
|
||||
@@ -130,7 +132,7 @@ export class CheckerInboxComponent implements OnInit {
|
||||
|
||||
approveChecker() {
|
||||
const approveCheckerDialogRef = this.dialog.open(ConfirmationDialogComponent, {
|
||||
data: { heading: 'Approve Checker', dialogContext: 'Are you sure you want to approve checker' }
|
||||
data: { heading: 'Approve Checker', dialogContext: this.translateService.instant('labels.dialogContext.Are you sure you want to approve checker') }
|
||||
});
|
||||
approveCheckerDialogRef.afterClosed().subscribe((response: { confirm: any }) => {
|
||||
if (response.confirm) {
|
||||
@@ -141,7 +143,7 @@ export class CheckerInboxComponent implements OnInit {
|
||||
|
||||
rejectChecker() {
|
||||
const rejectCheckerDialogRef = this.dialog.open(ConfirmationDialogComponent, {
|
||||
data: { heading: 'Reject Checker', dialogContext: 'Are you sure you want to reject checker' }
|
||||
data: { heading: 'Reject Checker', dialogContext: this.translateService.instant('labels.dialogContext.Are you sure you want to reject checker') }
|
||||
});
|
||||
rejectCheckerDialogRef.afterClosed().subscribe((response: { confirm: any }) => {
|
||||
if (response.confirm) {
|
||||
@@ -152,7 +154,7 @@ export class CheckerInboxComponent implements OnInit {
|
||||
|
||||
deleteChecker() {
|
||||
const deleteCheckerDialogRef = this.dialog.open(ConfirmationDialogComponent, {
|
||||
data: { heading: 'Delete Checker', dialogContext: 'Are you sure you want to delete checker' }
|
||||
data: { heading: 'Delete Checker', dialogContext: this.translateService.instant('labels.dialogContext.Are you sure you want to delete checker') }
|
||||
});
|
||||
deleteCheckerDialogRef.afterClosed().subscribe((response: { confirm: any }) => {
|
||||
if (response.confirm) {
|
||||
|
||||
@@ -13,6 +13,7 @@ import { ConfirmationDialogComponent } from 'app/shared/confirmation-dialog/conf
|
||||
import { TasksService } from '../../tasks.service';
|
||||
import { SettingsService } from 'app/settings/settings.service';
|
||||
import { Dates } from 'app/core/utils/dates';
|
||||
import { TranslateService } from '@ngx-translate/core';
|
||||
|
||||
@Component({
|
||||
selector: 'mifosx-loan-approval',
|
||||
@@ -53,6 +54,7 @@ export class LoanApprovalComponent {
|
||||
private dialog: MatDialog,
|
||||
private dateUtils: Dates,
|
||||
private router: Router,
|
||||
private translateService: TranslateService,
|
||||
private settingsService: SettingsService,
|
||||
private tasksService: TasksService) {
|
||||
this.route.data.subscribe((data: { officesData: any, loansData: any }) => {
|
||||
@@ -121,7 +123,7 @@ export class LoanApprovalComponent {
|
||||
|
||||
approveLoan() {
|
||||
const approveLoanDialogRef = this.dialog.open(ConfirmationDialogComponent, {
|
||||
data: { heading: 'Approve Loan', dialogContext: 'Are you sure you want to Approve Loan' }
|
||||
data: { heading: 'Approve Loan', dialogContext: this.translateService.instant('labels.dialogContext.Are you sure you want to Approve Loan') }
|
||||
});
|
||||
approveLoanDialogRef.afterClosed().subscribe((response: { confirm: any }) => {
|
||||
if (response.confirm) {
|
||||
|
||||
+3
-1
@@ -12,6 +12,7 @@ import { ConfirmationDialogComponent } from 'app/shared/confirmation-dialog/conf
|
||||
import { TasksService } from '../../tasks.service';
|
||||
import { SettingsService } from 'app/settings/settings.service';
|
||||
import { Dates } from 'app/core/utils/dates';
|
||||
import { TranslateService } from '@ngx-translate/core';
|
||||
|
||||
@Component({
|
||||
selector: 'mifosx-loan-disbursal',
|
||||
@@ -44,6 +45,7 @@ export class LoanDisbursalComponent {
|
||||
private dialog: MatDialog,
|
||||
private dateUtils: Dates,
|
||||
private settingsService: SettingsService,
|
||||
private translateService: TranslateService,
|
||||
private tasksService: TasksService) {
|
||||
this.route.data.subscribe((data: { loansData: any }) => {
|
||||
this.loans = data.loansData.pageItems;
|
||||
@@ -79,7 +81,7 @@ export class LoanDisbursalComponent {
|
||||
|
||||
disburseLoan() {
|
||||
const disburseLoanDialogRef = this.dialog.open(ConfirmationDialogComponent, {
|
||||
data: { heading: 'Loan Disbursal', dialogContext: 'Are you sure you want to Disburse Loan' }
|
||||
data: { heading: 'Loan Disbursal', dialogContext: this.translateService.instant('labels.dialogContext.Are you sure you want to Disburse Loan') }
|
||||
});
|
||||
disburseLoanDialogRef.afterClosed().subscribe((response: { confirm: any }) => {
|
||||
if (response.confirm) {
|
||||
|
||||
+3
-1
@@ -13,6 +13,7 @@ import { ConfirmationDialogComponent } from 'app/shared/confirmation-dialog/conf
|
||||
import { TasksService } from '../../tasks.service';
|
||||
import { SettingsService } from 'app/settings/settings.service';
|
||||
import { Dates } from 'app/core/utils/dates';
|
||||
import { TranslateService } from '@ngx-translate/core';
|
||||
|
||||
@Component({
|
||||
selector: 'mifosx-reschedule-loan',
|
||||
@@ -46,6 +47,7 @@ export class RescheduleLoanComponent implements OnInit {
|
||||
private dateUtils: Dates,
|
||||
private router: Router,
|
||||
private settingsService: SettingsService,
|
||||
private translateService: TranslateService,
|
||||
private tasksService: TasksService) {
|
||||
this.route.data.subscribe((data: { recheduleLoansData: any }) => {
|
||||
this.loans = data.recheduleLoansData;
|
||||
@@ -81,7 +83,7 @@ export class RescheduleLoanComponent implements OnInit {
|
||||
|
||||
bulkLoanReschedule(action: string) {
|
||||
const rescheduleLoanDialogRef = this.dialog.open(ConfirmationDialogComponent, {
|
||||
data: { heading: 'Reschedule Loan', dialogContext: 'Are you sure you want to ' + action + ' the Reschedule Loan' }
|
||||
data: { heading: 'Reschedule Loan', dialogContext: this.translateService.instant('labels.dialogContext.Are you sure you want to') + action + this.translateService.instant('labels.dialogContext.the Reschedule Loan') }
|
||||
});
|
||||
rescheduleLoanDialogRef.afterClosed().subscribe((response: { confirm: any }) => {
|
||||
if (response.confirm) {
|
||||
|
||||
@@ -9,6 +9,7 @@ import { TasksService } from '../tasks.service';
|
||||
|
||||
/** Dialog Components */
|
||||
import { ConfirmationDialogComponent } from 'app/shared/confirmation-dialog/confirmation-dialog.component';
|
||||
import { TranslateService } from '@ngx-translate/core';
|
||||
|
||||
@Component({
|
||||
selector: 'mifosx-view-checker-inbox',
|
||||
@@ -34,21 +35,22 @@ export class ViewCheckerInboxComponent {
|
||||
constructor(private route: ActivatedRoute,
|
||||
private dialog: MatDialog,
|
||||
private router: Router,
|
||||
private translateService: TranslateService,
|
||||
private tasksService: TasksService) {
|
||||
this.route.data.subscribe((data: { checkerInboxDetail: any }) => {
|
||||
this.checkerInboxDetail = data.checkerInboxDetail;
|
||||
this.jsondata = JSON.parse(this.checkerInboxDetail.commandAsJson);
|
||||
this.displayJSONData = !(_.isEmpty(this.jsondata));
|
||||
});
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Approve Checker
|
||||
*/
|
||||
/**
|
||||
* Approve Checker
|
||||
*/
|
||||
approveChecker() {
|
||||
const approveCheckerDialogRef = this.dialog.open(ConfirmationDialogComponent, {
|
||||
data: { heading: 'Approve Checker', dialogContext: 'Are you sure you want to approve checker' }
|
||||
data: { heading: 'Approve Checker', dialogContext: this.translateService.instant('labels.dialogContext.Are you sure you want to approve checker') }
|
||||
});
|
||||
approveCheckerDialogRef.afterClosed().subscribe((response: { confirm: any }) => {
|
||||
if (response.confirm) {
|
||||
@@ -64,7 +66,7 @@ export class ViewCheckerInboxComponent {
|
||||
*/
|
||||
rejectChecker() {
|
||||
const rejectCheckerDialogRef = this.dialog.open(ConfirmationDialogComponent, {
|
||||
data: { heading: 'Reject Checker', dialogContext: 'Are you sure you want to reject checker' }
|
||||
data: { heading: 'Reject Checker', dialogContext: this.translateService.instant('labels.dialogContext.Are you sure you want to reject checker') }
|
||||
});
|
||||
rejectCheckerDialogRef.afterClosed().subscribe((response: { confirm: any }) => {
|
||||
if (response.confirm) {
|
||||
@@ -80,7 +82,7 @@ export class ViewCheckerInboxComponent {
|
||||
*/
|
||||
deleteChecker() {
|
||||
const deleteCheckerDialogRef = this.dialog.open(ConfirmationDialogComponent, {
|
||||
data: { heading: 'Delete Checker', dialogContext: 'Are you sure you want to delete checker' }
|
||||
data: { heading: 'Delete Checker', dialogContext: this.translateService.instant('labels.dialogContext.Are you sure you want to delete checker') }
|
||||
});
|
||||
deleteCheckerDialogRef.afterClosed().subscribe((response: { confirm: any }) => {
|
||||
if (response.confirm) {
|
||||
|
||||
Reference in New Issue
Block a user