mirror of
https://github.com/Alfresco/alfresco-ng2-components.git
synced 2025-06-30 18:15:11 +00:00
remove wrong use of get in translation service
This commit is contained in:
parent
ccdcba8778
commit
5ce06d80cb
@ -396,8 +396,8 @@ export class FilesComponent implements OnInit, OnChanges, OnDestroy {
|
||||
}
|
||||
|
||||
onContentActionSuccess(message) {
|
||||
const translatedMessage: any = this.translateService.get(message);
|
||||
this.openSnackMessage(translatedMessage.value);
|
||||
const translatedMessage: any = this.translateService.instant(message);
|
||||
this.openSnackMessage(translatedMessage);
|
||||
this.documentList.reload();
|
||||
}
|
||||
|
||||
@ -424,8 +424,8 @@ export class FilesComponent implements OnInit, OnChanges, OnDestroy {
|
||||
width: '630px'
|
||||
});
|
||||
} else {
|
||||
const translatedErrorMessage: any = this.translateService.get('OPERATION.ERROR.PERMISSION');
|
||||
this.openSnackMessage(translatedErrorMessage.value);
|
||||
const translatedErrorMessage: any = this.translateService.instant('OPERATION.ERROR.PERMISSION');
|
||||
this.openSnackMessage(translatedErrorMessage);
|
||||
}
|
||||
}
|
||||
|
||||
@ -442,8 +442,8 @@ export class FilesComponent implements OnInit, OnChanges, OnDestroy {
|
||||
width: '630px'
|
||||
});
|
||||
} else {
|
||||
const translatedErrorMessage: any = this.translateService.get('OPERATION.ERROR.PERMISSION');
|
||||
this.openSnackMessage(translatedErrorMessage.value);
|
||||
const translatedErrorMessage: any = this.translateService.instant('OPERATION.ERROR.PERMISSION');
|
||||
this.openSnackMessage(translatedErrorMessage);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -93,9 +93,7 @@ export class TagActionsComponent implements OnChanges, OnInit, OnDestroy {
|
||||
|
||||
addTag() {
|
||||
if (this.searchTag(this.newTagName)) {
|
||||
this.translateService.get('TAG.MESSAGES.EXIST').subscribe((error) => {
|
||||
this.errorMsg = error;
|
||||
});
|
||||
this.errorMsg = this.translateService.instant('TAG.MESSAGES.EXIST');
|
||||
this.error.emit(this.errorMsg);
|
||||
} else {
|
||||
this.tagService.addTag(this.nodeId, this.newTagName).subscribe(() => {
|
||||
|
Loading…
x
Reference in New Issue
Block a user