From 25954c6ad408534ce47ef160f4a57a734422e864 Mon Sep 17 00:00:00 2001 From: Valentin Mihai Date: Tue, 20 Feb 2024 14:54:51 +0200 Subject: [PATCH 1/6] Integrate "user has no roles" message in sign-in page --- apps/red-ui/src/app/app-routing.module.ts | 6 - apps/red-ui/src/app/app.module.ts | 2 - .../auth-error/auth-error.component.html | 19 --- .../auth-error/auth-error.component.scss | 3 - .../auth-error/auth-error.component.ts | 17 -- .../src/app/models/file/annotation.wrapper.ts | 1 - .../select-tenant-translations.ts | 6 + apps/red-ui/src/assets/i18n/redact/de.json | 156 +++++++++--------- apps/red-ui/src/assets/i18n/redact/en.json | 10 +- apps/red-ui/src/assets/i18n/scm/de.json | 156 +++++++++--------- apps/red-ui/src/assets/i18n/scm/en.json | 10 +- libs/common-ui | 2 +- 12 files changed, 161 insertions(+), 227 deletions(-) delete mode 100644 apps/red-ui/src/app/components/auth-error/auth-error.component.html delete mode 100644 apps/red-ui/src/app/components/auth-error/auth-error.component.scss delete mode 100644 apps/red-ui/src/app/components/auth-error/auth-error.component.ts create mode 100644 apps/red-ui/src/app/translations/select-tenant-translations.ts diff --git a/apps/red-ui/src/app/app-routing.module.ts b/apps/red-ui/src/app/app-routing.module.ts index 48b8cd5be..f7006e19f 100644 --- a/apps/red-ui/src/app/app-routing.module.ts +++ b/apps/red-ui/src/app/app-routing.module.ts @@ -1,7 +1,6 @@ import { NgModule } from '@angular/core'; import { RouteReuseStrategy, RouterModule } from '@angular/router'; import { ifNotLoggedIn } from '@common-ui/tenants/guards/if-not-logged-in.guard'; -import { AuthErrorComponent } from '@components/auth-error/auth-error.component'; import { BaseScreenComponent } from '@components/base-screen/base-screen.component'; import { DownloadsListScreenComponent } from '@components/downloads-list-screen/downloads-list-screen.component'; import { DashboardGuard } from '@guards/dashboard-guard.service'; @@ -210,11 +209,6 @@ const routes: IqserRoutes = [ component: BaseScreenComponent, children: mainRoutes, }, - { - path: 'auth-error', - component: AuthErrorComponent, - canActivate: [doesNotHaveAnyRole()], - }, { path: '**', redirectTo: 'main', diff --git a/apps/red-ui/src/app/app.module.ts b/apps/red-ui/src/app/app.module.ts index b08d1384a..80b09e331 100644 --- a/apps/red-ui/src/app/app.module.ts +++ b/apps/red-ui/src/app/app.module.ts @@ -7,7 +7,6 @@ import { BrowserModule } from '@angular/platform-browser'; import { BrowserAnimationsModule } from '@angular/platform-browser/animations'; import { ServiceWorkerModule } from '@angular/service-worker'; import { GET_TENANT_FROM_PATH_FN, UI_ROOT } from '@common-ui/utils'; -import { AuthErrorComponent } from '@components/auth-error/auth-error.component'; import { BaseScreenComponent } from '@components/base-screen/base-screen.component'; import { BreadcrumbsComponent } from '@components/breadcrumbs/breadcrumbs.component'; import { DownloadsListScreenComponent } from '@components/downloads-list-screen/downloads-list-screen.component'; @@ -74,7 +73,6 @@ export const appModuleFactory = (config: AppConfig) => { @NgModule({ declarations: [ AppComponent, - AuthErrorComponent, NotificationsComponent, SpotlightSearchComponent, BreadcrumbsComponent, diff --git a/apps/red-ui/src/app/components/auth-error/auth-error.component.html b/apps/red-ui/src/app/components/auth-error/auth-error.component.html deleted file mode 100644 index 14f120f55..000000000 --- a/apps/red-ui/src/app/components/auth-error/auth-error.component.html +++ /dev/null @@ -1,19 +0,0 @@ -
-

-

-

-

- -
diff --git a/apps/red-ui/src/app/components/auth-error/auth-error.component.scss b/apps/red-ui/src/app/components/auth-error/auth-error.component.scss deleted file mode 100644 index 427b131fa..000000000 --- a/apps/red-ui/src/app/components/auth-error/auth-error.component.scss +++ /dev/null @@ -1,3 +0,0 @@ -section { - padding: 24px; -} diff --git a/apps/red-ui/src/app/components/auth-error/auth-error.component.ts b/apps/red-ui/src/app/components/auth-error/auth-error.component.ts deleted file mode 100644 index 5445ec196..000000000 --- a/apps/red-ui/src/app/components/auth-error/auth-error.component.ts +++ /dev/null @@ -1,17 +0,0 @@ -import { Component } from '@angular/core'; -import { UserService } from '@users/user.service'; -import { getConfig } from '@iqser/common-ui'; -import { AppConfig } from '@red/domain'; - -@Component({ - selector: 'redaction-auth-error', - templateUrl: './auth-error.component.html', - styleUrls: ['./auth-error.component.scss'], -}) -export class AuthErrorComponent { - readonly #config = getConfig(); - readonly adminName = this.#config.ADMIN_CONTACT_NAME; - readonly adminUrl = this.#config.ADMIN_CONTACT_URL; - - constructor(readonly userService: UserService) {} -} 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 00eab80cd..f6ebdd5f3 100644 --- a/apps/red-ui/src/app/models/file/annotation.wrapper.ts +++ b/apps/red-ui/src/app/models/file/annotation.wrapper.ts @@ -25,7 +25,6 @@ import { SuperTypes, } from '@red/domain'; import { annotationTypesTranslations } from '@translations/annotation-types-translations'; -import { log } from '@common-ui/utils'; export class AnnotationWrapper implements IListable { id: string; diff --git a/apps/red-ui/src/app/translations/select-tenant-translations.ts b/apps/red-ui/src/app/translations/select-tenant-translations.ts new file mode 100644 index 000000000..506b30535 --- /dev/null +++ b/apps/red-ui/src/app/translations/select-tenant-translations.ts @@ -0,0 +1,6 @@ +import { marker as _ } from '@biesbjerg/ngx-translate-extract-marker'; + +export const selectTenantTranslations: { [key in string]: string } = { + IS_LOGGED_OUT: _('tenant-resolve.header.youre-logged-out'), + NO_ROLE_LOG_OUT: _('tenant-resolve.header.no-role-log-out'), +} as const; diff --git a/apps/red-ui/src/assets/i18n/redact/de.json b/apps/red-ui/src/assets/i18n/redact/de.json index 41ec0f493..dd9480b13 100644 --- a/apps/red-ui/src/assets/i18n/redact/de.json +++ b/apps/red-ui/src/assets/i18n/redact/de.json @@ -255,9 +255,6 @@ "watermarks": "Watermarks" }, "analysis-disabled": "", - "annotation": { - "pending": "(Pending analysis)" - }, "annotation-actions": { "accept-recommendation": { "label": "Empfehlung annehmen" @@ -316,14 +313,14 @@ "error": "Rekategorisierung des Bildes gescheitert: {error}", "success": "Bild wurde einer neuen Kategorie zugeordnet." }, - "remove": { - "error": "Fehler beim Entfernen der Schwärzung: {error}", - "success": "Schwärzung entfernt!" - }, "remove-hint": { "error": "Failed to remove hint: {error}", "success": "Hint removed!" }, + "remove": { + "error": "Fehler beim Entfernen der Schwärzung: {error}", + "success": "Schwärzung entfernt!" + }, "undo": { "error": "Die Aktion konnte nicht rückgängig gemacht werden. Fehler: {error}", "success": "erfolgreich Rückgängig gemacht" @@ -336,15 +333,15 @@ "remove-highlights": { "label": "Remove selected earmarks" }, - "resize": { - "label": "Größe ändern" - }, "resize-accept": { "label": "Größe speichern" }, "resize-cancel": { "label": "Größenänderung abbrechen" }, + "resize": { + "label": "Größe ändern" + }, "see-references": { "label": "See references" }, @@ -376,6 +373,9 @@ "skipped": "Übersprungen", "text-highlight": "Earmark" }, + "annotation": { + "pending": "(Pending analysis)" + }, "archived-dossiers-listing": { "no-data": { "title": "No archived dossiers." @@ -458,13 +458,6 @@ }, "to": "bis" }, - "auth-error": { - "heading": "Ihr Benutzer verfügt nicht über die erforderlichen RED-*-Rollen, um auf diese Applikation zugreifen zu können. Bitte kontaktieren Sie Ihren Admin, um den Zugang anzufordern!", - "heading-with-link": "Ihr Benutzer verfügt nicht über die erforderlichen RED-*-Rollen, um auf diese Applikation zugreifen zu können. Bitte kontaktieren Sie Ihren Admin, um den Zugang anzufordern!", - "heading-with-name": "Ihr Benutzer verfügt nicht über die erforderlichen RED-*-Rollen, um auf diese Applikation zugreifen zu können. Bitte kontaktieren Sie {adminName}, um den Zugang anzufordern!", - "heading-with-name-and-link": "Ihr Benutzer verfügt nicht über die erforderlichen RED-*-Rollen, um auf diese Applikation zugreifen zu können. Bitte kontaktieren Sie {adminName}, um den Zugang anzufordern!", - "logout": "Ausloggen" - }, "change-legal-basis-dialog": { "actions": { "cancel": "Abbrechen", @@ -581,18 +574,14 @@ "warning": "Achtung: Diese Aktion kann nicht rückgängig gemacht werden!" }, "confirmation-dialog": { - "approve-file": { - "question": "Dieses Dokument enthält ungesehene Änderungen. Möchten Sie es trotzdem genehmigen?", - "title": "Warnung!" - }, "approve-file-without-analysis": { "confirmationText": "Approve without analysis", "denyText": "Cancel", "question": "Analysis required to detect new redactions.", "title": "Warning!" }, - "approve-multiple-files": { - "question": "Mindestens eine der ausgewählten Dateien enthält ungesehene Änderungen. Möchten Sie sie trotzdem genehmigen?", + "approve-file": { + "question": "Dieses Dokument enthält ungesehene Änderungen. Möchten Sie es trotzdem genehmigen?", "title": "Warnung!" }, "approve-multiple-files-without-analysis": { @@ -601,6 +590,10 @@ "question": "Analysis required to detect new redactions for at least one file.", "title": "Warning" }, + "approve-multiple-files": { + "question": "Mindestens eine der ausgewählten Dateien enthält ungesehene Änderungen. Möchten Sie sie trotzdem genehmigen?", + "title": "Warnung!" + }, "assign-file-to-me": { "question": { "multiple": "Dieses Dokument wird gerade von einer anderen Person geprüft. Möchten Sie Reviewer werden und sich selbst dem Dokument zuweisen?", @@ -945,13 +938,13 @@ "recent": "Neu ({hours} h)", "unassigned": "Niemandem zugewiesen" }, - "reanalyse": { - "action": "Datei analysieren" - }, "reanalyse-dossier": { "error": "Die Dateien konnten nicht für eine Reanalyse eingeplant werden. Bitte versuchen Sie es erneut.", "success": "Dateien für Reanalyse vorgesehen." }, + "reanalyse": { + "action": "Datei analysieren" + }, "start-auto-analysis": "Enable auto-analysis", "stop-auto-analysis": "Stop auto-analysis", "table-col-names": { @@ -1020,14 +1013,6 @@ "total-documents": "Anzahl der Dokumente", "total-people": "{count} {count, plural, one{user} other {users}}" }, - "dossier-templates": { - "label": "Dossier-Vorlagen", - "status": { - "active": "Active", - "inactive": "Inactive", - "incomplete": "Incomplete" - } - }, "dossier-templates-listing": { "action": { "clone": "Clone template", @@ -1063,6 +1048,14 @@ "title": "{length} {length, plural, one{Dossier-Vorlage} other{Dossier-Vorlagen}}" } }, + "dossier-templates": { + "label": "Dossier-Vorlagen", + "status": { + "active": "Active", + "inactive": "Inactive", + "incomplete": "Incomplete" + } + }, "dossier-watermark-selector": { "heading": "Watermarks on documents", "no-watermark": "There is no watermark defined for the dossier template.
Contact your app admin to define one.", @@ -1248,15 +1241,6 @@ "title": "{length} {length, plural, one{Wörterbuch} other{Wörterbücher}}" } }, - "entity": { - "info": { - "actions": { - "revert": "Revert", - "save": "Save changes" - }, - "heading": "Edit entity" - } - }, "entity-rules-screen": { "error": { "generic": "Something went wrong... Entity rules update failed!" @@ -1270,19 +1254,28 @@ "title": "Entity rule editor", "warning-text": "Warning: experimental feature!" }, + "entity": { + "info": { + "actions": { + "revert": "Revert", + "save": "Save changes" + }, + "heading": "Edit entity" + } + }, "error": { "deleted-entity": { "dossier": { "action": "Zurück zur Übersicht", "label": "Dieses Dossier wurde gelöscht!" }, - "file": { - "action": "Zurück zum Dossier", - "label": "Diese Datei wurde gelöscht!" - }, "file-dossier": { "action": "Zurück zur Übersicht", "label": "Das Dossier dieser Datei wurde gelöscht!" + }, + "file": { + "action": "Zurück zum Dossier", + "label": "Diese Datei wurde gelöscht!" } }, "file-preview": { @@ -1300,12 +1293,6 @@ }, "exact-date": "{day} {month} {year} um {hour}:{minute} Uhr", "file": "Datei", - "file-attribute": { - "update": { - "error": "Failed to update file attribute value!", - "success": "File attribute value has been updated successfully!" - } - }, "file-attribute-encoding-types": { "ascii": "ASCII", "iso": "ISO-8859-1", @@ -1316,6 +1303,12 @@ "number": "Nummer", "text": "Freier Text" }, + "file-attribute": { + "update": { + "error": "Failed to update file attribute value!", + "success": "File attribute value has been updated successfully!" + } + }, "file-attributes-configurations": { "cancel": "Cancel", "form": { @@ -1531,15 +1524,6 @@ "csv": "File attributes were imported successfully from uploaded CSV file." } }, - "filter": { - "analysis": "Analyse erforderlich", - "comment": "Kommentare", - "hint": "Nut Hinweise", - "image": "Bilder", - "none": "Keine Anmerkungen", - "redaction": "Geschwärzt", - "updated": "Aktualisiert" - }, "filter-menu": { "filter-options": "Filteroptionen", "filter-types": "Filter", @@ -1549,6 +1533,15 @@ "unseen-pages": "Nur Anmerkungen auf unsichtbaren Seiten", "with-comments": "Nur Anmerkungen mit Kommentaren" }, + "filter": { + "analysis": "Analyse erforderlich", + "comment": "Kommentare", + "hint": "Nut Hinweise", + "image": "Bilder", + "none": "Keine Anmerkungen", + "redaction": "Geschwärzt", + "updated": "Aktualisiert" + }, "filters": { "assigned-people": "Beauftragt", "documents-status": "Documents state", @@ -1819,13 +1812,6 @@ "user-promoted-to-approver": "{user} wurde im Dossier {dossierHref, select, null{{dossierName}} other{{dossierName}}} zum Genehmiger ernannt!", "user-removed-as-dossier-member": "{user} wurde als Mitglied von: {dossierHref, select, null{{dossierName}} other{{dossierName}}} entfernt!" }, - "notifications": { - "button-text": "Notifications", - "deleted-dossier": "Deleted dossier", - "label": "Benachrichtigungen", - "mark-all-as-read": "Alle als gelesen markieren", - "mark-as": "Mark as {type, select, read{read} unread{unread} other{}}" - }, "notifications-screen": { "category": { "email-notifications": "E-Mail Benachrichtigungen", @@ -1839,6 +1825,7 @@ "dossier": "Dossierbezogene Benachrichtigungen", "other": "Andere Benachrichtigungen" }, + "options-title": "Wählen Sie aus, in welcher Kategorie Sie benachrichtigt werden möchten", "options": { "ASSIGN_APPROVER": "Wenn ich einem Dokument als Genehmiger zugewiesen bin", "ASSIGN_REVIEWER": "Wenn ich einem Dokument als Überprüfer zugewiesen bin", @@ -1856,7 +1843,6 @@ "USER_PROMOTED_TO_APPROVER": "Wenn ich Genehmiger in einem Dossier werde", "USER_REMOVED_AS_DOSSIER_MEMBER": "Wenn ich die Dossier-Mitgliedschaft verliere" }, - "options-title": "Wählen Sie aus, in welcher Kategorie Sie benachrichtigt werden möchten", "schedule": { "daily": "Tägliche Zusammenfassung", "instant": "Sofortig", @@ -1864,6 +1850,13 @@ }, "title": "Benachrichtigungseinstellungen" }, + "notifications": { + "button-text": "Notifications", + "deleted-dossier": "Deleted dossier", + "label": "Benachrichtigungen", + "mark-all-as-read": "Alle als gelesen markieren", + "mark-as": "Mark as {type, select, read{read} unread{unread} other{}}" + }, "ocr": { "confirmation-dialog": { "cancel": "Cancel", @@ -1955,16 +1948,16 @@ "warnings-subtitle": "Do not show again options", "warnings-title": "Prompts and dialogs settings" }, - "processing": { - "basic": "Processing", - "ocr": "OCR" - }, "processing-status": { "ocr": "OCR", "pending": "Pending", "processed": "Processed", "processing": "Processing" }, + "processing": { + "basic": "Processing", + "ocr": "OCR" + }, "readonly": "Lesemodus", "readonly-archived": "Read only (archived)", "redact-text": { @@ -2191,12 +2184,6 @@ "red-user-admin": "Benutzer-Admin", "regular": "Regulär" }, - "search": { - "active-dossiers": "ganze Plattform", - "all-dossiers": "all documents", - "placeholder": "Nach Dokumenten oder Dokumenteninhalt suchen", - "this-dossier": "in diesem Dossier" - }, "search-screen": { "cols": { "assignee": "Bevollmächtigter", @@ -2220,6 +2207,12 @@ "no-match": "Keine Dokumente entsprechen Ihren aktuellen Filtern.", "table-header": "{length} {length, plural, one{Suchergebnis} other{Suchergebnisse}}" }, + "search": { + "active-dossiers": "ganze Plattform", + "all-dossiers": "all documents", + "placeholder": "Nach Dokumenten oder Dokumenteninhalt suchen", + "this-dossier": "in diesem Dossier" + }, "seconds": "seconds", "size": "Size", "smtp-auth-config": { @@ -2239,6 +2232,7 @@ "header": { "first-time": "Sign in for the first time to a workspace", "join-another-domain": "Or join another workspace", + "no-role-log-out": "", "sign-in-previous-domain": "Sign in to a previously used workspace", "youre-logged-out": "You have successfully been logged out." }, @@ -2470,4 +2464,4 @@ } }, "yesterday": "Gestern" -} \ No newline at end of file +} diff --git a/apps/red-ui/src/assets/i18n/redact/en.json b/apps/red-ui/src/assets/i18n/redact/en.json index 493f3d8b5..347617180 100644 --- a/apps/red-ui/src/assets/i18n/redact/en.json +++ b/apps/red-ui/src/assets/i18n/redact/en.json @@ -458,13 +458,6 @@ }, "to": "to" }, - "auth-error": { - "heading": "Your user is successfully logged in but has no role assigned yet. Please contact your RedactManager administrator to assign appropriate roles.", - "heading-with-link": "Your user is successfully logged in but has no role assigned yet. Please contact your RedactManager administrator to assign appropriate roles!", - "heading-with-name": "Your user is successfully logged in but has no role assigned yet. Please contact {adminName} to assign appropriate roles.", - "heading-with-name-and-link": "Your user is successfully logged in but has no role assigned yet. Please contact {adminName} to assign appropriate roles.", - "logout": "Logout" - }, "change-legal-basis-dialog": { "actions": { "cancel": "Cancel", @@ -2239,6 +2232,7 @@ "header": { "first-time": "Sign in for the first time to a workspace", "join-another-domain": "Or join another workspace", + "no-role-log-out": "User role missing. Please ask your administrator to assign roles before logging in again.", "sign-in-previous-domain": "Sign in to a previously used workspace", "youre-logged-out": "You have successfully been logged out." }, @@ -2470,4 +2464,4 @@ } }, "yesterday": "Yesterday" -} \ No newline at end of file +} diff --git a/apps/red-ui/src/assets/i18n/scm/de.json b/apps/red-ui/src/assets/i18n/scm/de.json index 60eb14b20..5272784ff 100644 --- a/apps/red-ui/src/assets/i18n/scm/de.json +++ b/apps/red-ui/src/assets/i18n/scm/de.json @@ -255,9 +255,6 @@ "watermarks": "Watermarks" }, "analysis-disabled": "Analysis disabled", - "annotation": { - "pending": "(Pending analysis)" - }, "annotation-actions": { "accept-recommendation": { "label": "Empfehlung annehmen" @@ -316,14 +313,14 @@ "error": "Rekategorisierung des Bildes gescheitert: {error}", "success": "Bild wurde einer neuen Kategorie zugeordnet." }, - "remove": { - "error": "Fehler beim Entfernen der Schwärzung: {error}", - "success": "Schwärzung entfernt!" - }, "remove-hint": { "error": "Failed to remove hint: {error}", "success": "Hint removed!" }, + "remove": { + "error": "Fehler beim Entfernen der Schwärzung: {error}", + "success": "Schwärzung entfernt!" + }, "undo": { "error": "Die Aktion konnte nicht rückgängig gemacht werden. Fehler: {error}", "success": "erfolgreich Rückgängig gemacht" @@ -336,15 +333,15 @@ "remove-highlights": { "label": "Remove selected earmarks" }, - "resize": { - "label": "Größe ändern" - }, "resize-accept": { "label": "Größe speichern" }, "resize-cancel": { "label": "Größenänderung abbrechen" }, + "resize": { + "label": "Größe ändern" + }, "see-references": { "label": "See references" }, @@ -376,6 +373,9 @@ "skipped": "Übersprungen", "text-highlight": "Earmark" }, + "annotation": { + "pending": "(Pending analysis)" + }, "archived-dossiers-listing": { "no-data": { "title": "No archived dossiers." @@ -458,13 +458,6 @@ }, "to": "bis" }, - "auth-error": { - "heading": "Ihr Benutzer verfügt nicht über die erforderlichen RED-*-Rollen, um auf diese Applikation zugreifen zu können. Bitte kontaktieren Sie Ihren Admin, um den Zugang anzufordern!", - "heading-with-link": "Ihr Benutzer verfügt nicht über die erforderlichen RED-*-Rollen, um auf diese Applikation zugreifen zu können. Bitte kontaktieren Sie Ihren Admin, um den Zugang anzufordern!", - "heading-with-name": "Ihr Benutzer verfügt nicht über die erforderlichen RED-*-Rollen, um auf diese Applikation zugreifen zu können. Bitte kontaktieren Sie {adminName}, um den Zugang anzufordern!", - "heading-with-name-and-link": "Ihr Benutzer verfügt nicht über die erforderlichen RED-*-Rollen, um auf diese Applikation zugreifen zu können. Bitte kontaktieren Sie {adminName}, um den Zugang anzufordern!", - "logout": "Ausloggen" - }, "change-legal-basis-dialog": { "actions": { "cancel": "Abbrechen", @@ -581,18 +574,14 @@ "warning": "Achtung: Diese Aktion kann nicht rückgängig gemacht werden!" }, "confirmation-dialog": { - "approve-file": { - "question": "Dieses Dokument enthält ungesehene Änderungen. Möchten Sie es trotzdem genehmigen?", - "title": "Warnung!" - }, "approve-file-without-analysis": { "confirmationText": "Approve without analysis", "denyText": "Cancel", "question": "Analysis required to detect new components.", "title": "Warning!" }, - "approve-multiple-files": { - "question": "Mindestens eine der ausgewählten Dateien enthält ungesehene Änderungen. Möchten Sie sie trotzdem genehmigen?", + "approve-file": { + "question": "Dieses Dokument enthält ungesehene Änderungen. Möchten Sie es trotzdem genehmigen?", "title": "Warnung!" }, "approve-multiple-files-without-analysis": { @@ -601,6 +590,10 @@ "question": "Analysis required to detect new components for at least one file.", "title": "Warning" }, + "approve-multiple-files": { + "question": "Mindestens eine der ausgewählten Dateien enthält ungesehene Änderungen. Möchten Sie sie trotzdem genehmigen?", + "title": "Warnung!" + }, "assign-file-to-me": { "question": { "multiple": "Dieses Dokument wird gerade von einer anderen Person geprüft. Möchten Sie Reviewer werden und sich selbst dem Dokument zuweisen?", @@ -945,13 +938,13 @@ "recent": "Neu ({hours} h)", "unassigned": "Niemandem zugewiesen" }, - "reanalyse": { - "action": "Datei analysieren" - }, "reanalyse-dossier": { "error": "Die Dateien konnten nicht für eine Reanalyse eingeplant werden. Bitte versuchen Sie es erneut.", "success": "Dateien für Reanalyse vorgesehen." }, + "reanalyse": { + "action": "Datei analysieren" + }, "start-auto-analysis": "Enable auto-analysis", "stop-auto-analysis": "Stop auto-analysis", "table-col-names": { @@ -1020,14 +1013,6 @@ "total-documents": "Anzahl der Dokumente", "total-people": "{count} {count, plural, one{user} other {users}}" }, - "dossier-templates": { - "label": "Dossier-Vorlagen", - "status": { - "active": "Active", - "inactive": "Inactive", - "incomplete": "Incomplete" - } - }, "dossier-templates-listing": { "action": { "clone": "Clone template", @@ -1063,6 +1048,14 @@ "title": "{length} dossier {length, plural, one{template} other{templates}}" } }, + "dossier-templates": { + "label": "Dossier-Vorlagen", + "status": { + "active": "Active", + "inactive": "Inactive", + "incomplete": "Incomplete" + } + }, "dossier-watermark-selector": { "heading": "Watermarks on documents", "no-watermark": "There is no watermark defined for the dossier template.
Contact your app admin to define one.", @@ -1248,15 +1241,6 @@ "title": "{length} {length, plural, one{entity} other{entities}}" } }, - "entity": { - "info": { - "actions": { - "revert": "Revert", - "save": "Save changes" - }, - "heading": "Edit entity" - } - }, "entity-rules-screen": { "error": { "generic": "Something went wrong... Entity rules update failed!" @@ -1270,19 +1254,28 @@ "title": "Entity rule editor", "warning-text": "Warning: experimental feature!" }, + "entity": { + "info": { + "actions": { + "revert": "Revert", + "save": "Save changes" + }, + "heading": "Edit entity" + } + }, "error": { "deleted-entity": { "dossier": { "action": "Zurück zur Übersicht", "label": "Dieses Dossier wurde gelöscht!" }, - "file": { - "action": "Zurück zum Dossier", - "label": "Diese Datei wurde gelöscht!" - }, "file-dossier": { "action": "Zurück zur Übersicht", "label": "Das Dossier dieser Datei wurde gelöscht!" + }, + "file": { + "action": "Zurück zum Dossier", + "label": "Diese Datei wurde gelöscht!" } }, "file-preview": { @@ -1300,12 +1293,6 @@ }, "exact-date": "{day} {month} {year} um {hour}:{minute} Uhr", "file": "Datei", - "file-attribute": { - "update": { - "error": "Failed to update file attribute value!", - "success": "File attribute value has been updated successfully!" - } - }, "file-attribute-encoding-types": { "ascii": "ASCII", "iso": "ISO-8859-1", @@ -1316,6 +1303,12 @@ "number": "Nummer", "text": "Freier Text" }, + "file-attribute": { + "update": { + "error": "Failed to update file attribute value!", + "success": "File attribute value has been updated successfully!" + } + }, "file-attributes-configurations": { "cancel": "Cancel", "form": { @@ -1531,15 +1524,6 @@ "csv": "File attributes were imported successfully from uploaded CSV file." } }, - "filter": { - "analysis": "Analyse erforderlich", - "comment": "Kommentare", - "hint": "Nut Hinweise", - "image": "Bilder", - "none": "Keine Anmerkungen", - "redaction": "Geschwärzt", - "updated": "Aktualisiert" - }, "filter-menu": { "filter-options": "Filteroptionen", "filter-types": "Filter", @@ -1549,6 +1533,15 @@ "unseen-pages": "Nur Anmerkungen auf unsichtbaren Seiten", "with-comments": "Nur Anmerkungen mit Kommentaren" }, + "filter": { + "analysis": "Analyse erforderlich", + "comment": "Kommentare", + "hint": "Nut Hinweise", + "image": "Bilder", + "none": "Keine Anmerkungen", + "redaction": "Geschwärzt", + "updated": "Aktualisiert" + }, "filters": { "assigned-people": "Beauftragt", "documents-status": "Documents state", @@ -1819,13 +1812,6 @@ "user-promoted-to-approver": "{user} wurde im Dossier {dossierHref, select, null{{dossierName}} other{{dossierName}}} zum Genehmiger ernannt!", "user-removed-as-dossier-member": "{user} wurde als Mitglied von: {dossierHref, select, null{{dossierName}} other{{dossierName}}} entfernt!" }, - "notifications": { - "button-text": "Notifications", - "deleted-dossier": "Deleted dossier", - "label": "Benachrichtigungen", - "mark-all-as-read": "Alle als gelesen markieren", - "mark-as": "Mark as {type, select, read{read} unread{unread} other{}}" - }, "notifications-screen": { "category": { "email-notifications": "E-Mail Benachrichtigungen", @@ -1839,6 +1825,7 @@ "dossier": "Dossierbezogene Benachrichtigungen", "other": "Andere Benachrichtigungen" }, + "options-title": "Wählen Sie aus, in welcher Kategorie Sie benachrichtigt werden möchten", "options": { "ASSIGN_APPROVER": "Wenn ich einem Dokument als Genehmiger zugewiesen bin", "ASSIGN_REVIEWER": "Wenn ich einem Dokument als Überprüfer zugewiesen bin", @@ -1856,7 +1843,6 @@ "USER_PROMOTED_TO_APPROVER": "Wenn ich Genehmiger in einem Dossier werde", "USER_REMOVED_AS_DOSSIER_MEMBER": "Wenn ich die Dossier-Mitgliedschaft verliere" }, - "options-title": "Wählen Sie aus, in welcher Kategorie Sie benachrichtigt werden möchten", "schedule": { "daily": "Tägliche Zusammenfassung", "instant": "Sofortig", @@ -1864,6 +1850,13 @@ }, "title": "Benachrichtigungseinstellungen" }, + "notifications": { + "button-text": "Notifications", + "deleted-dossier": "Deleted dossier", + "label": "Benachrichtigungen", + "mark-all-as-read": "Alle als gelesen markieren", + "mark-as": "Mark as {type, select, read{read} unread{unread} other{}}" + }, "ocr": { "confirmation-dialog": { "cancel": "Cancel", @@ -1955,16 +1948,16 @@ "warnings-subtitle": "Do not show again options", "warnings-title": "Prompts and dialogs settings" }, - "processing": { - "basic": "Processing", - "ocr": "OCR" - }, "processing-status": { "ocr": "OCR", "pending": "Pending", "processed": "Processed", "processing": "Processing" }, + "processing": { + "basic": "Processing", + "ocr": "OCR" + }, "readonly": "Lesemodus", "readonly-archived": "Read only (archived)", "redact-text": { @@ -2191,12 +2184,6 @@ "red-user-admin": "Benutzer-Admin", "regular": "Regulär" }, - "search": { - "active-dossiers": "ganze Plattform", - "all-dossiers": "all documents", - "placeholder": "Nach Dokumenten oder Dokumenteninhalt suchen", - "this-dossier": "in diesem Dossier" - }, "search-screen": { "cols": { "assignee": "Bevollmächtigter", @@ -2220,6 +2207,12 @@ "no-match": "Keine Dokumente entsprechen Ihren aktuellen Filtern.", "table-header": "{length} search {length, plural, one{result} other{results}}" }, + "search": { + "active-dossiers": "ganze Plattform", + "all-dossiers": "all documents", + "placeholder": "Nach Dokumenten oder Dokumenteninhalt suchen", + "this-dossier": "in diesem Dossier" + }, "seconds": "seconds", "size": "Size", "smtp-auth-config": { @@ -2239,6 +2232,7 @@ "header": { "first-time": "Sign in for the first time to a workspace", "join-another-domain": "Or join another workspace", + "no-role-log-out": "", "sign-in-previous-domain": "Sign in to a previously used workspace", "youre-logged-out": "You have successfully been logged out." }, @@ -2470,4 +2464,4 @@ } }, "yesterday": "Gestern" -} \ No newline at end of file +} diff --git a/apps/red-ui/src/assets/i18n/scm/en.json b/apps/red-ui/src/assets/i18n/scm/en.json index 25b648744..eaac3bae8 100644 --- a/apps/red-ui/src/assets/i18n/scm/en.json +++ b/apps/red-ui/src/assets/i18n/scm/en.json @@ -458,13 +458,6 @@ }, "to": "to" }, - "auth-error": { - "heading": "Your user is successfully logged in but has no role assigned yet. Please contact your DocuMine administrator to assign appropriate roles.", - "heading-with-link": "Your user is successfully logged in but has no role assigned yet. Please contact your DocuMine administrator to assign appropriate roles!", - "heading-with-name": "Your user is successfully logged in but has no role assigned yet. Please contact {adminName} to assign appropriate roles.", - "heading-with-name-and-link": "Your user is successfully logged in but has no role assigned yet. Please contact {adminName} to assign appropriate roles.", - "logout": "Logout" - }, "change-legal-basis-dialog": { "actions": { "cancel": "Cancel", @@ -2239,6 +2232,7 @@ "header": { "first-time": "Sign in for the first time to a workspace", "join-another-domain": "Or join another workspace", + "no-role-log-out": "User role missing. Please ask your administrator to assign roles before logging in again.", "sign-in-previous-domain": "Sign in to a previously used workspace", "youre-logged-out": "You have successfully been logged out." }, @@ -2470,4 +2464,4 @@ } }, "yesterday": "Yesterday" -} \ No newline at end of file +} diff --git a/libs/common-ui b/libs/common-ui index 6f255d68b..a37287f13 160000 --- a/libs/common-ui +++ b/libs/common-ui @@ -1 +1 @@ -Subproject commit 6f255d68b49e921ff458a59056c8bad6cede4abd +Subproject commit a37287f13c708ce5a7386b4144d7db5441358883 From 8cffa7d4acbb7cbe40c7b806603d58c5deedf28a Mon Sep 17 00:00:00 2001 From: Valentin Mihai Date: Tue, 20 Feb 2024 14:54:51 +0200 Subject: [PATCH 2/6] RED-7874 - Integrate "user has no roles" message in sign-in page --- apps/red-ui/src/app/app-routing.module.ts | 6 - apps/red-ui/src/app/app.module.ts | 2 - .../auth-error/auth-error.component.html | 19 --- .../auth-error/auth-error.component.scss | 3 - .../auth-error/auth-error.component.ts | 17 -- .../src/app/models/file/annotation.wrapper.ts | 1 - .../select-tenant-translations.ts | 6 + apps/red-ui/src/assets/i18n/redact/de.json | 156 +++++++++--------- apps/red-ui/src/assets/i18n/redact/en.json | 10 +- apps/red-ui/src/assets/i18n/scm/de.json | 156 +++++++++--------- apps/red-ui/src/assets/i18n/scm/en.json | 10 +- libs/common-ui | 2 +- 12 files changed, 161 insertions(+), 227 deletions(-) delete mode 100644 apps/red-ui/src/app/components/auth-error/auth-error.component.html delete mode 100644 apps/red-ui/src/app/components/auth-error/auth-error.component.scss delete mode 100644 apps/red-ui/src/app/components/auth-error/auth-error.component.ts create mode 100644 apps/red-ui/src/app/translations/select-tenant-translations.ts diff --git a/apps/red-ui/src/app/app-routing.module.ts b/apps/red-ui/src/app/app-routing.module.ts index 48b8cd5be..f7006e19f 100644 --- a/apps/red-ui/src/app/app-routing.module.ts +++ b/apps/red-ui/src/app/app-routing.module.ts @@ -1,7 +1,6 @@ import { NgModule } from '@angular/core'; import { RouteReuseStrategy, RouterModule } from '@angular/router'; import { ifNotLoggedIn } from '@common-ui/tenants/guards/if-not-logged-in.guard'; -import { AuthErrorComponent } from '@components/auth-error/auth-error.component'; import { BaseScreenComponent } from '@components/base-screen/base-screen.component'; import { DownloadsListScreenComponent } from '@components/downloads-list-screen/downloads-list-screen.component'; import { DashboardGuard } from '@guards/dashboard-guard.service'; @@ -210,11 +209,6 @@ const routes: IqserRoutes = [ component: BaseScreenComponent, children: mainRoutes, }, - { - path: 'auth-error', - component: AuthErrorComponent, - canActivate: [doesNotHaveAnyRole()], - }, { path: '**', redirectTo: 'main', diff --git a/apps/red-ui/src/app/app.module.ts b/apps/red-ui/src/app/app.module.ts index b08d1384a..80b09e331 100644 --- a/apps/red-ui/src/app/app.module.ts +++ b/apps/red-ui/src/app/app.module.ts @@ -7,7 +7,6 @@ import { BrowserModule } from '@angular/platform-browser'; import { BrowserAnimationsModule } from '@angular/platform-browser/animations'; import { ServiceWorkerModule } from '@angular/service-worker'; import { GET_TENANT_FROM_PATH_FN, UI_ROOT } from '@common-ui/utils'; -import { AuthErrorComponent } from '@components/auth-error/auth-error.component'; import { BaseScreenComponent } from '@components/base-screen/base-screen.component'; import { BreadcrumbsComponent } from '@components/breadcrumbs/breadcrumbs.component'; import { DownloadsListScreenComponent } from '@components/downloads-list-screen/downloads-list-screen.component'; @@ -74,7 +73,6 @@ export const appModuleFactory = (config: AppConfig) => { @NgModule({ declarations: [ AppComponent, - AuthErrorComponent, NotificationsComponent, SpotlightSearchComponent, BreadcrumbsComponent, diff --git a/apps/red-ui/src/app/components/auth-error/auth-error.component.html b/apps/red-ui/src/app/components/auth-error/auth-error.component.html deleted file mode 100644 index 14f120f55..000000000 --- a/apps/red-ui/src/app/components/auth-error/auth-error.component.html +++ /dev/null @@ -1,19 +0,0 @@ -
-

-

-

-

- -
diff --git a/apps/red-ui/src/app/components/auth-error/auth-error.component.scss b/apps/red-ui/src/app/components/auth-error/auth-error.component.scss deleted file mode 100644 index 427b131fa..000000000 --- a/apps/red-ui/src/app/components/auth-error/auth-error.component.scss +++ /dev/null @@ -1,3 +0,0 @@ -section { - padding: 24px; -} diff --git a/apps/red-ui/src/app/components/auth-error/auth-error.component.ts b/apps/red-ui/src/app/components/auth-error/auth-error.component.ts deleted file mode 100644 index 5445ec196..000000000 --- a/apps/red-ui/src/app/components/auth-error/auth-error.component.ts +++ /dev/null @@ -1,17 +0,0 @@ -import { Component } from '@angular/core'; -import { UserService } from '@users/user.service'; -import { getConfig } from '@iqser/common-ui'; -import { AppConfig } from '@red/domain'; - -@Component({ - selector: 'redaction-auth-error', - templateUrl: './auth-error.component.html', - styleUrls: ['./auth-error.component.scss'], -}) -export class AuthErrorComponent { - readonly #config = getConfig(); - readonly adminName = this.#config.ADMIN_CONTACT_NAME; - readonly adminUrl = this.#config.ADMIN_CONTACT_URL; - - constructor(readonly userService: UserService) {} -} 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 00eab80cd..f6ebdd5f3 100644 --- a/apps/red-ui/src/app/models/file/annotation.wrapper.ts +++ b/apps/red-ui/src/app/models/file/annotation.wrapper.ts @@ -25,7 +25,6 @@ import { SuperTypes, } from '@red/domain'; import { annotationTypesTranslations } from '@translations/annotation-types-translations'; -import { log } from '@common-ui/utils'; export class AnnotationWrapper implements IListable { id: string; diff --git a/apps/red-ui/src/app/translations/select-tenant-translations.ts b/apps/red-ui/src/app/translations/select-tenant-translations.ts new file mode 100644 index 000000000..506b30535 --- /dev/null +++ b/apps/red-ui/src/app/translations/select-tenant-translations.ts @@ -0,0 +1,6 @@ +import { marker as _ } from '@biesbjerg/ngx-translate-extract-marker'; + +export const selectTenantTranslations: { [key in string]: string } = { + IS_LOGGED_OUT: _('tenant-resolve.header.youre-logged-out'), + NO_ROLE_LOG_OUT: _('tenant-resolve.header.no-role-log-out'), +} as const; diff --git a/apps/red-ui/src/assets/i18n/redact/de.json b/apps/red-ui/src/assets/i18n/redact/de.json index 41ec0f493..dd9480b13 100644 --- a/apps/red-ui/src/assets/i18n/redact/de.json +++ b/apps/red-ui/src/assets/i18n/redact/de.json @@ -255,9 +255,6 @@ "watermarks": "Watermarks" }, "analysis-disabled": "", - "annotation": { - "pending": "(Pending analysis)" - }, "annotation-actions": { "accept-recommendation": { "label": "Empfehlung annehmen" @@ -316,14 +313,14 @@ "error": "Rekategorisierung des Bildes gescheitert: {error}", "success": "Bild wurde einer neuen Kategorie zugeordnet." }, - "remove": { - "error": "Fehler beim Entfernen der Schwärzung: {error}", - "success": "Schwärzung entfernt!" - }, "remove-hint": { "error": "Failed to remove hint: {error}", "success": "Hint removed!" }, + "remove": { + "error": "Fehler beim Entfernen der Schwärzung: {error}", + "success": "Schwärzung entfernt!" + }, "undo": { "error": "Die Aktion konnte nicht rückgängig gemacht werden. Fehler: {error}", "success": "erfolgreich Rückgängig gemacht" @@ -336,15 +333,15 @@ "remove-highlights": { "label": "Remove selected earmarks" }, - "resize": { - "label": "Größe ändern" - }, "resize-accept": { "label": "Größe speichern" }, "resize-cancel": { "label": "Größenänderung abbrechen" }, + "resize": { + "label": "Größe ändern" + }, "see-references": { "label": "See references" }, @@ -376,6 +373,9 @@ "skipped": "Übersprungen", "text-highlight": "Earmark" }, + "annotation": { + "pending": "(Pending analysis)" + }, "archived-dossiers-listing": { "no-data": { "title": "No archived dossiers." @@ -458,13 +458,6 @@ }, "to": "bis" }, - "auth-error": { - "heading": "Ihr Benutzer verfügt nicht über die erforderlichen RED-*-Rollen, um auf diese Applikation zugreifen zu können. Bitte kontaktieren Sie Ihren Admin, um den Zugang anzufordern!", - "heading-with-link": "Ihr Benutzer verfügt nicht über die erforderlichen RED-*-Rollen, um auf diese Applikation zugreifen zu können. Bitte kontaktieren Sie Ihren Admin, um den Zugang anzufordern!", - "heading-with-name": "Ihr Benutzer verfügt nicht über die erforderlichen RED-*-Rollen, um auf diese Applikation zugreifen zu können. Bitte kontaktieren Sie {adminName}, um den Zugang anzufordern!", - "heading-with-name-and-link": "Ihr Benutzer verfügt nicht über die erforderlichen RED-*-Rollen, um auf diese Applikation zugreifen zu können. Bitte kontaktieren Sie {adminName}, um den Zugang anzufordern!", - "logout": "Ausloggen" - }, "change-legal-basis-dialog": { "actions": { "cancel": "Abbrechen", @@ -581,18 +574,14 @@ "warning": "Achtung: Diese Aktion kann nicht rückgängig gemacht werden!" }, "confirmation-dialog": { - "approve-file": { - "question": "Dieses Dokument enthält ungesehene Änderungen. Möchten Sie es trotzdem genehmigen?", - "title": "Warnung!" - }, "approve-file-without-analysis": { "confirmationText": "Approve without analysis", "denyText": "Cancel", "question": "Analysis required to detect new redactions.", "title": "Warning!" }, - "approve-multiple-files": { - "question": "Mindestens eine der ausgewählten Dateien enthält ungesehene Änderungen. Möchten Sie sie trotzdem genehmigen?", + "approve-file": { + "question": "Dieses Dokument enthält ungesehene Änderungen. Möchten Sie es trotzdem genehmigen?", "title": "Warnung!" }, "approve-multiple-files-without-analysis": { @@ -601,6 +590,10 @@ "question": "Analysis required to detect new redactions for at least one file.", "title": "Warning" }, + "approve-multiple-files": { + "question": "Mindestens eine der ausgewählten Dateien enthält ungesehene Änderungen. Möchten Sie sie trotzdem genehmigen?", + "title": "Warnung!" + }, "assign-file-to-me": { "question": { "multiple": "Dieses Dokument wird gerade von einer anderen Person geprüft. Möchten Sie Reviewer werden und sich selbst dem Dokument zuweisen?", @@ -945,13 +938,13 @@ "recent": "Neu ({hours} h)", "unassigned": "Niemandem zugewiesen" }, - "reanalyse": { - "action": "Datei analysieren" - }, "reanalyse-dossier": { "error": "Die Dateien konnten nicht für eine Reanalyse eingeplant werden. Bitte versuchen Sie es erneut.", "success": "Dateien für Reanalyse vorgesehen." }, + "reanalyse": { + "action": "Datei analysieren" + }, "start-auto-analysis": "Enable auto-analysis", "stop-auto-analysis": "Stop auto-analysis", "table-col-names": { @@ -1020,14 +1013,6 @@ "total-documents": "Anzahl der Dokumente", "total-people": "{count} {count, plural, one{user} other {users}}" }, - "dossier-templates": { - "label": "Dossier-Vorlagen", - "status": { - "active": "Active", - "inactive": "Inactive", - "incomplete": "Incomplete" - } - }, "dossier-templates-listing": { "action": { "clone": "Clone template", @@ -1063,6 +1048,14 @@ "title": "{length} {length, plural, one{Dossier-Vorlage} other{Dossier-Vorlagen}}" } }, + "dossier-templates": { + "label": "Dossier-Vorlagen", + "status": { + "active": "Active", + "inactive": "Inactive", + "incomplete": "Incomplete" + } + }, "dossier-watermark-selector": { "heading": "Watermarks on documents", "no-watermark": "There is no watermark defined for the dossier template.
Contact your app admin to define one.", @@ -1248,15 +1241,6 @@ "title": "{length} {length, plural, one{Wörterbuch} other{Wörterbücher}}" } }, - "entity": { - "info": { - "actions": { - "revert": "Revert", - "save": "Save changes" - }, - "heading": "Edit entity" - } - }, "entity-rules-screen": { "error": { "generic": "Something went wrong... Entity rules update failed!" @@ -1270,19 +1254,28 @@ "title": "Entity rule editor", "warning-text": "Warning: experimental feature!" }, + "entity": { + "info": { + "actions": { + "revert": "Revert", + "save": "Save changes" + }, + "heading": "Edit entity" + } + }, "error": { "deleted-entity": { "dossier": { "action": "Zurück zur Übersicht", "label": "Dieses Dossier wurde gelöscht!" }, - "file": { - "action": "Zurück zum Dossier", - "label": "Diese Datei wurde gelöscht!" - }, "file-dossier": { "action": "Zurück zur Übersicht", "label": "Das Dossier dieser Datei wurde gelöscht!" + }, + "file": { + "action": "Zurück zum Dossier", + "label": "Diese Datei wurde gelöscht!" } }, "file-preview": { @@ -1300,12 +1293,6 @@ }, "exact-date": "{day} {month} {year} um {hour}:{minute} Uhr", "file": "Datei", - "file-attribute": { - "update": { - "error": "Failed to update file attribute value!", - "success": "File attribute value has been updated successfully!" - } - }, "file-attribute-encoding-types": { "ascii": "ASCII", "iso": "ISO-8859-1", @@ -1316,6 +1303,12 @@ "number": "Nummer", "text": "Freier Text" }, + "file-attribute": { + "update": { + "error": "Failed to update file attribute value!", + "success": "File attribute value has been updated successfully!" + } + }, "file-attributes-configurations": { "cancel": "Cancel", "form": { @@ -1531,15 +1524,6 @@ "csv": "File attributes were imported successfully from uploaded CSV file." } }, - "filter": { - "analysis": "Analyse erforderlich", - "comment": "Kommentare", - "hint": "Nut Hinweise", - "image": "Bilder", - "none": "Keine Anmerkungen", - "redaction": "Geschwärzt", - "updated": "Aktualisiert" - }, "filter-menu": { "filter-options": "Filteroptionen", "filter-types": "Filter", @@ -1549,6 +1533,15 @@ "unseen-pages": "Nur Anmerkungen auf unsichtbaren Seiten", "with-comments": "Nur Anmerkungen mit Kommentaren" }, + "filter": { + "analysis": "Analyse erforderlich", + "comment": "Kommentare", + "hint": "Nut Hinweise", + "image": "Bilder", + "none": "Keine Anmerkungen", + "redaction": "Geschwärzt", + "updated": "Aktualisiert" + }, "filters": { "assigned-people": "Beauftragt", "documents-status": "Documents state", @@ -1819,13 +1812,6 @@ "user-promoted-to-approver": "{user} wurde im Dossier {dossierHref, select, null{{dossierName}} other{{dossierName}}} zum Genehmiger ernannt!", "user-removed-as-dossier-member": "{user} wurde als Mitglied von: {dossierHref, select, null{{dossierName}} other{{dossierName}}} entfernt!" }, - "notifications": { - "button-text": "Notifications", - "deleted-dossier": "Deleted dossier", - "label": "Benachrichtigungen", - "mark-all-as-read": "Alle als gelesen markieren", - "mark-as": "Mark as {type, select, read{read} unread{unread} other{}}" - }, "notifications-screen": { "category": { "email-notifications": "E-Mail Benachrichtigungen", @@ -1839,6 +1825,7 @@ "dossier": "Dossierbezogene Benachrichtigungen", "other": "Andere Benachrichtigungen" }, + "options-title": "Wählen Sie aus, in welcher Kategorie Sie benachrichtigt werden möchten", "options": { "ASSIGN_APPROVER": "Wenn ich einem Dokument als Genehmiger zugewiesen bin", "ASSIGN_REVIEWER": "Wenn ich einem Dokument als Überprüfer zugewiesen bin", @@ -1856,7 +1843,6 @@ "USER_PROMOTED_TO_APPROVER": "Wenn ich Genehmiger in einem Dossier werde", "USER_REMOVED_AS_DOSSIER_MEMBER": "Wenn ich die Dossier-Mitgliedschaft verliere" }, - "options-title": "Wählen Sie aus, in welcher Kategorie Sie benachrichtigt werden möchten", "schedule": { "daily": "Tägliche Zusammenfassung", "instant": "Sofortig", @@ -1864,6 +1850,13 @@ }, "title": "Benachrichtigungseinstellungen" }, + "notifications": { + "button-text": "Notifications", + "deleted-dossier": "Deleted dossier", + "label": "Benachrichtigungen", + "mark-all-as-read": "Alle als gelesen markieren", + "mark-as": "Mark as {type, select, read{read} unread{unread} other{}}" + }, "ocr": { "confirmation-dialog": { "cancel": "Cancel", @@ -1955,16 +1948,16 @@ "warnings-subtitle": "Do not show again options", "warnings-title": "Prompts and dialogs settings" }, - "processing": { - "basic": "Processing", - "ocr": "OCR" - }, "processing-status": { "ocr": "OCR", "pending": "Pending", "processed": "Processed", "processing": "Processing" }, + "processing": { + "basic": "Processing", + "ocr": "OCR" + }, "readonly": "Lesemodus", "readonly-archived": "Read only (archived)", "redact-text": { @@ -2191,12 +2184,6 @@ "red-user-admin": "Benutzer-Admin", "regular": "Regulär" }, - "search": { - "active-dossiers": "ganze Plattform", - "all-dossiers": "all documents", - "placeholder": "Nach Dokumenten oder Dokumenteninhalt suchen", - "this-dossier": "in diesem Dossier" - }, "search-screen": { "cols": { "assignee": "Bevollmächtigter", @@ -2220,6 +2207,12 @@ "no-match": "Keine Dokumente entsprechen Ihren aktuellen Filtern.", "table-header": "{length} {length, plural, one{Suchergebnis} other{Suchergebnisse}}" }, + "search": { + "active-dossiers": "ganze Plattform", + "all-dossiers": "all documents", + "placeholder": "Nach Dokumenten oder Dokumenteninhalt suchen", + "this-dossier": "in diesem Dossier" + }, "seconds": "seconds", "size": "Size", "smtp-auth-config": { @@ -2239,6 +2232,7 @@ "header": { "first-time": "Sign in for the first time to a workspace", "join-another-domain": "Or join another workspace", + "no-role-log-out": "", "sign-in-previous-domain": "Sign in to a previously used workspace", "youre-logged-out": "You have successfully been logged out." }, @@ -2470,4 +2464,4 @@ } }, "yesterday": "Gestern" -} \ No newline at end of file +} diff --git a/apps/red-ui/src/assets/i18n/redact/en.json b/apps/red-ui/src/assets/i18n/redact/en.json index 493f3d8b5..347617180 100644 --- a/apps/red-ui/src/assets/i18n/redact/en.json +++ b/apps/red-ui/src/assets/i18n/redact/en.json @@ -458,13 +458,6 @@ }, "to": "to" }, - "auth-error": { - "heading": "Your user is successfully logged in but has no role assigned yet. Please contact your RedactManager administrator to assign appropriate roles.", - "heading-with-link": "Your user is successfully logged in but has no role assigned yet. Please contact your RedactManager administrator to assign appropriate roles!", - "heading-with-name": "Your user is successfully logged in but has no role assigned yet. Please contact {adminName} to assign appropriate roles.", - "heading-with-name-and-link": "Your user is successfully logged in but has no role assigned yet. Please contact {adminName} to assign appropriate roles.", - "logout": "Logout" - }, "change-legal-basis-dialog": { "actions": { "cancel": "Cancel", @@ -2239,6 +2232,7 @@ "header": { "first-time": "Sign in for the first time to a workspace", "join-another-domain": "Or join another workspace", + "no-role-log-out": "User role missing. Please ask your administrator to assign roles before logging in again.", "sign-in-previous-domain": "Sign in to a previously used workspace", "youre-logged-out": "You have successfully been logged out." }, @@ -2470,4 +2464,4 @@ } }, "yesterday": "Yesterday" -} \ No newline at end of file +} diff --git a/apps/red-ui/src/assets/i18n/scm/de.json b/apps/red-ui/src/assets/i18n/scm/de.json index 60eb14b20..5272784ff 100644 --- a/apps/red-ui/src/assets/i18n/scm/de.json +++ b/apps/red-ui/src/assets/i18n/scm/de.json @@ -255,9 +255,6 @@ "watermarks": "Watermarks" }, "analysis-disabled": "Analysis disabled", - "annotation": { - "pending": "(Pending analysis)" - }, "annotation-actions": { "accept-recommendation": { "label": "Empfehlung annehmen" @@ -316,14 +313,14 @@ "error": "Rekategorisierung des Bildes gescheitert: {error}", "success": "Bild wurde einer neuen Kategorie zugeordnet." }, - "remove": { - "error": "Fehler beim Entfernen der Schwärzung: {error}", - "success": "Schwärzung entfernt!" - }, "remove-hint": { "error": "Failed to remove hint: {error}", "success": "Hint removed!" }, + "remove": { + "error": "Fehler beim Entfernen der Schwärzung: {error}", + "success": "Schwärzung entfernt!" + }, "undo": { "error": "Die Aktion konnte nicht rückgängig gemacht werden. Fehler: {error}", "success": "erfolgreich Rückgängig gemacht" @@ -336,15 +333,15 @@ "remove-highlights": { "label": "Remove selected earmarks" }, - "resize": { - "label": "Größe ändern" - }, "resize-accept": { "label": "Größe speichern" }, "resize-cancel": { "label": "Größenänderung abbrechen" }, + "resize": { + "label": "Größe ändern" + }, "see-references": { "label": "See references" }, @@ -376,6 +373,9 @@ "skipped": "Übersprungen", "text-highlight": "Earmark" }, + "annotation": { + "pending": "(Pending analysis)" + }, "archived-dossiers-listing": { "no-data": { "title": "No archived dossiers." @@ -458,13 +458,6 @@ }, "to": "bis" }, - "auth-error": { - "heading": "Ihr Benutzer verfügt nicht über die erforderlichen RED-*-Rollen, um auf diese Applikation zugreifen zu können. Bitte kontaktieren Sie Ihren Admin, um den Zugang anzufordern!", - "heading-with-link": "Ihr Benutzer verfügt nicht über die erforderlichen RED-*-Rollen, um auf diese Applikation zugreifen zu können. Bitte kontaktieren Sie Ihren Admin, um den Zugang anzufordern!", - "heading-with-name": "Ihr Benutzer verfügt nicht über die erforderlichen RED-*-Rollen, um auf diese Applikation zugreifen zu können. Bitte kontaktieren Sie {adminName}, um den Zugang anzufordern!", - "heading-with-name-and-link": "Ihr Benutzer verfügt nicht über die erforderlichen RED-*-Rollen, um auf diese Applikation zugreifen zu können. Bitte kontaktieren Sie {adminName}, um den Zugang anzufordern!", - "logout": "Ausloggen" - }, "change-legal-basis-dialog": { "actions": { "cancel": "Abbrechen", @@ -581,18 +574,14 @@ "warning": "Achtung: Diese Aktion kann nicht rückgängig gemacht werden!" }, "confirmation-dialog": { - "approve-file": { - "question": "Dieses Dokument enthält ungesehene Änderungen. Möchten Sie es trotzdem genehmigen?", - "title": "Warnung!" - }, "approve-file-without-analysis": { "confirmationText": "Approve without analysis", "denyText": "Cancel", "question": "Analysis required to detect new components.", "title": "Warning!" }, - "approve-multiple-files": { - "question": "Mindestens eine der ausgewählten Dateien enthält ungesehene Änderungen. Möchten Sie sie trotzdem genehmigen?", + "approve-file": { + "question": "Dieses Dokument enthält ungesehene Änderungen. Möchten Sie es trotzdem genehmigen?", "title": "Warnung!" }, "approve-multiple-files-without-analysis": { @@ -601,6 +590,10 @@ "question": "Analysis required to detect new components for at least one file.", "title": "Warning" }, + "approve-multiple-files": { + "question": "Mindestens eine der ausgewählten Dateien enthält ungesehene Änderungen. Möchten Sie sie trotzdem genehmigen?", + "title": "Warnung!" + }, "assign-file-to-me": { "question": { "multiple": "Dieses Dokument wird gerade von einer anderen Person geprüft. Möchten Sie Reviewer werden und sich selbst dem Dokument zuweisen?", @@ -945,13 +938,13 @@ "recent": "Neu ({hours} h)", "unassigned": "Niemandem zugewiesen" }, - "reanalyse": { - "action": "Datei analysieren" - }, "reanalyse-dossier": { "error": "Die Dateien konnten nicht für eine Reanalyse eingeplant werden. Bitte versuchen Sie es erneut.", "success": "Dateien für Reanalyse vorgesehen." }, + "reanalyse": { + "action": "Datei analysieren" + }, "start-auto-analysis": "Enable auto-analysis", "stop-auto-analysis": "Stop auto-analysis", "table-col-names": { @@ -1020,14 +1013,6 @@ "total-documents": "Anzahl der Dokumente", "total-people": "{count} {count, plural, one{user} other {users}}" }, - "dossier-templates": { - "label": "Dossier-Vorlagen", - "status": { - "active": "Active", - "inactive": "Inactive", - "incomplete": "Incomplete" - } - }, "dossier-templates-listing": { "action": { "clone": "Clone template", @@ -1063,6 +1048,14 @@ "title": "{length} dossier {length, plural, one{template} other{templates}}" } }, + "dossier-templates": { + "label": "Dossier-Vorlagen", + "status": { + "active": "Active", + "inactive": "Inactive", + "incomplete": "Incomplete" + } + }, "dossier-watermark-selector": { "heading": "Watermarks on documents", "no-watermark": "There is no watermark defined for the dossier template.
Contact your app admin to define one.", @@ -1248,15 +1241,6 @@ "title": "{length} {length, plural, one{entity} other{entities}}" } }, - "entity": { - "info": { - "actions": { - "revert": "Revert", - "save": "Save changes" - }, - "heading": "Edit entity" - } - }, "entity-rules-screen": { "error": { "generic": "Something went wrong... Entity rules update failed!" @@ -1270,19 +1254,28 @@ "title": "Entity rule editor", "warning-text": "Warning: experimental feature!" }, + "entity": { + "info": { + "actions": { + "revert": "Revert", + "save": "Save changes" + }, + "heading": "Edit entity" + } + }, "error": { "deleted-entity": { "dossier": { "action": "Zurück zur Übersicht", "label": "Dieses Dossier wurde gelöscht!" }, - "file": { - "action": "Zurück zum Dossier", - "label": "Diese Datei wurde gelöscht!" - }, "file-dossier": { "action": "Zurück zur Übersicht", "label": "Das Dossier dieser Datei wurde gelöscht!" + }, + "file": { + "action": "Zurück zum Dossier", + "label": "Diese Datei wurde gelöscht!" } }, "file-preview": { @@ -1300,12 +1293,6 @@ }, "exact-date": "{day} {month} {year} um {hour}:{minute} Uhr", "file": "Datei", - "file-attribute": { - "update": { - "error": "Failed to update file attribute value!", - "success": "File attribute value has been updated successfully!" - } - }, "file-attribute-encoding-types": { "ascii": "ASCII", "iso": "ISO-8859-1", @@ -1316,6 +1303,12 @@ "number": "Nummer", "text": "Freier Text" }, + "file-attribute": { + "update": { + "error": "Failed to update file attribute value!", + "success": "File attribute value has been updated successfully!" + } + }, "file-attributes-configurations": { "cancel": "Cancel", "form": { @@ -1531,15 +1524,6 @@ "csv": "File attributes were imported successfully from uploaded CSV file." } }, - "filter": { - "analysis": "Analyse erforderlich", - "comment": "Kommentare", - "hint": "Nut Hinweise", - "image": "Bilder", - "none": "Keine Anmerkungen", - "redaction": "Geschwärzt", - "updated": "Aktualisiert" - }, "filter-menu": { "filter-options": "Filteroptionen", "filter-types": "Filter", @@ -1549,6 +1533,15 @@ "unseen-pages": "Nur Anmerkungen auf unsichtbaren Seiten", "with-comments": "Nur Anmerkungen mit Kommentaren" }, + "filter": { + "analysis": "Analyse erforderlich", + "comment": "Kommentare", + "hint": "Nut Hinweise", + "image": "Bilder", + "none": "Keine Anmerkungen", + "redaction": "Geschwärzt", + "updated": "Aktualisiert" + }, "filters": { "assigned-people": "Beauftragt", "documents-status": "Documents state", @@ -1819,13 +1812,6 @@ "user-promoted-to-approver": "{user} wurde im Dossier {dossierHref, select, null{{dossierName}} other{{dossierName}}} zum Genehmiger ernannt!", "user-removed-as-dossier-member": "{user} wurde als Mitglied von: {dossierHref, select, null{{dossierName}} other{{dossierName}}} entfernt!" }, - "notifications": { - "button-text": "Notifications", - "deleted-dossier": "Deleted dossier", - "label": "Benachrichtigungen", - "mark-all-as-read": "Alle als gelesen markieren", - "mark-as": "Mark as {type, select, read{read} unread{unread} other{}}" - }, "notifications-screen": { "category": { "email-notifications": "E-Mail Benachrichtigungen", @@ -1839,6 +1825,7 @@ "dossier": "Dossierbezogene Benachrichtigungen", "other": "Andere Benachrichtigungen" }, + "options-title": "Wählen Sie aus, in welcher Kategorie Sie benachrichtigt werden möchten", "options": { "ASSIGN_APPROVER": "Wenn ich einem Dokument als Genehmiger zugewiesen bin", "ASSIGN_REVIEWER": "Wenn ich einem Dokument als Überprüfer zugewiesen bin", @@ -1856,7 +1843,6 @@ "USER_PROMOTED_TO_APPROVER": "Wenn ich Genehmiger in einem Dossier werde", "USER_REMOVED_AS_DOSSIER_MEMBER": "Wenn ich die Dossier-Mitgliedschaft verliere" }, - "options-title": "Wählen Sie aus, in welcher Kategorie Sie benachrichtigt werden möchten", "schedule": { "daily": "Tägliche Zusammenfassung", "instant": "Sofortig", @@ -1864,6 +1850,13 @@ }, "title": "Benachrichtigungseinstellungen" }, + "notifications": { + "button-text": "Notifications", + "deleted-dossier": "Deleted dossier", + "label": "Benachrichtigungen", + "mark-all-as-read": "Alle als gelesen markieren", + "mark-as": "Mark as {type, select, read{read} unread{unread} other{}}" + }, "ocr": { "confirmation-dialog": { "cancel": "Cancel", @@ -1955,16 +1948,16 @@ "warnings-subtitle": "Do not show again options", "warnings-title": "Prompts and dialogs settings" }, - "processing": { - "basic": "Processing", - "ocr": "OCR" - }, "processing-status": { "ocr": "OCR", "pending": "Pending", "processed": "Processed", "processing": "Processing" }, + "processing": { + "basic": "Processing", + "ocr": "OCR" + }, "readonly": "Lesemodus", "readonly-archived": "Read only (archived)", "redact-text": { @@ -2191,12 +2184,6 @@ "red-user-admin": "Benutzer-Admin", "regular": "Regulär" }, - "search": { - "active-dossiers": "ganze Plattform", - "all-dossiers": "all documents", - "placeholder": "Nach Dokumenten oder Dokumenteninhalt suchen", - "this-dossier": "in diesem Dossier" - }, "search-screen": { "cols": { "assignee": "Bevollmächtigter", @@ -2220,6 +2207,12 @@ "no-match": "Keine Dokumente entsprechen Ihren aktuellen Filtern.", "table-header": "{length} search {length, plural, one{result} other{results}}" }, + "search": { + "active-dossiers": "ganze Plattform", + "all-dossiers": "all documents", + "placeholder": "Nach Dokumenten oder Dokumenteninhalt suchen", + "this-dossier": "in diesem Dossier" + }, "seconds": "seconds", "size": "Size", "smtp-auth-config": { @@ -2239,6 +2232,7 @@ "header": { "first-time": "Sign in for the first time to a workspace", "join-another-domain": "Or join another workspace", + "no-role-log-out": "", "sign-in-previous-domain": "Sign in to a previously used workspace", "youre-logged-out": "You have successfully been logged out." }, @@ -2470,4 +2464,4 @@ } }, "yesterday": "Gestern" -} \ No newline at end of file +} diff --git a/apps/red-ui/src/assets/i18n/scm/en.json b/apps/red-ui/src/assets/i18n/scm/en.json index 25b648744..eaac3bae8 100644 --- a/apps/red-ui/src/assets/i18n/scm/en.json +++ b/apps/red-ui/src/assets/i18n/scm/en.json @@ -458,13 +458,6 @@ }, "to": "to" }, - "auth-error": { - "heading": "Your user is successfully logged in but has no role assigned yet. Please contact your DocuMine administrator to assign appropriate roles.", - "heading-with-link": "Your user is successfully logged in but has no role assigned yet. Please contact your DocuMine administrator to assign appropriate roles!", - "heading-with-name": "Your user is successfully logged in but has no role assigned yet. Please contact {adminName} to assign appropriate roles.", - "heading-with-name-and-link": "Your user is successfully logged in but has no role assigned yet. Please contact {adminName} to assign appropriate roles.", - "logout": "Logout" - }, "change-legal-basis-dialog": { "actions": { "cancel": "Cancel", @@ -2239,6 +2232,7 @@ "header": { "first-time": "Sign in for the first time to a workspace", "join-another-domain": "Or join another workspace", + "no-role-log-out": "User role missing. Please ask your administrator to assign roles before logging in again.", "sign-in-previous-domain": "Sign in to a previously used workspace", "youre-logged-out": "You have successfully been logged out." }, @@ -2470,4 +2464,4 @@ } }, "yesterday": "Yesterday" -} \ No newline at end of file +} diff --git a/libs/common-ui b/libs/common-ui index 6f255d68b..a37287f13 160000 --- a/libs/common-ui +++ b/libs/common-ui @@ -1 +1 @@ -Subproject commit 6f255d68b49e921ff458a59056c8bad6cede4abd +Subproject commit a37287f13c708ce5a7386b4144d7db5441358883 From c835a3bd27618b32bf0fbf7de3a07d3c59873977 Mon Sep 17 00:00:00 2001 From: Valentin Mihai Date: Tue, 20 Feb 2024 15:17:35 +0200 Subject: [PATCH 3/6] RED-7874 - moved 'select-tenant-translations' to common-ui --- .../src/app/translations/select-tenant-translations.ts | 6 ------ libs/common-ui | 2 +- 2 files changed, 1 insertion(+), 7 deletions(-) delete mode 100644 apps/red-ui/src/app/translations/select-tenant-translations.ts diff --git a/apps/red-ui/src/app/translations/select-tenant-translations.ts b/apps/red-ui/src/app/translations/select-tenant-translations.ts deleted file mode 100644 index 506b30535..000000000 --- a/apps/red-ui/src/app/translations/select-tenant-translations.ts +++ /dev/null @@ -1,6 +0,0 @@ -import { marker as _ } from '@biesbjerg/ngx-translate-extract-marker'; - -export const selectTenantTranslations: { [key in string]: string } = { - IS_LOGGED_OUT: _('tenant-resolve.header.youre-logged-out'), - NO_ROLE_LOG_OUT: _('tenant-resolve.header.no-role-log-out'), -} as const; diff --git a/libs/common-ui b/libs/common-ui index a37287f13..5d31262fb 160000 --- a/libs/common-ui +++ b/libs/common-ui @@ -1 +1 @@ -Subproject commit a37287f13c708ce5a7386b4144d7db5441358883 +Subproject commit 5d31262fb3d09f02fb1bb7b30c587f689963e85a From fad56bea19dda8d8d69e28d9c9c269e820c48670 Mon Sep 17 00:00:00 2001 From: Valentin Mihai Date: Tue, 20 Feb 2024 19:03:56 +0200 Subject: [PATCH 4/6] RED-7874 - added back auth-error component --- apps/red-ui/src/app/app-routing.module.ts | 6 ++++++ apps/red-ui/src/app/app.module.ts | 2 ++ .../auth-error/auth-error.component.html | 19 +++++++++++++++++++ .../auth-error/auth-error.component.scss | 3 +++ .../auth-error/auth-error.component.ts | 17 +++++++++++++++++ apps/red-ui/src/assets/i18n/redact/de.json | 7 +++++++ apps/red-ui/src/assets/i18n/redact/en.json | 7 +++++++ apps/red-ui/src/assets/i18n/scm/de.json | 7 +++++++ apps/red-ui/src/assets/i18n/scm/en.json | 7 +++++++ 9 files changed, 75 insertions(+) create mode 100644 apps/red-ui/src/app/components/auth-error/auth-error.component.html create mode 100644 apps/red-ui/src/app/components/auth-error/auth-error.component.scss create mode 100644 apps/red-ui/src/app/components/auth-error/auth-error.component.ts diff --git a/apps/red-ui/src/app/app-routing.module.ts b/apps/red-ui/src/app/app-routing.module.ts index f7006e19f..82e164ea3 100644 --- a/apps/red-ui/src/app/app-routing.module.ts +++ b/apps/red-ui/src/app/app-routing.module.ts @@ -22,6 +22,7 @@ import { Roles } from '@users/roles'; import { mainGuard } from '@utils/main.guard'; import { webViewerLoadedGuard } from './modules/pdf-viewer/services/webviewer-loaded.guard'; import { ACTIVE_DOSSIERS_SERVICE } from './tokens'; +import { AuthErrorComponent } from '@components/auth-error/auth-error.component'; const dossierTemplateIdRoutes: IqserRoutes = [ { @@ -209,6 +210,11 @@ const routes: IqserRoutes = [ component: BaseScreenComponent, children: mainRoutes, }, + { + path: 'auth-error', + component: AuthErrorComponent, + canActivate: [doesNotHaveAnyRole()], + }, { path: '**', redirectTo: 'main', diff --git a/apps/red-ui/src/app/app.module.ts b/apps/red-ui/src/app/app.module.ts index 80b09e331..90d3d1daa 100644 --- a/apps/red-ui/src/app/app.module.ts +++ b/apps/red-ui/src/app/app.module.ts @@ -68,11 +68,13 @@ import { AppRoutingModule } from './app-routing.module'; import { AppComponent } from './app.component'; import { PdfViewerModule } from './modules/pdf-viewer/pdf-viewer.module'; import { ACTIVE_DOSSIERS_SERVICE, ARCHIVED_DOSSIERS_SERVICE } from './tokens'; +import { AuthErrorComponent } from '@components/auth-error/auth-error.component'; export const appModuleFactory = (config: AppConfig) => { @NgModule({ declarations: [ AppComponent, + AuthErrorComponent, NotificationsComponent, SpotlightSearchComponent, BreadcrumbsComponent, diff --git a/apps/red-ui/src/app/components/auth-error/auth-error.component.html b/apps/red-ui/src/app/components/auth-error/auth-error.component.html new file mode 100644 index 000000000..83eb55942 --- /dev/null +++ b/apps/red-ui/src/app/components/auth-error/auth-error.component.html @@ -0,0 +1,19 @@ +
+

+

+

+

+ +
diff --git a/apps/red-ui/src/app/components/auth-error/auth-error.component.scss b/apps/red-ui/src/app/components/auth-error/auth-error.component.scss new file mode 100644 index 000000000..427b131fa --- /dev/null +++ b/apps/red-ui/src/app/components/auth-error/auth-error.component.scss @@ -0,0 +1,3 @@ +section { + padding: 24px; +} diff --git a/apps/red-ui/src/app/components/auth-error/auth-error.component.ts b/apps/red-ui/src/app/components/auth-error/auth-error.component.ts new file mode 100644 index 000000000..5445ec196 --- /dev/null +++ b/apps/red-ui/src/app/components/auth-error/auth-error.component.ts @@ -0,0 +1,17 @@ +import { Component } from '@angular/core'; +import { UserService } from '@users/user.service'; +import { getConfig } from '@iqser/common-ui'; +import { AppConfig } from '@red/domain'; + +@Component({ + selector: 'redaction-auth-error', + templateUrl: './auth-error.component.html', + styleUrls: ['./auth-error.component.scss'], +}) +export class AuthErrorComponent { + readonly #config = getConfig(); + readonly adminName = this.#config.ADMIN_CONTACT_NAME; + readonly adminUrl = this.#config.ADMIN_CONTACT_URL; + + constructor(readonly userService: UserService) {} +} diff --git a/apps/red-ui/src/assets/i18n/redact/de.json b/apps/red-ui/src/assets/i18n/redact/de.json index dd9480b13..deb95a7fa 100644 --- a/apps/red-ui/src/assets/i18n/redact/de.json +++ b/apps/red-ui/src/assets/i18n/redact/de.json @@ -458,6 +458,13 @@ }, "to": "bis" }, + "auth-error": { + "heading": "Ihr Benutzer verfügt nicht über die erforderlichen RED-*-Rollen, um auf diese Applikation zugreifen zu können. Bitte kontaktieren Sie Ihren Admin, um den Zugang anzufordern!", + "heading-with-link": "Ihr Benutzer verfügt nicht über die erforderlichen RED-*-Rollen, um auf diese Applikation zugreifen zu können. Bitte kontaktieren Sie Ihren Admin, um den Zugang anzufordern!", + "heading-with-name": "Ihr Benutzer verfügt nicht über die erforderlichen RED-*-Rollen, um auf diese Applikation zugreifen zu können. Bitte kontaktieren Sie {adminName}, um den Zugang anzufordern!", + "heading-with-name-and-link": "Ihr Benutzer verfügt nicht über die erforderlichen RED-*-Rollen, um auf diese Applikation zugreifen zu können. Bitte kontaktieren Sie {adminName}, um den Zugang anzufordern!", + "logout": "Ausloggen" + }, "change-legal-basis-dialog": { "actions": { "cancel": "Abbrechen", diff --git a/apps/red-ui/src/assets/i18n/redact/en.json b/apps/red-ui/src/assets/i18n/redact/en.json index 347617180..0f54c8ea4 100644 --- a/apps/red-ui/src/assets/i18n/redact/en.json +++ b/apps/red-ui/src/assets/i18n/redact/en.json @@ -458,6 +458,13 @@ }, "to": "to" }, + "auth-error": { + "heading": "Your user is successfully logged in but has no role assigned yet. Please contact your RedactManager administrator to assign appropriate roles.", + "heading-with-link": "Your user is successfully logged in but has no role assigned yet. Please contact your RedactManager administrator to assign appropriate roles!", + "heading-with-name": "Your user is successfully logged in but has no role assigned yet. Please contact {adminName} to assign appropriate roles.", + "heading-with-name-and-link": "Your user is successfully logged in but has no role assigned yet. Please contact {adminName} to assign appropriate roles.", + "logout": "Logout" + }, "change-legal-basis-dialog": { "actions": { "cancel": "Cancel", diff --git a/apps/red-ui/src/assets/i18n/scm/de.json b/apps/red-ui/src/assets/i18n/scm/de.json index 5272784ff..4612f76d0 100644 --- a/apps/red-ui/src/assets/i18n/scm/de.json +++ b/apps/red-ui/src/assets/i18n/scm/de.json @@ -458,6 +458,13 @@ }, "to": "bis" }, + "auth-error": { + "heading": "Ihr Benutzer verfügt nicht über die erforderlichen RED-*-Rollen, um auf diese Applikation zugreifen zu können. Bitte kontaktieren Sie Ihren Admin, um den Zugang anzufordern!", + "heading-with-link": "Ihr Benutzer verfügt nicht über die erforderlichen RED-*-Rollen, um auf diese Applikation zugreifen zu können. Bitte kontaktieren Sie Ihren Admin, um den Zugang anzufordern!", + "heading-with-name": "Ihr Benutzer verfügt nicht über die erforderlichen RED-*-Rollen, um auf diese Applikation zugreifen zu können. Bitte kontaktieren Sie {adminName}, um den Zugang anzufordern!", + "heading-with-name-and-link": "Ihr Benutzer verfügt nicht über die erforderlichen RED-*-Rollen, um auf diese Applikation zugreifen zu können. Bitte kontaktieren Sie {adminName}, um den Zugang anzufordern!", + "logout": "Ausloggen" + }, "change-legal-basis-dialog": { "actions": { "cancel": "Abbrechen", diff --git a/apps/red-ui/src/assets/i18n/scm/en.json b/apps/red-ui/src/assets/i18n/scm/en.json index eaac3bae8..021e9fece 100644 --- a/apps/red-ui/src/assets/i18n/scm/en.json +++ b/apps/red-ui/src/assets/i18n/scm/en.json @@ -458,6 +458,13 @@ }, "to": "to" }, + "auth-error": { + "heading": "Your user is successfully logged in but has no role assigned yet. Please contact your RedactManager administrator to assign appropriate roles.", + "heading-with-link": "Your user is successfully logged in but has no role assigned yet. Please contact your RedactManager administrator to assign appropriate roles!", + "heading-with-name": "Your user is successfully logged in but has no role assigned yet. Please contact {adminName} to assign appropriate roles.", + "heading-with-name-and-link": "Your user is successfully logged in but has no role assigned yet. Please contact {adminName} to assign appropriate roles.", + "logout": "Logout" + }, "change-legal-basis-dialog": { "actions": { "cancel": "Cancel", From 649fa52e5db38118012f3f331d1e8a06d9854b81 Mon Sep 17 00:00:00 2001 From: Valentin Mihai Date: Tue, 20 Feb 2024 19:13:45 +0200 Subject: [PATCH 5/6] RED-7874 - update common-ui --- libs/common-ui | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libs/common-ui b/libs/common-ui index 5d31262fb..0010eba41 160000 --- a/libs/common-ui +++ b/libs/common-ui @@ -1 +1 @@ -Subproject commit 5d31262fb3d09f02fb1bb7b30c587f689963e85a +Subproject commit 0010eba4105a9e3d48f33eaa73694dce18ec933c From c8db2a8a7c42e752945c57d381cb56ce9d6f6199 Mon Sep 17 00:00:00 2001 From: Valentin Mihai Date: Tue, 20 Feb 2024 23:32:01 +0200 Subject: [PATCH 6/6] RED-6960 - update common ui --- libs/common-ui | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libs/common-ui b/libs/common-ui index 0010eba41..7b29cc5f3 160000 --- a/libs/common-ui +++ b/libs/common-ui @@ -1 +1 @@ -Subproject commit 0010eba4105a9e3d48f33eaa73694dce18ec933c +Subproject commit 7b29cc5f317838df075a939f2679bd899ef843bf