move justification to red-domain
This commit is contained in:
parent
8b6b93edd8
commit
c66439c859
@ -1,7 +1,7 @@
|
||||
import { ChangeDetectionStrategy, Component, Inject } from '@angular/core';
|
||||
import { FormBuilder, FormGroup, Validators } from '@angular/forms';
|
||||
import { MAT_DIALOG_DATA, MatDialogRef } from '@angular/material/dialog';
|
||||
import { Justification } from '@models/justification.model';
|
||||
import { Justification } from '@red/domain';
|
||||
import { JustificationsService } from '@services/entity-services/justifications.service';
|
||||
import { DossierTemplatesService } from '@services/entity-services/dossier-templates.service';
|
||||
import { LoadingService } from '@iqser/common-ui';
|
||||
|
||||
@ -13,7 +13,7 @@ import { AddEditJustificationDialogComponent } from './add-edit-justification-di
|
||||
import { marker as _ } from '@biesbjerg/ngx-translate-extract-marker';
|
||||
import { DossierTemplatesService } from '@services/entity-services/dossier-templates.service';
|
||||
import { JustificationsService } from '@services/entity-services/justifications.service';
|
||||
import { Justification } from '@models/justification.model';
|
||||
import { Justification } from '@red/domain';
|
||||
|
||||
type DialogType = 'confirm' | 'addEditJustification';
|
||||
|
||||
|
||||
@ -9,7 +9,7 @@ import {
|
||||
LoadingService,
|
||||
TableColumnConfig,
|
||||
} from '@iqser/common-ui';
|
||||
import { Justification } from '@models/justification.model';
|
||||
import { Justification } from '@red/domain';
|
||||
import { JustificationsService } from '@services/entity-services/justifications.service';
|
||||
import { DossierTemplatesService } from '@services/entity-services/dossier-templates.service';
|
||||
import { JustificationsDialogService } from '../justifications-dialog.service';
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
import { ChangeDetectionStrategy, Component, Input } from '@angular/core';
|
||||
import { Justification } from '@models/justification.model';
|
||||
import { Justification } from '@red/domain';
|
||||
import { CircleButtonTypes, ListingService, LoadingService } from '@iqser/common-ui';
|
||||
import { JustificationsDialogService } from '../justifications-dialog.service';
|
||||
import { UserService } from '@services/user.service';
|
||||
|
||||
@ -1,9 +1,8 @@
|
||||
import { Injectable, Injector } from '@angular/core';
|
||||
import { EntitiesService, RequiredParam, Validate } from '@iqser/common-ui';
|
||||
import { Justification } from '@models/justification.model';
|
||||
import { ILegalBasis, Justification } from '@red/domain';
|
||||
import { Observable } from 'rxjs';
|
||||
import { map } from 'rxjs/operators';
|
||||
import { ILegalBasis } from '@red/domain';
|
||||
|
||||
@Injectable({
|
||||
providedIn: 'root',
|
||||
|
||||
@ -16,3 +16,4 @@ export * from './lib/downloads';
|
||||
export * from './lib/reports';
|
||||
export * from './lib/configuration';
|
||||
export * from './lib/signature';
|
||||
export * from './lib/legal-basis';
|
||||
|
||||
3
libs/red-domain/src/lib/legal-basis/index.ts
Normal file
3
libs/red-domain/src/lib/legal-basis/index.ts
Normal file
@ -0,0 +1,3 @@
|
||||
export * from './legal-basis-change.request';
|
||||
export * from './legal-basis';
|
||||
export * from './justification.model';
|
||||
@ -1,19 +1,22 @@
|
||||
import { IListable } from '@iqser/common-ui';
|
||||
import { ILegalBasis } from '@red/domain';
|
||||
import { ILegalBasis } from './legal-basis';
|
||||
|
||||
export class Justification implements ILegalBasis, IListable {
|
||||
readonly id: string;
|
||||
readonly description?: string;
|
||||
readonly name?: string;
|
||||
readonly name: string;
|
||||
readonly reason?: string;
|
||||
readonly searchKey: string;
|
||||
|
||||
constructor(justification: ILegalBasis) {
|
||||
this.id = justification.name;
|
||||
this.description = justification.description;
|
||||
this.name = justification.name;
|
||||
this.reason = justification.reason;
|
||||
}
|
||||
|
||||
this.searchKey = this.name;
|
||||
get id(): string {
|
||||
return this.name;
|
||||
}
|
||||
|
||||
get searchKey(): string {
|
||||
return this.name;
|
||||
}
|
||||
}
|
||||
@ -1,5 +1,5 @@
|
||||
export interface ILegalBasis {
|
||||
name: string;
|
||||
description?: string;
|
||||
name?: string;
|
||||
reason?: string;
|
||||
}
|
||||
@ -1,12 +1,10 @@
|
||||
export * from './types';
|
||||
export * from './change';
|
||||
export * from './comment';
|
||||
export * from './legal-basis';
|
||||
export * from './add-redaction.request';
|
||||
export * from './manual-redaction-entry';
|
||||
export * from './redaction-log-entry';
|
||||
export * from './redaction-log';
|
||||
export * from './legal-basis-change.request';
|
||||
export * from './remove-redaction.request';
|
||||
export * from './manual-add.response';
|
||||
export * from './approve-request';
|
||||
|
||||
@ -1,4 +1,4 @@
|
||||
import { ILegalBasis } from './legal-basis';
|
||||
import { ILegalBasis } from '../legal-basis';
|
||||
import { IRedactionLogEntry } from './redaction-log-entry';
|
||||
|
||||
export interface IRedactionLog {
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user