DM-604 bug fix for release
This commit is contained in:
parent
9f72bd78f8
commit
5d82df9983
@ -228,7 +228,13 @@ const routes: IqserRoutes = [
|
|||||||
];
|
];
|
||||||
|
|
||||||
@NgModule({
|
@NgModule({
|
||||||
imports: [RouterModule.forRoot(routes, { scrollPositionRestoration: 'enabled', bindToComponentInputs: true })],
|
imports: [
|
||||||
|
RouterModule.forRoot(routes, {
|
||||||
|
scrollPositionRestoration: 'enabled',
|
||||||
|
bindToComponentInputs: true,
|
||||||
|
paramsInheritanceStrategy: 'always',
|
||||||
|
}),
|
||||||
|
],
|
||||||
providers: [{ provide: RouteReuseStrategy, useExisting: CustomRouteReuseStrategy }],
|
providers: [{ provide: RouteReuseStrategy, useExisting: CustomRouteReuseStrategy }],
|
||||||
exports: [RouterModule],
|
exports: [RouterModule],
|
||||||
})
|
})
|
||||||
|
|||||||
@ -1,8 +1,9 @@
|
|||||||
import { Injectable } from '@angular/core';
|
import { Injectable } from '@angular/core';
|
||||||
import { CanActivate } from '@angular/router';
|
import { CanActivate } from '@angular/router';
|
||||||
import { firstValueFrom } from 'rxjs';
|
|
||||||
import { DashboardStatsService } from '@services/dossier-templates/dashboard-stats.service';
|
import { DashboardStatsService } from '@services/dossier-templates/dashboard-stats.service';
|
||||||
|
import { firstValueFrom } from 'rxjs';
|
||||||
|
|
||||||
|
// TODO: Remove this and use a CanActivateFn instead
|
||||||
@Injectable({ providedIn: 'root' })
|
@Injectable({ providedIn: 'root' })
|
||||||
export class DashboardGuard implements CanActivate {
|
export class DashboardGuard implements CanActivate {
|
||||||
constructor(private readonly _dashboardStatsService: DashboardStatsService) {}
|
constructor(private readonly _dashboardStatsService: DashboardStatsService) {}
|
||||||
|
|||||||
@ -1,16 +1,19 @@
|
|||||||
import { Injectable, Injector, ProviderToken } from '@angular/core';
|
import { Injectable, Injector, ProviderToken } from '@angular/core';
|
||||||
import { ActivatedRouteSnapshot, CanActivate, Router } from '@angular/router';
|
import { ActivatedRouteSnapshot, CanActivate, Router } from '@angular/router';
|
||||||
import { FilesMapService } from '@services/files/files-map.service';
|
import { getConfig } from '@iqser/common-ui';
|
||||||
import { FilesService } from '@services/files/files.service';
|
import { TenantsService } from '@iqser/common-ui/lib/tenants';
|
||||||
import { firstValueFrom } from 'rxjs';
|
|
||||||
import { DOSSIER_ID, DOSSIER_TEMPLATE_ID } from '@red/domain';
|
import { DOSSIER_ID, DOSSIER_TEMPLATE_ID } from '@red/domain';
|
||||||
import { DossiersService } from '@services/dossiers/dossiers.service';
|
import { DossiersService } from '@services/dossiers/dossiers.service';
|
||||||
import { DictionaryService } from '@services/entity-services/dictionary.service';
|
import { DictionaryService } from '@services/entity-services/dictionary.service';
|
||||||
import { DossierDictionariesMapService } from '@services/entity-services/dossier-dictionaries-map.service';
|
import { DossierDictionariesMapService } from '@services/entity-services/dossier-dictionaries-map.service';
|
||||||
import { TenantsService } from '@iqser/common-ui/lib/tenants';
|
import { FilesMapService } from '@services/files/files-map.service';
|
||||||
|
import { FilesService } from '@services/files/files.service';
|
||||||
|
import { firstValueFrom } from 'rxjs';
|
||||||
|
|
||||||
@Injectable({ providedIn: 'root' })
|
@Injectable({ providedIn: 'root' })
|
||||||
export class DossierFilesGuard implements CanActivate {
|
export class DossierFilesGuard implements CanActivate {
|
||||||
|
readonly isDocumine = getConfig().IS_DOCUMINE;
|
||||||
|
|
||||||
constructor(
|
constructor(
|
||||||
private readonly _injector: Injector,
|
private readonly _injector: Injector,
|
||||||
private readonly _tenantsService: TenantsService,
|
private readonly _tenantsService: TenantsService,
|
||||||
@ -45,8 +48,8 @@ export class DossierFilesGuard implements CanActivate {
|
|||||||
async loadDossierData(dossierId: string, dossierTemplateId: string) {
|
async loadDossierData(dossierId: string, dossierTemplateId: string) {
|
||||||
const promises = [];
|
const promises = [];
|
||||||
|
|
||||||
if (!this._dictionaryMapService.has(dossierId)) {
|
if (!this._dictionaryMapService.has(dossierId) && !this.isDocumine) {
|
||||||
const dictionaryPromise = this._dictionaryService.loadDossierDictionary(dossierTemplateId, dossierId);
|
const dictionaryPromise = this._dictionaryService.loadDossierRedaction(dossierTemplateId, dossierId);
|
||||||
promises.push(dictionaryPromise);
|
promises.push(dictionaryPromise);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@ -1,7 +1,8 @@
|
|||||||
import { CanDeactivateFn } from '@angular/router';
|
|
||||||
import { inject } from '@angular/core';
|
import { inject } from '@angular/core';
|
||||||
|
import { CanDeactivateFn } from '@angular/router';
|
||||||
import { FileAttributesService } from '@services/entity-services/file-attributes.service';
|
import { FileAttributesService } from '@services/entity-services/file-attributes.service';
|
||||||
import { DossierOverviewScreenComponent } from '../modules/dossier-overview/screen/dossier-overview-screen.component';
|
import { DossierOverviewScreenComponent } from '../modules/dossier-overview/screen/dossier-overview-screen.component';
|
||||||
|
|
||||||
|
// TODO: rename to something like "isNotEditingFileAttributeGuard"
|
||||||
export const editAttributeGuard: CanDeactivateFn<DossierOverviewScreenComponent> = () =>
|
export const editAttributeGuard: CanDeactivateFn<DossierOverviewScreenComponent> = () =>
|
||||||
!inject(FileAttributesService).isEditingFileAttribute();
|
!inject(FileAttributesService).isEditingFileAttribute();
|
||||||
|
|||||||
@ -2,11 +2,12 @@
|
|||||||
<div class="dialog-content">
|
<div class="dialog-content">
|
||||||
<div *ngFor="let category of notificationCategories">
|
<div *ngFor="let category of notificationCategories">
|
||||||
<div class="iqser-input-group header w-full">
|
<div class="iqser-input-group header w-full">
|
||||||
<mat-slide-toggle color="primary" formControlName="{{ category }}Enabled">{{
|
<mat-slide-toggle color="primary" formControlName="{{ category }}Enabled"
|
||||||
translations[category] | translate
|
>{{ translations[category] | translate }}
|
||||||
}}</mat-slide-toggle>
|
</mat-slide-toggle>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
<!-- TODO: This lots of getters-->
|
||||||
<div *ngIf="isCategoryActive(category)" class="options-content">
|
<div *ngIf="isCategoryActive(category)" class="options-content">
|
||||||
<div [translate]="'notifications-screen.options-title'" class="statement"></div>
|
<div [translate]="'notifications-screen.options-title'" class="statement"></div>
|
||||||
|
|
||||||
@ -15,8 +16,8 @@
|
|||||||
<div class="iqser-input-group">
|
<div class="iqser-input-group">
|
||||||
<ng-container *ngFor="let preference of getRssFilteredSettings(notificationGroupsValues[i])">
|
<ng-container *ngFor="let preference of getRssFilteredSettings(notificationGroupsValues[i])">
|
||||||
<mat-checkbox
|
<mat-checkbox
|
||||||
*ngIf="!skipPreference(preference)"
|
|
||||||
(change)="addRemovePreference($event.checked, category, preference)"
|
(change)="addRemovePreference($event.checked, category, preference)"
|
||||||
|
*ngIf="!skipPreference(preference)"
|
||||||
[checked]="isPreferenceChecked(category, preference)"
|
[checked]="isPreferenceChecked(category, preference)"
|
||||||
color="primary"
|
color="primary"
|
||||||
>
|
>
|
||||||
|
|||||||
@ -1,14 +1,15 @@
|
|||||||
import { ChangeDetectionStrategy, Component, Inject } from '@angular/core';
|
|
||||||
import { BaseDialogComponent } from '@iqser/common-ui';
|
|
||||||
import { MAT_DIALOG_DATA, MatDialogRef } from '@angular/material/dialog';
|
|
||||||
import { IAudit } from '@red/domain';
|
|
||||||
import { DossierStatesService } from '@services/entity-services/dossier-states.service';
|
|
||||||
import { KeyValue } from '@angular/common';
|
import { KeyValue } from '@angular/common';
|
||||||
|
import { ChangeDetectionStrategy, Component, Inject } from '@angular/core';
|
||||||
|
import { MAT_DIALOG_DATA, MatDialogRef } from '@angular/material/dialog';
|
||||||
|
import { BaseDialogComponent } from '@iqser/common-ui';
|
||||||
|
import { IAudit } from '@red/domain';
|
||||||
|
|
||||||
interface DialogData {
|
interface DialogData {
|
||||||
readonly auditEntry: IAudit;
|
readonly auditEntry: IAudit;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
type OrderFn = (a: KeyValue<string, string>, b: KeyValue<string, string>) => number;
|
||||||
|
|
||||||
@Component({
|
@Component({
|
||||||
selector: 'redaction-audit-info-dialog',
|
selector: 'redaction-audit-info-dialog',
|
||||||
templateUrl: './audit-info-dialog.component.html',
|
templateUrl: './audit-info-dialog.component.html',
|
||||||
@ -17,14 +18,13 @@ interface DialogData {
|
|||||||
})
|
})
|
||||||
export class AuditInfoDialogComponent extends BaseDialogComponent {
|
export class AuditInfoDialogComponent extends BaseDialogComponent {
|
||||||
constructor(
|
constructor(
|
||||||
private readonly _dossierStatesService: DossierStatesService,
|
|
||||||
protected readonly _dialogRef: MatDialogRef<AuditInfoDialogComponent>,
|
protected readonly _dialogRef: MatDialogRef<AuditInfoDialogComponent>,
|
||||||
@Inject(MAT_DIALOG_DATA) readonly data: DialogData,
|
@Inject(MAT_DIALOG_DATA) readonly data: DialogData,
|
||||||
) {
|
) {
|
||||||
super(_dialogRef, false);
|
super(_dialogRef, false);
|
||||||
}
|
}
|
||||||
|
|
||||||
readonly originalOrder = (a: KeyValue<string, string>, b: KeyValue<string, string>): number => 0;
|
readonly originalOrder: OrderFn = () => 0;
|
||||||
|
|
||||||
async save(): Promise<void> {
|
async save(): Promise<void> {
|
||||||
return;
|
return;
|
||||||
|
|||||||
@ -1,8 +1,9 @@
|
|||||||
import { BaseFormComponent } from '@iqser/common-ui';
|
import { BaseFormComponent } from '@iqser/common-ui';
|
||||||
import { DigitalSignatureService } from '../../../services/digital-signature.service';
|
|
||||||
import { DigitalSignatureOption, DigitalSignatureOptions, IDigitalSignatureRequest } from '@red/domain';
|
import { DigitalSignatureOption, DigitalSignatureOptions, IDigitalSignatureRequest } from '@red/domain';
|
||||||
import { firstValueFrom, Observable } from 'rxjs';
|
import { firstValueFrom, Observable } from 'rxjs';
|
||||||
|
import { DigitalSignatureService } from '../../../services/digital-signature.service';
|
||||||
|
|
||||||
|
// TODO: This should be handled with services for each type of signature
|
||||||
export abstract class BaseSignatureConfigurationComponent extends BaseFormComponent {
|
export abstract class BaseSignatureConfigurationComponent extends BaseFormComponent {
|
||||||
file: File | null;
|
file: File | null;
|
||||||
|
|
||||||
|
|||||||
@ -5,28 +5,29 @@
|
|||||||
[readonly]="!!file"
|
[readonly]="!!file"
|
||||||
accept=".p12"
|
accept=".p12"
|
||||||
></iqser-upload-file>
|
></iqser-upload-file>
|
||||||
|
|
||||||
<form [formGroup]="form">
|
<form [formGroup]="form">
|
||||||
<div class="flex">
|
<div class="flex">
|
||||||
<div class="flex fields-container">
|
<div class="flex fields-container">
|
||||||
<div class="iqser-input-group required w-300">
|
<div class="iqser-input-group required w-300">
|
||||||
<label [translate]="'digital-signature-dialog.forms.pkcs.certificate-name'"></label>
|
<label [translate]="'digital-signature-dialog.forms.pkcs.certificate-name'"></label>
|
||||||
<input id="certificate-name-input" formControlName="certificateName" type="text" />
|
<input formControlName="certificateName" id="certificate-name-input" type="text" />
|
||||||
</div>
|
</div>
|
||||||
<div *ngIf="!digitalSignature" class="iqser-input-group required w-300">
|
<div *ngIf="!digitalSignature" class="iqser-input-group required w-300">
|
||||||
<label [translate]="'digital-signature-dialog.forms.pkcs.password-key'"></label>
|
<label [translate]="'digital-signature-dialog.forms.pkcs.password-key'"></label>
|
||||||
<input id="certificate-password-input" formControlName="password" type="password" />
|
<input formControlName="password" id="certificate-password-input" type="password" />
|
||||||
</div>
|
</div>
|
||||||
<div class="iqser-input-group w-300">
|
<div class="iqser-input-group w-300">
|
||||||
<label [translate]="'digital-signature-dialog.forms.pkcs.contact-information'"></label>
|
<label [translate]="'digital-signature-dialog.forms.pkcs.contact-information'"></label>
|
||||||
<input id="certificate-contact-info-input" formControlName="contactInfo" type="text" />
|
<input formControlName="contactInfo" id="certificate-contact-info-input" type="text" />
|
||||||
</div>
|
</div>
|
||||||
<div class="iqser-input-group w-300">
|
<div class="iqser-input-group w-300">
|
||||||
<label [translate]="'digital-signature-dialog.forms.pkcs.location'"></label>
|
<label [translate]="'digital-signature-dialog.forms.pkcs.location'"></label>
|
||||||
<input id="certificate-location-input" formControlName="location" type="text" />
|
<input formControlName="location" id="certificate-location-input" type="text" />
|
||||||
</div>
|
</div>
|
||||||
<div class="iqser-input-group w-450">
|
<div class="iqser-input-group w-450">
|
||||||
<label [translate]="'digital-signature-dialog.forms.pkcs.reason'"></label>
|
<label [translate]="'digital-signature-dialog.forms.pkcs.reason'"></label>
|
||||||
<textarea id="certificate-location-input" formControlName="reason" rows="4" type="text"></textarea>
|
<textarea formControlName="reason" id="certificate-reason-input" rows="4" type="text"></textarea>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
@ -1,10 +1,10 @@
|
|||||||
import { ChangeDetectionStrategy, Component, Input, OnInit } from '@angular/core';
|
import { ChangeDetectionStrategy, Component, Input, OnInit } from '@angular/core';
|
||||||
import { UntypedFormBuilder, Validators } from '@angular/forms';
|
import { UntypedFormBuilder, Validators } from '@angular/forms';
|
||||||
import { BaseSignatureConfigurationComponent } from '../base-signature-configuration-component';
|
|
||||||
import { DigitalSignatureOptions, IPkcsDigitalSignature, IPkcsDigitalSignatureRequest } from '@red/domain';
|
import { DigitalSignatureOptions, IPkcsDigitalSignature, IPkcsDigitalSignatureRequest } from '@red/domain';
|
||||||
|
import { lastIndexOfEnd } from '@utils/functions';
|
||||||
import { firstValueFrom } from 'rxjs';
|
import { firstValueFrom } from 'rxjs';
|
||||||
import { DigitalSignatureService } from '../../../../services/digital-signature.service';
|
import { DigitalSignatureService } from '../../../../services/digital-signature.service';
|
||||||
import { lastIndexOfEnd } from '../../../../../../utils';
|
import { BaseSignatureConfigurationComponent } from '../base-signature-configuration-component';
|
||||||
|
|
||||||
@Component({
|
@Component({
|
||||||
selector: 'redaction-pkcs-signature-configuration',
|
selector: 'redaction-pkcs-signature-configuration',
|
||||||
@ -15,7 +15,10 @@ import { lastIndexOfEnd } from '../../../../../../utils';
|
|||||||
export class PkcsSignatureConfigurationComponent extends BaseSignatureConfigurationComponent implements OnInit {
|
export class PkcsSignatureConfigurationComponent extends BaseSignatureConfigurationComponent implements OnInit {
|
||||||
@Input() digitalSignature!: IPkcsDigitalSignatureRequest;
|
@Input() digitalSignature!: IPkcsDigitalSignatureRequest;
|
||||||
|
|
||||||
constructor(protected readonly _digitalSignatureService: DigitalSignatureService, private readonly _formBuilder: UntypedFormBuilder) {
|
constructor(
|
||||||
|
protected readonly _digitalSignatureService: DigitalSignatureService,
|
||||||
|
private readonly _formBuilder: UntypedFormBuilder,
|
||||||
|
) {
|
||||||
super(_digitalSignatureService, DigitalSignatureOptions.PKCS);
|
super(_digitalSignatureService, DigitalSignatureOptions.PKCS);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@ -1,9 +1,9 @@
|
|||||||
import { Component, Inject } from '@angular/core';
|
import { Component, Inject } from '@angular/core';
|
||||||
import { UntypedFormGroup, Validators } from '@angular/forms';
|
import { Validators } from '@angular/forms';
|
||||||
import { MAT_DIALOG_DATA, MatDialogRef } from '@angular/material/dialog';
|
import { MAT_DIALOG_DATA, MatDialogRef } from '@angular/material/dialog';
|
||||||
import { getCurrentUser } from '@users/user.service';
|
|
||||||
import { ISmtpConfiguration } from '@red/domain';
|
|
||||||
import { BaseDialogComponent } from '@iqser/common-ui';
|
import { BaseDialogComponent } from '@iqser/common-ui';
|
||||||
|
import { ISmtpConfiguration } from '@red/domain';
|
||||||
|
import { getCurrentUser } from '@users/user.service';
|
||||||
|
|
||||||
@Component({
|
@Component({
|
||||||
selector: 'redaction-smtp-auth-dialog',
|
selector: 'redaction-smtp-auth-dialog',
|
||||||
@ -25,7 +25,7 @@ export class SmtpAuthDialogComponent extends BaseDialogComponent {
|
|||||||
this._dialogRef.close(this.form.getRawValue());
|
this._dialogRef.close(this.form.getRawValue());
|
||||||
}
|
}
|
||||||
|
|
||||||
private _getForm(): UntypedFormGroup {
|
private _getForm() {
|
||||||
return this._formBuilder.group({
|
return this._formBuilder.group({
|
||||||
user: [this.data?.user || this.#currentUser.email, [Validators.required]],
|
user: [this.data?.user || this.#currentUser.email, [Validators.required]],
|
||||||
password: [this.data?.password, Validators.required],
|
password: [this.data?.password, Validators.required],
|
||||||
|
|||||||
@ -1,5 +1,4 @@
|
|||||||
import { ChangeDetectionStrategy, Component } from '@angular/core';
|
import { ChangeDetectionStrategy, Component } from '@angular/core';
|
||||||
import { TranslateService } from '@ngx-translate/core';
|
|
||||||
import { MatDialogRef } from '@angular/material/dialog';
|
import { MatDialogRef } from '@angular/material/dialog';
|
||||||
import { IconButtonTypes } from '@iqser/common-ui';
|
import { IconButtonTypes } from '@iqser/common-ui';
|
||||||
|
|
||||||
@ -11,7 +10,7 @@ import { IconButtonTypes } from '@iqser/common-ui';
|
|||||||
export class UploadDictionaryDialogComponent {
|
export class UploadDictionaryDialogComponent {
|
||||||
readonly iconButtonTypes = IconButtonTypes;
|
readonly iconButtonTypes = IconButtonTypes;
|
||||||
|
|
||||||
constructor(private readonly _translateService: TranslateService, public dialogRef: MatDialogRef<UploadDictionaryDialogComponent>) {}
|
constructor(public dialogRef: MatDialogRef<UploadDictionaryDialogComponent>) {}
|
||||||
|
|
||||||
cancel() {
|
cancel() {
|
||||||
this.dialogRef.close();
|
this.dialogRef.close();
|
||||||
|
|||||||
@ -96,6 +96,7 @@
|
|||||||
</div>
|
</div>
|
||||||
</ng-template>
|
</ng-template>
|
||||||
|
|
||||||
|
<!--TODO: use ngTemplateContextGuard for typings here-->
|
||||||
<ng-template #tableItemTemplate let-entity="entity">
|
<ng-template #tableItemTemplate let-entity="entity">
|
||||||
<div *ngIf="cast(entity) as log">
|
<div *ngIf="cast(entity) as log">
|
||||||
<div class="cell">
|
<div class="cell">
|
||||||
|
|||||||
@ -14,8 +14,8 @@
|
|||||||
[helpModeKey]="'digital_signature'"
|
[helpModeKey]="'digital_signature'"
|
||||||
[showButton]="permissionsService.has$(roles.digitalSignature.write) | async"
|
[showButton]="permissionsService.has$(roles.digitalSignature.write) | async"
|
||||||
[text]="'digital-signature-screen.no-data.title' | translate"
|
[text]="'digital-signature-screen.no-data.title' | translate"
|
||||||
icon="iqser:document"
|
|
||||||
buttonId="configure-certificate-btn"
|
buttonId="configure-certificate-btn"
|
||||||
|
icon="iqser:document"
|
||||||
></iqser-empty-state>
|
></iqser-empty-state>
|
||||||
|
|
||||||
<ng-container *ngIf="digitalSignature">
|
<ng-container *ngIf="digitalSignature">
|
||||||
@ -23,6 +23,7 @@
|
|||||||
*ngIf="currentCertificateType === certificateType.PKCS"
|
*ngIf="currentCertificateType === certificateType.PKCS"
|
||||||
[digitalSignature]="digitalSignature"
|
[digitalSignature]="digitalSignature"
|
||||||
></redaction-pkcs-signature-configuration>
|
></redaction-pkcs-signature-configuration>
|
||||||
|
|
||||||
<redaction-kms-signature-configuration
|
<redaction-kms-signature-configuration
|
||||||
*ngIf="currentCertificateType === certificateType.KMS"
|
*ngIf="currentCertificateType === certificateType.KMS"
|
||||||
[digitalSignature]="digitalSignature"
|
[digitalSignature]="digitalSignature"
|
||||||
@ -31,19 +32,19 @@
|
|||||||
|
|
||||||
<div [class.hidden]="!digitalSignature" class="changes-box">
|
<div [class.hidden]="!digitalSignature" class="changes-box">
|
||||||
<iqser-icon-button
|
<iqser-icon-button
|
||||||
buttonId="save-certificate-changes-btn"
|
|
||||||
(action)="saveDigitalSignature()"
|
(action)="saveDigitalSignature()"
|
||||||
[disabled]="disabled"
|
[disabled]="disabled"
|
||||||
[label]="'digital-signature-screen.action.save' | translate"
|
[label]="'digital-signature-screen.action.save' | translate"
|
||||||
[type]="iconButtonTypes.primary"
|
[type]="iconButtonTypes.primary"
|
||||||
|
buttonId="save-certificate-changes-btn"
|
||||||
icon="iqser:check"
|
icon="iqser:check"
|
||||||
></iqser-icon-button>
|
></iqser-icon-button>
|
||||||
|
|
||||||
<div
|
<div
|
||||||
id="remove-certificate-btn"
|
|
||||||
(click)="removeDigitalSignature()"
|
(click)="removeDigitalSignature()"
|
||||||
*ngIf="digitalSignature"
|
*ngIf="digitalSignature"
|
||||||
class="all-caps-label cancel"
|
class="all-caps-label cancel"
|
||||||
|
id="remove-certificate-btn"
|
||||||
translate="digital-signature-screen.action.remove"
|
translate="digital-signature-screen.action.remove"
|
||||||
></div>
|
></div>
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
@ -52,12 +52,14 @@
|
|||||||
</div>
|
</div>
|
||||||
|
|
||||||
<redaction-watermark-selector
|
<redaction-watermark-selector
|
||||||
|
*ngIf="!config.IS_DOCUMINE"
|
||||||
[dossierTemplateId]="dossierTemplateId"
|
[dossierTemplateId]="dossierTemplateId"
|
||||||
[label]="'dossier-watermark-selector.watermark' | translate"
|
[label]="'dossier-watermark-selector.watermark' | translate"
|
||||||
formControlName="watermarkId"
|
formControlName="watermarkId"
|
||||||
></redaction-watermark-selector>
|
></redaction-watermark-selector>
|
||||||
|
|
||||||
<redaction-watermark-selector
|
<redaction-watermark-selector
|
||||||
|
*ngIf="!config.IS_DOCUMINE"
|
||||||
[dossierTemplateId]="dossierTemplateId"
|
[dossierTemplateId]="dossierTemplateId"
|
||||||
[label]="'dossier-watermark-selector.preview' | translate"
|
[label]="'dossier-watermark-selector.preview' | translate"
|
||||||
formControlName="previewWatermarkId"
|
formControlName="previewWatermarkId"
|
||||||
@ -83,7 +85,7 @@
|
|||||||
<div class="flex">
|
<div class="flex">
|
||||||
<redaction-select
|
<redaction-select
|
||||||
[height]="165"
|
[height]="165"
|
||||||
[label]="'report-type.label' | translate : { length: reportTemplateIdsLength }"
|
[label]="'report-type.label' | translate: { length: reportTemplateIdsLength }"
|
||||||
[optionTemplate]="reportTemplateOptionTemplate"
|
[optionTemplate]="reportTemplateOptionTemplate"
|
||||||
[options]="availableReportTypes"
|
[options]="availableReportTypes"
|
||||||
[valueMapper]="reportTemplateValueMapper"
|
[valueMapper]="reportTemplateValueMapper"
|
||||||
@ -94,7 +96,7 @@
|
|||||||
<redaction-select
|
<redaction-select
|
||||||
*deny="roles.getRss"
|
*deny="roles.getRss"
|
||||||
[height]="165"
|
[height]="165"
|
||||||
[label]="'download-type.label' | translate : { length: downloadFileTypesLength }"
|
[label]="'download-type.label' | translate: { length: downloadFileTypesLength }"
|
||||||
[options]="downloadTypes"
|
[options]="downloadTypes"
|
||||||
formControlName="downloadFileTypes"
|
formControlName="downloadFileTypes"
|
||||||
></redaction-select>
|
></redaction-select>
|
||||||
|
|||||||
@ -1,16 +1,16 @@
|
|||||||
import { Injectable } from '@angular/core';
|
|
||||||
import { firstValueFrom, forkJoin, Observable, throwError } from 'rxjs';
|
|
||||||
import { EntitiesService, QueryParam, Toaster } from '@iqser/common-ui';
|
|
||||||
import { Dictionary, DictionaryEntryType, DictionaryEntryTypes, IDictionary, IUpdateDictionary, SuperTypes } from '@red/domain';
|
|
||||||
import { catchError, map, switchMap, tap } from 'rxjs/operators';
|
|
||||||
import { marker as _ } from '@biesbjerg/ngx-translate-extract-marker';
|
|
||||||
import { DossierTemplateStatsService } from './dossier-template-stats.service';
|
|
||||||
import { DictionariesMapService } from './dictionaries-map.service';
|
|
||||||
import { HttpErrorResponse, HttpStatusCode } from '@angular/common/http';
|
import { HttpErrorResponse, HttpStatusCode } from '@angular/common/http';
|
||||||
import { FALLBACK_COLOR } from '@utils/constants';
|
import { Injectable } from '@angular/core';
|
||||||
import { DossierDictionariesMapService } from '@services/entity-services/dossier-dictionaries-map.service';
|
import { marker as _ } from '@biesbjerg/ngx-translate-extract-marker';
|
||||||
|
import { EntitiesService, QueryParam, Toaster } from '@iqser/common-ui';
|
||||||
import { List } from '@iqser/common-ui/lib/utils';
|
import { List } from '@iqser/common-ui/lib/utils';
|
||||||
|
import { Dictionary, DictionaryEntryType, DictionaryEntryTypes, IDictionary, IUpdateDictionary, SuperTypes } from '@red/domain';
|
||||||
|
import { DossierDictionariesMapService } from '@services/entity-services/dossier-dictionaries-map.service';
|
||||||
|
import { FALLBACK_COLOR } from '@utils/constants';
|
||||||
|
import { firstValueFrom, forkJoin, Observable, throwError } from 'rxjs';
|
||||||
|
import { catchError, map, switchMap, tap } from 'rxjs/operators';
|
||||||
import { IMAGE_CATEGORIES } from '../../modules/file-preview/utils/constants';
|
import { IMAGE_CATEGORIES } from '../../modules/file-preview/utils/constants';
|
||||||
|
import { DictionariesMapService } from './dictionaries-map.service';
|
||||||
|
import { DossierTemplateStatsService } from './dossier-template-stats.service';
|
||||||
|
|
||||||
const IMAGE_TYPES = ['image', 'formula', 'ocr'];
|
const IMAGE_TYPES = ['image', 'formula', 'ocr'];
|
||||||
|
|
||||||
@ -216,7 +216,7 @@ export class DictionaryService extends EntitiesService<IDictionary, Dictionary>
|
|||||||
return possibleDictionaries;
|
return possibleDictionaries;
|
||||||
}
|
}
|
||||||
|
|
||||||
async loadDossierDictionary(dossierTemplateId: string, dossierId: string): Promise<Dictionary> {
|
async loadDossierRedaction(dossierTemplateId: string, dossierId: string): Promise<Dictionary> {
|
||||||
const promise = this.getForType(dossierTemplateId, 'dossier_redaction', dossierId);
|
const promise = this.getForType(dossierTemplateId, 'dossier_redaction', dossierId);
|
||||||
const dict = await promise.catch(() => undefined);
|
const dict = await promise.catch(() => undefined);
|
||||||
if (dict) {
|
if (dict) {
|
||||||
|
|||||||
@ -1,6 +1,6 @@
|
|||||||
import { Injectable } from '@angular/core';
|
import { Injectable } from '@angular/core';
|
||||||
import { INGXLoggerConfig, NgxLoggerLevel, NGXLoggerRulesService } from 'ngx-logger';
|
|
||||||
import { ILoggerConfig } from '@red/domain';
|
import { ILoggerConfig } from '@red/domain';
|
||||||
|
import { INGXLoggerConfig, NgxLoggerLevel, NGXLoggerRulesService } from 'ngx-logger';
|
||||||
|
|
||||||
@Injectable()
|
@Injectable()
|
||||||
export class LoggerRulesService extends NGXLoggerRulesService {
|
export class LoggerRulesService extends NGXLoggerRulesService {
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user