Charges with translations
This commit is contained in:
committed by
Jose Alberto Hernandez
parent
8ac82cc6a6
commit
b380f7f630
@@ -19,7 +19,7 @@
|
||||
</ng-container>
|
||||
|
||||
<ng-container matColumnDef="documentKey">
|
||||
<th mat-header-cell *matHeaderCellDef> {{"labels.inputs.Key" | translate}} </th>
|
||||
<th mat-header-cell *matHeaderCellDef> {{"labels.inputs.Document Key" | translate}} </th>
|
||||
<td mat-cell *matCellDef="let identity"> {{identity.documentKey}} </td>
|
||||
</ng-container>
|
||||
|
||||
|
||||
@@ -16,6 +16,7 @@ import { FormDialogComponent } from 'app/shared/form-dialog/form-dialog.componen
|
||||
|
||||
/** Custom Services */
|
||||
import { ClientsService } from '../../clients.service';
|
||||
import { TranslateService } from '@ngx-translate/core';
|
||||
|
||||
/**
|
||||
* Identities Tab Component
|
||||
@@ -45,8 +46,9 @@ export class IdentitiesTabComponent {
|
||||
* @param {ClientsService} clientService Clients Service
|
||||
*/
|
||||
constructor(private route: ActivatedRoute,
|
||||
public dialog: MatDialog,
|
||||
private clientService: ClientsService) {
|
||||
private dialog: MatDialog,
|
||||
private clientService: ClientsService,
|
||||
private translateService: TranslateService) {
|
||||
this.clientId = this.route.parent.snapshot.paramMap.get('clientId');
|
||||
this.route.data.subscribe((data: { clientIdentities: any, clientIdentifierTemplate: any }) => {
|
||||
this.clientIdentities = data.clientIdentities;
|
||||
@@ -73,7 +75,7 @@ export class IdentitiesTabComponent {
|
||||
const formfields: FormfieldBase[] = [
|
||||
new SelectBase({
|
||||
controlName: 'documentTypeId',
|
||||
label: 'Document Type',
|
||||
label: this.translateService.instant('labels.inputs.Document Type'),
|
||||
value: '',
|
||||
options: { label: 'name', value: 'id', data: this.clientIdentifierTemplate.allowedDocumentTypes },
|
||||
required: true,
|
||||
@@ -81,15 +83,18 @@ export class IdentitiesTabComponent {
|
||||
}),
|
||||
new SelectBase({
|
||||
controlName: 'status',
|
||||
label: 'Status',
|
||||
label: this.translateService.instant('labels.inputs.Status'),
|
||||
value: '2',
|
||||
options: { label: 'value', value: 'value', data: [{ value: 'Active' }, { value: 'Inactive' }] },
|
||||
options: { label: 'label', value: 'value', data: [
|
||||
{ label: this.translateService.instant('labels.catalogs.Active'), value: 'Active' },
|
||||
{ label: this.translateService.instant('labels.catalogs.Inactive'), value: 'Inactive' }
|
||||
] },
|
||||
required: true,
|
||||
order: 2
|
||||
}),
|
||||
new InputBase({
|
||||
controlName: 'documentKey',
|
||||
label: 'Unique Id',
|
||||
label: this.translateService.instant('labels.inputs.Document Key'),
|
||||
value: '',
|
||||
type: 'text',
|
||||
required: true,
|
||||
@@ -97,14 +102,14 @@ export class IdentitiesTabComponent {
|
||||
}),
|
||||
new InputBase({
|
||||
controlName: 'description',
|
||||
label: 'Description',
|
||||
label: this.translateService.instant('labels.inputs.Description'),
|
||||
value: '',
|
||||
type: 'text',
|
||||
order: 4
|
||||
})
|
||||
];
|
||||
const data = {
|
||||
title: 'Add Client Identifier',
|
||||
title: this.translateService.instant('labels.heading.Add Client Identifier'),
|
||||
formfields: formfields
|
||||
};
|
||||
const addIdentifierDialogRef = this.dialog.open(FormDialogComponent, { data });
|
||||
|
||||
Reference in New Issue
Block a user