@topconsultnpm/sdkui-react 6.20.0-dev2.5 → 6.20.0-dev2.51
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/components/base/Styled.d.ts +1 -0
- package/lib/components/base/Styled.js +10 -2
- package/lib/components/base/TMTreeView.d.ts +3 -1
- package/lib/components/base/TMTreeView.js +63 -20
- package/lib/components/choosers/TMDataListItemEditor.d.ts +11 -0
- package/lib/components/choosers/TMDataListItemEditor.js +130 -0
- package/lib/components/choosers/TMDataListItemFields.d.ts +11 -0
- package/lib/components/choosers/TMDataListItemFields.js +61 -0
- package/lib/components/choosers/TMDataListItemPicker.d.ts +1 -0
- package/lib/components/choosers/TMDataListItemPicker.js +178 -18
- package/lib/components/choosers/TMDynDataListItemChooser.js +11 -6
- package/lib/components/choosers/TMImageIDChooser.d.ts +16 -0
- package/lib/components/choosers/TMImageIDChooser.js +53 -0
- package/lib/components/choosers/TMMetadataChooser.js +1 -1
- package/lib/components/editors/TMLocalizedTextBox.d.ts +1 -0
- package/lib/components/editors/TMLocalizedTextBox.js +3 -3
- package/lib/components/editors/TMMetadataValues.js +3 -1
- package/lib/components/editors/TMTextBox.js +8 -9
- package/lib/components/features/archive/TMArchive.js +29 -42
- package/lib/components/features/documents/TMDcmtForm.js +165 -42
- package/lib/components/features/documents/TMDcmtPreview.js +2 -1
- package/lib/components/features/documents/TMMasterDetailDcmts.js +67 -6
- package/lib/components/features/documents/TMRelationViewer.d.ts +7 -1
- package/lib/components/features/documents/TMRelationViewer.js +389 -76
- package/lib/components/features/search/TMSearchResult.d.ts +1 -0
- package/lib/components/features/search/TMSearchResult.js +44 -82
- package/lib/components/features/search/TMSearchResultsMenuItems.js +2 -2
- package/lib/components/features/tasks/TMTaskForm.js +35 -187
- package/lib/components/features/tasks/TMTaskFormUtils.d.ts +74 -0
- package/lib/components/features/tasks/TMTaskFormUtils.js +538 -0
- package/lib/components/features/tasks/TMTasksUtils.d.ts +2 -0
- package/lib/components/features/tasks/TMTasksUtils.js +38 -13
- package/lib/components/features/tasks/TMTasksUtilsView.d.ts +0 -7
- package/lib/components/features/tasks/TMTasksUtilsView.js +7 -14
- package/lib/components/features/tasks/TMTasksView.js +2 -2
- package/lib/components/features/workflow/TMWorkflowPopup.d.ts +2 -1
- package/lib/components/features/workflow/TMWorkflowPopup.js +2 -1
- package/lib/components/features/workflow/diagram/DiagramItemForm.js +1 -1
- package/lib/components/forms/Login/TMLoginForm.js +1 -1
- package/lib/components/forms/TMSaveForm.js +61 -13
- package/lib/components/grids/TMBlogsPost.js +2 -2
- package/lib/components/index.d.ts +2 -0
- package/lib/components/index.js +2 -0
- package/lib/components/layout/panelManager/TMPanelManagerContainer.js +3 -2
- package/lib/components/pages/TMPage.js +4 -0
- package/lib/components/query/TMQueryEditor.d.ts +1 -0
- package/lib/components/query/TMQueryEditor.js +2 -2
- package/lib/helper/Enum_Localizator.js +5 -0
- package/lib/helper/GlobalStyles.js +3 -0
- package/lib/helper/SDKUI_Globals.d.ts +4 -0
- package/lib/helper/SDKUI_Globals.js +6 -0
- package/lib/helper/SDKUI_Localizator.d.ts +11 -3
- package/lib/helper/SDKUI_Localizator.js +102 -22
- package/lib/helper/TMUtils.d.ts +18 -0
- package/lib/helper/TMUtils.js +58 -0
- package/lib/helper/helpers.d.ts +6 -2
- package/lib/helper/helpers.js +23 -8
- package/lib/helper/index.d.ts +1 -0
- package/lib/helper/index.js +1 -0
- package/lib/helper/queryHelper.js +1 -1
- package/lib/hooks/useBetaFeatures.d.ts +1 -0
- package/lib/hooks/useBetaFeatures.js +41 -0
- package/lib/hooks/useDcmtOperations.js +14 -2
- package/lib/hooks/useRelatedDocuments.js +34 -11
- package/lib/index.d.ts +1 -0
- package/lib/index.js +1 -0
- package/package.json +11 -11
|
@@ -37,6 +37,7 @@ export declare class SDKUI_Localizator {
|
|
|
37
37
|
static get Anomalies(): "Anomalien" | "Anomalies" | "Anomalías" | "Anomalias" | "Anomalie";
|
|
38
38
|
static get Answer(): "Antwort" | "Answer" | "Respuesta" | "Réponse" | "Resposta" | "Risposta";
|
|
39
39
|
static get AnswerTooltip(): "Die Antwort kann nur bearbeitet werden, wenn der Aktivitätsstatus \"Abgeschlossen\", \"Ausstehend\" oder \"Verschoben\" ist." | "The answer can be edited only if the activity status is \"Completed\", \"Pending\", or \"Deferred\"." | "La respuesta solo se puede editar si el estado de la actividad es \"Completada\", \"Pendiente\" o \"Pospuesta\"." | "La réponse peut être modifiée uniquement si l'état de l’activité est \"Terminée\", \"En attente\" ou \"Reportée\"." | "A resposta só pode ser editada se o estado da atividade for \"Concluída\", \"Pendente\" ou \"Adiada\"." | "La risposta può essere modificata solo se lo stato dell’attività è \"Completata\", \"In attesa\" o \"Rinviata\".";
|
|
40
|
+
static get NoAnswerProvided(): "Keine Antwort" | "No answer" | "Sin respuesta" | "Aucune réponse" | "Nenhuma resposta" | "Nessuna risposta";
|
|
40
41
|
static get Application(): "Anwendung" | "Application" | "Aplicación" | "Aplicação" | "Applicazione";
|
|
41
42
|
static get Applied(): string;
|
|
42
43
|
static get Apply(): "Anwenden" | "Apply" | "Aplicar" | "Applique" | "Applica";
|
|
@@ -99,6 +100,8 @@ export declare class SDKUI_Localizator {
|
|
|
99
100
|
static get ClearCache(): string;
|
|
100
101
|
static get ClearOTP(): "OTP löschen" | "Clear OTP" | "Borrar OTP" | "Effacer l'OTP" | "Limpar OTP" | "Cancella OTP";
|
|
101
102
|
static get Close(): "Ausgang" | "Close" | "Salida" | "Sortie" | "Saída" | "Chiudi";
|
|
103
|
+
static get Closed(): "Geschlossen" | "Closed" | "Cerrada" | "Fermée" | "Fechada" | "Chiusa";
|
|
104
|
+
static get CloseTask(): string;
|
|
102
105
|
static get Columns_All_Hide(): "Alle Spalten ausblenden" | "Hide all columns" | "Ocultar todas las columnas" | "Masquer toutes les colonnes" | "Ocultar todas as colunas" | "Nascondi tutte le colonne";
|
|
103
106
|
static get Columns_All_Show(): "Alle Spalten anzeigen" | "Show all columns" | "Mostrar todas las columnas" | "Afficher toutes les colonnes" | "Mostrar todas as colunas" | "Visualizza tutte le colonne";
|
|
104
107
|
static get Comment(): string;
|
|
@@ -240,6 +243,7 @@ export declare class SDKUI_Localizator {
|
|
|
240
243
|
static get EvaluateResult(): "Bewerten Sie das Ergebnis" | "Evaluate result" | "Valorar el resultado" | "Évalue les résultats" | "Avalia os resultados" | "Valuta il risultato";
|
|
241
244
|
static get Expected(): "Erwartet" | "Expected" | "Esperado" | "Attendu" | "Atteso";
|
|
242
245
|
static get Expiration(): "Ablaufdatum" | "Expiration" | "Fecha de expiración" | "Date d'expiration" | "Data de expiração" | "Scadenza";
|
|
246
|
+
static get ExpirationDate(): "Ablaufdatum" | "Expiration date" | "Fecha de vencimiento" | "Date d'échéance" | "Data de validade" | "Data di scadenza";
|
|
243
247
|
static get ExpertMode(): "Expertenmodus" | "Expert mode" | "Modo experto" | "Mode expert" | "Modo especialista" | "Modalità esperto";
|
|
244
248
|
static get Expiring(): "Ablaufend" | "Expiring" | "Por vencer" | "Expirant" | "Vencendo" | "In scadenza";
|
|
245
249
|
static get Export(): "Exportieren" | "Export" | "Exportar" | "Exporter" | "Esporta";
|
|
@@ -515,6 +519,8 @@ export declare class SDKUI_Localizator {
|
|
|
515
519
|
static get Redo(): "Wiederherstellen" | "Redo" | "Rehacer" | "Rétablir" | "Refazer" | "Rifai";
|
|
516
520
|
static get Reject(): "Ablehnen" | "Reject" | "Rechazar" | "Rejeter" | "Rejeitar" | "Rifiuta";
|
|
517
521
|
static get Relations(): "Korrelationen" | "Correlations" | "Correlaciones" | "Relations" | "Correlacionados" | "Correlazioni";
|
|
522
|
+
static get RelationsNotFound(): "Keine Korrelationen gefunden" | "No correlations found" | "No se encontraron correlaciones" | "Aucune corrélation trouvée" | "Nenhuma correlação encontrada" | "Nessuna correlazione trovata";
|
|
523
|
+
static get RelatedDcmtsNotFound(): "Für das ausgewählte Dokument wurden keine zugehörigen Dokumente gefunden." | "No related documents were found for the selected document." | "No se encontraron documentos relacionados para el documento seleccionado." | "Aucun document associé n'a été trouvé pour le document sélectionné." | "Nenhum documento relacionado foi encontrado para o documento selecionado." | "Non sono stati trovati documenti correlati per il documento selezionato.";
|
|
518
524
|
static get RelationManyToMany(): "Folge viele mit vielen" | "Relation many to many" | "Correlación muchos a muchos" | "Corrélation plusieurs à plusieurs" | "Muitos para muitos relação" | "Correlazione molti a molti";
|
|
519
525
|
static get RelationType(): "Art der Beziehung" | "Relation type" | "Tipo de relación" | "Type de relation" | "Tipo de relacionamento" | "Tipo di relazione";
|
|
520
526
|
static get RemoveContextualFilter(): "Kontextbezogenen Filter entfernen" | "Remove contextual filter" | "Eliminar filtro contextual" | "Supprimer le filtre contextuel" | "Remover filtro contextual" | "Rimuovi filtro contestuale";
|
|
@@ -535,7 +541,6 @@ export declare class SDKUI_Localizator {
|
|
|
535
541
|
static get RequiredNOT(): "Nicht obligatorisch" | "Not mandatory" | "No obligatorio" | "Pas obligatoire" | "Não é obrigatório" | "Non obbligatorio";
|
|
536
542
|
static get Refresh(): "Aktualisieren" | "Refresh" | "Actualizar" | "Mis à jour" | "Refrescar" | "Aggiorna";
|
|
537
543
|
static get Reminder(): "Erinnerung" | "Reminder" | "Recordatorio" | "Rappel" | "Lembrete" | "Promemoria";
|
|
538
|
-
static get ReminderDateMustBeBeforeEndDate(): "Das Erinnerungsdatum muss vor dem Enddatum liegen" | "The reminder date must be before the end date" | "La fecha de recordatorio debe ser anterior a la fecha de finalización" | "La date de rappel doit être antérieure à la date de fin" | "A data de lembrete deve ser anterior à data de término" | "La data di promemoria deve essere precedente alla data di fine";
|
|
539
544
|
static get ReminderSetForToday(): "Es gibt eine Erinnerung, die für heute eingestellt ist und bis zum Ablaufdatum gültig ist" | "There is a reminder set for today, valid until the expiration date" | "Hay un recordatorio establecido para hoy, válido hasta la fecha de vencimiento" | "Il y a un rappel réglé pour aujourd'hui, valable jusqu'à la date d'échéance" | "Há um lembrete definido para hoje, válido até à data de expiração" | "È presente un promemoria impostato per oggi, valido fino alla data di scadenza";
|
|
540
545
|
static get Remove(): "Entfernen" | "Remove" | "Quitar" | "Supprime" | "Remover" | "Rimuovi";
|
|
541
546
|
static get RemoveAll(): "Alle entfernen" | "Remove all" | "Eliminar todo" | "Supprime tout" | "Remover todos" | "Rimuovi tutto";
|
|
@@ -552,6 +557,7 @@ export declare class SDKUI_Localizator {
|
|
|
552
557
|
static get Save(): "Speichern" | "Save" | "Guardar" | "Enregistre" | "Salvar" | "Salva";
|
|
553
558
|
static get SaveAndLogin(): string;
|
|
554
559
|
static get SaveQuestion(): "Ihre Änderungen speichern?" | "Save modifications?" | "¿Guardar modificaciones aportadas?" | "Enregistrez les modifications?" | "Salve as alterações?" | "Salvare le modifiche apportate?";
|
|
560
|
+
static get FormErrorsProceedQuestion(): "Es gibt Fehler im Formular. Wenn Sie fortfahren, werden die Daten nicht gespeichert. Möchten Sie trotzdem fortfahren?" | "There are errors in the form. If you continue, the data will not be saved. Do you want to proceed anyway?" | "Hay errores en el formulario. Si continúas, los datos no se guardarán. ¿Quieres proceder de todos modos?" | "Il y a des erreurs dans le formulaire. Si vous continuez, les données ne seront pas enregistrées. Voulez-vous continuer quand même?" | "Há erros no formulário. Se continuar, os dados não serão salvos. Deseja prosseguir mesmo assim?" | "Ci sono errori nel form. Se continui, i dati non saranno salvati. Vuoi comunque procedere?";
|
|
555
561
|
static get SavedQueryNew(): "Neue Suche speichern" | "Save new search" | "Guardar nueva búsqueda" | "Enregistrer la nouvelle recherche" | "Guardar nova pesquisa" | "Salva nuova ricerca";
|
|
556
562
|
static get SavedQueryUpdate(): "Suche bearbeiten" | "Modify query" | "Modificar búsqueda" | "Modifie la recherche" | "Mudar pesquisa" | "Modifica ricerca";
|
|
557
563
|
static get Search(): "Auf der Suche nach" | "Search" | "Búsqueda" | "Recherche" | "Pesquisa" | "Ricerca";
|
|
@@ -569,6 +575,7 @@ export declare class SDKUI_Localizator {
|
|
|
569
575
|
static get SelectArchiveToStart(): "Klicken Sie auf Archivieren, um zu beginnen." | "Click on Archive button to start." | "Haz clic en el botón Archivar para comenzar." | "Cliquez sur le bouton Archiver pour commencer." | "Clique no botão Arquivar para iniciar." | "Clicca sul pulsante Archivia per iniziare.";
|
|
570
576
|
static get SelectAttachToStart(): "Sie können Dateien zu Ihrer E-Mail hinzufügen, klicken Sie auf Anhängen, um zu beginnen." | "You can attach files to your email, click on Attach button to start." | "Puedes adjuntar archivos a tu correo electrónico, haz clic en el botón Adjuntar para comenzar." | "Vous pouvez joindre des fichiers à votre e-mail, cliquez sur le bouton Joindre pour commencer." | "Você pode anexar arquivos ao seu e-mail, clique no botão Anexar para iniciar." | "Puoi allegare file alla tua email, clicca sul pulsante Allega per iniziare.";
|
|
571
577
|
static get SelectFromAttachments(): "Aus Anhängen auswählen" | "Select from attachments" | "Seleccionar de archivos adjuntos" | "Sélectionner parmi les pièces jointes" | "Selecionar dos anexos" | "Seleziona dagli allegati";
|
|
578
|
+
static get SelectMetadata(): "Metadaten auswählen" | "Select metadata" | "Seleccionar metadatos" | "Sélectionner les métadonnées" | "Selecionar metadados" | "Seleziona metadato";
|
|
572
579
|
static get SelectSupportAreaMessage(): "Wählen Sie einen Ablagebereich aus" | "Select a support area" | "Seleccione un área de apoyo" | "Sélectionnez une zone de support" | "Selecione uma área de apoio" | "Selezionare un'area di appoggio";
|
|
573
580
|
static get SelectedSingular(): string;
|
|
574
581
|
static get Selected(): "Ausgewählt" | "Selected" | "Sélectionné" | "Selecionado" | "Seleccionados" | "Selezionati";
|
|
@@ -627,12 +634,13 @@ export declare class SDKUI_Localizator {
|
|
|
627
634
|
static get StartDateMustBeBeforeEndDate(): "Das Startdatum muss vor dem Enddatum liegen" | "The start date must be before the end date" | "La fecha de inicio debe ser anterior a la fecha de finalización" | "La date de début doit être antérieure à la date de fin" | "A data de início deve ser anterior à data de término" | "La data di inizio deve essere precedente alla data di fine";
|
|
628
635
|
static get Statistics(): "Statistiken" | "Statistics" | "Estadística" | "Statistiques" | "Estatísticas" | "Statistiche";
|
|
629
636
|
static get Status(): "Status" | "Estado" | "Statut" | "Stato";
|
|
637
|
+
static get StatusAndAnswer(): "Status und Antwort" | "Status and answer" | "Estado y respuesta" | "Statut et réponse" | "Estado e resposta" | "Stato e risposta";
|
|
630
638
|
static get Subject(): "Betreff" | "Subject" | "Asunto" | "Objet" | "Assunto" | "Oggetto";
|
|
631
639
|
static get Summary(): "Zusammenfassung" | "Summary" | "Resumen" | "Résumé" | "Resumo" | "Riepilogo";
|
|
632
640
|
static get SwitchUser(): "Benutzer wechseln" | "Switch user" | "Cambiar usuario" | "Changer d'utilisateur" | "Mudar de usuário" | "Cambia utente";
|
|
633
641
|
static get TargetedSearch(): "Gezielte Suche" | "Targeted search" | "Búsqueda dirigida" | "Recherche ciblée" | "Pesquisa direcionada" | "Ricerca puntuale";
|
|
634
|
-
static get TaskAssignedMessage(): "
|
|
635
|
-
static get TaskAssignedToUserMessage(): "Aufgabe zugewiesen an den Benutzer
|
|
642
|
+
static get TaskAssignedMessage(): "Aufgabe wurde vom Benutzer \"{{0}}\" zugewiesen." | "Task assigned by user \"{{0}}\"." | "Tarea asignada por el usuario \"{{0}}\"." | "Tâche assignée par l'utilisateur \"{{0}}\"." | "Tarefa atribuída pelo usuário \"{{0}}\"." | "Attività assegnata dall'utente \"{{0}}\".";
|
|
643
|
+
static get TaskAssignedToUserMessage(): "Aufgabe zugewiesen an den Benutzer \"{{0}}\"" | "Task assigned to user \"{{0}}\"" | "Tarea asignada al usuario \"{{0}}\"" | "Tâche assignée à l'utilisateur \"{{0}}\"" | "Tarefa atribuída ao usuário \"{{0}}\"" | "Attività assegnata all'utente \"{{0}}\"";
|
|
636
644
|
static get TaskConsideredExpiring(): "Die Aufgabe wird als ablaufend betrachtet, wenn" | "The task is considered expiring if" | "La tarea se considera por vencer si" | "La tâche est considérée comme expirante si" | "A tarefa é considerada vencendo se" | "L'attività è considerata in scadenza se";
|
|
637
645
|
static get TasksEmpty(): string;
|
|
638
646
|
static get TaskSavedSuccessfully(): string;
|
|
@@ -324,6 +324,16 @@ export class SDKUI_Localizator {
|
|
|
324
324
|
return "La risposta può essere modificata solo se lo stato dell’attività è \"Completata\", \"In attesa\" o \"Rinviata\".";
|
|
325
325
|
}
|
|
326
326
|
}
|
|
327
|
+
static get NoAnswerProvided() {
|
|
328
|
+
switch (this._cultureID) {
|
|
329
|
+
case CultureIDs.De_DE: return "Keine Antwort";
|
|
330
|
+
case CultureIDs.En_US: return "No answer";
|
|
331
|
+
case CultureIDs.Es_ES: return "Sin respuesta";
|
|
332
|
+
case CultureIDs.Fr_FR: return "Aucune réponse";
|
|
333
|
+
case CultureIDs.Pt_PT: return "Nenhuma resposta";
|
|
334
|
+
default: return "Nessuna risposta";
|
|
335
|
+
}
|
|
336
|
+
}
|
|
327
337
|
static get Application() {
|
|
328
338
|
switch (this._cultureID) {
|
|
329
339
|
case CultureIDs.De_DE: return "Anwendung";
|
|
@@ -970,6 +980,26 @@ export class SDKUI_Localizator {
|
|
|
970
980
|
default: return "Chiudi";
|
|
971
981
|
}
|
|
972
982
|
}
|
|
983
|
+
static get Closed() {
|
|
984
|
+
switch (this._cultureID) {
|
|
985
|
+
case CultureIDs.De_DE: return "Geschlossen";
|
|
986
|
+
case CultureIDs.En_US: return "Closed";
|
|
987
|
+
case CultureIDs.Es_ES: return "Cerrada";
|
|
988
|
+
case CultureIDs.Fr_FR: return "Fermée";
|
|
989
|
+
case CultureIDs.Pt_PT: return "Fechada";
|
|
990
|
+
default: return "Chiusa";
|
|
991
|
+
}
|
|
992
|
+
}
|
|
993
|
+
static get CloseTask() {
|
|
994
|
+
switch (this._cultureID) {
|
|
995
|
+
case CultureIDs.De_DE: return "Aufgabe schließen";
|
|
996
|
+
case CultureIDs.En_US: return "Close task";
|
|
997
|
+
case CultureIDs.Es_ES: return "Cerrar tarea";
|
|
998
|
+
case CultureIDs.Fr_FR: return "Fermer la tâche";
|
|
999
|
+
case CultureIDs.Pt_PT: return "Fechar tarefa";
|
|
1000
|
+
default: return "Chiudi attività";
|
|
1001
|
+
}
|
|
1002
|
+
}
|
|
973
1003
|
static get Columns_All_Hide() {
|
|
974
1004
|
switch (this._cultureID) {
|
|
975
1005
|
case CultureIDs.De_DE: return "Alle Spalten ausblenden";
|
|
@@ -2367,6 +2397,16 @@ export class SDKUI_Localizator {
|
|
|
2367
2397
|
default: return "Scadenza";
|
|
2368
2398
|
}
|
|
2369
2399
|
}
|
|
2400
|
+
static get ExpirationDate() {
|
|
2401
|
+
switch (this._cultureID) {
|
|
2402
|
+
case CultureIDs.De_DE: return "Ablaufdatum";
|
|
2403
|
+
case CultureIDs.En_US: return "Expiration date";
|
|
2404
|
+
case CultureIDs.Es_ES: return "Fecha de vencimiento";
|
|
2405
|
+
case CultureIDs.Fr_FR: return "Date d'échéance";
|
|
2406
|
+
case CultureIDs.Pt_PT: return "Data de validade";
|
|
2407
|
+
default: return "Data di scadenza";
|
|
2408
|
+
}
|
|
2409
|
+
}
|
|
2370
2410
|
static get ExpertMode() {
|
|
2371
2411
|
switch (this._cultureID) {
|
|
2372
2412
|
case CultureIDs.De_DE: return "Expertenmodus";
|
|
@@ -5115,6 +5155,26 @@ export class SDKUI_Localizator {
|
|
|
5115
5155
|
}
|
|
5116
5156
|
;
|
|
5117
5157
|
}
|
|
5158
|
+
static get RelationsNotFound() {
|
|
5159
|
+
switch (this._cultureID) {
|
|
5160
|
+
case CultureIDs.De_DE: return "Keine Korrelationen gefunden";
|
|
5161
|
+
case CultureIDs.En_US: return "No correlations found";
|
|
5162
|
+
case CultureIDs.Es_ES: return "No se encontraron correlaciones";
|
|
5163
|
+
case CultureIDs.Fr_FR: return "Aucune corrélation trouvée";
|
|
5164
|
+
case CultureIDs.Pt_PT: return "Nenhuma correlação encontrada";
|
|
5165
|
+
default: return "Nessuna correlazione trovata";
|
|
5166
|
+
}
|
|
5167
|
+
}
|
|
5168
|
+
static get RelatedDcmtsNotFound() {
|
|
5169
|
+
switch (this._cultureID) {
|
|
5170
|
+
case CultureIDs.De_DE: return "Für das ausgewählte Dokument wurden keine zugehörigen Dokumente gefunden.";
|
|
5171
|
+
case CultureIDs.En_US: return "No related documents were found for the selected document.";
|
|
5172
|
+
case CultureIDs.Es_ES: return "No se encontraron documentos relacionados para el documento seleccionado.";
|
|
5173
|
+
case CultureIDs.Fr_FR: return "Aucun document associé n'a été trouvé pour le document sélectionné.";
|
|
5174
|
+
case CultureIDs.Pt_PT: return "Nenhum documento relacionado foi encontrado para o documento selecionado.";
|
|
5175
|
+
default: return "Non sono stati trovati documenti correlati per il documento selezionato.";
|
|
5176
|
+
}
|
|
5177
|
+
}
|
|
5118
5178
|
static get RelationManyToMany() {
|
|
5119
5179
|
switch (this._cultureID) {
|
|
5120
5180
|
case CultureIDs.De_DE: return "Folge viele mit vielen";
|
|
@@ -5321,16 +5381,6 @@ export class SDKUI_Localizator {
|
|
|
5321
5381
|
default: return "Promemoria";
|
|
5322
5382
|
}
|
|
5323
5383
|
}
|
|
5324
|
-
static get ReminderDateMustBeBeforeEndDate() {
|
|
5325
|
-
switch (this._cultureID) {
|
|
5326
|
-
case CultureIDs.De_DE: return "Das Erinnerungsdatum muss vor dem Enddatum liegen";
|
|
5327
|
-
case CultureIDs.En_US: return "The reminder date must be before the end date";
|
|
5328
|
-
case CultureIDs.Es_ES: return "La fecha de recordatorio debe ser anterior a la fecha de finalización";
|
|
5329
|
-
case CultureIDs.Fr_FR: return "La date de rappel doit être antérieure à la date de fin";
|
|
5330
|
-
case CultureIDs.Pt_PT: return "A data de lembrete deve ser anterior à data de término";
|
|
5331
|
-
default: return "La data di promemoria deve essere precedente alla data di fine";
|
|
5332
|
-
}
|
|
5333
|
-
}
|
|
5334
5384
|
static get ReminderSetForToday() {
|
|
5335
5385
|
switch (this._cultureID) {
|
|
5336
5386
|
case CultureIDs.De_DE: return "Es gibt eine Erinnerung, die für heute eingestellt ist und bis zum Ablaufdatum gültig ist";
|
|
@@ -5491,6 +5541,16 @@ export class SDKUI_Localizator {
|
|
|
5491
5541
|
default: return "Salvare le modifiche apportate?";
|
|
5492
5542
|
}
|
|
5493
5543
|
}
|
|
5544
|
+
static get FormErrorsProceedQuestion() {
|
|
5545
|
+
switch (this._cultureID) {
|
|
5546
|
+
case CultureIDs.De_DE: return "Es gibt Fehler im Formular. Wenn Sie fortfahren, werden die Daten nicht gespeichert. Möchten Sie trotzdem fortfahren?";
|
|
5547
|
+
case CultureIDs.En_US: return "There are errors in the form. If you continue, the data will not be saved. Do you want to proceed anyway?";
|
|
5548
|
+
case CultureIDs.Es_ES: return "Hay errores en el formulario. Si continúas, los datos no se guardarán. ¿Quieres proceder de todos modos?";
|
|
5549
|
+
case CultureIDs.Fr_FR: return "Il y a des erreurs dans le formulaire. Si vous continuez, les données ne seront pas enregistrées. Voulez-vous continuer quand même?";
|
|
5550
|
+
case CultureIDs.Pt_PT: return "Há erros no formulário. Se continuar, os dados não serão salvos. Deseja prosseguir mesmo assim?";
|
|
5551
|
+
default: return "Ci sono errori nel form. Se continui, i dati non saranno salvati. Vuoi comunque procedere?";
|
|
5552
|
+
}
|
|
5553
|
+
}
|
|
5494
5554
|
static get SavedQueryNew() {
|
|
5495
5555
|
switch (this._cultureID) {
|
|
5496
5556
|
case CultureIDs.De_DE: return "Neue Suche speichern";
|
|
@@ -5661,6 +5721,16 @@ export class SDKUI_Localizator {
|
|
|
5661
5721
|
default: return "Seleziona dagli allegati";
|
|
5662
5722
|
}
|
|
5663
5723
|
}
|
|
5724
|
+
static get SelectMetadata() {
|
|
5725
|
+
switch (this._cultureID) {
|
|
5726
|
+
case CultureIDs.De_DE: return "Metadaten auswählen";
|
|
5727
|
+
case CultureIDs.En_US: return "Select metadata";
|
|
5728
|
+
case CultureIDs.Es_ES: return "Seleccionar metadatos";
|
|
5729
|
+
case CultureIDs.Fr_FR: return "Sélectionner les métadonnées";
|
|
5730
|
+
case CultureIDs.Pt_PT: return "Selecionar metadados";
|
|
5731
|
+
default: return "Seleziona metadato";
|
|
5732
|
+
}
|
|
5733
|
+
}
|
|
5664
5734
|
static get SelectSupportAreaMessage() {
|
|
5665
5735
|
switch (this._cultureID) {
|
|
5666
5736
|
case CultureIDs.De_DE: return "Wählen Sie einen Ablagebereich aus";
|
|
@@ -6242,6 +6312,16 @@ export class SDKUI_Localizator {
|
|
|
6242
6312
|
default: return "Stato";
|
|
6243
6313
|
}
|
|
6244
6314
|
}
|
|
6315
|
+
static get StatusAndAnswer() {
|
|
6316
|
+
switch (this._cultureID) {
|
|
6317
|
+
case CultureIDs.De_DE: return "Status und Antwort";
|
|
6318
|
+
case CultureIDs.En_US: return "Status and answer";
|
|
6319
|
+
case CultureIDs.Es_ES: return "Estado y respuesta";
|
|
6320
|
+
case CultureIDs.Fr_FR: return "Statut et réponse";
|
|
6321
|
+
case CultureIDs.Pt_PT: return "Estado e resposta";
|
|
6322
|
+
default: return "Stato e risposta";
|
|
6323
|
+
}
|
|
6324
|
+
}
|
|
6245
6325
|
static get Subject() {
|
|
6246
6326
|
switch (this._cultureID) {
|
|
6247
6327
|
case CultureIDs.De_DE: return "Betreff";
|
|
@@ -6284,22 +6364,22 @@ export class SDKUI_Localizator {
|
|
|
6284
6364
|
}
|
|
6285
6365
|
static get TaskAssignedMessage() {
|
|
6286
6366
|
switch (this._cultureID) {
|
|
6287
|
-
case CultureIDs.De_DE: return "
|
|
6288
|
-
case CultureIDs.En_US: return "
|
|
6289
|
-
case CultureIDs.Es_ES: return "
|
|
6290
|
-
case CultureIDs.Fr_FR: return "
|
|
6291
|
-
case CultureIDs.Pt_PT: return "
|
|
6292
|
-
default: return "Attività assegnata dall'utente
|
|
6367
|
+
case CultureIDs.De_DE: return "Aufgabe wurde vom Benutzer \"{{0}}\" zugewiesen.";
|
|
6368
|
+
case CultureIDs.En_US: return "Task assigned by user \"{{0}}\".";
|
|
6369
|
+
case CultureIDs.Es_ES: return "Tarea asignada por el usuario \"{{0}}\".";
|
|
6370
|
+
case CultureIDs.Fr_FR: return "Tâche assignée par l'utilisateur \"{{0}}\".";
|
|
6371
|
+
case CultureIDs.Pt_PT: return "Tarefa atribuída pelo usuário \"{{0}}\".";
|
|
6372
|
+
default: return "Attività assegnata dall'utente \"{{0}}\".";
|
|
6293
6373
|
}
|
|
6294
6374
|
}
|
|
6295
6375
|
static get TaskAssignedToUserMessage() {
|
|
6296
6376
|
switch (this._cultureID) {
|
|
6297
|
-
case CultureIDs.De_DE: return "Aufgabe zugewiesen an den Benutzer
|
|
6298
|
-
case CultureIDs.En_US: return "Task assigned to user
|
|
6299
|
-
case CultureIDs.Es_ES: return "Tarea asignada al usuario
|
|
6300
|
-
case CultureIDs.Fr_FR: return "Tâche assignée à l'utilisateur
|
|
6301
|
-
case CultureIDs.Pt_PT: return "Tarefa atribuída ao usuário
|
|
6302
|
-
default: return "Attività assegnata all'utente
|
|
6377
|
+
case CultureIDs.De_DE: return "Aufgabe zugewiesen an den Benutzer \"{{0}}\"";
|
|
6378
|
+
case CultureIDs.En_US: return "Task assigned to user \"{{0}}\"";
|
|
6379
|
+
case CultureIDs.Es_ES: return "Tarea asignada al usuario \"{{0}}\"";
|
|
6380
|
+
case CultureIDs.Fr_FR: return "Tâche assignée à l'utilisateur \"{{0}}\"";
|
|
6381
|
+
case CultureIDs.Pt_PT: return "Tarefa atribuída ao usuário \"{{0}}\"";
|
|
6382
|
+
default: return "Attività assegnata all'utente \"{{0}}\"";
|
|
6303
6383
|
}
|
|
6304
6384
|
}
|
|
6305
6385
|
static get TaskConsideredExpiring() {
|
package/lib/helper/TMUtils.d.ts
CHANGED
|
@@ -67,4 +67,22 @@ export declare const parseSignatureConfiguration: (did: number, informationSign:
|
|
|
67
67
|
};
|
|
68
68
|
export declare const convertSearchResultDescriptorToFileItems: (documents: Array<SearchResultDescriptor>) => Array<FileItem>;
|
|
69
69
|
export declare const getAppModuleGradient: (appModuleID: AppModules) => string;
|
|
70
|
+
export declare const getPanelManagerToolbarColor: (appModuleID: AppModules) => string;
|
|
71
|
+
type SearchToolbarVisibility = {
|
|
72
|
+
tmSearchResult: boolean;
|
|
73
|
+
tmBlog: boolean;
|
|
74
|
+
tmSysMetadata: boolean;
|
|
75
|
+
tmDcmtPreview: boolean;
|
|
76
|
+
tmFullTextSearch: boolean;
|
|
77
|
+
};
|
|
78
|
+
export declare const getSearchToolbarVisibility: (appModuleID: AppModules) => SearchToolbarVisibility;
|
|
79
|
+
type DcmtFormToolbarVisibility = {
|
|
80
|
+
tmDcmtForm: boolean;
|
|
81
|
+
tmBlog: boolean;
|
|
82
|
+
tmSysMetadata: boolean;
|
|
83
|
+
tmDcmtPreview: boolean;
|
|
84
|
+
tmWF: boolean;
|
|
85
|
+
tmDcmtTasks: boolean;
|
|
86
|
+
};
|
|
87
|
+
export declare const getDcmtFormToolbarVisibility: (appModuleID: AppModules) => DcmtFormToolbarVisibility;
|
|
70
88
|
export {};
|
package/lib/helper/TMUtils.js
CHANGED
|
@@ -445,3 +445,61 @@ export const getAppModuleGradient = (appModuleID) => {
|
|
|
445
445
|
return 'linear-gradient(270deg, #46B5A2 16%, #3BAABC 34%, #3BAABC 34%, #3681AD 54%, #3368A5 72%, #2F549D 88%, #304F99 100%)';
|
|
446
446
|
}
|
|
447
447
|
};
|
|
448
|
+
export const getPanelManagerToolbarColor = (appModuleID) => {
|
|
449
|
+
switch (appModuleID) {
|
|
450
|
+
case AppModules.SURFER:
|
|
451
|
+
return 'transparent linear-gradient(90deg, #CCE0F4 0%, #7EC1E7 14%, #39A6DB 28%, #1E9CD7 35%, #0075BE 78%, #005B97 99%) 0% 0% no-repeat padding-box';
|
|
452
|
+
case AppModules.DESIGNER:
|
|
453
|
+
return '#482234';
|
|
454
|
+
case AppModules.ORCHESTRATOR:
|
|
455
|
+
return '#1d6f42';
|
|
456
|
+
default:
|
|
457
|
+
return 'transparent linear-gradient(90deg, #CCE0F4 0%, #7EC1E7 14%, #39A6DB 28%, #1E9CD7 35%, #0075BE 78%, #005B97 99%) 0% 0% no-repeat padding-box';
|
|
458
|
+
}
|
|
459
|
+
};
|
|
460
|
+
export const getSearchToolbarVisibility = (appModuleID) => {
|
|
461
|
+
switch (appModuleID) {
|
|
462
|
+
case AppModules.SURFER:
|
|
463
|
+
return {
|
|
464
|
+
tmSearchResult: true,
|
|
465
|
+
tmBlog: true,
|
|
466
|
+
tmSysMetadata: true,
|
|
467
|
+
tmDcmtPreview: true,
|
|
468
|
+
tmFullTextSearch: true,
|
|
469
|
+
};
|
|
470
|
+
case AppModules.DESIGNER:
|
|
471
|
+
case AppModules.ORCHESTRATOR:
|
|
472
|
+
default:
|
|
473
|
+
return {
|
|
474
|
+
tmSearchResult: true,
|
|
475
|
+
tmBlog: false,
|
|
476
|
+
tmSysMetadata: false,
|
|
477
|
+
tmDcmtPreview: false,
|
|
478
|
+
tmFullTextSearch: false,
|
|
479
|
+
};
|
|
480
|
+
}
|
|
481
|
+
};
|
|
482
|
+
export const getDcmtFormToolbarVisibility = (appModuleID) => {
|
|
483
|
+
switch (appModuleID) {
|
|
484
|
+
case AppModules.SURFER:
|
|
485
|
+
return {
|
|
486
|
+
tmDcmtForm: true,
|
|
487
|
+
tmBlog: true,
|
|
488
|
+
tmSysMetadata: true,
|
|
489
|
+
tmDcmtPreview: true,
|
|
490
|
+
tmWF: true,
|
|
491
|
+
tmDcmtTasks: true,
|
|
492
|
+
};
|
|
493
|
+
case AppModules.DESIGNER:
|
|
494
|
+
case AppModules.ORCHESTRATOR:
|
|
495
|
+
default:
|
|
496
|
+
return {
|
|
497
|
+
tmDcmtForm: true,
|
|
498
|
+
tmBlog: false,
|
|
499
|
+
tmSysMetadata: true,
|
|
500
|
+
tmDcmtPreview: true,
|
|
501
|
+
tmWF: false,
|
|
502
|
+
tmDcmtTasks: false,
|
|
503
|
+
};
|
|
504
|
+
}
|
|
505
|
+
};
|
package/lib/helper/helpers.d.ts
CHANGED
|
@@ -2,12 +2,16 @@ import { Colors as ColorsType } from "../components/base/TMEditorBase";
|
|
|
2
2
|
import { DeviceType } from "../components";
|
|
3
3
|
import { AppModules, DataColumnDescriptor, DcmtTypeDescriptor, ITopMediaSession, MetadataDescriptor, QueryDescriptor, SearchResultDescriptor, TaskDescriptor } from "@topconsultnpm/sdk-ts";
|
|
4
4
|
import { FileExtensionHandler, FormModes, moduleTypes } from "../ts";
|
|
5
|
+
declare const calcResponsiveSizes: (deviceType: DeviceType | undefined, desktopSize: string, tabletSize: string, mobileSize: string) => string;
|
|
6
|
+
declare const taskModalSizes: (deviceType: DeviceType | undefined, formMode: FormModes) => {
|
|
7
|
+
width: string;
|
|
8
|
+
height: string;
|
|
9
|
+
};
|
|
5
10
|
declare const TABLET_WIDTH = 1024;
|
|
6
11
|
declare const MOBILE_WIDTH = 640;
|
|
7
12
|
declare const calcResponsiveDirection: (deviceType: DeviceType, desktopDir: "horizontal" | "vertical", tabletDir: "horizontal" | "vertical", mobileDir: "horizontal" | "vertical") => "horizontal" | "vertical";
|
|
8
13
|
declare const openApps: (appModule: AppModules, tmSession: ITopMediaSession, appRoutes?: any[]) => Promise<void>;
|
|
9
14
|
export declare const setSDK_GlobalsInfoAsync: (tms: ITopMediaSession | undefined) => Promise<ITopMediaSession | undefined>;
|
|
10
|
-
declare const calcResponsiveSizes: (deviceType: DeviceType | undefined, desktopSize: string, tabletSize: string, mobileSize: string) => string;
|
|
11
15
|
declare const getColor: (color: ColorsType) => string;
|
|
12
16
|
/**
|
|
13
17
|
* Genera un Universally Unique Identifier (UUID) versione 4.
|
|
@@ -44,7 +48,7 @@ export declare const canPrev: (visibleItems: any[], selectedItems: any[]) => boo
|
|
|
44
48
|
export declare const getPrev: (visibleItems: any[], selectedItems: any[]) => any;
|
|
45
49
|
export declare const calcSaveFormTitle: (rootTitle: string | undefined, formMode: FormModes, updateId: number | undefined, pathKeys: string[] | undefined) => string;
|
|
46
50
|
export declare function calcIsModified(formData: any, formDataOrig: any): boolean;
|
|
47
|
-
export { openApps, calcResponsiveDirection, calcResponsiveSizes, getColor, genUniqueId, makeID, MOBILE_WIDTH, TABLET_WIDTH };
|
|
51
|
+
export { openApps, calcResponsiveDirection, calcResponsiveSizes, taskModalSizes, getColor, genUniqueId, makeID, MOBILE_WIDTH, TABLET_WIDTH };
|
|
48
52
|
export declare function moduleVersion(module: moduleTypes): string;
|
|
49
53
|
export declare function buildtype(module: moduleTypes): string;
|
|
50
54
|
export declare const highlightText: (text: string, searchValue: string) => JSX.Element;
|
package/lib/helper/helpers.js
CHANGED
|
@@ -7,6 +7,27 @@ import { buildTypes, FileExtensionHandler, FormModes, moduleTypes } from "../ts"
|
|
|
7
7
|
import { SDKUI_Localizator } from "./SDKUI_Localizator";
|
|
8
8
|
import ReactDOMServer from "react-dom/server";
|
|
9
9
|
import { DeepCompareHelper } from "./DeepCompareHelper";
|
|
10
|
+
const calcResponsiveSizes = (deviceType, desktopSize, tabletSize, mobileSize) => {
|
|
11
|
+
if (deviceType === DeviceType.DESKTOP)
|
|
12
|
+
return desktopSize;
|
|
13
|
+
if (deviceType === DeviceType.TABLET)
|
|
14
|
+
return tabletSize;
|
|
15
|
+
return mobileSize;
|
|
16
|
+
};
|
|
17
|
+
const taskModalSizes = (deviceType, formMode) => {
|
|
18
|
+
switch (formMode) {
|
|
19
|
+
case FormModes.Create:
|
|
20
|
+
return {
|
|
21
|
+
width: calcResponsiveSizes(deviceType, '500px', '90%', '95%'),
|
|
22
|
+
height: calcResponsiveSizes(deviceType, '600px', '90%', '95%'),
|
|
23
|
+
};
|
|
24
|
+
default:
|
|
25
|
+
return {
|
|
26
|
+
width: calcResponsiveSizes(deviceType, '670px', '90%', '95%'),
|
|
27
|
+
height: calcResponsiveSizes(deviceType, '770px', '90%', '95%'),
|
|
28
|
+
};
|
|
29
|
+
}
|
|
30
|
+
};
|
|
10
31
|
//#region Responsive Helpers
|
|
11
32
|
const TABLET_WIDTH = 1024;
|
|
12
33
|
const MOBILE_WIDTH = 640;
|
|
@@ -50,13 +71,6 @@ export const setSDK_GlobalsInfoAsync = async (tms) => {
|
|
|
50
71
|
return undefined;
|
|
51
72
|
}
|
|
52
73
|
};
|
|
53
|
-
const calcResponsiveSizes = (deviceType, desktopSize, tabletSize, mobileSize) => {
|
|
54
|
-
if (deviceType === DeviceType.DESKTOP)
|
|
55
|
-
return desktopSize;
|
|
56
|
-
if (deviceType === DeviceType.TABLET)
|
|
57
|
-
return tabletSize;
|
|
58
|
-
return mobileSize;
|
|
59
|
-
};
|
|
60
74
|
//#endregion
|
|
61
75
|
const getColor = (color) => {
|
|
62
76
|
let c = '';
|
|
@@ -540,6 +554,7 @@ export const getMoreInfoTasksForDocument = (allTasks, TID, DID) => {
|
|
|
540
554
|
return [];
|
|
541
555
|
return allTasks.filter(task => isTaskMoreInfo(task.name) &&
|
|
542
556
|
task.state !== Task_States.Completed &&
|
|
557
|
+
task.state !== Task_States.Closed &&
|
|
543
558
|
task.iD1?.toString() === TID.toString() &&
|
|
544
559
|
task.iD2?.toString() === DID.toString());
|
|
545
560
|
};
|
|
@@ -616,7 +631,7 @@ export function calcIsModified(formData, formDataOrig) {
|
|
|
616
631
|
return JSON.stringify(formData) !== JSON.stringify(formDataOrig);
|
|
617
632
|
}
|
|
618
633
|
//#endregion
|
|
619
|
-
export { openApps, calcResponsiveDirection, calcResponsiveSizes, getColor, genUniqueId, makeID, MOBILE_WIDTH, TABLET_WIDTH };
|
|
634
|
+
export { openApps, calcResponsiveDirection, calcResponsiveSizes, taskModalSizes, getColor, genUniqueId, makeID, MOBILE_WIDTH, TABLET_WIDTH };
|
|
620
635
|
export function moduleVersion(module) {
|
|
621
636
|
switch (module) {
|
|
622
637
|
case moduleTypes.SDK: return SDK_Globals.sdkVersion ?? '0.0.0';
|
package/lib/helper/index.d.ts
CHANGED
package/lib/helper/index.js
CHANGED
|
@@ -49,7 +49,7 @@ export const IsParametricQuery = (qd) => {
|
|
|
49
49
|
return false;
|
|
50
50
|
};
|
|
51
51
|
export const addHiddenSelectItem = (select, tid, mid) => {
|
|
52
|
-
if (select.findIndex(o => o.mid == mid) >= 0)
|
|
52
|
+
if (select.findIndex(o => o.tid == tid && o.mid == mid) >= 0)
|
|
53
53
|
return;
|
|
54
54
|
let si = new SelectItem();
|
|
55
55
|
si.tid = tid;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare const useBetaFeatures: () => boolean;
|
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
import { useEffect, useMemo } from 'react';
|
|
2
|
+
import { SDK_Globals } from '@topconsultnpm/sdk-ts';
|
|
3
|
+
import { SDKUI_Globals } from '../helper';
|
|
4
|
+
import { ShowAlert } from '../components';
|
|
5
|
+
export const useBetaFeatures = () => {
|
|
6
|
+
const tmSession = SDK_Globals.tmSession;
|
|
7
|
+
const archiveId = tmSession?.SessionDescr?.archiveID;
|
|
8
|
+
const userId = tmSession?.SessionDescr?.userID;
|
|
9
|
+
const isBetaFeaturesEnabled = useMemo(() => {
|
|
10
|
+
return SDKUI_Globals.userSettings.devSettings?.betaFeatures === 1;
|
|
11
|
+
}, [archiveId, userId]);
|
|
12
|
+
useEffect(() => {
|
|
13
|
+
const handleBetaFeaturesShortcut = (e) => {
|
|
14
|
+
if (e.ctrlKey && e.altKey && e.key.toLowerCase() === 'y') {
|
|
15
|
+
e.preventDefault();
|
|
16
|
+
e.stopPropagation();
|
|
17
|
+
e.stopImmediatePropagation();
|
|
18
|
+
const currentValue = SDKUI_Globals.userSettings.devSettings?.betaFeatures;
|
|
19
|
+
const isCurrentlyEnabled = currentValue === 1;
|
|
20
|
+
if (isCurrentlyEnabled) {
|
|
21
|
+
SDKUI_Globals.userSettings.devSettings = undefined;
|
|
22
|
+
}
|
|
23
|
+
else {
|
|
24
|
+
SDKUI_Globals.userSettings.devSettings = { betaFeatures: 1 };
|
|
25
|
+
}
|
|
26
|
+
const status = isCurrentlyEnabled ? 'disabilitato' : 'abilitato';
|
|
27
|
+
ShowAlert({
|
|
28
|
+
message: `Beta features ${status}! Saranno ${status === 'abilitato' ? 'disponibili' : 'nascoste'} al prossimo login.`,
|
|
29
|
+
mode: 'info',
|
|
30
|
+
duration: 5000,
|
|
31
|
+
title: 'Beta Features'
|
|
32
|
+
});
|
|
33
|
+
}
|
|
34
|
+
};
|
|
35
|
+
globalThis.addEventListener('keydown', handleBetaFeaturesShortcut);
|
|
36
|
+
return () => {
|
|
37
|
+
globalThis.removeEventListener('keydown', handleBetaFeaturesShortcut);
|
|
38
|
+
};
|
|
39
|
+
}, []);
|
|
40
|
+
return isBetaFeaturesEnabled;
|
|
41
|
+
};
|
|
@@ -8,6 +8,18 @@ import { useFileDialog } from './useInputDialog';
|
|
|
8
8
|
import { isXMLFileExt } from '../helper/dcmtsHelper';
|
|
9
9
|
import { ShowConfirm } from '../components/base/TMConfirm';
|
|
10
10
|
let abortController = new AbortController();
|
|
11
|
+
const downloadCountMap = new Map();
|
|
12
|
+
const getDownloadFileName = (fileName) => {
|
|
13
|
+
const firstDot = fileName.indexOf('.');
|
|
14
|
+
const lastDot = fileName.lastIndexOf('.');
|
|
15
|
+
if (firstDot === -1 || firstDot === lastDot)
|
|
16
|
+
return fileName;
|
|
17
|
+
const count = downloadCountMap.get(fileName) ?? 0;
|
|
18
|
+
downloadCountMap.set(fileName, count + 1);
|
|
19
|
+
if (count === 0)
|
|
20
|
+
return fileName;
|
|
21
|
+
return `${fileName.slice(0, firstDot)}(${count})${fileName.slice(firstDot)}`;
|
|
22
|
+
};
|
|
11
23
|
export function useDcmtOperations() {
|
|
12
24
|
const [showWaitPanel, setShowWaitPanel] = useState(false);
|
|
13
25
|
const [waitPanelTitle, setWaitPanelTitle] = useState('');
|
|
@@ -96,8 +108,8 @@ export function useDcmtOperations() {
|
|
|
96
108
|
else {
|
|
97
109
|
const alink2 = document.createElement('a');
|
|
98
110
|
alink2.href = fileURL;
|
|
99
|
-
const
|
|
100
|
-
alink2.download =
|
|
111
|
+
const baseFileName = inputDcmts[i].fileName ?? (inputDcmts[i].FILEEXT ? `${inputDcmts[i].DID}.${inputDcmts[i].FILEEXT}` : file?.name);
|
|
112
|
+
alink2.download = getDownloadFileName(baseFileName);
|
|
101
113
|
alink2.target = "_blank";
|
|
102
114
|
alink2.rel = "noreferrer";
|
|
103
115
|
alink2.click();
|
|
@@ -225,9 +225,6 @@ export const useRelatedDocuments = ({ selectedSearchResult, focusedItem, current
|
|
|
225
225
|
const filterRelationsWithAssociations = (relations) => {
|
|
226
226
|
return relations.filter(rel => rel.associations && rel.associations.length > 0);
|
|
227
227
|
};
|
|
228
|
-
const getRelatedDcmt = async (relation, type) => {
|
|
229
|
-
return await DcmtTypeListCacheService.GetAsync(type === 'detail' ? relation.detailTID : relation.masterTID);
|
|
230
|
-
};
|
|
231
228
|
const showNoRelationsAlert = (type) => {
|
|
232
229
|
ShowAlert({
|
|
233
230
|
message: type === 'detail'
|
|
@@ -282,6 +279,26 @@ export const useRelatedDocuments = ({ selectedSearchResult, focusedItem, current
|
|
|
282
279
|
TMExceptionBoxManager.show({ exception: error });
|
|
283
280
|
}
|
|
284
281
|
}, [mapAssociationsToMids]);
|
|
282
|
+
const filterRelationsByPermission = async (relations, type) => {
|
|
283
|
+
const dataSourcePromises = relations.map(async (rel) => {
|
|
284
|
+
const targetTID = type === 'detail' ? rel.detailTID : rel.masterTID;
|
|
285
|
+
const dtd = await DcmtTypeListCacheService.GetWithNotGrantedAsync(targetTID, undefined);
|
|
286
|
+
const hasPermission = dtd?.perm?.canArchive === AccessLevelsEx.Yes || dtd?.perm?.canArchive === AccessLevelsEx.Mixed;
|
|
287
|
+
return { id: rel?.id, name: dtd?.name, hasPermission, relation: rel };
|
|
288
|
+
});
|
|
289
|
+
const allResults = await Promise.all(dataSourcePromises);
|
|
290
|
+
return allResults.filter(r => r.hasPermission);
|
|
291
|
+
};
|
|
292
|
+
const showNoPermissionAlert = (type) => {
|
|
293
|
+
ShowAlert({
|
|
294
|
+
message: type === 'detail'
|
|
295
|
+
? SDKUI_Localizator.YouDoNotHavePermissionsToArchiveDetailDocumentsOfThisType
|
|
296
|
+
: SDKUI_Localizator.YouDoNotHavePermissionsToArchiveMasterDocumentsOfThisType,
|
|
297
|
+
mode: 'warning',
|
|
298
|
+
title: type === 'detail' ? SDKUI_Localizator.DcmtsDetail : SDKUI_Localizator.DcmtsMaster,
|
|
299
|
+
duration: 5000
|
|
300
|
+
});
|
|
301
|
+
};
|
|
285
302
|
const archiveRelatedDocuments = useCallback(async (tid, type) => {
|
|
286
303
|
try {
|
|
287
304
|
TMSpinner.show({ description: SDKUI_Localizator.Loading });
|
|
@@ -300,14 +317,20 @@ export const useRelatedDocuments = ({ selectedSearchResult, focusedItem, current
|
|
|
300
317
|
}
|
|
301
318
|
setRelatedDcmts(withAssociations);
|
|
302
319
|
if (withAssociations.length > 1) {
|
|
303
|
-
const
|
|
304
|
-
|
|
305
|
-
|
|
306
|
-
|
|
307
|
-
|
|
308
|
-
|
|
309
|
-
|
|
310
|
-
|
|
320
|
+
const permittedResults = await filterRelationsByPermission(withAssociations, type);
|
|
321
|
+
if (permittedResults.length === 0) {
|
|
322
|
+
showNoPermissionAlert(type);
|
|
323
|
+
return;
|
|
324
|
+
}
|
|
325
|
+
if (permittedResults.length === 1) {
|
|
326
|
+
await archiveRelatedDcmtHandler(permittedResults[0].relation, type);
|
|
327
|
+
}
|
|
328
|
+
else {
|
|
329
|
+
const dataSource = permittedResults.map(r => ({ id: r.id, name: r.name }));
|
|
330
|
+
setRelatedDcmtsChooserDataSource(dataSource);
|
|
331
|
+
setArchiveType(type);
|
|
332
|
+
setShowRelatedDcmtsChooser(true);
|
|
333
|
+
}
|
|
311
334
|
}
|
|
312
335
|
else {
|
|
313
336
|
await archiveRelatedDcmtHandler(withAssociations[0], type);
|
package/lib/index.d.ts
CHANGED
package/lib/index.js
CHANGED
|
@@ -10,6 +10,7 @@ export * from './hooks/useResizeObserver';
|
|
|
10
10
|
export * from './hooks/useWorkflowApprove';
|
|
11
11
|
export * from './hooks/useRelatedDocuments';
|
|
12
12
|
export * from './hooks/useSettingsFeedback';
|
|
13
|
+
export * from './hooks/useBetaFeatures';
|
|
13
14
|
export * from './services';
|
|
14
15
|
import config from 'devextreme/core/config';
|
|
15
16
|
// DevExtreme License Key (valid for v25.2 and earlier versions)
|