simplified annotation flow
This commit is contained in:
parent
bb719a224a
commit
13172a6a55
@ -234,11 +234,6 @@ export class AnnotationWrapper {
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (redactionLogEntryWrapper.status === 'DECLINED') {
|
|
||||||
annotationWrapper.superType = 'declined-suggestion';
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
|
|
||||||
if (redactionLogEntryWrapper.manualRedactionType === 'FORCE_REDACT') {
|
if (redactionLogEntryWrapper.manualRedactionType === 'FORCE_REDACT') {
|
||||||
annotationWrapper.force = true;
|
annotationWrapper.force = true;
|
||||||
|
|
||||||
@ -261,6 +256,10 @@ export class AnnotationWrapper {
|
|||||||
annotationWrapper.superType = 'add-dictionary';
|
annotationWrapper.superType = 'add-dictionary';
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
if (redactionLogEntryWrapper.status === 'DECLINED') {
|
||||||
|
annotationWrapper.superType = 'declined-suggestion';
|
||||||
|
return;
|
||||||
|
}
|
||||||
if (!redactionLogEntryWrapper.manual) {
|
if (!redactionLogEntryWrapper.manual) {
|
||||||
annotationWrapper.superType = 'skipped';
|
annotationWrapper.superType = 'skipped';
|
||||||
}
|
}
|
||||||
@ -276,6 +275,10 @@ export class AnnotationWrapper {
|
|||||||
annotationWrapper.superType = 'manual-redaction';
|
annotationWrapper.superType = 'manual-redaction';
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
if (redactionLogEntryWrapper.status === 'DECLINED') {
|
||||||
|
annotationWrapper.superType = 'declined-suggestion';
|
||||||
|
return;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if (redactionLogEntryWrapper.manualRedactionType === 'LEGAL_BASIS_CHANGE') {
|
if (redactionLogEntryWrapper.manualRedactionType === 'LEGAL_BASIS_CHANGE') {
|
||||||
@ -308,6 +311,10 @@ export class AnnotationWrapper {
|
|||||||
annotationWrapper.superType = 'add-dictionary';
|
annotationWrapper.superType = 'add-dictionary';
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
if (redactionLogEntryWrapper.status === 'DECLINED') {
|
||||||
|
annotationWrapper.superType = 'declined-suggestion';
|
||||||
|
return;
|
||||||
|
}
|
||||||
} else {
|
} else {
|
||||||
if (redactionLogEntryWrapper.status === 'REQUESTED') {
|
if (redactionLogEntryWrapper.status === 'REQUESTED') {
|
||||||
annotationWrapper.superType = 'suggestion-add';
|
annotationWrapper.superType = 'suggestion-add';
|
||||||
@ -317,6 +324,10 @@ export class AnnotationWrapper {
|
|||||||
annotationWrapper.superType = 'manual-redaction';
|
annotationWrapper.superType = 'manual-redaction';
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
if (redactionLogEntryWrapper.status === 'DECLINED') {
|
||||||
|
annotationWrapper.superType = 'declined-suggestion';
|
||||||
|
return;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@ -71,6 +71,7 @@ export class FileDataModel {
|
|||||||
redactionLogEntryWrapper.isChangeLogEntry = true;
|
redactionLogEntryWrapper.isChangeLogEntry = true;
|
||||||
redactionLogEntryWrapper.changeLogType = changeLogEntry.changeType;
|
redactionLogEntryWrapper.changeLogType = changeLogEntry.changeType;
|
||||||
redactionLogEntryWrapper.id = 'changed-log-removed-' + redactionLogEntryWrapper.id;
|
redactionLogEntryWrapper.id = 'changed-log-removed-' + redactionLogEntryWrapper.id;
|
||||||
|
|
||||||
result.push(redactionLogEntryWrapper);
|
result.push(redactionLogEntryWrapper);
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
@ -90,7 +91,17 @@ export class FileDataModel {
|
|||||||
Object.assign(redactionLogEntryWrapper, redactionLogEntry);
|
Object.assign(redactionLogEntryWrapper, redactionLogEntry);
|
||||||
redactionLogEntryWrapper.isChangeLogEntry = !!existingChangeLogEntry;
|
redactionLogEntryWrapper.isChangeLogEntry = !!existingChangeLogEntry;
|
||||||
redactionLogEntryWrapper.changeLogType = 'ADDED';
|
redactionLogEntryWrapper.changeLogType = 'ADDED';
|
||||||
result.push(redactionLogEntryWrapper);
|
|
||||||
|
if (
|
||||||
|
redactionLogEntryWrapper.status === 'DECLINED' &&
|
||||||
|
redactionLogEntryWrapper.manualRedactionType === 'ADD' &&
|
||||||
|
redactionLogEntryWrapper.type === 'false_positive'
|
||||||
|
) {
|
||||||
|
// ignore these
|
||||||
|
return;
|
||||||
|
} else {
|
||||||
|
result.push(redactionLogEntryWrapper);
|
||||||
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
result = result.filter(r => reasonAnnotationIds.indexOf(r.id) < 0);
|
result = result.filter(r => reasonAnnotationIds.indexOf(r.id) < 0);
|
||||||
|
|||||||
@ -41,7 +41,7 @@
|
|||||||
[tooltipPosition]="tooltipPosition"
|
[tooltipPosition]="tooltipPosition"
|
||||||
[tooltip]="'annotation-actions.reject-suggestion' | translate"
|
[tooltip]="'annotation-actions.reject-suggestion' | translate"
|
||||||
[type]="buttonType"
|
[type]="buttonType"
|
||||||
icon="red:trash"
|
icon="red:close"
|
||||||
></iqser-circle-button>
|
></iqser-circle-button>
|
||||||
|
|
||||||
<iqser-circle-button
|
<iqser-circle-button
|
||||||
|
|||||||
@ -236,7 +236,7 @@ export class AnnotationActionsService {
|
|||||||
if (canRejectSuggestion) {
|
if (canRejectSuggestion) {
|
||||||
availableActions.push({
|
availableActions.push({
|
||||||
type: 'actionButton',
|
type: 'actionButton',
|
||||||
img: this._convertPath('/assets/icons/general/trash.svg'),
|
img: this._convertPath('/assets/icons/general/close.svg'),
|
||||||
title: this._translateService.instant('annotation-actions.reject-suggestion'),
|
title: this._translateService.instant('annotation-actions.reject-suggestion'),
|
||||||
onClick: () => {
|
onClick: () => {
|
||||||
this._ngZone.run(() => {
|
this._ngZone.run(() => {
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user