@topconsultnpm/sdkui-react-beta 6.9.127 → 6.9.129
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.
|
@@ -19,7 +19,7 @@ const cellRender = (cellData) => {
|
|
|
19
19
|
}
|
|
20
20
|
};
|
|
21
21
|
const TMResultDialog = ({ title, result, id1Caption, id2Caption }) => {
|
|
22
|
-
return (_jsx(TMModal, { height: '65%', width: '75%', title: `${SDKUI_Localizator.OperationResult} - ${title}`, children: _jsxs(TMLayoutContainer, { children: [_jsxs("div", { style: { display: 'flex', flexDirection: 'row', gap: '5px', padding: '5px', justifyContent: 'center', alignItems: 'center' }, children: [_jsx("p", { children: `${SDKUI_Localizator.ProcessedItems}: ${result.length}` }), _jsx(IconSuccessCirlce, { fontSize: 22, color: TMColors.success }), _jsx("p", { children: result.filter(o => o.resultType == ResultTypes.SUCCESS).length ?? 0 }), _jsx(IconWarning, { fontSize: 22, color: TMColors.warning }), _jsx("p", { children: result.filter(o => o.resultType == ResultTypes.WARNING).length ?? 0 }), _jsx(IconCloseCircle, { fontSize: 22, color: TMColors.error }), _jsx("p", { children: result.filter(o => o.resultType == ResultTypes.ERROR).length ?? 0 })] }), _jsxs(DataGrid, { dataSource: result.filter(o => o.resultType != ResultTypes.SUCCESS), showColumnLines: SDKUI_Globals.dataGridShowColumnLines, showRowLines: SDKUI_Globals.dataGridShowRowLines, keyExpr: "rowIndex", width: "100%", height: "100%", columnResizingMode: "widget", allowColumnResizing: true, columnAutoWidth: true, children: [_jsx(Column, { dataField: 'resultType', caption: '', allowResizing: true, allowSorting: true, cellRender: cellRender }), _jsx(Column, { dataField: 'id1', caption: id1Caption }), id2Caption && _jsx(Column, { dataField: 'id2', caption: id2Caption }), _jsx(Column, { dataField: 'description', allowResizing: true, caption: SDKUI_Localizator.Description, allowSorting: true }), _jsx(Paging, { enabled: true, pageSize: 30 }), _jsx(Pager, { visible: true, showInfo: true, showNavigationButtons: true }), _jsx(Scrolling, { mode: 'standard', useNative: SDKUI_Globals.dataGridUseNativeScrollbar }), _jsx(HeaderFilter, { visible: true })] })] }) }));
|
|
22
|
+
return (_jsx(TMModal, { height: '65%', width: '75%', title: `${SDKUI_Localizator.OperationResult} - ${title}`, children: _jsxs(TMLayoutContainer, { children: [_jsxs("div", { style: { display: 'flex', flexDirection: 'row', gap: '5px', padding: '5px', justifyContent: 'center', alignItems: 'center' }, children: [_jsx("p", { children: `${SDKUI_Localizator.ProcessedItems}: ${result.length}` }), _jsx(IconSuccessCirlce, { fontSize: 22, color: TMColors.success }), _jsx("p", { children: result.filter(o => o.resultType == ResultTypes.SUCCESS).length ?? 0 }), _jsx(IconWarning, { fontSize: 22, color: TMColors.warning }), _jsx("p", { children: result.filter(o => o.resultType == ResultTypes.WARNING).length ?? 0 }), _jsx(IconCloseCircle, { fontSize: 22, color: TMColors.error }), _jsx("p", { children: result.filter(o => o.resultType == ResultTypes.ERROR).length ?? 0 })] }), _jsxs(DataGrid, { dataSource: result.filter(o => o.resultType != ResultTypes.SUCCESS), showColumnLines: SDKUI_Globals.dataGridShowColumnLines, showRowLines: SDKUI_Globals.dataGridShowRowLines, keyExpr: "rowIndex", width: "100%", height: "100%", columnResizingMode: "widget", allowColumnResizing: true, columnAutoWidth: true, focusedRowEnabled: true, hoverStateEnabled: true, rowAlternationEnabled: true, children: [_jsx(Column, { dataField: 'resultType', caption: '', allowResizing: true, allowSorting: true, cellRender: cellRender, width: 50 }), _jsx(Column, { dataField: 'id1', caption: id1Caption }), id2Caption && _jsx(Column, { dataField: 'id2', caption: id2Caption }), _jsx(Column, { dataField: 'description', allowResizing: true, caption: SDKUI_Localizator.Description, allowSorting: true }), _jsx(Paging, { enabled: true, pageSize: 30 }), _jsx(Pager, { visible: true, showInfo: true, showNavigationButtons: true }), _jsx(Scrolling, { mode: 'standard', useNative: SDKUI_Globals.dataGridUseNativeScrollbar }), _jsx(HeaderFilter, { visible: true })] })] }) }));
|
|
23
23
|
};
|
|
24
24
|
export default TMResultDialog;
|
|
25
25
|
export class TMResultManager {
|
|
@@ -2,13 +2,14 @@ import React from 'react';
|
|
|
2
2
|
import { ITopMediaSession, LayoutModes, MetadataDescriptor } from '@topconsultnpm/sdk-ts-beta';
|
|
3
3
|
import { TID_MID } from '../../ts';
|
|
4
4
|
import { DataGridTypes } from 'devextreme-react/cjs/data-grid';
|
|
5
|
-
export declare const TMMidViewer: ({ tmSession, tid_mid, showCompleteName, showIcon, showId, noneSelectionText }: {
|
|
5
|
+
export declare const TMMidViewer: ({ isMetadataSelected, tmSession, tid_mid, showCompleteName, showIcon, showId, noneSelectionText }: {
|
|
6
6
|
tmSession?: ITopMediaSession;
|
|
7
7
|
tid_mid: TID_MID | undefined;
|
|
8
8
|
showCompleteName?: boolean;
|
|
9
9
|
showIcon?: boolean;
|
|
10
10
|
showId?: boolean;
|
|
11
11
|
noneSelectionText?: string;
|
|
12
|
+
isMetadataSelected?: boolean;
|
|
12
13
|
}) => import("react/jsx-runtime").JSX.Element;
|
|
13
14
|
interface ITMMetadataIcon {
|
|
14
15
|
tid: number | undefined;
|
|
@@ -5,7 +5,7 @@ import { DcmtTypeListCacheService, LayoutModes, MetadataDataDomains, MetadataDat
|
|
|
5
5
|
import { StyledDivHorizontal, StyledTooltipContainer, StyledTooltipItem, StyledTooltipSeparatorItem } from '../base/Styled';
|
|
6
6
|
import TMTooltip from '../base/TMTooltip';
|
|
7
7
|
import { TMColors } from '../../utils/theme';
|
|
8
|
-
export const TMMidViewer = ({ tmSession, tid_mid, showCompleteName, showIcon = false, showId = false, noneSelectionText = `<${SDKUI_Localizator.NoneSelection}>` }) => {
|
|
8
|
+
export const TMMidViewer = ({ isMetadataSelected = false, tmSession, tid_mid, showCompleteName, showIcon = false, showId = false, noneSelectionText = `<${SDKUI_Localizator.NoneSelection}>` }) => {
|
|
9
9
|
const [md, setMd] = useState();
|
|
10
10
|
const [dcmtTypeName, setDcmtTypeName] = useState();
|
|
11
11
|
useEffect(() => {
|
|
@@ -26,7 +26,7 @@ export const TMMidViewer = ({ tmSession, tid_mid, showCompleteName, showIcon = f
|
|
|
26
26
|
return getCompleteMetadataName(dcmtTypeName, SDK_Globals.useLocalizedName ? md.nameLoc : md.name);
|
|
27
27
|
return SDK_Globals.useLocalizedName ? md.nameLoc : md.name;
|
|
28
28
|
};
|
|
29
|
-
return (_jsxs(StyledDivHorizontal, { children: [showIcon && _jsx(TMMetadataIcon, { tid: tid_mid?.tid, md: md }), _jsx("p", { style: { textAlign: 'left', marginLeft: showIcon ? '5px' : '', color: md?.isRequired == 1 ? 'red' : undefined }, children: displayName() }), showId && _jsx("p", { style: { padding: '0px 3px' }, children: `(MID: ${tid_mid?.mid})` })] }));
|
|
29
|
+
return (_jsxs(StyledDivHorizontal, { children: [showIcon && _jsx(TMMetadataIcon, { isMetadataSelected: isMetadataSelected, tid: tid_mid?.tid, md: md }), _jsx("p", { style: { textAlign: 'left', marginLeft: showIcon ? '5px' : '', color: md?.isRequired == 1 ? 'red' : undefined }, children: displayName() }), showId && _jsx("p", { style: { padding: '0px 3px' }, children: `(MID: ${tid_mid?.mid})` })] }));
|
|
30
30
|
};
|
|
31
31
|
export const TMMetadataIcon = ({ tid, md, layoutMode = LayoutModes.Update, isMetadataSelected = false }) => {
|
|
32
32
|
let selectedMetadataStyle = { borderBottom: isMetadataSelected ? `thick solid ${TMColors.text_normal}` : 'none', height: 'max-content' };
|