Merge branch 'RED-7067' into 'master'
RED-7067, keep disabled state in case initial processing finishes before ocr queue Closes RED-7067 See merge request redactmanager/red-ui!73
This commit is contained in:
commit
51ccc63d34
@ -1,10 +1,10 @@
|
||||
<ng-container *ngIf="componentContext$ | async as ctx">
|
||||
<div>
|
||||
<div
|
||||
[class.error]="file.isError"
|
||||
[class.initial-processing]="file.isInitialProcessing"
|
||||
[matTooltip]="file.filename"
|
||||
[attr.help-mode-key]="'document_in_editor'"
|
||||
[class.error]="file.isError"
|
||||
[class.initial-processing]="file.isInitialProcessing || (ctx.ocrByDefault && !file.lastOCRTime)"
|
||||
[matTooltip]="file.filename"
|
||||
class="table-item-title"
|
||||
matTooltipPosition="above"
|
||||
>
|
||||
|
||||
@ -4,6 +4,7 @@ import { FileAttributes } from '@red/domain';
|
||||
import { FileAttributesService } from '@services/entity-services/file-attributes.service';
|
||||
import { combineLatest, map, ReplaySubject } from 'rxjs';
|
||||
import { ContextComponent } from '@iqser/common-ui/lib/utils';
|
||||
import { DossierTemplatesService } from '@services/dossier-templates/dossier-templates.service';
|
||||
|
||||
interface PartialFile {
|
||||
readonly isError: boolean;
|
||||
@ -18,6 +19,7 @@ interface PartialFile {
|
||||
|
||||
interface FileNameColumnContext {
|
||||
primaryAttribute: string;
|
||||
ocrByDefault: boolean;
|
||||
}
|
||||
|
||||
@Component({
|
||||
@ -27,13 +29,14 @@ interface FileNameColumnContext {
|
||||
changeDetection: ChangeDetectionStrategy.OnPush,
|
||||
})
|
||||
export class FileNameColumnComponent extends ContextComponent<FileNameColumnContext> implements OnInit, OnChanges {
|
||||
readonly #reloadAttribute = new ReplaySubject<void>(1);
|
||||
@Input() file: PartialFile;
|
||||
@Input() dossierTemplateId: string;
|
||||
readonly #reloadAttribute = new ReplaySubject<void>(1);
|
||||
|
||||
constructor(
|
||||
private readonly _fileAttributeService: FileAttributesService,
|
||||
private readonly _primaryFileAttributeService: PrimaryFileAttributeService,
|
||||
private readonly _dossierTemplateService: DossierTemplatesService,
|
||||
) {
|
||||
super();
|
||||
}
|
||||
@ -42,8 +45,10 @@ export class FileNameColumnComponent extends ContextComponent<FileNameColumnCont
|
||||
const primaryAttribute$ = combineLatest([this._fileAttributeService.fileAttributesConfig$, this.#reloadAttribute]).pipe(
|
||||
map(() => this._primaryFileAttributeService.getPrimaryFileAttributeValue(this.file, this.dossierTemplateId)),
|
||||
);
|
||||
const ocrByDefault$ = this._dossierTemplateService.get(this.dossierTemplateId).pipe(map(template => template.ocrByDefault));
|
||||
super._initContext({
|
||||
primaryAttribute: primaryAttribute$,
|
||||
ocrByDefault: ocrByDefault$,
|
||||
});
|
||||
}
|
||||
|
||||
|
||||
@ -3,7 +3,7 @@
|
||||
"ADMIN_CONTACT_URL": null,
|
||||
"API_URL": "https://dan.iqser.cloud",
|
||||
"APP_NAME": "RedactManager",
|
||||
"IS_DOCUMINE": true,
|
||||
"IS_DOCUMINE": false,
|
||||
"RULE_EDITOR_DEV_ONLY": false,
|
||||
"AUTO_READ_TIME": 3,
|
||||
"BACKEND_APP_VERSION": "4.4.40",
|
||||
@ -18,8 +18,8 @@
|
||||
"SELECTION_MODE": "structural",
|
||||
"MANUAL_BASE_URL": "https://docs.redactmanager.com/preview",
|
||||
"ANNOTATIONS_THRESHOLD": 1000,
|
||||
"THEME": "scm",
|
||||
"BASE_TRANSLATIONS_DIRECTORY": "/assets/i18n/scm/",
|
||||
"THEME": "redact",
|
||||
"BASE_TRANSLATIONS_DIRECTORY": "/assets/i18n/redact/",
|
||||
"AVAILABLE_NOTIFICATIONS_DAYS": 30,
|
||||
"AVAILABLE_OLD_NOTIFICATIONS_MINUTES": 60,
|
||||
"NOTIFICATIONS_THRESHOLD": 1000,
|
||||
|
||||
@ -234,6 +234,7 @@
|
||||
},
|
||||
"admin-side-nav": {
|
||||
"audit": "Audit",
|
||||
"component-rule-editor": "",
|
||||
"configurations": "Configurations",
|
||||
"default-colors": "Default Colors",
|
||||
"dictionary": "Dictionary",
|
||||
@ -557,6 +558,19 @@
|
||||
"title": "Aktion bestätigen"
|
||||
}
|
||||
},
|
||||
"component-rules-screen": {
|
||||
"error": {
|
||||
"generic": ""
|
||||
},
|
||||
"errors-found": "",
|
||||
"revert-changes": "",
|
||||
"save-changes": "",
|
||||
"success": {
|
||||
"generic": ""
|
||||
},
|
||||
"title": "",
|
||||
"warning-text": ""
|
||||
},
|
||||
"configurations": "Einstellungen",
|
||||
"confirm-archive-dossier": {
|
||||
"archive": "Archive Dossier",
|
||||
@ -1237,7 +1251,8 @@
|
||||
"reason": "Reason",
|
||||
"redacted-text": "Redacted text",
|
||||
"section": "Paragraph / Location",
|
||||
"type": "Type"
|
||||
"type": "Type",
|
||||
"unchanged": "Unchanged"
|
||||
},
|
||||
"title": "Edit {type, select, image{Image} hint{Hint} other{Redaction}}"
|
||||
}
|
||||
@ -1732,7 +1747,7 @@
|
||||
"unused": "Unused Storage"
|
||||
},
|
||||
"capacity-details": "Capacity Details",
|
||||
"copyright-claim-text": "Copyright © 2020 - {currentYear} knecon AG (powered by IQSER)",
|
||||
"copyright-claim-text": "Copyright © 2020 - {currentYear} knecon",
|
||||
"copyright-claim-title": "Copyright",
|
||||
"current-analyzed-pages": "In aktuellem Lizenzzeitraum analysierte Seiten",
|
||||
"current-volume-analyzed": "Data Volume Analyzed in Licensing Period",
|
||||
@ -2021,22 +2036,29 @@
|
||||
"content": {
|
||||
"comment": "Comment",
|
||||
"comment-placeholder": "Add remarks or mentions ...",
|
||||
"list-item": "",
|
||||
"list-item-false-positive": "",
|
||||
"options": {
|
||||
"false-positive": {
|
||||
"description": "\"{value}\" is not a \"{type}\" in this context: \"{context}\".",
|
||||
"description-bulk": "",
|
||||
"label": "False positive"
|
||||
},
|
||||
"in-dossier": {
|
||||
"description": "Do not annotate \"{value}\" as \"{type}\" in any dossier.",
|
||||
"label": "No longer annotate as \"{type}\""
|
||||
"description-bulk": "",
|
||||
"label": "No longer annotate as \"{type}\"",
|
||||
"label-bulk": ""
|
||||
},
|
||||
"only-here": {
|
||||
"description": "Do not annotate \"{value}\" at this position in the current document.",
|
||||
"description-bulk": "",
|
||||
"label": "Remove here"
|
||||
}
|
||||
}
|
||||
},
|
||||
"redacted-text": ""
|
||||
},
|
||||
"title": "Remove annotation"
|
||||
"title": "Remove {count, plural, one{annotation} other {annotations}}"
|
||||
}
|
||||
},
|
||||
"remove-redaction": {
|
||||
@ -2051,6 +2073,7 @@
|
||||
"options": {
|
||||
"do-not-recommend": {
|
||||
"description": "Do not recommend \"{value}\" as {type} in any document of the current dossier.",
|
||||
"description-bulk": "",
|
||||
"extraOptionLabel": "Apply to all dossiers",
|
||||
"label": "Remove from dossier"
|
||||
},
|
||||
@ -2212,6 +2235,7 @@
|
||||
"error": {
|
||||
"generic": "Es ist ein Fehler aufgetreten ... Die Regeln konnten nicht aktualisiert werden!"
|
||||
},
|
||||
"errors-found": "{errors, plural, one{An error} other{{errors} errors}} found in rules",
|
||||
"revert-changes": "Anmeldedaten speichern",
|
||||
"save-changes": "Änderungen speichern",
|
||||
"success": {
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user