RED-6005 - type changes

This commit is contained in:
Timo Bejan 2023-01-18 13:34:53 +08:00
parent 9db8117b1d
commit a37e36dff1
3 changed files with 36 additions and 16 deletions

View File

@ -473,22 +473,42 @@ export class AnnotationWrapper implements IListable, Record<string, unknown> {
break; break;
case ManualRedactionTypes.REMOVE_FROM_DICTIONARY: case ManualRedactionTypes.REMOVE_FROM_DICTIONARY:
if (redactionLogEntry.redacted) { if (redactionLogEntry.redacted) {
switch (lastManualChange.annotationStatus) { if (lastManualChange.processed) {
case LogEntryStatuses.APPROVED: switch (lastManualChange.annotationStatus) {
return SuperTypes.Skipped; case LogEntryStatuses.APPROVED:
case LogEntryStatuses.DECLINED: return SuperTypes.Skipped;
return SuperTypes.Redaction; case LogEntryStatuses.DECLINED:
case LogEntryStatuses.REQUESTED: return SuperTypes.Redaction;
return SuperTypes.SuggestionRemoveDictionary; case LogEntryStatuses.REQUESTED:
return SuperTypes.SuggestionRemoveDictionary;
}
} else {
switch (lastManualChange.annotationStatus) {
case LogEntryStatuses.APPROVED:
case LogEntryStatuses.DECLINED:
return SuperTypes.Redaction;
case LogEntryStatuses.REQUESTED:
return SuperTypes.SuggestionRemoveDictionary;
}
} }
} else { } else {
switch (lastManualChange.annotationStatus) { if (lastManualChange.processed) {
case LogEntryStatuses.APPROVED: switch (lastManualChange.annotationStatus) {
return SuperTypes.Redaction; case LogEntryStatuses.APPROVED:
case LogEntryStatuses.DECLINED: return SuperTypes.Redaction;
return isHintDictionary ? SuperTypes.Hint : SuperTypes.Skipped; case LogEntryStatuses.DECLINED:
case LogEntryStatuses.REQUESTED: return isHintDictionary ? SuperTypes.Hint : SuperTypes.Skipped;
return SuperTypes.SuggestionRemoveDictionary; case LogEntryStatuses.REQUESTED:
return SuperTypes.SuggestionRemoveDictionary;
}
} else {
switch (lastManualChange.annotationStatus) {
case LogEntryStatuses.APPROVED:
case LogEntryStatuses.DECLINED:
return isHintDictionary ? SuperTypes.Hint : SuperTypes.Skipped;
case LogEntryStatuses.REQUESTED:
return SuperTypes.SuggestionRemoveDictionary;
}
} }
} }
break; break;

View File

@ -11,7 +11,7 @@
<div *ngIf="!annotation.isEarmark" class="actions-wrapper"> <div *ngIf="!annotation.isEarmark" class="actions-wrapper">
<div <div
(click)="comments.toggleExpandComments($event)" (click)="comments.toggleExpandComments($event)"
[matTooltip]="'comments.comments' | translate: { count: annotation.comments?.length }" [matTooltip]="'comments.comments' | translate : { count: annotation.comments?.length }"
class="comments-counter" class="comments-counter"
matTooltipPosition="above" matTooltipPosition="above"
> >

@ -1 +1 @@
Subproject commit 03d63fc78e36cbb36dbaee65bd5638eb3d501eb9 Subproject commit e6fcc2b9f0f7c199c83cf57ff4e84ce7307b8026