@topconsultnpm/sdkui-react 6.20.0-dev1.13 → 6.20.0-dev1.130
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/assets/Toppy-help-center.png +0 -0
- package/lib/assets/headergradient.svg +87 -0
- package/lib/components/NewComponents/ContextMenu/TMContextMenu.js +322 -30
- package/lib/components/NewComponents/ContextMenu/hooks.d.ts +8 -1
- package/lib/components/NewComponents/ContextMenu/hooks.js +80 -8
- package/lib/components/NewComponents/ContextMenu/index.d.ts +3 -0
- package/lib/components/NewComponents/ContextMenu/index.js +2 -0
- package/lib/components/NewComponents/ContextMenu/styles.d.ts +9 -1
- package/lib/components/NewComponents/ContextMenu/styles.js +146 -47
- package/lib/components/NewComponents/ContextMenu/types.d.ts +22 -3
- package/lib/components/NewComponents/ContextMenu/useLongPress.d.ts +21 -0
- package/lib/components/NewComponents/ContextMenu/useLongPress.js +112 -0
- package/lib/components/NewComponents/FloatingMenuBar/TMFloatingMenuBar.js +620 -125
- package/lib/components/NewComponents/FloatingMenuBar/styles.d.ts +25 -5
- package/lib/components/NewComponents/FloatingMenuBar/styles.js +215 -59
- package/lib/components/NewComponents/FloatingMenuBar/types.d.ts +12 -3
- package/lib/components/base/TMAccordionNew.js +35 -14
- package/lib/components/base/TMButton.js +6 -0
- package/lib/components/base/TMClosableList.js +4 -0
- package/lib/components/base/TMCustomButton.js +61 -17
- package/lib/components/base/TMDataGrid.d.ts +7 -4
- package/lib/components/base/TMDataGrid.js +153 -11
- package/lib/components/base/TMDropDownMenu.js +21 -18
- package/lib/components/base/TMFileManager.d.ts +4 -3
- package/lib/components/base/TMFileManager.js +32 -24
- package/lib/components/base/TMFileManagerDataGridView.d.ts +3 -2
- package/lib/components/base/TMFileManagerDataGridView.js +1 -11
- package/lib/components/base/TMFileManagerThumbnailItems.d.ts +7 -1
- package/lib/components/base/TMFileManagerThumbnailItems.js +5 -2
- package/lib/components/base/TMFileManagerThumbnailsView.d.ts +17 -4
- package/lib/components/base/TMFileManagerThumbnailsView.js +18 -6
- package/lib/components/base/TMFileManagerUtils.d.ts +0 -12
- package/lib/components/base/TMListView.js +33 -15
- package/lib/components/base/TMPanel.d.ts +1 -1
- package/lib/components/base/TMPanel.js +4 -2
- package/lib/components/base/TMPopUp.js +6 -0
- package/lib/components/base/TMToolbarCard.js +2 -0
- package/lib/components/base/TMTreeView.d.ts +2 -1
- package/lib/components/base/TMTreeView.js +33 -26
- package/lib/components/choosers/TMDataListItemChooser.d.ts +2 -0
- package/lib/components/choosers/TMDataListItemChooser.js +8 -2
- package/lib/components/choosers/TMDcmtTypeChooser.d.ts +1 -0
- package/lib/components/choosers/TMDcmtTypeChooser.js +11 -3
- package/lib/components/choosers/TMDistinctValues.js +2 -2
- package/lib/components/choosers/TMDynDataListItemChooser.d.ts +2 -0
- package/lib/components/choosers/TMDynDataListItemChooser.js +8 -2
- package/lib/components/choosers/TMInvoiceRetrieveFormats.js +1 -1
- package/lib/components/choosers/TMMetadataChooser.d.ts +2 -0
- package/lib/components/choosers/TMMetadataChooser.js +19 -4
- package/lib/components/choosers/TMOrderRetrieveFormats.js +1 -1
- package/lib/components/choosers/TMUserChooser.d.ts +2 -5
- package/lib/components/choosers/TMUserChooser.js +33 -47
- package/lib/components/editors/TMCheckBox.js +2 -0
- package/lib/components/editors/TMDateBox.js +18 -9
- package/lib/components/editors/TMEditorStyled.js +7 -0
- package/lib/components/editors/TMLocalizedTextBox.d.ts +3 -1
- package/lib/components/editors/TMLocalizedTextBox.js +16 -14
- package/lib/components/editors/TMMetadataEditor.d.ts +1 -0
- package/lib/components/editors/TMMetadataEditor.js +4 -4
- package/lib/components/editors/TMMetadataTextBox.d.ts +9 -0
- package/lib/components/editors/TMMetadataTextBox.js +92 -0
- package/lib/components/editors/TMMetadataValues.d.ts +2 -0
- package/lib/components/editors/TMMetadataValues.js +26 -8
- package/lib/components/editors/TMRadioButton.js +2 -0
- package/lib/components/editors/TMTextArea.js +18 -30
- package/lib/components/editors/TMTextBox.d.ts +1 -1
- package/lib/components/editors/TMTextBox.js +29 -4
- package/lib/components/editors/TMTextExpression.js +6 -91
- package/lib/components/features/archive/TMArchive.js +2 -2
- package/lib/components/features/assistant/TMToppyDraggableHelpCenter.d.ts +15 -0
- package/lib/components/features/assistant/TMToppyDraggableHelpCenter.js +462 -0
- package/lib/components/features/assistant/TMToppySpeechBubble.d.ts +11 -0
- package/lib/components/features/assistant/TMToppySpeechBubble.js +126 -0
- package/lib/components/features/documents/TMDcmtBlog.js +1 -1
- package/lib/components/features/documents/TMDcmtForm.d.ts +14 -2
- package/lib/components/features/documents/TMDcmtForm.js +576 -292
- package/lib/components/features/documents/TMDcmtPreview.js +42 -155
- package/lib/components/features/documents/TMDcmtTasks.js +9 -9
- package/lib/components/features/documents/TMMasterDetailDcmts.js +38 -53
- package/lib/components/features/documents/TMRelationViewer.d.ts +1 -1
- package/lib/components/features/documents/TMRelationViewer.js +2 -2
- package/lib/components/features/search/TMDcmtCheckoutInfoForm.d.ts +8 -0
- package/lib/components/features/search/{TMSearchResultCheckoutInfoForm.js → TMDcmtCheckoutInfoForm.js} +2 -2
- package/lib/components/features/search/TMSavedQuerySelector.js +72 -67
- package/lib/components/features/search/TMSearch.d.ts +3 -0
- package/lib/components/features/search/TMSearch.js +50 -11
- package/lib/components/features/search/TMSearchQueryEditor.d.ts +1 -0
- package/lib/components/features/search/TMSearchQueryEditor.js +10 -10
- package/lib/components/features/search/TMSearchQueryPanel.d.ts +1 -0
- package/lib/components/features/search/TMSearchQueryPanel.js +40 -25
- package/lib/components/features/search/TMSearchResult.d.ts +3 -0
- package/lib/components/features/search/TMSearchResult.js +370 -252
- package/lib/components/features/search/TMSearchResultsMenuItems.d.ts +3 -3
- package/lib/components/features/search/TMSearchResultsMenuItems.js +227 -171
- package/lib/components/features/search/TMSignSettingsForm.js +1 -1
- package/lib/components/features/search/TMSignatureInfoContent.d.ts +6 -0
- package/lib/components/features/search/TMSignatureInfoContent.js +140 -0
- package/lib/components/features/search/TMViewHistoryDcmt.js +47 -52
- package/lib/components/features/tasks/TMTaskForm.js +75 -25
- package/lib/components/features/tasks/TMTasksAgenda.d.ts +3 -1
- package/lib/components/features/tasks/TMTasksAgenda.js +48 -9
- package/lib/components/features/tasks/TMTasksCalendar.d.ts +2 -0
- package/lib/components/features/tasks/TMTasksCalendar.js +19 -7
- package/lib/components/features/tasks/TMTasksUtils.d.ts +2 -2
- package/lib/components/features/tasks/TMTasksUtils.js +57 -37
- package/lib/components/features/tasks/TMTasksView.js +28 -19
- package/lib/components/features/workflow/TMWorkflowPopup.d.ts +33 -2
- package/lib/components/features/workflow/TMWorkflowPopup.js +140 -34
- package/lib/components/features/workflow/diagram/DiagramItemComponent.d.ts +2 -0
- package/lib/components/features/workflow/diagram/DiagramItemComponent.js +14 -7
- package/lib/components/features/workflow/diagram/DiagramItemForm.js +1 -1
- package/lib/components/features/workflow/diagram/RecipientList.js +3 -2
- package/lib/components/features/workflow/diagram/WFDiagram.d.ts +4 -0
- package/lib/components/features/workflow/diagram/WFDiagram.js +164 -13
- package/lib/components/forms/Login/LoginValidatorService.d.ts +2 -0
- package/lib/components/forms/Login/LoginValidatorService.js +7 -2
- package/lib/components/forms/Login/TMLoginForm.js +35 -7
- package/lib/components/forms/TMChooserForm.js +1 -1
- package/lib/components/grids/TMBlogsPost.js +56 -31
- package/lib/components/grids/TMRecentsManager.js +20 -10
- package/lib/components/grids/TMValidationItemsList.js +6 -0
- package/lib/components/index.d.ts +6 -3
- package/lib/components/index.js +6 -3
- package/lib/components/layout/panelManager/TMPanelManagerContext.js +13 -5
- package/lib/components/query/TMQueryEditor.d.ts +6 -1
- package/lib/components/query/TMQueryEditor.js +105 -101
- package/lib/components/settings/SettingsAppearance.d.ts +2 -1
- package/lib/components/settings/SettingsAppearance.js +99 -30
- package/lib/components/sidebar/TMHeader.js +11 -7
- package/lib/components/sidebar/TMSidebar.d.ts +0 -1
- package/lib/components/sidebar/TMSidebar.js +16 -44
- package/lib/components/sidebar/TMSidebarItem.js +36 -17
- package/lib/components/viewers/TMDataListItemViewer.d.ts +2 -1
- package/lib/components/viewers/TMDataListItemViewer.js +35 -71
- package/lib/components/viewers/TMDataUserIdItemViewer.d.ts +8 -0
- package/lib/components/viewers/TMDataUserIdItemViewer.js +39 -0
- package/lib/css/tm-sdkui.css +1 -1
- package/lib/helper/SDKUI_Globals.d.ts +22 -0
- package/lib/helper/SDKUI_Globals.js +10 -1
- package/lib/helper/SDKUI_Localizator.d.ts +21 -3
- package/lib/helper/SDKUI_Localizator.js +196 -10
- package/lib/helper/TMCommandsContextMenu.d.ts +4 -2
- package/lib/helper/TMCommandsContextMenu.js +15 -4
- package/lib/helper/TMIcons.d.ts +4 -0
- package/lib/helper/TMIcons.js +13 -3
- package/lib/helper/TMPdfViewer.d.ts +8 -0
- package/lib/helper/TMPdfViewer.js +373 -0
- package/lib/helper/TMToppyMessage.js +4 -0
- package/lib/helper/checkinCheckoutManager.d.ts +31 -1
- package/lib/helper/checkinCheckoutManager.js +112 -30
- package/lib/helper/devextremeCustomMessages.d.ts +30 -0
- package/lib/helper/devextremeCustomMessages.js +30 -0
- package/lib/helper/helpers.d.ts +30 -2
- package/lib/helper/helpers.js +132 -4
- package/lib/helper/index.d.ts +2 -0
- package/lib/helper/index.js +2 -0
- package/lib/helper/queryHelper.d.ts +2 -2
- package/lib/helper/queryHelper.js +80 -24
- package/lib/helper/workItemsHelper.d.ts +6 -0
- package/lib/helper/workItemsHelper.js +230 -0
- package/lib/hooks/useCheckInOutOperations.d.ts +28 -0
- package/lib/hooks/useCheckInOutOperations.js +223 -0
- package/lib/hooks/useDataListItem.d.ts +12 -0
- package/lib/hooks/useDataListItem.js +132 -0
- package/lib/hooks/useDataUserIdItem.d.ts +10 -0
- package/lib/hooks/useDataUserIdItem.js +96 -0
- package/lib/hooks/useFloatingBarPinnedItems.d.ts +11 -0
- package/lib/hooks/useFloatingBarPinnedItems.js +54 -0
- package/lib/hooks/useMetadataExpression.d.ts +19 -0
- package/lib/hooks/useMetadataExpression.js +99 -0
- package/lib/hooks/useSettingsFeedback.d.ts +11 -0
- package/lib/hooks/useSettingsFeedback.js +38 -0
- package/lib/hooks/useWorkflowApprove.d.ts +4 -0
- package/lib/hooks/useWorkflowApprove.js +14 -1
- package/lib/index.d.ts +1 -0
- package/lib/index.js +3 -2
- package/lib/services/platform_services.d.ts +3 -3
- package/lib/ts/types.d.ts +61 -1
- package/lib/utils/theme.d.ts +1 -1
- package/lib/utils/theme.js +1 -1
- package/package.json +6 -5
- package/lib/components/NewComponents/Notification/Notification.d.ts +0 -4
- package/lib/components/NewComponents/Notification/Notification.js +0 -60
- package/lib/components/NewComponents/Notification/NotificationContainer.d.ts +0 -8
- package/lib/components/NewComponents/Notification/NotificationContainer.js +0 -33
- package/lib/components/NewComponents/Notification/index.d.ts +0 -2
- package/lib/components/NewComponents/Notification/index.js +0 -2
- package/lib/components/NewComponents/Notification/styles.d.ts +0 -21
- package/lib/components/NewComponents/Notification/styles.js +0 -180
- package/lib/components/NewComponents/Notification/types.d.ts +0 -18
- package/lib/components/NewComponents/Notification/types.js +0 -1
- package/lib/components/base/TMContextMenu.d.ts +0 -25
- package/lib/components/base/TMContextMenu.js +0 -109
- package/lib/components/base/TMContextMenuOLD.d.ts +0 -26
- package/lib/components/base/TMContextMenuOLD.js +0 -56
- package/lib/components/base/TMFloatingToolbar.d.ts +0 -9
- package/lib/components/base/TMFloatingToolbar.js +0 -101
- package/lib/components/features/assistant/ToppyDraggableHelpCenter.d.ts +0 -30
- package/lib/components/features/assistant/ToppyDraggableHelpCenter.js +0 -482
- package/lib/components/features/assistant/ToppySpeechBubble.d.ts +0 -9
- package/lib/components/features/assistant/ToppySpeechBubble.js +0 -117
- package/lib/components/features/search/TMSearchResultCheckoutInfoForm.d.ts +0 -8
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
1
|
+
import { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from "react/jsx-runtime";
|
|
2
2
|
import ArrayStore from 'devextreme/data/array_store';
|
|
3
3
|
import { useCallback, useEffect, useRef, useState } from 'react';
|
|
4
4
|
import { Priorities, Task_States } from "@topconsultnpm/sdk-ts";
|
|
@@ -10,13 +10,15 @@ import { FormModes } from '../../../ts';
|
|
|
10
10
|
import { SDKUI_Localizator } from '../../../helper';
|
|
11
11
|
import TMTooltip from '../../base/TMTooltip';
|
|
12
12
|
import TMCustomSearchBar from '../../../helper/TMCustomSearchBar';
|
|
13
|
+
import TMContextMenu from '../../NewComponents/ContextMenu/TMContextMenu';
|
|
13
14
|
const views = ['month'];
|
|
14
|
-
let clickTimeout = null;
|
|
15
|
+
let clickTimeout = null;
|
|
15
16
|
let clickCount = 0; // Click counter
|
|
16
17
|
let lastClickedCell = null;
|
|
17
18
|
const TMTasksCalendar = (props) => {
|
|
18
|
-
const { id, visualizedTasks, showId, showSearch, fromCell, toCell, openTaskForm, onDeleteCallback, currentCalendarDate, setCurrentCalendarDate, focusedRowKey, handleFocusedRowChange, setCalendarStartDate, setCalendarEndDate } = props;
|
|
19
|
+
const { id, visualizedTasks, showId, showSearch, fromCell, toCell, openTaskForm, onDeleteCallback, currentCalendarDate, setCurrentCalendarDate, focusedRowKey, handleFocusedRowChange, setCalendarStartDate, setCalendarEndDate, menuItems } = props;
|
|
19
20
|
const [isMobile, setIsMobile] = useState(false);
|
|
21
|
+
const [contextMenuControl, setContextMenuControl] = useState({ visible: false, position: { x: 0, y: 0 } });
|
|
20
22
|
const mobileBreakpoint = 768;
|
|
21
23
|
const [schedulerData, setSchedulerData] = useState([]);
|
|
22
24
|
const [isRange, setIsRange] = useState(false);
|
|
@@ -228,13 +230,23 @@ const TMTasksCalendar = (props) => {
|
|
|
228
230
|
}
|
|
229
231
|
}
|
|
230
232
|
};
|
|
231
|
-
const onWrapperContextMenu = useCallback(() => {
|
|
232
|
-
handleFocusedRowChange(undefined);
|
|
233
|
-
}, []);
|
|
234
233
|
const onWrapperClick = useCallback(() => {
|
|
235
234
|
handleFocusedRowChange(undefined);
|
|
236
235
|
}, []);
|
|
236
|
+
const handleWrapperContextMenu = useCallback((e) => {
|
|
237
|
+
setContextMenuControl({
|
|
238
|
+
visible: true,
|
|
239
|
+
position: { x: e.clientX, y: e.clientY }
|
|
240
|
+
});
|
|
241
|
+
}, []);
|
|
242
|
+
const handleCloseContextMenu = useCallback(() => {
|
|
243
|
+
setContextMenuControl(prev => ({ ...prev, visible: false }));
|
|
244
|
+
}, []);
|
|
237
245
|
return (_jsxs("div", { style: { width: "100%", height: "100%" }, children: [_jsxs("div", { style: { display: 'flex', justifyContent: 'space-between', alignItems: 'center', width: '100%', height: "48px", padding: 5 }, children: [_jsx("div", { style: { width: showSearch ? "160px" : "0", marginLeft: '10px' }, children: showSearch && (_jsx(TMCustomSearchBar, { initialValue: searchText, onSearchChange: (value) => setSearchText(value) })) }), _jsx("div", { style: { display: 'flex', alignItems: 'center', justifyContent: 'center', cursor: "default" }, children: _jsx(TMTooltip, { content: priorityLegend(), children: SDKUI_Localizator.PriorityLegend }) })] }), _jsx("div", { style: { height: "calc(100% - 48px)", width: "100%" }, children: loading ? _jsx("div", { style: { display: "flex", justifyContent: "center", alignItems: "center", height: "100%", width: "100%" }, children: _jsx(LoadIndicator, {}) })
|
|
238
|
-
:
|
|
246
|
+
: _jsxs(_Fragment, { children: [_jsx(TMContextMenu, { items: menuItems, externalControl: {
|
|
247
|
+
visible: contextMenuControl.visible,
|
|
248
|
+
position: contextMenuControl.position,
|
|
249
|
+
onClose: handleCloseContextMenu
|
|
250
|
+
} }), _jsx("div", { id: `tasks-calendar-wrapper-${id}`, style: { width: "100%", height: "100%" }, onContextMenu: handleWrapperContextMenu, onClick: onWrapperClick, children: _jsx(Scheduler, { ref: schedulerRef, id: "tasks-calendar", dataSource: new ArrayStore({ key: 'tasks-calendar-data', data: schedulerData }), views: views, defaultCurrentView: "month", adaptivityEnabled: isMobile, editing: false, width: "100%", height: "100%", currentDate: currentCalendarDate, appointmentComponent: appointmentComponent, onAppointmentFormOpening: handleAppointmentFormOpening, appointmentTooltipComponent: appointmentTooltipComponent, onAppointmentDblClick: handleAppointmentDblClick, onCurrentDateChange: onCurrentCalendarDateChange, onAppointmentContextMenu: onAppointmentContextMenu, onCellContextMenu: onCellContextMenu, onCellClick: handleCellClick, onAppointmentClick: handleAppointmentClick, onContentReady: handleContentReady, onOptionChanged: onOptionChanged, children: _jsx(Resource, { dataSource: prioritiesResourceData, fieldExpr: "priority", label: "Priority" }) }) })] }) })] }));
|
|
239
251
|
};
|
|
240
252
|
export default TMTasksCalendar;
|
|
@@ -2,7 +2,7 @@ import { Appointment } from 'devextreme/ui/scheduler';
|
|
|
2
2
|
import { ContextMenuTypes } from 'devextreme-react/context-menu';
|
|
3
3
|
import { TaskDescriptor, Task_States, PdGs, Priorities, ValidationItem } from '@topconsultnpm/sdk-ts';
|
|
4
4
|
import { FormModes, TaskContext } from '../../../ts';
|
|
5
|
-
import {
|
|
5
|
+
import { TMContextMenuItemProps } from '../../NewComponents/ContextMenu';
|
|
6
6
|
export declare const TEXT_SELECTED_COLOR = "#ff5e1a";
|
|
7
7
|
export declare const BG_COLOR_INACTIVE_WIDGET = "#fff";
|
|
8
8
|
export declare const BG_COLOR_ACTIVE_WIDGET = "#fff0b7";
|
|
@@ -100,7 +100,7 @@ export declare const gotoPDGExtendedLabel: (gotoVisible: boolean, pdg: PdGs, iD1
|
|
|
100
100
|
export declare const convertToSchedulerAppointments: (tasks: Array<TaskDescriptor>) => Array<Appointment>;
|
|
101
101
|
export declare const formatDate: (date: Date) => string;
|
|
102
102
|
export declare const areDifferentIDs: (fromID: number | undefined, userID: number | undefined) => boolean;
|
|
103
|
-
export declare const createTasksMenuItems: (taskDescriptor: TaskDescriptor | undefined, showId: boolean, setShowId: React.Dispatch<React.SetStateAction<boolean>>, showSearch: boolean, setShowSearch: React.Dispatch<React.SetStateAction<boolean>>, openTaskForm: (formMode: FormModes, task?: TaskDescriptor, isContextual?: boolean) => void, openEditTaskForm: (rowId: number | undefined) => void, openDuplicateTaskForm: (rowId: number | undefined) => void, onDeleteCallback: (rowIds: Array<number>) => void, markAsStatus: (rowIds: Array<number>, status: Task_States) => void, getAllTasks: () => Promise<void>, fromWG: boolean, showContextualWG: boolean, setShowContextualWG: React.Dispatch<React.SetStateAction<boolean>>, fromDossier: boolean, showContextualDossier: boolean, setShowContextualDossier: React.Dispatch<React.SetStateAction<boolean>>, fromDocument: boolean, showContextualDocument: boolean, setShowContextualDocument: React.Dispatch<React.SetStateAction<boolean>>, showGoToToday: boolean, handleGoToToday?: () => void, fromDatagrid?: boolean) => Array<
|
|
103
|
+
export declare const createTasksMenuItems: (taskDescriptor: TaskDescriptor | undefined, showId: boolean, setShowId: React.Dispatch<React.SetStateAction<boolean>>, showSearch: boolean, setShowSearch: React.Dispatch<React.SetStateAction<boolean>>, openTaskForm: (formMode: FormModes, task?: TaskDescriptor, isContextual?: boolean) => void, openEditTaskForm: (rowId: number | undefined) => void, openDuplicateTaskForm: (rowId: number | undefined) => void, onDeleteCallback: (rowIds: Array<number>) => void, markAsStatus: (rowIds: Array<number>, status: Task_States) => void, getAllTasks: () => Promise<void>, fromWG: boolean, showContextualWG: boolean, setShowContextualWG: React.Dispatch<React.SetStateAction<boolean>>, fromDossier: boolean, showContextualDossier: boolean, setShowContextualDossier: React.Dispatch<React.SetStateAction<boolean>>, fromDocument: boolean, showContextualDocument: boolean, setShowContextualDocument: React.Dispatch<React.SetStateAction<boolean>>, showGoToToday: boolean, handleGoToToday?: () => void, fromDatagrid?: boolean) => Array<TMContextMenuItemProps>;
|
|
104
104
|
export declare const checkIfNew: (fromId: number | undefined, isNew: number | undefined) => boolean;
|
|
105
105
|
export declare const getNewTaskCount: (tasks: Array<TaskDescriptor>) => number;
|
|
106
106
|
export declare const isTaskAssignedToAnotherUser: (task: TaskDescriptor) => boolean;
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { jsx as _jsx } from "react/jsx-runtime";
|
|
1
2
|
import { Task_States, PdGs, Priorities, ValidationItem, SDK_Localizator, ResultTypes, SDK_Globals } from '@topconsultnpm/sdk-ts';
|
|
2
3
|
import { TMColors } from '../../../utils/theme';
|
|
3
4
|
import { SDKUI_Localizator } from '../../../helper';
|
|
@@ -296,7 +297,20 @@ newTasks // Array of new tasks to merge
|
|
|
296
297
|
return Array.from(taskMap.values());
|
|
297
298
|
};
|
|
298
299
|
export const getOriginLabel = (pdg, ID1Name) => {
|
|
299
|
-
|
|
300
|
+
let label = ID1Name ?? SDKUI_Localizator.NoSource;
|
|
301
|
+
try {
|
|
302
|
+
if (typeof label === 'string' && label.length > 0) {
|
|
303
|
+
// Rimuove: (TID: 123), (DID: 456), TID: 123, DID: 456
|
|
304
|
+
label = label.replace(/\s*\(\s*\b(?:TID|DID):\s*\d+\s*\)|\s*\b(?:TID|DID):\s*\d+/gi, '');
|
|
305
|
+
// Rimuove eventuali spazi multipli rimasti
|
|
306
|
+
label = label.replace(/\s{2,}/g, ' ').trim();
|
|
307
|
+
}
|
|
308
|
+
}
|
|
309
|
+
catch {
|
|
310
|
+
label = ID1Name ?? SDKUI_Localizator.NoSource;
|
|
311
|
+
}
|
|
312
|
+
// Se pdg esiste ritorna la label (anche se vuota), altrimenti ritorna sempre NoSource
|
|
313
|
+
return pdg ? label : SDKUI_Localizator.NoSource;
|
|
300
314
|
};
|
|
301
315
|
export const taskValidatorAsync = async (taskDescriptor) => {
|
|
302
316
|
let vil = [];
|
|
@@ -399,59 +413,65 @@ export const areDifferentIDs = (fromID, userID) => {
|
|
|
399
413
|
export const createTasksMenuItems = (taskDescriptor, showId, setShowId, showSearch, setShowSearch, openTaskForm, openEditTaskForm, openDuplicateTaskForm, onDeleteCallback, markAsStatus, getAllTasks, fromWG, showContextualWG, setShowContextualWG, fromDossier, showContextualDossier, setShowContextualDossier, fromDocument, showContextualDocument, setShowContextualDocument, showGoToToday, handleGoToToday, fromDatagrid = true) => {
|
|
400
414
|
const isTaskDescriptorDefined = taskDescriptor !== undefined;
|
|
401
415
|
const isTaskFromAnotherUser = isTaskDescriptorDefined && areDifferentIDs(taskDescriptor.fromID, SDK_Globals.tmSession?.SessionDescr?.userID);
|
|
416
|
+
const getRowIdsAsArray = (rowIds) => {
|
|
417
|
+
if (fromDatagrid) {
|
|
418
|
+
return Array.isArray(rowIds) ? rowIds : [rowIds];
|
|
419
|
+
}
|
|
420
|
+
return taskDescriptor?.id ? [taskDescriptor.id] : [];
|
|
421
|
+
};
|
|
402
422
|
const menuItems = [
|
|
403
423
|
{
|
|
404
424
|
id: 'createContextualTask',
|
|
405
|
-
|
|
406
|
-
icon:
|
|
425
|
+
name: SDKUI_Localizator.CreateContextualTask,
|
|
426
|
+
icon: _jsx("span", { className: "dx-icon-plus" }),
|
|
407
427
|
onClick: () => { openTaskForm(FormModes.Create, undefined, true); },
|
|
408
428
|
disabled: false
|
|
409
429
|
},
|
|
410
430
|
{
|
|
411
|
-
|
|
412
|
-
icon:
|
|
431
|
+
name: SDKUI_Localizator.Create,
|
|
432
|
+
icon: _jsx("span", { className: "dx-icon-plus" }),
|
|
413
433
|
onClick: () => { openTaskForm(FormModes.Create, undefined, false); },
|
|
414
434
|
disabled: false
|
|
415
435
|
},
|
|
416
436
|
{
|
|
417
|
-
|
|
418
|
-
icon:
|
|
419
|
-
onClick: openEditTaskForm,
|
|
437
|
+
name: SDKUI_Localizator.Update,
|
|
438
|
+
icon: _jsx("span", { className: "dx-icon-edit" }),
|
|
439
|
+
onClick: (rowId) => openEditTaskForm(fromDatagrid ? rowId : taskDescriptor?.id),
|
|
420
440
|
operationType: 'singleRow',
|
|
421
441
|
disabled: fromDatagrid ? false : !isTaskDescriptorDefined
|
|
422
442
|
},
|
|
423
443
|
{
|
|
424
|
-
|
|
425
|
-
icon:
|
|
426
|
-
onClick: openDuplicateTaskForm,
|
|
444
|
+
name: SDKUI_Localizator.Duplicate,
|
|
445
|
+
icon: _jsx("span", { className: "dx-icon-copy" }),
|
|
446
|
+
onClick: (rowId) => openDuplicateTaskForm(fromDatagrid ? rowId : taskDescriptor?.id),
|
|
427
447
|
operationType: 'singleRow',
|
|
428
448
|
disabled: fromDatagrid ? isTaskFromAnotherUser : !isTaskDescriptorDefined || isTaskFromAnotherUser
|
|
429
449
|
},
|
|
430
450
|
{
|
|
431
|
-
|
|
432
|
-
icon:
|
|
433
|
-
onClick: onDeleteCallback,
|
|
451
|
+
name: SDKUI_Localizator.Delete,
|
|
452
|
+
icon: _jsx("span", { className: "dx-icon-trash" }),
|
|
453
|
+
onClick: (rowIds) => onDeleteCallback(getRowIdsAsArray(rowIds)),
|
|
434
454
|
operationType: 'multiRow',
|
|
435
455
|
disabled: fromDatagrid ? isTaskFromAnotherUser : !isTaskDescriptorDefined || isTaskFromAnotherUser
|
|
436
456
|
},
|
|
437
457
|
{
|
|
438
|
-
icon:
|
|
439
|
-
|
|
458
|
+
icon: _jsx("span", { className: "dx-icon-optionsgear" }),
|
|
459
|
+
name: SDKUI_Localizator.MarkAs,
|
|
440
460
|
id: "markAs",
|
|
441
461
|
operationType: 'multiRow',
|
|
442
462
|
disabled: fromDatagrid ? false : !isTaskDescriptorDefined,
|
|
443
|
-
|
|
444
|
-
{ icon:
|
|
445
|
-
{ icon:
|
|
446
|
-
{ icon:
|
|
447
|
-
{ icon:
|
|
448
|
-
{ icon:
|
|
463
|
+
submenu: [
|
|
464
|
+
{ icon: _jsx("span", { className: "dx-icon-product" }), name: SDKUI_Localizator.NewFemale, operationType: 'multiRow', onClick: (rowIds) => markAsStatus(getRowIdsAsArray(rowIds), Task_States.NotStarted) },
|
|
465
|
+
{ icon: _jsx("span", { className: "dx-icon-refresh" }), name: SDKUI_Localizator.InProgress, operationType: 'multiRow', onClick: (rowIds) => markAsStatus(getRowIdsAsArray(rowIds), Task_States.InProgress) },
|
|
466
|
+
{ icon: _jsx("span", { className: "dx-icon-check" }), name: SDKUI_Localizator.Completed, operationType: 'multiRow', onClick: (rowIds) => markAsStatus(getRowIdsAsArray(rowIds), Task_States.Completed) },
|
|
467
|
+
{ icon: _jsx("span", { className: "dx-icon-taskstop" }), name: SDKUI_Localizator.Pending, operationType: 'multiRow', onClick: (rowIds) => markAsStatus(getRowIdsAsArray(rowIds), Task_States.Waiting) },
|
|
468
|
+
{ icon: _jsx("span", { className: "dx-icon-clock" }), name: SDKUI_Localizator.Postponed, operationType: 'multiRow', onClick: (rowIds) => markAsStatus(getRowIdsAsArray(rowIds), Task_States.Deferred) }
|
|
449
469
|
]
|
|
450
470
|
},
|
|
451
471
|
{
|
|
452
472
|
id: 'wgContextFilter',
|
|
453
|
-
|
|
454
|
-
icon:
|
|
473
|
+
name: showContextualWG ? SDKUI_Localizator.RemoveContextualFilter : SDKUI_Localizator.ApplyContextualFilter,
|
|
474
|
+
icon: _jsx("span", { className: "dx-icon-filter" }),
|
|
455
475
|
onClick: () => { setShowContextualWG(prev => !prev); },
|
|
456
476
|
disabled: false,
|
|
457
477
|
beginGroup: true,
|
|
@@ -459,8 +479,8 @@ export const createTasksMenuItems = (taskDescriptor, showId, setShowId, showSear
|
|
|
459
479
|
},
|
|
460
480
|
{
|
|
461
481
|
id: 'dossierContextFilter',
|
|
462
|
-
|
|
463
|
-
icon:
|
|
482
|
+
name: showContextualDossier ? SDKUI_Localizator.RemoveContextualFilter : SDKUI_Localizator.ApplyContextualFilter,
|
|
483
|
+
icon: _jsx("span", { className: "dx-icon-filter" }),
|
|
464
484
|
onClick: () => { setShowContextualDossier(prev => !prev); },
|
|
465
485
|
disabled: false,
|
|
466
486
|
beginGroup: !fromWG && !fromDocument,
|
|
@@ -468,38 +488,38 @@ export const createTasksMenuItems = (taskDescriptor, showId, setShowId, showSear
|
|
|
468
488
|
},
|
|
469
489
|
{
|
|
470
490
|
id: 'documentContextFilter',
|
|
471
|
-
|
|
472
|
-
icon:
|
|
491
|
+
name: showContextualDocument ? SDKUI_Localizator.RemoveContextualFilter : SDKUI_Localizator.ApplyContextualFilter,
|
|
492
|
+
icon: _jsx("span", { className: "dx-icon-filter" }),
|
|
473
493
|
onClick: () => { setShowContextualDocument(prev => !prev); },
|
|
474
494
|
disabled: false,
|
|
475
495
|
beginGroup: !fromDossier && !fromWG,
|
|
476
496
|
visible: fromDocument
|
|
477
497
|
},
|
|
478
498
|
{
|
|
479
|
-
icon: "event",
|
|
499
|
+
icon: _jsx("span", { className: "dx-icon-event" }),
|
|
480
500
|
onClick: () => { if (handleGoToToday) {
|
|
481
501
|
handleGoToToday();
|
|
482
502
|
} },
|
|
483
|
-
|
|
503
|
+
name: SDKUI_Localizator.GoToToday,
|
|
484
504
|
disabled: false,
|
|
485
505
|
beginGroup: true,
|
|
486
506
|
},
|
|
487
507
|
{
|
|
488
508
|
beginGroup: true,
|
|
489
|
-
icon: showSearch ? "eyeclose" : "eyeopen",
|
|
509
|
+
icon: showSearch ? _jsx("span", { className: "dx-icon-eyeclose" }) : _jsx("span", { className: "dx-icon-eyeopen" }),
|
|
490
510
|
onClick: () => setShowSearch(prevShowSearch => !prevShowSearch),
|
|
491
|
-
|
|
511
|
+
name: showSearch ? SDKUI_Localizator.HideSearch : SDKUI_Localizator.ShowSearch,
|
|
492
512
|
disabled: false
|
|
493
513
|
},
|
|
494
514
|
{
|
|
495
|
-
icon: showId ? "eyeclose" : "eyeopen",
|
|
515
|
+
icon: showId ? _jsx("span", { className: "dx-icon-eyeclose" }) : _jsx("span", { className: "dx-icon-eyeopen" }),
|
|
496
516
|
onClick: () => setShowId(prevShowId => !prevShowId),
|
|
497
|
-
|
|
517
|
+
name: showId ? SDKUI_Localizator.ID_Hide : SDKUI_Localizator.ID_Show,
|
|
498
518
|
disabled: false
|
|
499
519
|
},
|
|
500
520
|
{
|
|
501
|
-
|
|
502
|
-
icon:
|
|
521
|
+
name: SDKUI_Localizator.Refresh,
|
|
522
|
+
icon: _jsx("span", { className: "dx-icon-refresh" }),
|
|
503
523
|
onClick: () => getAllTasks(),
|
|
504
524
|
disabled: false,
|
|
505
525
|
},
|
|
@@ -529,7 +549,7 @@ export const createTasksMenuItems = (taskDescriptor, showId, setShowId, showSear
|
|
|
529
549
|
item.visible === undefined);
|
|
530
550
|
}
|
|
531
551
|
if (showGoToToday === false) {
|
|
532
|
-
filteredMenuItems = filteredMenuItems.filter(item => item.
|
|
552
|
+
filteredMenuItems = filteredMenuItems.filter(item => item.name !== SDKUI_Localizator.GoToToday);
|
|
533
553
|
}
|
|
534
554
|
return filteredMenuItems;
|
|
535
555
|
};
|
|
@@ -5,7 +5,6 @@ import { TabPanel, Item } from 'devextreme-react/tab-panel';
|
|
|
5
5
|
import { Priorities, ResultTypes, SDK_Globals, Task_States } from "@topconsultnpm/sdk-ts";
|
|
6
6
|
import { calculateNumberOfDays, renderTaskIcons } from "./TMTasksUtilsView";
|
|
7
7
|
import { getPriorityLocalizatorValue } from "../tasks/TMTasksUtils";
|
|
8
|
-
import ContextMenu from 'devextreme-react/context-menu';
|
|
9
8
|
import { calcResponsiveSizes, getExceptionMessage, SDKUI_Localizator, StyledTabItem, TMCountBadge } from "../../../helper";
|
|
10
9
|
import { useDeviceType } from "../../base/TMDeviceProvider";
|
|
11
10
|
import { FormModes } from "../../../ts";
|
|
@@ -85,8 +84,9 @@ const TMTasksView = (props) => {
|
|
|
85
84
|
onDeleteCallback([focusedRowKey]); }, (rowIds, status) => { if (focusedRowKey)
|
|
86
85
|
markAsStatus([focusedRowKey], status); }, getAllTasks, taskContext?.workingGroup?.id !== undefined, showContextualWG, setShowContextualWG, taskContext?.dossier?.id !== undefined, showContextualDossier, setShowContextualDossier, taskContext?.document?.tid !== undefined && taskContext?.document?.did !== undefined, showContextualDocument, setShowContextualDocument, true, () => { setCurrentCalendarDate(new Date()); setCurrentAgendaDate(new Date()); }, false),
|
|
87
86
|
];
|
|
88
|
-
}, [
|
|
87
|
+
}, [focusedRowKey, showId, showSearch, showContextualWG, showContextualDossier, taskContext]);
|
|
89
88
|
const [menuItems, setMenuItems] = useState(agendaCalendarItems());
|
|
89
|
+
const [datagridMenu, setDatagridMenu] = useState([]);
|
|
90
90
|
const newTaskCount = getNewTaskCount(allTasks);
|
|
91
91
|
useEffect(() => {
|
|
92
92
|
setMenuItems(agendaCalendarItems());
|
|
@@ -266,6 +266,23 @@ const TMTasksView = (props) => {
|
|
|
266
266
|
}
|
|
267
267
|
});
|
|
268
268
|
}, [visualizedTasks]);
|
|
269
|
+
const listMenuItems = useCallback(() => {
|
|
270
|
+
const taskDescriptor = visualizedTasks.find(task => task.id === focusedRowKey);
|
|
271
|
+
return createTasksMenuItems(taskDescriptor, showId, setShowId, showSearch, setShowSearch, openTaskFormCallback, (rowId) => { if (rowId) {
|
|
272
|
+
const task = visualizedTasks.find(t => t.id === rowId);
|
|
273
|
+
if (task)
|
|
274
|
+
openTaskFormCallback(FormModes.Update, task);
|
|
275
|
+
} }, (rowId) => { if (rowId) {
|
|
276
|
+
const task = visualizedTasks.find(t => t.id === rowId);
|
|
277
|
+
if (task)
|
|
278
|
+
openTaskFormCallback(FormModes.Duplicate, task);
|
|
279
|
+
} }, onDeleteCallback, markAsStatus, getAllTasks, taskContext?.workingGroup?.id !== undefined, showContextualWG, setShowContextualWG, taskContext?.dossier?.id !== undefined, showContextualDossier, setShowContextualDossier, taskContext?.document?.tid !== undefined && taskContext?.document?.did !== undefined, showContextualDocument, setShowContextualDocument, false, // showGoToToday
|
|
280
|
+
undefined, true // fromDatagrid
|
|
281
|
+
);
|
|
282
|
+
}, [visualizedTasks, focusedRowKey, showId, showSearch, showContextualWG, showContextualDossier, showContextualDocument, taskContext, openTaskFormCallback, onDeleteCallback, markAsStatus, getAllTasks]);
|
|
283
|
+
useEffect(() => {
|
|
284
|
+
setDatagridMenu(listMenuItems());
|
|
285
|
+
}, [listMenuItems]);
|
|
269
286
|
const onSavedCallback = async (task) => {
|
|
270
287
|
// If task is undefined or has no ID, exit early
|
|
271
288
|
if (task === undefined || task.id === undefined)
|
|
@@ -295,22 +312,14 @@ const TMTasksView = (props) => {
|
|
|
295
312
|
}
|
|
296
313
|
setShowTaskForm(false);
|
|
297
314
|
};
|
|
298
|
-
const handleNavigateToDossiersWrapper = useCallback(async (
|
|
315
|
+
const handleNavigateToDossiersWrapper = useCallback(async (value) => {
|
|
299
316
|
setShowTaskForm(false);
|
|
300
|
-
await handleNavigateToDossiers(
|
|
301
|
-
}, []);
|
|
302
|
-
const handleNavigateToWGsWrapper = useCallback(async (
|
|
317
|
+
await handleNavigateToDossiers(value);
|
|
318
|
+
}, [handleNavigateToDossiers]);
|
|
319
|
+
const handleNavigateToWGsWrapper = useCallback(async (value) => {
|
|
303
320
|
setShowTaskForm(false);
|
|
304
|
-
await handleNavigateToWGs(
|
|
305
|
-
}, []);
|
|
306
|
-
const onContextMenuPreparing = (e) => {
|
|
307
|
-
if (e === undefined)
|
|
308
|
-
return;
|
|
309
|
-
if (e.target === 'content') {
|
|
310
|
-
e.items = e.items || [];
|
|
311
|
-
e.items = createTasksMenuItems(e.row?.data, showId, setShowId, showSearch, setShowSearch, openTaskFormCallback, () => { openTaskFormCallback(FormModes.Update, e.row?.data); }, () => { openTaskFormCallback(FormModes.Duplicate, e.row?.data); }, onDeleteCallback, markAsStatus, getAllTasks, taskContext?.workingGroup?.id !== undefined, showContextualWG, setShowContextualWG, taskContext?.dossier?.id !== undefined, showContextualDossier, setShowContextualDossier, taskContext?.document?.tid !== undefined && taskContext?.document?.did !== undefined, showContextualDocument, setShowContextualDocument, false);
|
|
312
|
-
}
|
|
313
|
-
};
|
|
321
|
+
await handleNavigateToWGs(value);
|
|
322
|
+
}, [handleNavigateToWGs]);
|
|
314
323
|
const RenderCustomHeader = ({ data }) => { return _jsx("p", { style: { color: TEXT_NOT_SELECTED_COLOR }, children: data.column.caption }); };
|
|
315
324
|
const cellDefaultRender = useCallback((cellData) => {
|
|
316
325
|
const data = cellData.data;
|
|
@@ -519,13 +528,13 @@ const TMTasksView = (props) => {
|
|
|
519
528
|
];
|
|
520
529
|
}, [showId]);
|
|
521
530
|
const getFromOrToDatagridElement = (fromOrToDataSource, fromCell = false, toCell = false) => {
|
|
522
|
-
return _jsx(TMDataGrid, { dataSource: fromOrToDataSource, dataColumns: getDataColumns(fromCell, toCell), selection: { mode: 'multiple', showCheckBoxesMode: "always" }, focusedRowKey: focusedRowKey, selectedRowKeys: [...selectedRowKeys], onFocusedRowChanged: onFocusedRowChanged, onSelectionChanged: onSelectionChanged, onRowDblClick: onRowDblClick,
|
|
531
|
+
return _jsx(TMDataGrid, { dataSource: fromOrToDataSource, dataColumns: getDataColumns(fromCell, toCell), selection: { mode: 'multiple', showCheckBoxesMode: "always" }, focusedRowKey: focusedRowKey, selectedRowKeys: [...selectedRowKeys], onFocusedRowChanged: onFocusedRowChanged, onSelectionChanged: onSelectionChanged, onRowDblClick: onRowDblClick, customContextMenuItems: datagridMenu, showSearchPanel: showSearch, noDataText: SDKUI_Localizator.TasksEmpty, counterConfig: { show: true }, onHasFiltersChange: (active) => setHasFilters(active) });
|
|
523
532
|
};
|
|
524
533
|
const getFromOrToAgendaElement = (fromOrToDataSource, fromCell = false, toCell = false) => {
|
|
525
|
-
return
|
|
534
|
+
return _jsx("div", { style: { width: '100%', height: '100%', display: 'flex', flexDirection: 'column', overflow: "auto" }, children: _jsx("div", { style: { width: "100%", height: "100%" }, children: _jsx(TMTasksAgenda, { id: id, showId: showId, showSearch: showSearch, visualizedTasks: fromOrToDataSource, fromCell: fromCell, toCell: toCell, currentAgendaDate: currentAgendaDate, setCurrentAgendaDate: setCurrentAgendaDate, openTaskForm: openTaskFormCallback, handleFocusedRowChange: handleFocusedRowChange, menuItems: menuItems }) }) });
|
|
526
535
|
};
|
|
527
536
|
const getFromOrToCalendarElement = (fromOrToDataSource, fromCell = false, toCell = false) => {
|
|
528
|
-
return
|
|
537
|
+
return _jsx("div", { style: { width: '100%', height: '100%', display: 'flex', flexDirection: 'column', overflow: "auto" }, children: _jsx("div", { style: { width: "100%", height: "100%" }, children: _jsx(TMTasksCalendar, { id: id, visualizedTasks: fromOrToDataSource, showId: showId, fromCell: fromCell, toCell: toCell, showSearch: showSearch, currentCalendarDate: currentCalendarDate, setCurrentCalendarDate: setCurrentCalendarDate, openTaskForm: openTaskFormCallback, onDeleteCallback: onDeleteCallback, setCalendarStartDate: setCalendarStartDate, setCalendarEndDate: setCalendarEndDate, focusedRowKey: focusedRowKey, handleFocusedRowChange: handleFocusedRowChange, menuItems: menuItems }) }) });
|
|
529
538
|
};
|
|
530
539
|
return _jsxs("div", { style: { width: '100%', height: '100%' }, onContextMenu: (e) => e.preventDefault(), children: [_jsx(TMLayoutWaitingContainer, { direction: 'vertical', showWaitPanel: showWaitPanel, showWaitPanelPrimary: showPrimary, waitPanelTitle: waitPanelTitle, waitPanelTextPrimary: waitPanelTextPrimary, waitPanelValuePrimary: waitPanelValuePrimary, waitPanelMaxValuePrimary: waitPanelMaxValuePrimary, isCancelable: true, abortController: abortController, children: _jsxs(TabPanel, { width: "100%", height: "100%", animationEnabled: false, swipeEnabled: false, loop: false, showNavButtons: true, repaintChangesOnly: true, stylingMode: "primary", iconPosition: 'start', tabsPosition: 'top', selectedIndex: activeTabIndex, onSelectedIndexChange: onSelectedIndexChange, id: "task-centered-tab-title", children: [_jsx(Item, { title: SDKUI_Localizator.AssignedToMe, icon: "user", tabRender: (params) => {
|
|
531
540
|
return _jsxs(StyledTabItem, { "$isSelected": activeTabIndex === AssignedTab.AssignedToMe, children: [_jsxs(TMTooltip, { content: SDKUI_Localizator.AssignedToMe, children: [_jsx("i", { className: `dx-icon-${params.icon}` }), "\u00A0", params.title, " ", (assignedToMeCount > 0) ? `(${assignedToMeCount})` : ''] }), newTaskCount > 0 && (_jsx(TMTooltip, { content: SDKUI_Localizator.NewAssignedActivitiesNumber + ": " + newTaskCount, children: _jsx(TMCountBadge, { children: newTaskCount }) }))] });
|
|
@@ -1,5 +1,6 @@
|
|
|
1
|
-
import { DcmtTypeDescriptor } from '@topconsultnpm/sdk-ts';
|
|
1
|
+
import { DcmtTypeDescriptor, WFDescriptor } from '@topconsultnpm/sdk-ts';
|
|
2
2
|
import { DeviceType } from "../../base/TMDeviceProvider";
|
|
3
|
+
import { WorkItemDetail } from "../../../ts";
|
|
3
4
|
interface IWorkflowOperationButtonsProps {
|
|
4
5
|
dtd: DcmtTypeDescriptor | undefined;
|
|
5
6
|
approveDisable?: boolean;
|
|
@@ -24,13 +25,43 @@ export declare const WorkFlowApproveRejectPopUp: ({ TID, DID, deviceType, isReje
|
|
|
24
25
|
onClose?: () => void;
|
|
25
26
|
onCompleted?: () => Promise<void>;
|
|
26
27
|
}) => import("react/jsx-runtime").JSX.Element;
|
|
27
|
-
export declare const WorkFlowReAssignPopUp: ({ DID, TID, deviceType, onClose, selectedItems, onCompleted }: {
|
|
28
|
+
export declare const WorkFlowReAssignPopUp: ({ DID, TID, deviceType, onClose, selectedItems, onCompleted, wf, workItemDetail }: {
|
|
28
29
|
TID?: number;
|
|
29
30
|
DID?: number;
|
|
30
31
|
deviceType?: DeviceType;
|
|
31
32
|
onClose?: () => void;
|
|
32
33
|
selectedItems?: any[];
|
|
33
34
|
onCompleted?: () => Promise<void>;
|
|
35
|
+
wf?: WFDescriptor;
|
|
36
|
+
workItemDetail?: WorkItemDetail;
|
|
37
|
+
}) => import("react/jsx-runtime").JSX.Element;
|
|
38
|
+
/**
|
|
39
|
+
* Modal per forzare l'approvazione di un work item
|
|
40
|
+
*/
|
|
41
|
+
export declare const WorkflowForceApproveModal: ({ detail, onClose, onCompleted }: {
|
|
42
|
+
detail: WorkItemDetail;
|
|
43
|
+
onClose?: () => void;
|
|
44
|
+
onCompleted?: () => Promise<void>;
|
|
45
|
+
}) => import("react/jsx-runtime").JSX.Element;
|
|
46
|
+
/**
|
|
47
|
+
* Modal per forzare il rifiuto di un work item
|
|
48
|
+
*/
|
|
49
|
+
export declare const WorkflowForceRejectModal: ({ detail, onClose, onCompleted }: {
|
|
50
|
+
detail: WorkItemDetail;
|
|
51
|
+
onClose?: () => void;
|
|
52
|
+
onCompleted?: () => Promise<void>;
|
|
53
|
+
}) => import("react/jsx-runtime").JSX.Element;
|
|
54
|
+
/**
|
|
55
|
+
* Modal per terminare le istanze workflow selezionate
|
|
56
|
+
*/
|
|
57
|
+
export declare const WorkflowEndInstanceModal: ({ selectedInstances, onClose, onCompleted }: {
|
|
58
|
+
selectedInstances: Array<{
|
|
59
|
+
wfid?: number;
|
|
60
|
+
tid?: number;
|
|
61
|
+
did?: number;
|
|
62
|
+
}>;
|
|
63
|
+
onClose?: () => void;
|
|
64
|
+
onCompleted?: () => Promise<void>;
|
|
34
65
|
}) => import("react/jsx-runtime").JSX.Element;
|
|
35
66
|
export declare const WorkFlowMoreInfoPopUp: ({ DID, TID, deviceType, onClose, onCompleted }: {
|
|
36
67
|
TID?: number;
|