diff --git a/apps/red-ui/src/app/models/file/annotation.wrapper.ts b/apps/red-ui/src/app/models/file/annotation.wrapper.ts index 9d5a99980..742bb6e96 100644 --- a/apps/red-ui/src/app/models/file/annotation.wrapper.ts +++ b/apps/red-ui/src/app/models/file/annotation.wrapper.ts @@ -299,11 +299,6 @@ export class AnnotationWrapper implements Record { } private static _setSuperType(annotationWrapper: AnnotationWrapper, redactionLogEntryWrapper: RedactionLogEntry) { - if (redactionLogEntryWrapper.recommendation && !redactionLogEntryWrapper.redacted) { - annotationWrapper.superType = SuperTypes.Recommendation; - return; - } - if (redactionLogEntryWrapper.manualChanges?.length) { const lastManualChange = redactionLogEntryWrapper.manualChanges[redactionLogEntryWrapper.manualChanges.length - 1]; diff --git a/apps/red-ui/src/app/modules/file-preview/services/file-data.service.ts b/apps/red-ui/src/app/modules/file-preview/services/file-data.service.ts index 92df9d108..cc01efc4d 100644 --- a/apps/red-ui/src/app/modules/file-preview/services/file-data.service.ts +++ b/apps/red-ui/src/app/modules/file-preview/services/file-data.service.ts @@ -28,6 +28,7 @@ import { ViewModeService } from './view-mode.service'; import { Core } from '@pdftron/webviewer'; import { Router } from '@angular/router'; import dayjs from 'dayjs'; +import { NGXLogger } from 'ngx-logger'; import Annotation = Core.Annotations.Annotation; const DELTA_VIEW_TIME = 10 * 60 * 1000; // 10 minutes; @@ -56,6 +57,7 @@ export class FileDataService { private readonly _textHighlightsService: TextHighlightService, private readonly _toaster: Toaster, private readonly _router: Router, + private readonly _logger: NGXLogger, ) { this.annotations$ = this.#annotations$; this.visibleAnnotations$ = this._viewModeService.viewMode$.pipe( @@ -107,6 +109,8 @@ export class FileDataService { return; } + this._logger.debug('[ANNOTATIONS] Load annotations'); + await this.loadViewedPages(file); await this.loadRedactionLog(); } diff --git a/apps/red-ui/src/app/services/entity-services/files.service.ts b/apps/red-ui/src/app/services/entity-services/files.service.ts index 06685575a..f3c1da6b0 100644 --- a/apps/red-ui/src/app/services/entity-services/files.service.ts +++ b/apps/red-ui/src/app/services/entity-services/files.service.ts @@ -6,6 +6,7 @@ import { UserService } from '../user.service'; import { FilesMapService } from '@services/entity-services/files-map.service'; import { map, mapTo, switchMap, tap } from 'rxjs/operators'; import { DossierStatsService } from '@services/dossiers/dossier-stats.service'; +import { NGXLogger } from 'ngx-logger'; @Injectable({ providedIn: 'root', @@ -13,6 +14,7 @@ import { DossierStatsService } from '@services/dossiers/dossier-stats.service'; export class FilesService extends EntitiesService { constructor( protected readonly _injector: Injector, + protected readonly _logger: NGXLogger, private readonly _userService: UserService, private readonly _filesMapService: FilesMapService, private readonly _dossierStatsService: DossierStatsService, @@ -34,6 +36,7 @@ export class FilesService extends EntitiesService { map(_file => new File(_file, this._userService.getNameForId(_file.assignee), file.routerPath)), switchMap(_file => this._dossierStatsService.getFor([dossierId]).pipe(mapTo(_file))), map(_file => this._filesMapService.replace([_file])), + tap(() => this._logger.debug('[FILE] Loaded')), ); }