Merge branch 'VM/DM-422' into 'master'
DM-422 - Remove remaining reason/legal basis fields Closes DM-422 See merge request redactmanager/red-ui!59
This commit is contained in:
commit
74fffe049d
@ -302,6 +302,7 @@ export class AnnotationWrapper implements IListable {
|
|||||||
changeLogType: ChangeType,
|
changeLogType: ChangeType,
|
||||||
legalBasisList: ILegalBasis[],
|
legalBasisList: ILegalBasis[],
|
||||||
hintDictionary: boolean,
|
hintDictionary: boolean,
|
||||||
|
isDocumine: boolean,
|
||||||
) {
|
) {
|
||||||
const annotationWrapper = new AnnotationWrapper();
|
const annotationWrapper = new AnnotationWrapper();
|
||||||
|
|
||||||
@ -351,7 +352,7 @@ export class AnnotationWrapper implements IListable {
|
|||||||
c => c.manualRedactionType === ManualRedactionTypes.LEGAL_BASIS_CHANGE && c.annotationStatus === LogEntryStatuses.REQUESTED,
|
c => c.manualRedactionType === ManualRedactionTypes.LEGAL_BASIS_CHANGE && c.annotationStatus === LogEntryStatuses.REQUESTED,
|
||||||
)?.propertyChanges.legalBasis;
|
)?.propertyChanges.legalBasis;
|
||||||
|
|
||||||
this.#createContent(annotationWrapper, redactionLogEntry);
|
this.#createContent(annotationWrapper, redactionLogEntry, isDocumine);
|
||||||
this.#setSuperType(annotationWrapper, redactionLogEntry);
|
this.#setSuperType(annotationWrapper, redactionLogEntry);
|
||||||
this.#handleRecommendations(annotationWrapper, redactionLogEntry);
|
this.#handleRecommendations(annotationWrapper, redactionLogEntry);
|
||||||
annotationWrapper.typeLabel = this.#getTypeLabel(redactionLogEntry, annotationWrapper);
|
annotationWrapper.typeLabel = this.#getTypeLabel(redactionLogEntry, annotationWrapper);
|
||||||
@ -421,7 +422,7 @@ export class AnnotationWrapper implements IListable {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
static #createContent(annotationWrapper: AnnotationWrapper, entry: IRedactionLogEntry) {
|
static #createContent(annotationWrapper: AnnotationWrapper, entry: IRedactionLogEntry, isDocumine: boolean) {
|
||||||
let content = '';
|
let content = '';
|
||||||
if (entry.matchedRule) {
|
if (entry.matchedRule) {
|
||||||
content += `Rule ${entry.matchedRule} matched \n\n`;
|
content += `Rule ${entry.matchedRule} matched \n\n`;
|
||||||
@ -434,7 +435,7 @@ export class AnnotationWrapper implements IListable {
|
|||||||
content = content.substring(0, 1).toUpperCase() + content.substring(1);
|
content = content.substring(0, 1).toUpperCase() + content.substring(1);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (annotationWrapper.legalBasis) {
|
if (annotationWrapper.legalBasis && !isDocumine) {
|
||||||
content += 'Legal basis: ' + annotationWrapper.legalBasis + '\n\n';
|
content += 'Legal basis: ' + annotationWrapper.legalBasis + '\n\n';
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@ -4,7 +4,7 @@
|
|||||||
<div *ngIf="isHintDialog" class="dialog-header heading-l" [translate]="'manual-annotation.dialog.header.force-hint'"></div>
|
<div *ngIf="isHintDialog" class="dialog-header heading-l" [translate]="'manual-annotation.dialog.header.force-hint'"></div>
|
||||||
|
|
||||||
<div class="dialog-content">
|
<div class="dialog-content">
|
||||||
<div *ngIf="!isHintDialog" class="iqser-input-group required w-400">
|
<div *ngIf="!isHintDialog && !isDocumine" class="iqser-input-group required w-400">
|
||||||
<label [translate]="'manual-annotation.dialog.content.reason'"></label>
|
<label [translate]="'manual-annotation.dialog.content.reason'"></label>
|
||||||
<mat-form-field>
|
<mat-form-field>
|
||||||
<mat-select
|
<mat-select
|
||||||
@ -19,7 +19,7 @@
|
|||||||
</mat-form-field>
|
</mat-form-field>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div *ngIf="!isHintDialog" class="iqser-input-group w-400">
|
<div *ngIf="!isHintDialog && !isDocumine" class="iqser-input-group w-400">
|
||||||
<label [translate]="'manual-annotation.dialog.content.legalBasis'"></label>
|
<label [translate]="'manual-annotation.dialog.content.legalBasis'"></label>
|
||||||
<input [value]="form.get('reason').value?.legalBasis" disabled type="text" />
|
<input [value]="form.get('reason').value?.legalBasis" disabled type="text" />
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
@ -1,7 +1,7 @@
|
|||||||
import { Component, Inject, OnInit } from '@angular/core';
|
import { Component, Inject, OnInit } from '@angular/core';
|
||||||
import { UntypedFormGroup, Validators } from '@angular/forms';
|
import { UntypedFormGroup, Validators } from '@angular/forms';
|
||||||
import { MAT_DIALOG_DATA, MatDialogRef } from '@angular/material/dialog';
|
import { MAT_DIALOG_DATA, MatDialogRef } from '@angular/material/dialog';
|
||||||
import { BaseDialogComponent } from '@iqser/common-ui';
|
import { BaseDialogComponent, getConfig } from '@iqser/common-ui';
|
||||||
import { JustificationsService } from '@services/entity-services/justifications.service';
|
import { JustificationsService } from '@services/entity-services/justifications.service';
|
||||||
import { Dossier, ILegalBasisChangeRequest } from '@red/domain';
|
import { Dossier, ILegalBasisChangeRequest } from '@red/domain';
|
||||||
import { firstValueFrom } from 'rxjs';
|
import { firstValueFrom } from 'rxjs';
|
||||||
@ -19,6 +19,7 @@ export interface LegalBasisOption {
|
|||||||
styleUrls: ['./force-annotation-dialog.component.scss'],
|
styleUrls: ['./force-annotation-dialog.component.scss'],
|
||||||
})
|
})
|
||||||
export class ForceAnnotationDialogComponent extends BaseDialogComponent implements OnInit {
|
export class ForceAnnotationDialogComponent extends BaseDialogComponent implements OnInit {
|
||||||
|
readonly isDocumine = getConfig().IS_DOCUMINE;
|
||||||
legalOptions: LegalBasisOption[] = [];
|
legalOptions: LegalBasisOption[] = [];
|
||||||
|
|
||||||
constructor(
|
constructor(
|
||||||
|
|||||||
@ -1,7 +1,7 @@
|
|||||||
import { effect, Injectable, Signal, signal } from '@angular/core';
|
import { effect, Injectable, Signal, signal } from '@angular/core';
|
||||||
import { toObservable } from '@angular/core/rxjs-interop';
|
import { toObservable } from '@angular/core/rxjs-interop';
|
||||||
import { marker as _ } from '@biesbjerg/ngx-translate-extract-marker';
|
import { marker as _ } from '@biesbjerg/ngx-translate-extract-marker';
|
||||||
import { EntitiesService, Toaster } from '@iqser/common-ui';
|
import { EntitiesService, getConfig, Toaster } from '@iqser/common-ui';
|
||||||
import { AnnotationWrapper } from '@models/file/annotation.wrapper';
|
import { AnnotationWrapper } from '@models/file/annotation.wrapper';
|
||||||
import {
|
import {
|
||||||
ChangeType,
|
ChangeType,
|
||||||
@ -50,6 +50,7 @@ export class FileDataService extends EntitiesService<AnnotationWrapper, Annotati
|
|||||||
readonly earmarks: Signal<Map<number, AnnotationWrapper[]>>;
|
readonly earmarks: Signal<Map<number, AnnotationWrapper[]>>;
|
||||||
readonly annotations: Signal<AnnotationWrapper[]>;
|
readonly annotations: Signal<AnnotationWrapper[]>;
|
||||||
readonly annotations$: Observable<AnnotationWrapper[]>;
|
readonly annotations$: Observable<AnnotationWrapper[]>;
|
||||||
|
readonly #isDocumine = getConfig().IS_DOCUMINE;
|
||||||
|
|
||||||
constructor(
|
constructor(
|
||||||
private readonly _state: FilePreviewStateService,
|
private readonly _state: FilePreviewStateService,
|
||||||
@ -220,6 +221,7 @@ export class FileDataService extends EntitiesService<AnnotationWrapper, Annotati
|
|||||||
changeLogValues.changeLogType,
|
changeLogValues.changeLogType,
|
||||||
redactionLog.legalBasis ?? [],
|
redactionLog.legalBasis ?? [],
|
||||||
!!dictionary?.hint,
|
!!dictionary?.hint,
|
||||||
|
this.#isDocumine,
|
||||||
);
|
);
|
||||||
|
|
||||||
if (entry.sourceId) {
|
if (entry.sourceId) {
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user