RED-7980 - Not all unprocessed annotations are displayed correctly

This commit is contained in:
Valentin Mihai 2023-12-06 17:11:27 +02:00
parent d363da17fc
commit 7fcad33eb3
3 changed files with 8 additions and 1 deletions

View File

@ -60,6 +60,7 @@ export class AnnotationWrapper implements IListable {
hasBeenForcedRedaction: boolean;
hasBeenRemovedByManualOverride: boolean;
isRemoved = false;
isRemovedLocally = false;
get isRuleBased() {
return this.engines.includes(LogEntryEngines.RULE);
@ -237,6 +238,8 @@ export class AnnotationWrapper implements IListable {
annotationWrapper.IMAGE_HINT = logEntry.entryType === EntityTypes.IMAGE_HINT;
annotationWrapper.isRemoved = logEntry.state === EntryStates.REMOVED;
annotationWrapper.isRemovedLocally =
logEntry.manualChanges.slice(-1)[0]?.manualRedactionType === ManualRedactionTypes.REMOVE_LOCALLY;
annotationWrapper.numberOfComments = logEntry.numberOfComments;
annotationWrapper.imported = logEntry.imported;

View File

@ -10,7 +10,7 @@
<div>
<strong>{{ annotation.superTypeLabel | translate }}</strong>
&nbsp;
<strong *ngIf="annotation.pending" class="pending-analysis">
<strong *ngIf="pending" class="pending-analysis">
{{ 'annotation.pending' | translate }}
</strong>
</div>

View File

@ -16,4 +16,8 @@ export class AnnotationCardComponent {
@Input() isSelected = false;
constructor(readonly multiSelectService: MultiSelectService) {}
get pending() {
return this.annotation.pending && this.annotation.isModifyDictionary && !this.annotation.isRemovedLocally;
}
}