more localization tags #123

This commit is contained in:
jonaswinkler
2020-12-28 22:54:49 +01:00
parent 619e25d71b
commit 5e4d610b5e
8 changed files with 65 additions and 17 deletions

View File

@@ -84,14 +84,14 @@ export abstract class GenericListComponent<T extends ObjectWithId> implements On
})
}
getObjectName(object: T) {
return object.toString()
getDeleteMessage(object: T) {
return $localize`Do you really want to delete this element?`
}
openDeleteDialog(object: T) {
var activeModal = this.modalService.open(ConfirmDialogComponent, {backdrop: 'static'})
activeModal.componentInstance.title = $localize`Confirm delete`
activeModal.componentInstance.messageBold = $localize`Do you really want to delete ${this.getObjectName(object)}?`
activeModal.componentInstance.messageBold = this.getDeleteMessage(object)
activeModal.componentInstance.message = $localize`Associated documents will not be deleted.`
activeModal.componentInstance.btnClass = "btn-danger"
activeModal.componentInstance.btnCaption = $localize`Delete`