Merge branch 'master' into VM/RED-6774
This commit is contained in:
commit
219b37f797
@ -68,6 +68,13 @@
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<p class="heading download-includes">{{ 'add-edit-clone-dossier-template.form.apply-updates-default.heading' | translate }}</p>
|
||||
<div class="iqser-input-group">
|
||||
<mat-checkbox color="primary" formControlName="applyDictionaryUpdatesToAllDossiersByDefault">
|
||||
{{ 'add-edit-clone-dossier-template.form.apply-updates-default.description' | translate }}
|
||||
</mat-checkbox>
|
||||
</div>
|
||||
|
||||
<p class="heading download-includes">{{ 'download-includes' | translate }}</p>
|
||||
<div class="flex">
|
||||
<redaction-select
|
||||
|
||||
@ -43,7 +43,7 @@ export class AddEditCloneDossierTemplateDialogComponent extends BaseDialogCompon
|
||||
) {
|
||||
super(_dialogRef, !!data && !data.clone);
|
||||
this.dossierTemplate = this._dossierTemplatesService.find(this.data?.dossierTemplateId);
|
||||
this.form = this._getForm();
|
||||
this.form = this.#getForm();
|
||||
this.initialFormValue = this.form.getRawValue();
|
||||
this.hasValidFrom = !!this.dossierTemplate?.validFrom;
|
||||
this.hasValidTo = !!this.dossierTemplate?.validTo;
|
||||
@ -113,18 +113,19 @@ export class AddEditCloneDossierTemplateDialogComponent extends BaseDialogCompon
|
||||
this._lastValidTo = this._previousValidTo || this._lastValidTo;
|
||||
}
|
||||
|
||||
private _getForm() {
|
||||
#getForm() {
|
||||
return this._formBuilder.group({
|
||||
name: [this._getCloneName(), Validators.required],
|
||||
name: [this.#getCloneName(), Validators.required],
|
||||
description: [this.dossierTemplate?.description],
|
||||
validFrom: [
|
||||
this.dossierTemplate?.validFrom ? dayjs(this.dossierTemplate?.validFrom).toDate() : null,
|
||||
this._requiredIfValidator(() => this.hasValidFrom),
|
||||
this.#requiredIfValidator(() => this.hasValidFrom),
|
||||
],
|
||||
validTo: [
|
||||
this.dossierTemplate?.validTo ? dayjs(this.dossierTemplate?.validTo).toDate() : null,
|
||||
this._requiredIfValidator(() => this.hasValidTo),
|
||||
this.#requiredIfValidator(() => this.hasValidTo),
|
||||
],
|
||||
applyDictionaryUpdatesToAllDossiersByDefault: [this.dossierTemplate?.applyDictionaryUpdatesToAllDossiersByDefault],
|
||||
downloadFileTypes: [this.dossierTemplate?.downloadFileTypes || ['PREVIEW', 'REDACTED']],
|
||||
keepHiddenText: [this.dossierTemplate?.keepHiddenText],
|
||||
keepImageMetadata: [this.dossierTemplate?.keepImageMetadata],
|
||||
@ -132,7 +133,7 @@ export class AddEditCloneDossierTemplateDialogComponent extends BaseDialogCompon
|
||||
});
|
||||
}
|
||||
|
||||
private _getCloneName(): string {
|
||||
#getCloneName(): string {
|
||||
if (!this.data?.clone) {
|
||||
return this.dossierTemplate?.name;
|
||||
}
|
||||
@ -157,7 +158,7 @@ export class AddEditCloneDossierTemplateDialogComponent extends BaseDialogCompon
|
||||
return `Copy of ${nameOfClonedTemplate}`;
|
||||
}
|
||||
|
||||
private _requiredIfValidator(predicate) {
|
||||
#requiredIfValidator(predicate) {
|
||||
return (formControl: AbstractControl) => {
|
||||
if (!formControl.parent) {
|
||||
return null;
|
||||
|
||||
@ -260,7 +260,7 @@ export class WatermarkScreenComponent implements OnInit {
|
||||
}
|
||||
|
||||
async #loadDocument() {
|
||||
const filename = `blank-${this.#config.WATERMARK_PREVIEW_PAPER_FORMAT}.pdf`;
|
||||
const filename = `blank-${this.#config.WATERMARK_PREVIEW_PAPER_FORMAT || 'a4'}.pdf`;
|
||||
const request = this._http.get(`/assets/pdftron/${filename}`, {
|
||||
responseType: 'blob',
|
||||
});
|
||||
|
||||
@ -282,13 +282,11 @@ export class SearchScreenComponent extends ListingComponent<ISearchListItem> imp
|
||||
}: IMatchedDocument): ISearchListItem {
|
||||
const file = this._filesMapService.get(dossierId, fileId);
|
||||
if (!file) {
|
||||
console.error('Missing file');
|
||||
return undefined;
|
||||
}
|
||||
|
||||
const dossier = this._dossiersCacheService.get(dossierId);
|
||||
if (!dossier) {
|
||||
console.error('Missing dossier');
|
||||
return undefined;
|
||||
}
|
||||
|
||||
|
||||
@ -61,7 +61,11 @@
|
||||
"title": ""
|
||||
},
|
||||
"valid-from": "Gültig ab",
|
||||
"valid-to": "Gültig bis"
|
||||
"valid-to": "Gültig bis",
|
||||
"apply-updates-default": {
|
||||
"heading": "",
|
||||
"description": ""
|
||||
}
|
||||
},
|
||||
"save": "Dossier-Vorlage speichern",
|
||||
"title": "{type, select, edit{Dossier-Vorlage {name} bearbeiten} create{Dossier-Vorlage erstellen} clone{} other{}}"
|
||||
|
||||
@ -61,7 +61,11 @@
|
||||
"title": "Keep overlapping elements"
|
||||
},
|
||||
"valid-from": "Valid from",
|
||||
"valid-to": "Valid to"
|
||||
"valid-to": "Valid to",
|
||||
"apply-updates-default": {
|
||||
"heading": "Entity configuration",
|
||||
"description": "Apply dictionary updates to all dossiers by default"
|
||||
}
|
||||
},
|
||||
"save": "Save Dossier Template",
|
||||
"title": "{type, select, edit{Edit {name}} create{Create} clone{Clone} other{}} Dossier Template"
|
||||
|
||||
@ -23,7 +23,7 @@ AVAILABLE_OLD_NOTIFICATIONS_MINUTES="${AVAILABLE_OLD_NOTIFICATIONS_MINUTES:-60}"
|
||||
NOTIFICATIONS_THRESHOLD="${NOTIFICATIONS_THRESHOLD:-1000}"
|
||||
BASE_TRANSLATIONS_DIRECTORY="${BASE_TRANSLATIONS_DIRECTORY:-/assets/i18n/redact/}"
|
||||
THEME="${THEME:-theme-template}"
|
||||
WATERMARK_PREVIEW_PAPER_FORMAT="${WATERMARK_PREVIEW_PAPER_FORMAT:a4}"
|
||||
WATERMARK_PREVIEW_PAPER_FORMAT="${WATERMARK_PREVIEW_PAPER_FORMAT:-a4}"
|
||||
|
||||
|
||||
|
||||
@ -50,7 +50,7 @@ echo '{
|
||||
"AVAILABLE_NOTIFICATIONS_DAYS":"'"$AVAILABLE_NOTIFICATIONS_DAYS"'",
|
||||
"AVAILABLE_OLD_NOTIFICATIONS_MINUTES":"'"$AVAILABLE_OLD_NOTIFICATIONS_MINUTES"'",
|
||||
"NOTIFICATIONS_THRESHOLD":"'"$NOTIFICATIONS_THRESHOLD"'",
|
||||
"WATERMARK_PREVIEW_PAPER_FORMAT":"'"$WATERMARK_PREVIEW_PAPER_FORMAT"'",
|
||||
"WATERMARK_PREVIEW_PAPER_FORMAT":"'"$WATERMARK_PREVIEW_PAPER_FORMAT"'"
|
||||
}' > /usr/share/nginx/html/ui/assets/config/config.json
|
||||
|
||||
echo 'Env variables: '
|
||||
|
||||
@ -19,6 +19,7 @@ export class DossierTemplate implements IDossierTemplate, IListable {
|
||||
readonly keepHiddenText: boolean;
|
||||
readonly keepImageMetadata: boolean;
|
||||
readonly keepOverlappingObjects: boolean;
|
||||
readonly applyDictionaryUpdatesToAllDossiersByDefault: boolean;
|
||||
|
||||
constructor(dossierTemplate: IDossierTemplate) {
|
||||
this.createdBy = dossierTemplate.createdBy;
|
||||
@ -36,6 +37,7 @@ export class DossierTemplate implements IDossierTemplate, IListable {
|
||||
this.keepHiddenText = dossierTemplate.keepHiddenText;
|
||||
this.keepImageMetadata = dossierTemplate.keepImageMetadata;
|
||||
this.keepOverlappingObjects = dossierTemplate.keepOverlappingObjects;
|
||||
this.applyDictionaryUpdatesToAllDossiersByDefault = dossierTemplate.applyDictionaryUpdatesToAllDossiersByDefault;
|
||||
}
|
||||
|
||||
get isActive(): boolean {
|
||||
|
||||
@ -60,4 +60,5 @@ export interface IDossierTemplate {
|
||||
* Overlapping elements in the document can potentially contain hidden sensitive information
|
||||
*/
|
||||
readonly keepOverlappingObjects: boolean;
|
||||
readonly applyDictionaryUpdatesToAllDossiersByDefault: boolean;
|
||||
}
|
||||
|
||||
@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "redaction",
|
||||
"version": "4.128.0",
|
||||
"version": "4.129.0",
|
||||
"private": true,
|
||||
"license": "MIT",
|
||||
"scripts": {
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user