@topconsultnpm/sdkui-react 6.21.0-t2 → 6.21.0-t3
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/NewComponents/ContextMenu/TMContextMenu.js +22 -1
- package/lib/components/NewComponents/ContextMenu/styles.d.ts +4 -4
- package/lib/components/NewComponents/FloatingMenuBar/styles.d.ts +6 -6
- package/lib/components/base/Styled.d.ts +1 -1
- package/lib/components/base/TMAreaManager.js +11 -0
- package/lib/components/base/TMCounterBar.d.ts +2 -2
- package/lib/components/base/TMCounterContainer.d.ts +2 -1
- package/lib/components/base/TMCustomButton.d.ts +1 -1
- package/lib/components/base/TMDataGrid.js +12 -2
- package/lib/components/base/TMDataGridExportForm.d.ts +2 -1
- package/lib/components/base/TMDataGridExportForm.js +19 -8
- package/lib/components/base/TMFileManager.d.ts +2 -1
- package/lib/components/base/TMFileManagerDataGridView.d.ts +2 -1
- package/lib/components/base/TMFileManagerDataGridView.js +4 -4
- package/lib/components/base/TMFileManagerThumbnailItems.d.ts +1 -1
- package/lib/components/base/TMFileManagerThumbnailItems.js +3 -3
- package/lib/components/base/TMFileManagerThumbnailsView.d.ts +1 -1
- package/lib/components/base/TMFileManagerUtils.d.ts +7 -0
- package/lib/components/base/TMFileManagerUtils.js +14 -1
- package/lib/components/base/TMLayout.d.ts +4 -4
- package/lib/components/base/TMList.d.ts +2 -1
- package/lib/components/base/TMListView.d.ts +1 -1
- package/lib/components/base/TMModal.js +2 -2
- package/lib/components/base/TMPopUp.d.ts +1 -0
- package/lib/components/base/TMPopUp.js +59 -2
- package/lib/components/base/TMSpinner.d.ts +5 -2
- package/lib/components/base/TMSpinner.js +33 -6
- package/lib/components/base/TMTab.d.ts +4 -3
- package/lib/components/base/TMTooltip.d.ts +1 -1
- package/lib/components/base/TMTreeView.d.ts +1 -1
- package/lib/components/base/TMTreeView.js +12 -15
- package/lib/components/base/TMUserAvatar.d.ts +2 -1
- package/lib/components/base/TMVilViewer.d.ts +2 -1
- package/lib/components/base/TMWaitPanel.d.ts +5 -2
- package/lib/components/base/TMWaitPanel.js +8 -6
- package/lib/components/choosers/TMDynDataListItemChooser.d.ts +1 -1
- package/lib/components/choosers/TMDynDataListItemChooser.js +6 -1
- package/lib/components/choosers/TMGroupChooser.js +1 -1
- package/lib/components/choosers/TMInvoiceRetrieveFormats.d.ts +2 -1
- package/lib/components/choosers/TMOrderRetrieveFormats.d.ts +2 -1
- package/lib/components/choosers/TMRelationChooser.d.ts +3 -3
- package/lib/components/choosers/TMUserChooser.d.ts +2 -2
- package/lib/components/editors/TMEditorStyled.d.ts +6 -6
- package/lib/components/editors/TMFormulaEditor.d.ts +2 -1
- package/lib/components/editors/TMFormulaEditor.js +98 -49
- package/lib/components/editors/TMHtmlContentDisplay.d.ts +2 -1
- package/lib/components/editors/TMHtmlEditor.d.ts +2 -1
- package/lib/components/editors/TMMetadataEditor.js +6 -2
- package/lib/components/editors/TMMetadataValues.js +23 -6
- package/lib/components/editors/TMTreeDropDown.d.ts +1 -1
- package/lib/components/features/assistant/TMToppyDraggableHelpCenter.d.ts +1 -1
- package/lib/components/features/blog/TMBlogCommentForm.d.ts +2 -1
- package/lib/components/features/blog/TMBlogCommentForm.js +5 -2
- package/lib/components/features/documents/TMCopyToFolderForm.js +46 -24
- package/lib/components/features/documents/TMDcmtForm.js +19 -9
- package/lib/components/features/documents/TMDcmtFormActionButtons.d.ts +1 -1
- package/lib/components/features/documents/TMDcmtIcon.d.ts +2 -1
- package/lib/components/features/documents/TMDcmtIcon.js +1 -1
- package/lib/components/features/documents/TMDcmtPreview.d.ts +1 -1
- package/lib/components/features/documents/TMDcmtTasks.d.ts +2 -1
- package/lib/components/features/documents/TMDragDropOverlay.d.ts +1 -1
- package/lib/components/features/documents/TMMasterDetailDcmts.d.ts +0 -2
- package/lib/components/features/documents/TMMasterDetailDcmts.js +4 -5
- package/lib/components/features/documents/TMMergeToPdfForm.d.ts +0 -2
- package/lib/components/features/documents/TMMergeToPdfForm.js +26 -10
- package/lib/components/features/documents/TMRelationViewer.js +8 -3
- package/lib/components/features/documents/copyAndMergeDcmtsShared.d.ts +0 -13
- package/lib/components/features/documents/copyAndMergeDcmtsShared.js +1 -39
- package/lib/components/features/search/TMDcmtCheckoutInfoForm.d.ts +2 -1
- package/lib/components/features/search/TMMetadataOutputForm.d.ts +18 -0
- package/lib/components/features/search/TMMetadataOutputForm.js +225 -0
- package/lib/components/features/search/TMMetadataSorterForm.d.ts +18 -0
- package/lib/components/features/search/TMMetadataSorterForm.js +243 -0
- package/lib/components/features/search/TMSavedQuerySelector.d.ts +2 -2
- package/lib/components/features/search/TMSearch.d.ts +0 -2
- package/lib/components/features/search/TMSearch.js +2 -2
- package/lib/components/features/search/TMSearchQueryEditor.js +14 -8
- package/lib/components/features/search/TMSearchQueryPanel.js +249 -58
- package/lib/components/features/search/TMSearchResult.d.ts +1 -2
- package/lib/components/features/search/TMSearchResult.js +40 -20
- package/lib/components/features/search/TMSearchResultFloatingActionButton.d.ts +1 -1
- package/lib/components/features/search/TMSignatureInfoContent.d.ts +2 -1
- package/lib/components/features/search/TMViewHistoryDcmt.d.ts +2 -1
- package/lib/components/features/search/TMViewHistoryDcmt.js +1 -1
- package/lib/components/features/search/metadataFormHelper.d.ts +16 -0
- package/lib/components/features/search/metadataFormHelper.js +77 -0
- package/lib/components/features/tasks/TMTaskForm.d.ts +1 -1
- package/lib/components/features/tasks/TMTaskFormUtils.d.ts +10 -10
- package/lib/components/features/tasks/TMTasksAgenda.d.ts +1 -1
- package/lib/components/features/tasks/TMTasksCalendar.d.ts +1 -1
- package/lib/components/features/tasks/TMTasksHeader.d.ts +1 -1
- package/lib/components/features/tasks/TMTasksPanelContent.d.ts +1 -1
- package/lib/components/features/tasks/TMTasksUtilsView.d.ts +5 -5
- package/lib/components/features/tasks/TMTasksView.d.ts +1 -1
- package/lib/components/features/wg/TMWGsCopyMoveForm.d.ts +3 -2
- package/lib/components/features/workflow/TMWorkflowPopup.d.ts +8 -7
- package/lib/components/forms/Login/Chooser.d.ts +2 -2
- package/lib/components/forms/Login/TMLoginForm.js +15 -3
- package/lib/components/forms/TMChooserForm.d.ts +2 -1
- package/lib/components/forms/TMSaveForm.d.ts +4 -4
- package/lib/components/grids/TMBlogAttachments.d.ts +2 -1
- package/lib/components/grids/TMBlogAttachments.js +2 -2
- package/lib/components/grids/TMBlogHeader.d.ts +1 -1
- package/lib/components/grids/TMBlogsPost.d.ts +1 -1
- package/lib/components/grids/TMBlogsPost.js +5 -3
- package/lib/components/grids/TMBlogsPostUtils.d.ts +10 -9
- package/lib/components/grids/TMBlogsPostUtils.js +3 -1
- package/lib/components/grids/TMValidationItemsList.d.ts +2 -1
- package/lib/components/layout/panelManager/TMPanelManagerContainer.d.ts +2 -1
- package/lib/components/layout/panelManager/TMPanelManagerContext.d.ts +2 -2
- package/lib/components/layout/panelManager/TMPanelManagerToolbar.d.ts +1 -1
- package/lib/components/layout/panelManager/TMPanelManagerWithPersistenceProvider.d.ts +2 -2
- package/lib/components/layout/panelManager/TMPanelWrapper.d.ts +2 -2
- package/lib/components/pages/TMPage.d.ts +1 -1
- package/lib/components/settings/SettingsAppearance.d.ts +2 -1
- package/lib/components/sidebar/TMAboutApp.d.ts +2 -1
- package/lib/components/sidebar/TMHeader.d.ts +3 -3
- package/lib/components/viewers/TMDataListItemViewer.d.ts +3 -2
- package/lib/components/viewers/TMDataUserIdItemViewer.d.ts +3 -2
- package/lib/components/viewers/TMMidViewer.d.ts +2 -2
- package/lib/components/viewers/TMTidViewer.d.ts +2 -2
- package/lib/components/wizard/TMWizard.d.ts +1 -0
- package/lib/components/wizard/TMWizard.js +5 -3
- package/lib/helper/Enum_Localizator.js +1 -0
- package/lib/helper/MergePdfManager.d.ts +45 -0
- package/lib/helper/MergePdfManager.js +148 -0
- package/lib/helper/SDKUI_Globals.js +2 -1
- package/lib/helper/SDKUI_Localizator.d.ts +6 -0
- package/lib/helper/SDKUI_Localizator.js +60 -0
- package/lib/helper/TMCommandsContextMenu.d.ts +1 -1
- package/lib/helper/TMIcons.d.ts +278 -278
- package/lib/helper/TMPdfViewer.d.ts +2 -1
- package/lib/helper/TMToppyMessage.d.ts +2 -2
- package/lib/helper/TMUtils.d.ts +24 -20
- package/lib/helper/TMUtils.js +55 -0
- package/lib/helper/checkinCheckoutManager.d.ts +4 -3
- package/lib/helper/checkinCheckoutManager.js +29 -11
- package/lib/helper/helpers.d.ts +3 -2
- package/lib/helper/helpers.js +1 -0
- package/lib/hooks/useCheckInOutOperations.d.ts +4 -3
- package/lib/hooks/useDataUserIdItem.js +1 -1
- package/lib/hooks/useDcmtOperations.d.ts +18 -1
- package/lib/hooks/useDcmtOperations.js +235 -24
- package/lib/hooks/useDocumentOperations.d.ts +0 -2
- package/lib/hooks/useDocumentOperations.js +27 -10
- package/lib/hooks/useInputDialog.d.ts +2 -1
- package/lib/hooks/useRelatedDocuments.js +4 -4
- package/lib/services/platform_services.d.ts +7 -6
- package/lib/ts/types.d.ts +2 -1
- package/lib/ts/types.js +1 -0
- package/package.json +14 -7
|
@@ -142,7 +142,7 @@ const TMViewHistoryDcmt = (props) => {
|
|
|
142
142
|
files.push({ TID: Number(focusedRow.TID), DID: Number(focusedRow.DID), FILEEXT: focusedRow.FileExt });
|
|
143
143
|
}
|
|
144
144
|
if (files.length > 0)
|
|
145
|
-
await downloadDcmtsAsync(files, DownloadTypes.Dcmt, "download");
|
|
145
|
+
await downloadDcmtsAsync({ inputDcmts: files, downloadType: DownloadTypes.Dcmt, downloadMode: "download" });
|
|
146
146
|
};
|
|
147
147
|
const deleteFilesCallback = () => {
|
|
148
148
|
if (!focusedRowKey)
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import { DcmtTypeDescriptor, MetadataDescriptor, QueryDescriptor } from "@topconsultnpm/sdk-ts";
|
|
2
|
+
export type MetadataDescriptorWithKey = MetadataDescriptor & {
|
|
3
|
+
uniqueKey: string;
|
|
4
|
+
};
|
|
5
|
+
export declare function removeDuplicatesByTidMid<T extends {
|
|
6
|
+
tid?: number;
|
|
7
|
+
mid?: number;
|
|
8
|
+
}>(items: T[]): T[];
|
|
9
|
+
export declare function loadMetadataFromQd(qd: QueryDescriptor | undefined, filterMetadata?: (value: MetadataDescriptor, index: number, array: MetadataDescriptor[]) => unknown): Promise<{
|
|
10
|
+
metadata: MetadataDescriptorWithKey[];
|
|
11
|
+
dcmtTypes: DcmtTypeDescriptor[];
|
|
12
|
+
}>;
|
|
13
|
+
export declare function areArraysEqual<T extends {
|
|
14
|
+
tid?: number;
|
|
15
|
+
mid?: number;
|
|
16
|
+
}>(arr1: T[], arr2: T[], additionalCompare?: (a: T, b: T) => boolean): boolean;
|
|
@@ -0,0 +1,77 @@
|
|
|
1
|
+
import { DcmtTypeDescriptor, DcmtTypeListCacheService, SDK_Localizator } from "@topconsultnpm/sdk-ts";
|
|
2
|
+
import { getTIDsByQd } from "../../../helper/queryHelper";
|
|
3
|
+
import { SDKUI_Localizator } from "../../../helper";
|
|
4
|
+
import TMSpinner from "../../base/TMSpinner";
|
|
5
|
+
// =============================================================================
|
|
6
|
+
// HELPER: Rimuove duplicati dalla lista (basato su tid + mid)
|
|
7
|
+
// =============================================================================
|
|
8
|
+
export function removeDuplicatesByTidMid(items) {
|
|
9
|
+
const seen = new Set();
|
|
10
|
+
return items.filter(item => {
|
|
11
|
+
const key = `${item.tid}_${item.mid}`;
|
|
12
|
+
if (seen.has(key))
|
|
13
|
+
return false;
|
|
14
|
+
seen.add(key);
|
|
15
|
+
return true;
|
|
16
|
+
});
|
|
17
|
+
}
|
|
18
|
+
// =============================================================================
|
|
19
|
+
// FUNZIONE PRINCIPALE: Estrae i metadati dal QueryDescriptor
|
|
20
|
+
// =============================================================================
|
|
21
|
+
export async function loadMetadataFromQd(qd, filterMetadata) {
|
|
22
|
+
if (!qd)
|
|
23
|
+
return { metadata: [], dcmtTypes: [] };
|
|
24
|
+
const dtdList = [];
|
|
25
|
+
const metadata = [];
|
|
26
|
+
try {
|
|
27
|
+
const tidsFromQd = getTIDsByQd(qd);
|
|
28
|
+
const inputTIDs = tidsFromQd.map((item) => item.tid);
|
|
29
|
+
if (inputTIDs.length === 0)
|
|
30
|
+
return { metadata: [], dcmtTypes: [] };
|
|
31
|
+
TMSpinner.show({ description: `${SDKUI_Localizator.Loading} - ${SDK_Localizator.DcmtType} ...` });
|
|
32
|
+
const dtds = await DcmtTypeListCacheService.GetFromTIDsAsync(inputTIDs, true, undefined, false, false);
|
|
33
|
+
for (let i = 0; i < dtds.length; i++) {
|
|
34
|
+
const dtd = new DcmtTypeDescriptor();
|
|
35
|
+
dtd.init({ ...dtds[i] });
|
|
36
|
+
const alias = tidsFromQd?.[i]?.alias ?? '';
|
|
37
|
+
dtd.customData2 = alias;
|
|
38
|
+
dtd.metadata?.forEach((md) => {
|
|
39
|
+
const mdWithKey = md;
|
|
40
|
+
mdWithKey.customData1 = dtd.id;
|
|
41
|
+
mdWithKey.customData2 = alias;
|
|
42
|
+
mdWithKey.uniqueKey = `${dtd.id}_${md.id}_${alias}`;
|
|
43
|
+
});
|
|
44
|
+
const filteredMetadata = filterMetadata
|
|
45
|
+
? dtd.metadata?.filter(filterMetadata)
|
|
46
|
+
: dtd.metadata;
|
|
47
|
+
dtdList.push({ ...dtd, metadata: filteredMetadata });
|
|
48
|
+
}
|
|
49
|
+
for (const dtd of dtdList) {
|
|
50
|
+
if (!dtd.metadata)
|
|
51
|
+
continue;
|
|
52
|
+
for (const md of dtd.metadata) {
|
|
53
|
+
metadata.push(md);
|
|
54
|
+
}
|
|
55
|
+
}
|
|
56
|
+
return { metadata, dcmtTypes: dtdList };
|
|
57
|
+
}
|
|
58
|
+
finally {
|
|
59
|
+
TMSpinner.hide();
|
|
60
|
+
}
|
|
61
|
+
}
|
|
62
|
+
// =============================================================================
|
|
63
|
+
// HELPER: Confronta due array per determinare se sono stati modificati
|
|
64
|
+
// =============================================================================
|
|
65
|
+
export function areArraysEqual(arr1, arr2, additionalCompare) {
|
|
66
|
+
if (arr1.length !== arr2.length)
|
|
67
|
+
return false;
|
|
68
|
+
for (let i = 0; i < arr1.length; i++) {
|
|
69
|
+
const a = arr1[i];
|
|
70
|
+
const b = arr2[i];
|
|
71
|
+
if (a.tid !== b.tid || a.mid !== b.mid)
|
|
72
|
+
return false;
|
|
73
|
+
if (additionalCompare && !additionalCompare(a, b))
|
|
74
|
+
return false;
|
|
75
|
+
}
|
|
76
|
+
return true;
|
|
77
|
+
}
|
|
@@ -36,5 +36,5 @@ export interface TMTaskFormProps {
|
|
|
36
36
|
onOpenPdfEditorRequest?: (dcmtInfo: Array<DcmtInfo>, refreshDocumentPreview?: () => Promise<void>) => void;
|
|
37
37
|
s4TViewerDialogComponent?: React.ReactNode;
|
|
38
38
|
}
|
|
39
|
-
declare const TMTaskForm: (props: TMTaskFormProps) =>
|
|
39
|
+
declare const TMTaskForm: (props: TMTaskFormProps) => React.JSX.Element;
|
|
40
40
|
export default TMTaskForm;
|
|
@@ -8,7 +8,7 @@ interface TaskFormAssignmentNoticeSectionProps {
|
|
|
8
8
|
users: Array<UserDescriptor>;
|
|
9
9
|
requestMoreInfo?: boolean;
|
|
10
10
|
}
|
|
11
|
-
export declare const TaskFormAssignmentNoticeBadge: (props: TaskFormAssignmentNoticeSectionProps) =>
|
|
11
|
+
export declare const TaskFormAssignmentNoticeBadge: (props: TaskFormAssignmentNoticeSectionProps) => React.JSX.Element | null;
|
|
12
12
|
interface RenderContextBlockParams {
|
|
13
13
|
condition: boolean;
|
|
14
14
|
pdg: PdGs;
|
|
@@ -19,7 +19,7 @@ interface TaskFormContextualAttachmentsProps {
|
|
|
19
19
|
currentTask: TaskDescriptor | undefined;
|
|
20
20
|
taskContext: TaskContext | undefined;
|
|
21
21
|
}
|
|
22
|
-
export declare const TaskFormContextualAttachments: (props: TaskFormContextualAttachmentsProps) =>
|
|
22
|
+
export declare const TaskFormContextualAttachments: (props: TaskFormContextualAttachmentsProps) => React.JSX.Element;
|
|
23
23
|
interface TaskFormAssignedToProps {
|
|
24
24
|
formMode: FormModes;
|
|
25
25
|
formData: TaskDescriptor | undefined;
|
|
@@ -31,7 +31,7 @@ interface TaskFormAssignedToProps {
|
|
|
31
31
|
label?: string;
|
|
32
32
|
onValueChanged: (newValue: Array<number> | undefined) => void;
|
|
33
33
|
}
|
|
34
|
-
export declare const TaskAssigneeField: (props: TaskFormAssignedToProps) =>
|
|
34
|
+
export declare const TaskAssigneeField: (props: TaskFormAssignedToProps) => React.JSX.Element;
|
|
35
35
|
interface RenderFieldBaseProps {
|
|
36
36
|
fieldsReadOnly: IFieldsEditability;
|
|
37
37
|
formDataOrig?: TaskDescriptor;
|
|
@@ -50,12 +50,12 @@ interface RenderDateFieldProps extends RenderFieldProps {
|
|
|
50
50
|
label?: string;
|
|
51
51
|
onContentReady?: () => void;
|
|
52
52
|
}
|
|
53
|
-
export declare const RenderNameField: ({ requestMoreInfo, validationItems, setFormData, formData, formDataOrig, fieldsReadOnly }: RenderFieldProps) =>
|
|
54
|
-
export declare const RenderDescriptionField: ({ validationItems, setFormData, formData, formDataOrig, fieldsReadOnly }: RenderFieldProps) =>
|
|
55
|
-
export declare const RenderPriorityField: ({ formData, formDataOrig, fieldsReadOnly, onPriorityValueChange }: RenderPriorityFieldProps) =>
|
|
56
|
-
export declare const RenderStartDateField: ({ label, validationItems, setFormData, formData, formDataOrig, fieldsReadOnly, onContentReady }: RenderDateFieldProps) =>
|
|
57
|
-
export declare const RenderEndDateField: ({ label, validationItems, setFormData, formData, formDataOrig, fieldsReadOnly, onContentReady }: RenderDateFieldProps) =>
|
|
58
|
-
export declare const RenderRemindDateField: ({ validationItems, setFormData, formData, formDataOrig, fieldsReadOnly }: RenderFieldProps) =>
|
|
53
|
+
export declare const RenderNameField: ({ requestMoreInfo, validationItems, setFormData, formData, formDataOrig, fieldsReadOnly }: RenderFieldProps) => React.JSX.Element;
|
|
54
|
+
export declare const RenderDescriptionField: ({ validationItems, setFormData, formData, formDataOrig, fieldsReadOnly }: RenderFieldProps) => React.JSX.Element;
|
|
55
|
+
export declare const RenderPriorityField: ({ formData, formDataOrig, fieldsReadOnly, onPriorityValueChange }: RenderPriorityFieldProps) => React.JSX.Element;
|
|
56
|
+
export declare const RenderStartDateField: ({ label, validationItems, setFormData, formData, formDataOrig, fieldsReadOnly, onContentReady }: RenderDateFieldProps) => React.JSX.Element;
|
|
57
|
+
export declare const RenderEndDateField: ({ label, validationItems, setFormData, formData, formDataOrig, fieldsReadOnly, onContentReady }: RenderDateFieldProps) => React.JSX.Element;
|
|
58
|
+
export declare const RenderRemindDateField: ({ validationItems, setFormData, formData, formDataOrig, fieldsReadOnly }: RenderFieldProps) => React.JSX.Element;
|
|
59
59
|
interface RenderTaskFormStateFieldProps {
|
|
60
60
|
formDataOrig: TaskDescriptor | undefined;
|
|
61
61
|
formData: TaskDescriptor | undefined;
|
|
@@ -71,7 +71,7 @@ interface TMChangeStateFormProps {
|
|
|
71
71
|
handleShowChangeStateForm: (value: boolean) => void;
|
|
72
72
|
setFormData: React.Dispatch<React.SetStateAction<TaskDescriptor | undefined>>;
|
|
73
73
|
}
|
|
74
|
-
export declare const TMChangeStateForm: (props: TMChangeStateFormProps) =>
|
|
74
|
+
export declare const TMChangeStateForm: (props: TMChangeStateFormProps) => React.JSX.Element;
|
|
75
75
|
type TaskRole = "personal" | "sender" | "receiver";
|
|
76
76
|
type StatusTransitionMap = {
|
|
77
77
|
[key in Task_States]?: Task_States[];
|
|
@@ -15,5 +15,5 @@ interface TMTasksAgendaProps {
|
|
|
15
15
|
handleFocusedRowChange: (row: TaskDescriptor | undefined) => void;
|
|
16
16
|
menuItems: TMContextMenuItemProps[];
|
|
17
17
|
}
|
|
18
|
-
declare const TMTasksAgenda: (props: TMTasksAgendaProps) =>
|
|
18
|
+
declare const TMTasksAgenda: (props: TMTasksAgendaProps) => React.JSX.Element;
|
|
19
19
|
export default TMTasksAgenda;
|
|
@@ -19,5 +19,5 @@ interface TMTasksCalendarProps {
|
|
|
19
19
|
handleFocusedRowChange: (row: TaskDescriptor | undefined) => void;
|
|
20
20
|
menuItems: TMContextMenuItemProps[];
|
|
21
21
|
}
|
|
22
|
-
declare const TMTasksCalendar: (props: TMTasksCalendarProps) =>
|
|
22
|
+
declare const TMTasksCalendar: (props: TMTasksCalendarProps) => React.JSX.Element;
|
|
23
23
|
export default TMTasksCalendar;
|
|
@@ -10,5 +10,5 @@ interface TMTasksHeaderProps {
|
|
|
10
10
|
color?: string;
|
|
11
11
|
height?: string;
|
|
12
12
|
}
|
|
13
|
-
declare const TMTasksHeader: (props: TMTasksHeaderProps) =>
|
|
13
|
+
declare const TMTasksHeader: (props: TMTasksHeaderProps) => React.JSX.Element;
|
|
14
14
|
export default TMTasksHeader;
|
|
@@ -16,5 +16,5 @@ interface TMTasksPanelContentProps {
|
|
|
16
16
|
s4TViewerDialogComponent?: React.ReactNode;
|
|
17
17
|
afterTaskSaved?: (task: TaskDescriptor | undefined, formMode: FormModes | undefined, forceRefresh?: boolean) => Promise<void>;
|
|
18
18
|
}
|
|
19
|
-
declare const TMTasksPanelContent: (props: TMTasksPanelContentProps) =>
|
|
19
|
+
declare const TMTasksPanelContent: (props: TMTasksPanelContentProps) => React.JSX.Element;
|
|
20
20
|
export default TMTasksPanelContent;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { ReactNode } from "react";
|
|
1
|
+
import React, { ReactNode } from "react";
|
|
2
2
|
import { PdGs, Task_States, TaskDescriptor } from '@topconsultnpm/sdk-ts';
|
|
3
3
|
import { FormModes } from "../../../ts";
|
|
4
4
|
export declare const taskStateIconMap: (fontSize?: number) => Map<Task_States, JSX.Element>;
|
|
@@ -12,15 +12,15 @@ export declare const renderTaskIcons: (taskData: {
|
|
|
12
12
|
remTime: Date | undefined;
|
|
13
13
|
isNew: boolean;
|
|
14
14
|
numberOfDays: number;
|
|
15
|
-
}) =>
|
|
15
|
+
}) => React.JSX.Element;
|
|
16
16
|
interface TMActionCalendarProps {
|
|
17
17
|
currentTask: TaskDescriptor;
|
|
18
18
|
openTaskForm: (formMode: FormModes, task?: TaskDescriptor) => void;
|
|
19
19
|
onDeleteCallback: (rowIds: Array<number>) => void;
|
|
20
20
|
}
|
|
21
|
-
export declare const TMActionCalendar: (props: TMActionCalendarProps) =>
|
|
22
|
-
export declare const priorityLegend: () =>
|
|
23
|
-
export declare const highlightTaskText: (text: string, search: string, taskId: number) => string | (string |
|
|
21
|
+
export declare const TMActionCalendar: (props: TMActionCalendarProps) => React.JSX.Element;
|
|
22
|
+
export declare const priorityLegend: () => React.JSX.Element;
|
|
23
|
+
export declare const highlightTaskText: (text: string, search: string, taskId: number) => string | (string | React.JSX.Element)[];
|
|
24
24
|
export declare const treeFilterDataSource: (allTasks: Array<TaskDescriptor>) => Array<{
|
|
25
25
|
id: number;
|
|
26
26
|
label: string;
|
|
@@ -36,5 +36,5 @@ interface TMTasksViewProps {
|
|
|
36
36
|
s4TViewerDialogComponent?: React.ReactNode;
|
|
37
37
|
afterTaskSaved?: (task: TaskDescriptor | undefined, formMode: FormModes | undefined, forceRefresh?: boolean) => Promise<void>;
|
|
38
38
|
}
|
|
39
|
-
declare const TMTasksView: (props: TMTasksViewProps) =>
|
|
39
|
+
declare const TMTasksView: (props: TMTasksViewProps) => React.JSX.Element;
|
|
40
40
|
export default TMTasksView;
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import React from 'react';
|
|
1
2
|
import { DcmtTypeDescriptor, WorkingGroupDescriptor } from "@topconsultnpm/sdk-ts";
|
|
2
3
|
import { FileItem } from '../../base/TMFileManagerUtils';
|
|
3
4
|
/** Context descriptor for copy/move operations using different engines */
|
|
@@ -24,7 +25,7 @@ interface TMWGsCopyMoveFormProps {
|
|
|
24
25
|
fetchTreeFileSystemForWorkingGroup?: (workingGroupId: number | undefined) => Promise<void>;
|
|
25
26
|
fetchArchivedDocumentsForWorkingGroup?: (workingGroupId: number | undefined) => Promise<void>;
|
|
26
27
|
}
|
|
27
|
-
declare const TMWGsCopyMoveForm: (props: TMWGsCopyMoveFormProps) =>
|
|
28
|
+
declare const TMWGsCopyMoveForm: (props: TMWGsCopyMoveFormProps) => React.JSX.Element;
|
|
28
29
|
export default TMWGsCopyMoveForm;
|
|
29
30
|
interface StepItem {
|
|
30
31
|
id: number | string;
|
|
@@ -36,4 +37,4 @@ interface TMStepNavigatorProps {
|
|
|
36
37
|
currentStep: number;
|
|
37
38
|
onStepChange: (stepIndex: number) => void;
|
|
38
39
|
}
|
|
39
|
-
export declare const TMStepNavigator: (props: TMStepNavigatorProps) =>
|
|
40
|
+
export declare const TMStepNavigator: (props: TMStepNavigatorProps) => React.JSX.Element;
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import React from "react";
|
|
1
2
|
import { DcmtTypeDescriptor, HomeBlogPost, TaskDescriptor, WFDescriptor } from '@topconsultnpm/sdk-ts';
|
|
2
3
|
import { DeviceType } from "../../base/TMDeviceProvider";
|
|
3
4
|
import { WorkItemDetail } from "../../../ts";
|
|
@@ -22,7 +23,7 @@ interface IWorkflowOperationButtonsProps {
|
|
|
22
23
|
handleNavigateToWGs?: (value: HomeBlogPost | number) => Promise<void>;
|
|
23
24
|
handleNavigateToDossiers?: (value: HomeBlogPost | number) => Promise<void>;
|
|
24
25
|
}
|
|
25
|
-
export declare const WorkFlowOperationButtons: (props: IWorkflowOperationButtonsProps) =>
|
|
26
|
+
export declare const WorkFlowOperationButtons: (props: IWorkflowOperationButtonsProps) => React.JSX.Element;
|
|
26
27
|
export declare const WorkFlowApproveRejectPopUp: ({ TID, DID, deviceType, isReject, selectedItems, onClose, onCompleted }: {
|
|
27
28
|
TID?: number;
|
|
28
29
|
DID?: number;
|
|
@@ -31,7 +32,7 @@ export declare const WorkFlowApproveRejectPopUp: ({ TID, DID, deviceType, isReje
|
|
|
31
32
|
isReject: number;
|
|
32
33
|
onClose?: () => void;
|
|
33
34
|
onCompleted?: () => Promise<void>;
|
|
34
|
-
}) =>
|
|
35
|
+
}) => React.JSX.Element;
|
|
35
36
|
export declare const WorkFlowReAssignPopUp: ({ DID, TID, deviceType, onClose, selectedItems, onCompleted, wf, workItemDetail }: {
|
|
36
37
|
TID?: number;
|
|
37
38
|
DID?: number;
|
|
@@ -41,7 +42,7 @@ export declare const WorkFlowReAssignPopUp: ({ DID, TID, deviceType, onClose, se
|
|
|
41
42
|
onCompleted?: () => Promise<void>;
|
|
42
43
|
wf?: WFDescriptor;
|
|
43
44
|
workItemDetail?: WorkItemDetail;
|
|
44
|
-
}) =>
|
|
45
|
+
}) => React.JSX.Element;
|
|
45
46
|
/**
|
|
46
47
|
* Modal per forzare l'approvazione di un work item
|
|
47
48
|
*/
|
|
@@ -49,7 +50,7 @@ export declare const WorkflowForceApproveModal: ({ detail, onClose, onCompleted
|
|
|
49
50
|
detail: WorkItemDetail;
|
|
50
51
|
onClose?: () => void;
|
|
51
52
|
onCompleted?: () => Promise<void>;
|
|
52
|
-
}) =>
|
|
53
|
+
}) => React.JSX.Element;
|
|
53
54
|
/**
|
|
54
55
|
* Modal per forzare il rifiuto di un work item
|
|
55
56
|
*/
|
|
@@ -57,7 +58,7 @@ export declare const WorkflowForceRejectModal: ({ detail, onClose, onCompleted }
|
|
|
57
58
|
detail: WorkItemDetail;
|
|
58
59
|
onClose?: () => void;
|
|
59
60
|
onCompleted?: () => Promise<void>;
|
|
60
|
-
}) =>
|
|
61
|
+
}) => React.JSX.Element;
|
|
61
62
|
/**
|
|
62
63
|
* Modal per terminare le istanze workflow selezionate
|
|
63
64
|
*/
|
|
@@ -69,7 +70,7 @@ export declare const WorkflowEndInstanceModal: ({ selectedInstances, onClose, on
|
|
|
69
70
|
}>;
|
|
70
71
|
onClose?: () => void;
|
|
71
72
|
onCompleted?: () => Promise<void>;
|
|
72
|
-
}) =>
|
|
73
|
+
}) => React.JSX.Element;
|
|
73
74
|
interface IWorkFlowMoreInfoPopUpProps {
|
|
74
75
|
fromDTD?: DcmtTypeDescriptor;
|
|
75
76
|
TID?: number;
|
|
@@ -86,5 +87,5 @@ interface IWorkFlowMoreInfoPopUpProps {
|
|
|
86
87
|
handleNavigateToDossiers?: (value: HomeBlogPost | number) => Promise<void>;
|
|
87
88
|
triggerBlogRefresh?: () => Promise<void>;
|
|
88
89
|
}
|
|
89
|
-
export declare const WorkFlowMoreInfoPopUp: (props: IWorkFlowMoreInfoPopUpProps) =>
|
|
90
|
+
export declare const WorkFlowMoreInfoPopUp: (props: IWorkFlowMoreInfoPopUpProps) => React.JSX.Element | undefined;
|
|
90
91
|
export {};
|
|
@@ -23,6 +23,6 @@ interface ChooserProps<T> {
|
|
|
23
23
|
onClose?: () => void;
|
|
24
24
|
isDropDown?: boolean;
|
|
25
25
|
}
|
|
26
|
-
declare const Chooser: <T>({ dataSource, columns, value, additionalIcons, validationItems, title, label, icon, placeHolder, disabled, selectedRow, onChooserClick, onSelectionChanged, onClose, isDropDown }: ChooserProps<T>) =>
|
|
26
|
+
declare const Chooser: <T>({ dataSource, columns, value, additionalIcons, validationItems, title, label, icon, placeHolder, disabled, selectedRow, onChooserClick, onSelectionChanged, onClose, isDropDown }: ChooserProps<T>) => React.JSX.Element;
|
|
27
27
|
export default Chooser;
|
|
28
|
-
export declare function IconDropDown(props: React.SVGProps<SVGSVGElement>):
|
|
28
|
+
export declare function IconDropDown(props: React.SVGProps<SVGSVGElement>): React.JSX.Element;
|
|
@@ -33,7 +33,7 @@ import { TMColors } from "../../../utils/theme";
|
|
|
33
33
|
import ShowAlert from "../../base/TMAlert";
|
|
34
34
|
import TMButton from "../../base/TMButton";
|
|
35
35
|
import { useDeviceType, DeviceType } from "../../base/TMDeviceProvider";
|
|
36
|
-
import { TMExceptionBoxManager, TMMessageBoxManager, ButtonNames } from "../../base/TMPopUp";
|
|
36
|
+
import { TMExceptionBoxManager, TMMessageBoxManager, ButtonNames, sanitizeException } from "../../base/TMPopUp";
|
|
37
37
|
import TMSpinner from "../../base/TMSpinner";
|
|
38
38
|
import TMTooltip from "../../base/TMTooltip";
|
|
39
39
|
import TMCheckBox from "../../editors/TMCheckBox";
|
|
@@ -457,6 +457,18 @@ const TMLoginForm = (props) => {
|
|
|
457
457
|
// Skip auto-selection when defaultLoginValues provides an archiveId (external link)
|
|
458
458
|
if (props.defaultLoginValues?.archiveId)
|
|
459
459
|
return;
|
|
460
|
+
// Se dcmtArchive è già impostato (es. da rapid access), gestisci manualArchiveID
|
|
461
|
+
if (dcmtArchive) {
|
|
462
|
+
// Se la lista archivi è vuota, serve accesso manuale
|
|
463
|
+
if (archives.length === 0) {
|
|
464
|
+
setManualArchiveID(dcmtArchive.id ?? '');
|
|
465
|
+
}
|
|
466
|
+
else {
|
|
467
|
+
// Se l'archivio esiste nella lista, pulisci manualArchiveID
|
|
468
|
+
setManualArchiveID('');
|
|
469
|
+
}
|
|
470
|
+
return;
|
|
471
|
+
}
|
|
460
472
|
if (archives.length === 1) {
|
|
461
473
|
setDcmtArchive(archives[0]);
|
|
462
474
|
return;
|
|
@@ -522,7 +534,7 @@ const TMLoginForm = (props) => {
|
|
|
522
534
|
return true;
|
|
523
535
|
}
|
|
524
536
|
catch (e) {
|
|
525
|
-
TMExceptionBoxManager.show({ exception: e });
|
|
537
|
+
TMExceptionBoxManager.show({ exception: sanitizeException(e) });
|
|
526
538
|
return false;
|
|
527
539
|
}
|
|
528
540
|
finally {
|
|
@@ -558,7 +570,7 @@ const TMLoginForm = (props) => {
|
|
|
558
570
|
}
|
|
559
571
|
}
|
|
560
572
|
catch (e) {
|
|
561
|
-
TMExceptionBoxManager.show({ exception: e });
|
|
573
|
+
TMExceptionBoxManager.show({ exception: sanitizeException(e) });
|
|
562
574
|
}
|
|
563
575
|
finally {
|
|
564
576
|
TMSpinner.hide();
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import React from 'react';
|
|
1
2
|
import { ITMChooserFormProps } from '../../ts';
|
|
2
|
-
declare const TMChooserForm: <T>({ children, title, allowMultipleSelection, allowApplyWithZeroSelection, startWithShowOnlySelectedItems, hasShowOnlySelectedItems, allowGrouping, allowSorting, width, height, dataSource, selectedIDs, manageUseLocalizedName, hasShowId, hideRefresh, keyName, customButtons, showFilterPanel, showDefaultColumns, columns, summaryItems, convertID, customFilter, getItems, cellRenderIcon, cellRenderNameAndDesc, onChoose, onClose, onShowIdChanged }: ITMChooserFormProps<T>) =>
|
|
3
|
+
declare const TMChooserForm: <T>({ children, title, allowMultipleSelection, allowApplyWithZeroSelection, startWithShowOnlySelectedItems, hasShowOnlySelectedItems, allowGrouping, allowSorting, width, height, dataSource, selectedIDs, manageUseLocalizedName, hasShowId, hideRefresh, keyName, customButtons, showFilterPanel, showDefaultColumns, columns, summaryItems, convertID, customFilter, getItems, cellRenderIcon, cellRenderNameAndDesc, onChoose, onClose, onShowIdChanged }: ITMChooserFormProps<T>) => React.JSX.Element;
|
|
3
4
|
export default TMChooserForm;
|
|
@@ -13,19 +13,19 @@ interface ITMSaveFormButtonPreviousProps extends ITMSaveFormButtonBase {
|
|
|
13
13
|
onPrev?: () => void;
|
|
14
14
|
onSaveAsync?: () => Promise<void>;
|
|
15
15
|
}
|
|
16
|
-
export declare const TMSaveFormButtonPrevious: ({ btnStyle, formMode, isModified, onPrev, canPrev, iconColor, onSaveAsync }: ITMSaveFormButtonPreviousProps) =>
|
|
16
|
+
export declare const TMSaveFormButtonPrevious: ({ btnStyle, formMode, isModified, onPrev, canPrev, iconColor, onSaveAsync }: ITMSaveFormButtonPreviousProps) => React.JSX.Element;
|
|
17
17
|
interface ITMSaveFormButtonNextProps extends ITMSaveFormButtonBase {
|
|
18
18
|
canNext?: boolean;
|
|
19
19
|
onNext?: () => void;
|
|
20
20
|
onSaveAsync?: () => Promise<void>;
|
|
21
21
|
}
|
|
22
|
-
export declare const TMSaveFormButtonNext: ({ btnStyle, formMode, isModified, onNext, canNext, iconColor, onSaveAsync }: ITMSaveFormButtonNextProps) =>
|
|
22
|
+
export declare const TMSaveFormButtonNext: ({ btnStyle, formMode, isModified, onNext, canNext, iconColor, onSaveAsync }: ITMSaveFormButtonNextProps) => React.JSX.Element;
|
|
23
23
|
interface ITMSaveFormButtonSaveProps extends ITMSaveFormButtonBase {
|
|
24
24
|
errorsCount: number;
|
|
25
25
|
onSaveAsync?: () => Promise<void>;
|
|
26
26
|
}
|
|
27
|
-
export declare const TMSaveFormButtonSave: ({ btnStyle, errorsCount, isModified, iconColor, width, advancedColor, advancedType, onSaveAsync }: ITMSaveFormButtonSaveProps) =>
|
|
27
|
+
export declare const TMSaveFormButtonSave: ({ btnStyle, errorsCount, isModified, iconColor, width, advancedColor, advancedType, onSaveAsync }: ITMSaveFormButtonSaveProps) => React.JSX.Element;
|
|
28
28
|
interface ITMSaveFormButtonUndoProps extends ITMSaveFormButtonBase {
|
|
29
29
|
onUndo?: () => void;
|
|
30
30
|
}
|
|
31
|
-
export declare const TMSaveFormButtonUndo: ({ btnStyle, isModified, iconColor, width, advancedColor, advancedType, onUndo, color, showTooltip }: ITMSaveFormButtonUndoProps) =>
|
|
31
|
+
export declare const TMSaveFormButtonUndo: ({ btnStyle, isModified, iconColor, width, advancedColor, advancedType, onUndo, color, showTooltip }: ITMSaveFormButtonUndoProps) => React.JSX.Element;
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import React from "react";
|
|
1
2
|
import { BlogPostAttachment, DcmtTypeDescriptor } from "@topconsultnpm/sdk-ts";
|
|
2
3
|
import { DcmtInfo } from "../../ts";
|
|
3
4
|
import { FileItem } from "../base/TMFileManagerUtils";
|
|
@@ -25,5 +26,5 @@ interface TMBlogAttachmentsProps {
|
|
|
25
26
|
handleAttachmentFocus: (attachment: DcmtInfo | undefined) => void;
|
|
26
27
|
openDcmtForm: (dcmtInfo: DcmtInfo) => void;
|
|
27
28
|
}
|
|
28
|
-
declare const TMBlogAttachments: (props: TMBlogAttachmentsProps) =>
|
|
29
|
+
declare const TMBlogAttachments: (props: TMBlogAttachmentsProps) => React.JSX.Element;
|
|
29
30
|
export default TMBlogAttachments;
|
|
@@ -23,7 +23,7 @@ const TMBlogAttachments = (props) => {
|
|
|
23
23
|
openDcmtForm({ TID: blogPostAttachment.tid, DID: blogPostAttachment.did, fileName });
|
|
24
24
|
};
|
|
25
25
|
return _jsx("div", { style: { width: "100%", marginTop: "5px", overflow: "hidden" }, children: attachments.map((blogPostAttachment, index) => {
|
|
26
|
-
const { name, nameElement, tooltipContent, fileExt, archivedDocumentsExist, draftExist } = getAttachmentInfo(blogPostAttachment, treeFs, draftLatestInfoMap, archivedDocumentMap, dcmtTypeDescriptors, isSelected, searchText);
|
|
26
|
+
const { name, nameElement, tooltipContent, fileExt, archivedDocumentsExist, draftExist, isSigned } = getAttachmentInfo(blogPostAttachment, treeFs, draftLatestInfoMap, archivedDocumentMap, dcmtTypeDescriptors, isSelected, searchText);
|
|
27
27
|
return _jsx("div", { onDoubleClick: (e) => !isLoading && onDoubleClick(e, blogPostAttachment, name, fileExt), onMouseEnter: (e) => !isLoading && handleMouseEnter(e, blogPostAttachment, name, fileExt), onMouseLeave: (e) => !isLoading && handleMouseLeave(e), style: {
|
|
28
28
|
display: layoutMode === "extended" ? "inline-flex" : "flex",
|
|
29
29
|
padding: '4px 8px',
|
|
@@ -63,7 +63,7 @@ const TMBlogAttachments = (props) => {
|
|
|
63
63
|
}
|
|
64
64
|
` })] })) : (_jsxs(_Fragment, { children: [(!archivedDocumentsExist && !draftExist) ?
|
|
65
65
|
_jsx(IconAttachment, { style: { marginRight: "5px", flexShrink: 0 } }) :
|
|
66
|
-
_jsx("div", { style: { marginRight: "10px", flexShrink: 0 }, children: _jsx(TMDcmtIcon, { tid: blogPostAttachment.tid, did: blogPostAttachment.did, fileExtension: fileExt, downloadMode: 'openInNewWindow', tooltipContent: tooltipContent }) }), _jsx("span", { title: layoutMode === 'compact' ? name + " (DID: " + blogPostAttachment.did + ")" : undefined, style: {
|
|
66
|
+
_jsx("div", { style: { marginRight: "10px", flexShrink: 0, width: isSigned ? "40px" : undefined }, children: _jsx(TMDcmtIcon, { tid: blogPostAttachment.tid, did: blogPostAttachment.did, fileExtension: fileExt, downloadMode: 'openInNewWindow', tooltipContent: tooltipContent, isSigned: isSigned }) }), _jsx("span", { title: layoutMode === 'compact' ? name + " (DID: " + blogPostAttachment.did + ")" : undefined, style: {
|
|
67
67
|
whiteSpace: 'nowrap',
|
|
68
68
|
overflow: 'hidden',
|
|
69
69
|
textOverflow: 'ellipsis',
|
|
@@ -27,5 +27,5 @@ interface TMBlogHeaderProps {
|
|
|
27
27
|
/** Callback when the search text changes */
|
|
28
28
|
onSearchChange: (value: string) => void;
|
|
29
29
|
}
|
|
30
|
-
declare const TMBlogHeader: (props: TMBlogHeaderProps) =>
|
|
30
|
+
declare const TMBlogHeader: (props: TMBlogHeaderProps) => React.JSX.Element;
|
|
31
31
|
export default TMBlogHeader;
|
|
@@ -87,5 +87,5 @@ interface TMBlogsPostProps {
|
|
|
87
87
|
handleNavigateToWGs?: (value: HomeBlogPost | number) => Promise<void>;
|
|
88
88
|
handleNavigateToDossiers?: (value: HomeBlogPost | number) => Promise<void>;
|
|
89
89
|
}
|
|
90
|
-
declare const TMBlogsPost: (props: TMBlogsPostProps) =>
|
|
90
|
+
declare const TMBlogsPost: (props: TMBlogsPostProps) => React.JSX.Element;
|
|
91
91
|
export default TMBlogsPost;
|
|
@@ -510,9 +510,11 @@ const TMBlogsPost = (props) => {
|
|
|
510
510
|
icon: _jsx("span", { className: "dx-icon-download" }),
|
|
511
511
|
name: 'Download',
|
|
512
512
|
onClick: async () => {
|
|
513
|
-
await downloadDcmtsAsync(
|
|
514
|
-
{ TID: focusedAttachment.TID, DID: focusedAttachment.DID, fileName: focusedAttachment.fileName }
|
|
515
|
-
|
|
513
|
+
await downloadDcmtsAsync({
|
|
514
|
+
inputDcmts: [{ TID: focusedAttachment.TID, DID: focusedAttachment.DID, fileName: focusedAttachment.fileName }],
|
|
515
|
+
downloadType: DownloadTypes.Dcmt,
|
|
516
|
+
downloadMode: "download"
|
|
517
|
+
});
|
|
516
518
|
},
|
|
517
519
|
});
|
|
518
520
|
}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { ReactNode } from "react";
|
|
1
|
+
import React, { ReactNode } from "react";
|
|
2
2
|
import { BlogPost, BlogPostAttachment, DcmtTypeDescriptor, DossierDescriptor, HomeBlogPost, TID_DID, WorkingGroupDescriptor } from "@topconsultnpm/sdk-ts";
|
|
3
3
|
import { FileItem } from "../base/TMFileManagerUtils";
|
|
4
4
|
export declare const DRAFT_TYPE_TID = 6;
|
|
@@ -59,10 +59,10 @@ export declare const getCompactEllipsisStyle: (layoutMode: "compact" | "extended
|
|
|
59
59
|
display: string;
|
|
60
60
|
};
|
|
61
61
|
export declare const findFileItemByDraftID: (tree: FileItem | undefined, draftID: number | undefined) => FileItem | null;
|
|
62
|
-
export declare const highlightText: (text: string, searchText: string, isSelected: boolean) => string | (string |
|
|
62
|
+
export declare const highlightText: (text: string, searchText: string, isSelected: boolean) => string | (string | React.JSX.Element)[];
|
|
63
63
|
export declare const lightenColor: (hex: string, amount: number) => string;
|
|
64
|
-
export declare const OwnerInitialsBadge: (blogPost: BlogPost | HomeBlogPost) =>
|
|
65
|
-
export declare const getTooltipContent: (title: string | undefined, content: JSX.Element) =>
|
|
64
|
+
export declare const OwnerInitialsBadge: (blogPost: BlogPost | HomeBlogPost) => React.JSX.Element;
|
|
65
|
+
export declare const getTooltipContent: (title: string | undefined, content: JSX.Element) => React.JSX.Element;
|
|
66
66
|
export declare const getAttachmentInfo: (attachment: BlogPostAttachment, treeFs: FileItem | undefined, draftLatestInfoMap: Map<number, {
|
|
67
67
|
latestVersion: number;
|
|
68
68
|
folderId: number;
|
|
@@ -76,15 +76,16 @@ export declare const getAttachmentInfo: (attachment: BlogPostAttachment, treeFs:
|
|
|
76
76
|
fileSize: string;
|
|
77
77
|
}> | undefined, dcmtTypeDescriptors: Map<number, DcmtTypeDescriptor>, isSelected: boolean, searchText: string) => {
|
|
78
78
|
name: string;
|
|
79
|
-
nameElement:
|
|
80
|
-
tooltipContent:
|
|
79
|
+
nameElement: React.JSX.Element;
|
|
80
|
+
tooltipContent: React.JSX.Element;
|
|
81
81
|
folderId: number;
|
|
82
82
|
fileExt: string;
|
|
83
83
|
draftExist: boolean;
|
|
84
84
|
archivedDocumentsExist: boolean;
|
|
85
|
+
isSigned: number;
|
|
85
86
|
};
|
|
86
87
|
export declare const getDcmtTypeDescriptor: (blogPosts: Array<BlogPost>) => Promise<Map<number, DcmtTypeDescriptor>>;
|
|
87
|
-
export declare const BlogPostHomeHeader: (header: string | undefined, classId: string | undefined, isSelected: boolean, searchText: string, headerClickCallback: () => void) =>
|
|
88
|
+
export declare const BlogPostHomeHeader: (header: string | undefined, classId: string | undefined, isSelected: boolean, searchText: string, headerClickCallback: () => void) => React.JSX.Element;
|
|
88
89
|
export declare const isHeaderFullyHidden: (header: {
|
|
89
90
|
showViewMode: boolean;
|
|
90
91
|
showFilters: boolean;
|
|
@@ -94,7 +95,7 @@ export declare const isHeaderFullyHidden: (header: {
|
|
|
94
95
|
interface NewBadgeProps {
|
|
95
96
|
layoutMode: "compact" | "extended";
|
|
96
97
|
}
|
|
97
|
-
export declare const NewBadge: ({ layoutMode }: NewBadgeProps) =>
|
|
98
|
+
export declare const NewBadge: ({ layoutMode }: NewBadgeProps) => React.JSX.Element;
|
|
98
99
|
export declare const removeFileExtension: (filename: string) => string;
|
|
99
100
|
interface BlogPostTitleProps {
|
|
100
101
|
displayMode: "chat" | "stacked";
|
|
@@ -109,6 +110,6 @@ interface BlogPostTitleProps {
|
|
|
109
110
|
handleNavigateToWGs?: (blogPost: BlogPost | HomeBlogPost) => void;
|
|
110
111
|
handleNavigateToDossiers?: (blogPost: BlogPost | HomeBlogPost) => void;
|
|
111
112
|
}
|
|
112
|
-
export declare const BlogPostTitle: (props: BlogPostTitleProps) =>
|
|
113
|
+
export declare const BlogPostTitle: (props: BlogPostTitleProps) => React.JSX.Element;
|
|
113
114
|
export declare const stripHtml: (html: string) => string;
|
|
114
115
|
export {};
|
|
@@ -86,6 +86,7 @@ export const getAttachmentInfo = (attachment, treeFs, draftLatestInfoMap, archiv
|
|
|
86
86
|
let archivedDocumentsExist = false;
|
|
87
87
|
let name = '';
|
|
88
88
|
let tooltipContent = _jsx(_Fragment, {});
|
|
89
|
+
let isSigned = 0;
|
|
89
90
|
if (attachment.tid === DRAFT_TYPE_TID && treeFs) {
|
|
90
91
|
const draftfileItem = findFileItemByDraftID(treeFs, attachment.draftID);
|
|
91
92
|
if (draftfileItem) {
|
|
@@ -94,6 +95,7 @@ export const getAttachmentInfo = (attachment, treeFs, draftLatestInfoMap, archiv
|
|
|
94
95
|
draftExist = true;
|
|
95
96
|
let fileSize = '0';
|
|
96
97
|
name = draftfileItem.name;
|
|
98
|
+
isSigned = draftfileItem.isSigned ? 1 : 0;
|
|
97
99
|
if (draftLatestInfoMap && attachment.draftID && attachment.version) {
|
|
98
100
|
const draftInfo = draftLatestInfoMap.get(attachment.draftID);
|
|
99
101
|
if (draftInfo) {
|
|
@@ -139,7 +141,7 @@ export const getAttachmentInfo = (attachment, treeFs, draftLatestInfoMap, archiv
|
|
|
139
141
|
nameElement = (_jsx("span", { children: highlightText(`${name} (DID: ${attachment.did})`, searchText, isSelected) }));
|
|
140
142
|
}
|
|
141
143
|
}
|
|
142
|
-
return { name, nameElement, tooltipContent, folderId, fileExt, draftExist, archivedDocumentsExist };
|
|
144
|
+
return { name, nameElement, tooltipContent, folderId, fileExt, draftExist, archivedDocumentsExist, isSigned };
|
|
143
145
|
};
|
|
144
146
|
export const getDcmtTypeDescriptor = async (blogPosts) => {
|
|
145
147
|
const dcmtTypeMap = new Map();
|
|
@@ -1,6 +1,7 @@
|
|
|
1
|
+
import React from 'react';
|
|
1
2
|
import { ValidationItem } from '@topconsultnpm/sdk-ts';
|
|
2
3
|
interface ITMValidationItemsList {
|
|
3
4
|
validationItems?: ValidationItem[];
|
|
4
5
|
}
|
|
5
|
-
declare const TMValidationItemsList: ({ validationItems }: ITMValidationItemsList) =>
|
|
6
|
+
declare const TMValidationItemsList: ({ validationItems }: ITMValidationItemsList) => React.JSX.Element;
|
|
6
7
|
export default TMValidationItemsList;
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import React from 'react';
|
|
1
2
|
import { TMPanelDefinition, TMPanelDirection } from './types';
|
|
2
3
|
interface TMPanelManagerContainerProps {
|
|
3
4
|
panels: Array<TMPanelDefinition>;
|
|
@@ -6,5 +7,5 @@ interface TMPanelManagerContainerProps {
|
|
|
6
7
|
parentId?: string;
|
|
7
8
|
minPanelSizePx?: number;
|
|
8
9
|
}
|
|
9
|
-
declare const TMPanelManagerContainer: (props: TMPanelManagerContainerProps) =>
|
|
10
|
+
declare const TMPanelManagerContainer: (props: TMPanelManagerContainerProps) => React.JSX.Element | null;
|
|
10
11
|
export default TMPanelManagerContainer;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { ReactNode } from 'react';
|
|
1
|
+
import React, { ReactNode } from 'react';
|
|
2
2
|
import type { TMPanelDefinition, TMPanelDimensionsMap } from './types';
|
|
3
3
|
interface TMPanelManagerContextType {
|
|
4
4
|
panelVisibility: {
|
|
@@ -34,6 +34,6 @@ interface TMPanelManagerProviderProps {
|
|
|
34
34
|
initialMobilePanelId: string;
|
|
35
35
|
isPersistenceEnabled?: boolean;
|
|
36
36
|
}
|
|
37
|
-
export declare const TMPanelManagerProvider: (props: TMPanelManagerProviderProps) =>
|
|
37
|
+
export declare const TMPanelManagerProvider: (props: TMPanelManagerProviderProps) => React.JSX.Element;
|
|
38
38
|
export declare const useTMPanelManagerContext: () => TMPanelManagerContextType;
|
|
39
39
|
export {};
|
|
@@ -10,5 +10,5 @@ export declare const StyledToolbarButton: import("styled-components/dist/types")
|
|
|
10
10
|
interface TMPanelManagerToolbarProps {
|
|
11
11
|
panels: Array<TMPanelDefinition>;
|
|
12
12
|
}
|
|
13
|
-
declare const TMPanelManagerToolbar: (props: TMPanelManagerToolbarProps) =>
|
|
13
|
+
declare const TMPanelManagerToolbar: (props: TMPanelManagerToolbarProps) => React.JSX.Element;
|
|
14
14
|
export default TMPanelManagerToolbar;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { ReactNode } from 'react';
|
|
1
|
+
import React, { ReactNode } from 'react';
|
|
2
2
|
import type { TMPanelDefinition, TMPanelDimensionsMap } from './types';
|
|
3
3
|
interface TMPanelManagerWithPersistenceProps {
|
|
4
4
|
children: ReactNode;
|
|
@@ -17,5 +17,5 @@ interface TMPanelManagerWithPersistenceProps {
|
|
|
17
17
|
}>) => void;
|
|
18
18
|
persistedPanelStates?: Record<string, any>;
|
|
19
19
|
}
|
|
20
|
-
export declare const TMPanelManagerWithPersistenceProvider: (props: TMPanelManagerWithPersistenceProps) =>
|
|
20
|
+
export declare const TMPanelManagerWithPersistenceProvider: (props: TMPanelManagerWithPersistenceProps) => React.JSX.Element | null;
|
|
21
21
|
export {};
|