From 78d6328af80b5c6cd4881238c66d841479647548 Mon Sep 17 00:00:00 2001 From: Valentin Mihai Date: Tue, 9 Jul 2024 12:53:02 +0300 Subject: [PATCH] WIP on master RED-9401 - Show manual changes icon in workload for all entries with MANUAL engine --- .../annotation-details.component.ts | 13 ++++++++++--- 1 file changed, 10 insertions(+), 3 deletions(-) diff --git a/apps/red-ui/src/app/modules/file-preview/components/annotation-details/annotation-details.component.ts b/apps/red-ui/src/app/modules/file-preview/components/annotation-details/annotation-details.component.ts index aa5d99769..2c647bd76 100644 --- a/apps/red-ui/src/app/modules/file-preview/components/annotation-details/annotation-details.component.ts +++ b/apps/red-ui/src/app/modules/file-preview/components/annotation-details/annotation-details.component.ts @@ -51,13 +51,20 @@ export class AnnotationDetailsComponent implements OnChanges { getChangesTooltip(): string | undefined { const changes = changesProperties.filter(key => this.annotation.item[key]); - if (!changes.length || !this.annotation.item.engines?.includes(LogEntryEngines.MANUAL)) { + if (!changes.length && !this.annotation.item.engines?.includes(LogEntryEngines.MANUAL)) { return; } + const details = []; + if (this.annotation.item.engines?.includes(LogEntryEngines.MANUAL)) { + details.push(this._translateService.instant(_('annotation-changes.added-locally'))); + } + + if (changes.length) { + details.push(...changes.map(change => this._translateService.instant(annotationChangesTranslations[change]))); + } + const header = this._translateService.instant(_('annotation-changes.header')); - const details = [this._translateService.instant(_('annotation-changes.added-locally'))]; - details.push(...changes.map(change => this._translateService.instant(annotationChangesTranslations[change]))); return [header, ...details.map(change => `• ${change}`)].join('\n'); }