@gridsuite/commons-ui 0.212.0 → 0.213.0
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/dist/components/filter/expert/ExpertFilterForm.d.ts +1 -1
- package/dist/components/filter/expert/ExpertFilterForm.js +2 -13
- package/dist/components/filter/explicitNaming/ExplicitNamingFilterForm.js +7 -10
- package/dist/components/filter/utils/filterApi.js +3 -3
- package/dist/components/index.js +16 -0
- package/dist/components/network-modification-table/columns-definition.d.ts +0 -2
- package/dist/components/network-modification-table/index.js +16 -0
- package/dist/components/network-modification-table/network-modifications-table.d.ts +8 -2
- package/dist/components/network-modification-table/network-modifications-table.js +33 -8
- package/dist/components/network-modification-table/renderers/cell-renderers.d.ts +23 -0
- package/dist/components/network-modification-table/renderers/cell-renderers.js +103 -0
- package/dist/components/network-modification-table/renderers/description-cell.d.ts +9 -0
- package/dist/components/network-modification-table/renderers/description-cell.js +73 -0
- package/dist/components/network-modification-table/renderers/index.d.ts +4 -0
- package/dist/components/network-modification-table/renderers/index.js +17 -1
- package/dist/components/network-modification-table/renderers/name-cell.d.ts +2 -2
- package/dist/components/network-modification-table/renderers/name-cell.js +28 -9
- package/dist/components/network-modification-table/renderers/root-network-chip-cell.d.ts +13 -0
- package/dist/components/network-modification-table/renderers/root-network-chip-cell.js +138 -0
- package/dist/components/network-modification-table/renderers/select-cell.js +2 -2
- package/dist/components/network-modification-table/renderers/select-header-cell.js +2 -2
- package/dist/components/network-modification-table/renderers/switch-cell.d.ts +9 -0
- package/dist/components/network-modification-table/renderers/switch-cell.js +63 -0
- package/dist/index.js +24 -3
- package/dist/services/index.js +4 -1
- package/dist/services/networkModification.d.ts +8 -1
- package/dist/services/networkModification.js +45 -1
- package/dist/translations/en/filterEn.d.ts +0 -1
- package/dist/translations/en/filterEn.js +0 -1
- package/dist/translations/en/filterExpertEn.d.ts +0 -2
- package/dist/translations/en/filterExpertEn.js +0 -2
- package/dist/translations/en/networkModificationsEn.d.ts +1 -0
- package/dist/translations/en/networkModificationsEn.js +4 -3
- package/dist/translations/fr/filterExpertFr.d.ts +0 -2
- package/dist/translations/fr/filterExpertFr.js +0 -2
- package/dist/translations/fr/filterFr.d.ts +0 -1
- package/dist/translations/fr/filterFr.js +0 -1
- package/dist/translations/fr/networkModificationsFr.d.ts +1 -0
- package/dist/translations/fr/networkModificationsFr.js +4 -3
- package/dist/utils/constants/index.js +2 -1
- package/dist/utils/constants/translationKeys.d.ts +1 -0
- package/dist/utils/constants/translationKeys.js +2 -0
- package/dist/utils/index.js +4 -2
- package/dist/utils/types/equipmentTypes.d.ts +1 -0
- package/dist/utils/types/equipmentTypes.js +5 -1
- package/dist/utils/types/index.js +2 -1
- package/dist/utils/types/network-modification-types.d.ts +6 -0
- package/package.json +1 -1
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { jsxs, jsx } from "react/jsx-runtime";
|
|
2
|
-
import { useCallback, useMemo, useState, useRef } from "react";
|
|
2
|
+
import { useCallback, useMemo, useState, useEffect, useRef } from "react";
|
|
3
3
|
import { useIntl } from "react-intl";
|
|
4
4
|
import { useTheme, Box, IconButton, InputBase } from "@mui/material";
|
|
5
5
|
import { KeyboardArrowDown, KeyboardArrowRight } from "@mui/icons-material";
|
|
@@ -9,13 +9,14 @@ import { DepthBox } from "./depth-box.js";
|
|
|
9
9
|
import { isCompositeModification } from "../utils.js";
|
|
10
10
|
import { useModificationLabelComputer } from "../../../hooks/useModificationLabelComputer.js";
|
|
11
11
|
import "../../../utils/conversionUtils.js";
|
|
12
|
+
import { snackWithFallback } from "../../../utils/error.js";
|
|
12
13
|
import "../../../utils/types/equipmentType.js";
|
|
13
14
|
import { mergeSx } from "../../../utils/styles.js";
|
|
14
15
|
import "../../../utils/yupConfig.js";
|
|
15
16
|
import "localized-countries";
|
|
16
17
|
import "localized-countries/data/fr";
|
|
17
18
|
import "localized-countries/data/en";
|
|
18
|
-
import "
|
|
19
|
+
import { useSnackMessage } from "../../../hooks/useSnackMessage.js";
|
|
19
20
|
const MIN_CHAR_WIDTH = 30;
|
|
20
21
|
function measureTextPx(text, font) {
|
|
21
22
|
const ctx = document.createElement("canvas").getContext("2d");
|
|
@@ -25,10 +26,11 @@ function measureTextPx(text, font) {
|
|
|
25
26
|
}
|
|
26
27
|
return text.length * 8;
|
|
27
28
|
}
|
|
28
|
-
function NameCell({ row,
|
|
29
|
+
function NameCell({ row, onChange }) {
|
|
29
30
|
const intl = useIntl();
|
|
30
31
|
const theme = useTheme();
|
|
31
32
|
const { computeLabel } = useModificationLabelComputer();
|
|
33
|
+
const { snackError } = useSnackMessage();
|
|
32
34
|
const { depth } = row;
|
|
33
35
|
const isComposite = isCompositeModification(row.original);
|
|
34
36
|
const getModificationLabel = useCallback(
|
|
@@ -40,8 +42,7 @@ function NameCell({ row, onEditNameCell }) {
|
|
|
40
42
|
},
|
|
41
43
|
[computeLabel, intl]
|
|
42
44
|
);
|
|
43
|
-
const
|
|
44
|
-
const compositeName = useMemo(() => {
|
|
45
|
+
const savedCompositeName = useMemo(() => {
|
|
45
46
|
if (!isComposite) {
|
|
46
47
|
return "";
|
|
47
48
|
}
|
|
@@ -51,6 +52,14 @@ function NameCell({ row, onEditNameCell }) {
|
|
|
51
52
|
return "";
|
|
52
53
|
}
|
|
53
54
|
}, [isComposite, row.original.messageValues]);
|
|
55
|
+
const [compositeName, setCompositeName] = useState(savedCompositeName);
|
|
56
|
+
useEffect(() => {
|
|
57
|
+
setCompositeName(savedCompositeName);
|
|
58
|
+
}, [savedCompositeName]);
|
|
59
|
+
const label = useMemo(
|
|
60
|
+
() => isComposite ? getModificationLabel({ ...row.original, messageValues: JSON.stringify({ name: compositeName }) }) : getModificationLabel(row.original),
|
|
61
|
+
[getModificationLabel, row.original, isComposite, compositeName]
|
|
62
|
+
);
|
|
54
63
|
const [isEditing, setIsEditing] = useState(false);
|
|
55
64
|
const [draftName, setDraftName] = useState("");
|
|
56
65
|
const [inputBaseWidthPx, setInputBaseWidthPx] = useState(null);
|
|
@@ -62,16 +71,26 @@ function NameCell({ row, onEditNameCell }) {
|
|
|
62
71
|
setIsEditing(false);
|
|
63
72
|
setInputBaseWidthPx(null);
|
|
64
73
|
}, []);
|
|
74
|
+
const updateName = useCallback(
|
|
75
|
+
(newName) => {
|
|
76
|
+
setCompositeName(newName);
|
|
77
|
+
Promise.resolve(onChange?.(row.original, newName)).catch((error) => {
|
|
78
|
+
setCompositeName(savedCompositeName);
|
|
79
|
+
snackWithFallback(snackError, error, { headerId: "networkModificationRenamingError" });
|
|
80
|
+
});
|
|
81
|
+
},
|
|
82
|
+
[onChange, row.original, savedCompositeName, snackError]
|
|
83
|
+
);
|
|
65
84
|
const handleBlur = useCallback(() => {
|
|
66
85
|
if (!isEditingRef.current) {
|
|
67
86
|
return;
|
|
68
87
|
}
|
|
69
88
|
const trimmed = draftName.trim();
|
|
70
89
|
if (trimmed !== "" && trimmed !== compositeName) {
|
|
71
|
-
|
|
90
|
+
updateName(trimmed);
|
|
72
91
|
}
|
|
73
92
|
stopEditing();
|
|
74
|
-
}, [compositeName, draftName,
|
|
93
|
+
}, [compositeName, draftName, updateName, stopEditing]);
|
|
75
94
|
const handleLabelClick = useCallback(
|
|
76
95
|
(e) => {
|
|
77
96
|
e.stopPropagation();
|
|
@@ -96,7 +115,7 @@ function NameCell({ row, onEditNameCell }) {
|
|
|
96
115
|
if (e.key === "Enter") {
|
|
97
116
|
const trimmed = draftName.trim();
|
|
98
117
|
if (trimmed !== "" && trimmed !== compositeName) {
|
|
99
|
-
|
|
118
|
+
updateName(trimmed);
|
|
100
119
|
}
|
|
101
120
|
stopEditing();
|
|
102
121
|
inputRef.current?.blur();
|
|
@@ -105,7 +124,7 @@ function NameCell({ row, onEditNameCell }) {
|
|
|
105
124
|
inputRef.current?.blur();
|
|
106
125
|
}
|
|
107
126
|
},
|
|
108
|
-
[compositeName, draftName,
|
|
127
|
+
[compositeName, draftName, updateName, stopEditing]
|
|
109
128
|
);
|
|
110
129
|
const renderDepthBox = () => {
|
|
111
130
|
const depthLevelCount = depth;
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import { default as React, SetStateAction } from 'react';
|
|
2
|
+
import { UUID } from 'node:crypto';
|
|
3
|
+
import { ComposedModificationMetadata, ExcludedNetworkModifications, RootNetworkRowInfo } from '../../../utils';
|
|
4
|
+
export interface RootNetworkChipCellProps {
|
|
5
|
+
data: ComposedModificationMetadata;
|
|
6
|
+
studyUuid: UUID | null;
|
|
7
|
+
currentNodeId?: UUID;
|
|
8
|
+
rootNetwork: RootNetworkRowInfo;
|
|
9
|
+
modificationsToExclude: ExcludedNetworkModifications[];
|
|
10
|
+
setModificationsToExclude: React.Dispatch<SetStateAction<ExcludedNetworkModifications[]>>;
|
|
11
|
+
isDisabled?: boolean;
|
|
12
|
+
}
|
|
13
|
+
export declare function RootNetworkChipCell(props: RootNetworkChipCellProps): import("react/jsx-runtime").JSX.Element;
|
|
@@ -0,0 +1,138 @@
|
|
|
1
|
+
import { jsx } from "react/jsx-runtime";
|
|
2
|
+
import { useState, useMemo, useCallback } from "react";
|
|
3
|
+
import "react-intl";
|
|
4
|
+
import "@mui/material";
|
|
5
|
+
import "../../overflowableText/OverflowableText.js";
|
|
6
|
+
import "../../../utils/conversionUtils.js";
|
|
7
|
+
import { snackWithFallback } from "../../../utils/error.js";
|
|
8
|
+
import "../../../utils/types/equipmentType.js";
|
|
9
|
+
import "@mui/icons-material";
|
|
10
|
+
import "../../../utils/yupConfig.js";
|
|
11
|
+
import "react-hook-form";
|
|
12
|
+
import { updateModificationStatusByRootNetwork } from "../../../services/networkModification.js";
|
|
13
|
+
import "localized-countries";
|
|
14
|
+
import "localized-countries/data/fr";
|
|
15
|
+
import "localized-countries/data/en";
|
|
16
|
+
import { useSnackMessage } from "../../../hooks/useSnackMessage.js";
|
|
17
|
+
import "../../inputs/reactHookForm/provider/CustomFormProvider.js";
|
|
18
|
+
import "yup";
|
|
19
|
+
import "../../treeViewFinder/TreeViewFinder.js";
|
|
20
|
+
import "../../inputs/reactHookForm/agGridTable/BottomRightButtons.js";
|
|
21
|
+
import "../../customAGGrid/customAggrid.js";
|
|
22
|
+
import "ag-grid-community";
|
|
23
|
+
import "react-papaparse";
|
|
24
|
+
import "react-csv-downloader";
|
|
25
|
+
import "../../inputs/reactHookForm/numbers/RangeInput.js";
|
|
26
|
+
import "@material-symbols/svg-400/outlined/left_panel_open.svg?react";
|
|
27
|
+
import "@material-symbols/svg-400/outlined/arrows_output.svg?react";
|
|
28
|
+
import "@material-symbols/svg-400/outlined/arrows_input.svg?react";
|
|
29
|
+
import "@material-symbols/svg-400/outlined/left_panel_close.svg?react";
|
|
30
|
+
import "@material-symbols/svg-400/outlined/add_notes.svg?react";
|
|
31
|
+
import "../../dialogs/descriptionModificationDialog/DescriptionModificationDialog.js";
|
|
32
|
+
import "../../inputs/reactHookForm/expandableInput/ExpandableInput.js";
|
|
33
|
+
import "@react-querybuilder/material";
|
|
34
|
+
import "../../filter/expert/expertFilterConstants.js";
|
|
35
|
+
import "../../inputs/reactQueryBuilder/CustomReactQueryBuilder.js";
|
|
36
|
+
import "uuid";
|
|
37
|
+
import "../../inputs/reactQueryBuilder/PropertyValueEditor.js";
|
|
38
|
+
import "react-querybuilder";
|
|
39
|
+
import { ActivableChip } from "../../inputs/ActivableChip.js";
|
|
40
|
+
function getUpdatedExcludedModifications(prev, rootNetworkUuid, modificationUuid) {
|
|
41
|
+
const exists = prev.some((item) => item.rootNetworkUuid === rootNetworkUuid);
|
|
42
|
+
if (exists) {
|
|
43
|
+
let newStatus = false;
|
|
44
|
+
const nextExcluded = prev.map((modif) => {
|
|
45
|
+
if (modif.rootNetworkUuid !== rootNetworkUuid) {
|
|
46
|
+
return modif;
|
|
47
|
+
}
|
|
48
|
+
const isExcluded = modif.modificationUuidsToExclude.includes(modificationUuid);
|
|
49
|
+
const newModificationUuidsToExclude = isExcluded ? modif.modificationUuidsToExclude.filter((id) => id !== modificationUuid) : [...modif.modificationUuidsToExclude, modificationUuid];
|
|
50
|
+
newStatus = isExcluded;
|
|
51
|
+
return {
|
|
52
|
+
...modif,
|
|
53
|
+
modificationUuidsToExclude: newModificationUuidsToExclude
|
|
54
|
+
};
|
|
55
|
+
});
|
|
56
|
+
return { nextExcluded, newStatus };
|
|
57
|
+
}
|
|
58
|
+
return {
|
|
59
|
+
nextExcluded: [
|
|
60
|
+
...prev,
|
|
61
|
+
{
|
|
62
|
+
rootNetworkUuid,
|
|
63
|
+
modificationUuidsToExclude: [modificationUuid]
|
|
64
|
+
}
|
|
65
|
+
],
|
|
66
|
+
newStatus: false
|
|
67
|
+
};
|
|
68
|
+
}
|
|
69
|
+
function RootNetworkChipCell(props) {
|
|
70
|
+
const {
|
|
71
|
+
data,
|
|
72
|
+
studyUuid,
|
|
73
|
+
currentNodeId,
|
|
74
|
+
rootNetwork,
|
|
75
|
+
modificationsToExclude,
|
|
76
|
+
setModificationsToExclude,
|
|
77
|
+
isDisabled = false
|
|
78
|
+
} = props;
|
|
79
|
+
const [isLoading, setIsLoading] = useState(false);
|
|
80
|
+
const { snackError } = useSnackMessage();
|
|
81
|
+
const modificationUuid = data.uuid;
|
|
82
|
+
const isModificationActivated = useMemo(() => {
|
|
83
|
+
if (rootNetwork.isCreating) {
|
|
84
|
+
return true;
|
|
85
|
+
}
|
|
86
|
+
const excludedSet = new Set(
|
|
87
|
+
modificationsToExclude.find((item) => item.rootNetworkUuid === rootNetwork.rootNetworkUuid)?.modificationUuidsToExclude || []
|
|
88
|
+
);
|
|
89
|
+
return !excludedSet.has(modificationUuid);
|
|
90
|
+
}, [modificationUuid, modificationsToExclude, rootNetwork.rootNetworkUuid, rootNetwork.isCreating]);
|
|
91
|
+
const handleModificationActivationByRootNetwork = useCallback(() => {
|
|
92
|
+
if (!studyUuid || !currentNodeId) {
|
|
93
|
+
return;
|
|
94
|
+
}
|
|
95
|
+
setIsLoading(true);
|
|
96
|
+
const { nextExcluded, newStatus } = getUpdatedExcludedModifications(
|
|
97
|
+
modificationsToExclude,
|
|
98
|
+
rootNetwork.rootNetworkUuid,
|
|
99
|
+
modificationUuid
|
|
100
|
+
);
|
|
101
|
+
setModificationsToExclude(nextExcluded);
|
|
102
|
+
updateModificationStatusByRootNetwork(
|
|
103
|
+
studyUuid,
|
|
104
|
+
currentNodeId,
|
|
105
|
+
rootNetwork.rootNetworkUuid,
|
|
106
|
+
modificationUuid,
|
|
107
|
+
newStatus
|
|
108
|
+
).catch((error) => {
|
|
109
|
+
setModificationsToExclude(
|
|
110
|
+
(prev) => getUpdatedExcludedModifications(prev, rootNetwork.rootNetworkUuid, modificationUuid).nextExcluded
|
|
111
|
+
);
|
|
112
|
+
snackWithFallback(snackError, error, { headerId: "modificationActivationByRootNetworkError" });
|
|
113
|
+
}).finally(() => {
|
|
114
|
+
setIsLoading(false);
|
|
115
|
+
});
|
|
116
|
+
}, [
|
|
117
|
+
modificationUuid,
|
|
118
|
+
studyUuid,
|
|
119
|
+
currentNodeId,
|
|
120
|
+
modificationsToExclude,
|
|
121
|
+
rootNetwork.rootNetworkUuid,
|
|
122
|
+
setModificationsToExclude,
|
|
123
|
+
snackError
|
|
124
|
+
]);
|
|
125
|
+
return /* @__PURE__ */ jsx(
|
|
126
|
+
ActivableChip,
|
|
127
|
+
{
|
|
128
|
+
label: rootNetwork.tag,
|
|
129
|
+
tooltipMessage: rootNetwork.name,
|
|
130
|
+
isActivated: isModificationActivated,
|
|
131
|
+
isDisabled: isLoading || isDisabled,
|
|
132
|
+
onClick: handleModificationActivationByRootNetwork
|
|
133
|
+
}
|
|
134
|
+
);
|
|
135
|
+
}
|
|
136
|
+
export {
|
|
137
|
+
RootNetworkChipCell
|
|
138
|
+
};
|
|
@@ -18,7 +18,7 @@ function SelectCell({ row, table }) {
|
|
|
18
18
|
(event) => {
|
|
19
19
|
const rows = table.getRowModel().flatRows;
|
|
20
20
|
const currentIndex = rows.indexOf(row);
|
|
21
|
-
const anchorRowId = meta?.lastClickedRowId.current;
|
|
21
|
+
const anchorRowId = meta?.interaction.lastClickedRowId.current;
|
|
22
22
|
const anchorIndex = anchorRowId == null ? null : rows.findIndex((candidate) => candidate.id === anchorRowId);
|
|
23
23
|
const targetSelected = !isSelected;
|
|
24
24
|
if (event.shiftKey && anchorIndex != null && anchorIndex !== -1) {
|
|
@@ -27,7 +27,7 @@ function SelectCell({ row, table }) {
|
|
|
27
27
|
row.toggleSelected(targetSelected);
|
|
28
28
|
}
|
|
29
29
|
if (meta) {
|
|
30
|
-
meta.lastClickedRowId.current = row.id;
|
|
30
|
+
meta.interaction.lastClickedRowId.current = row.id;
|
|
31
31
|
}
|
|
32
32
|
},
|
|
33
33
|
[table, row, meta, isSelected]
|
|
@@ -6,8 +6,8 @@ function SelectHeaderCell({ table }) {
|
|
|
6
6
|
const { meta } = table.options;
|
|
7
7
|
if (meta) {
|
|
8
8
|
const nextSelectedRows = table.getIsAllRowsSelected() ? [] : table.getCoreRowModel().rows.map((r) => r.original);
|
|
9
|
-
meta.onRowSelected?.(nextSelectedRows);
|
|
10
|
-
meta.lastClickedRowId.current = null;
|
|
9
|
+
meta.interaction.onRowSelected?.(nextSelectedRows);
|
|
10
|
+
meta.interaction.lastClickedRowId.current = null;
|
|
11
11
|
}
|
|
12
12
|
table.toggleAllRowsSelected();
|
|
13
13
|
}, [table]);
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { UUID } from 'node:crypto';
|
|
2
|
+
import { ComposedModificationMetadata } from '../../../utils';
|
|
3
|
+
export interface SwitchCellProps {
|
|
4
|
+
data: ComposedModificationMetadata;
|
|
5
|
+
studyUuid: UUID | null;
|
|
6
|
+
currentNodeId?: UUID;
|
|
7
|
+
isDisabled?: boolean;
|
|
8
|
+
}
|
|
9
|
+
export declare function SwitchCell(props: SwitchCellProps): import("react/jsx-runtime").JSX.Element;
|
|
@@ -0,0 +1,63 @@
|
|
|
1
|
+
import { jsx } from "react/jsx-runtime";
|
|
2
|
+
import { useState, useEffect, useCallback } from "react";
|
|
3
|
+
import { Tooltip, Switch } from "@mui/material";
|
|
4
|
+
import { FormattedMessage } from "react-intl";
|
|
5
|
+
import "../../../utils/conversionUtils.js";
|
|
6
|
+
import { snackWithFallback } from "../../../utils/error.js";
|
|
7
|
+
import "../../../utils/types/equipmentType.js";
|
|
8
|
+
import "@mui/icons-material";
|
|
9
|
+
import "../../../utils/yupConfig.js";
|
|
10
|
+
import { setModificationMetadata } from "../../../services/networkModification.js";
|
|
11
|
+
import "localized-countries";
|
|
12
|
+
import "localized-countries/data/fr";
|
|
13
|
+
import "localized-countries/data/en";
|
|
14
|
+
import { useSnackMessage } from "../../../hooks/useSnackMessage.js";
|
|
15
|
+
function SwitchCell(props) {
|
|
16
|
+
const { data, studyUuid, currentNodeId, isDisabled = false } = props;
|
|
17
|
+
const [isLoading, setIsLoading] = useState(false);
|
|
18
|
+
const { snackError } = useSnackMessage();
|
|
19
|
+
const modificationUuid = data.uuid;
|
|
20
|
+
const [modificationActivated, setModificationActivated] = useState(data.activated);
|
|
21
|
+
useEffect(() => {
|
|
22
|
+
setModificationActivated(data.activated);
|
|
23
|
+
}, [data.activated]);
|
|
24
|
+
const toggleModificationActive = useCallback(
|
|
25
|
+
(_event, checked) => {
|
|
26
|
+
if (!modificationUuid) {
|
|
27
|
+
return;
|
|
28
|
+
}
|
|
29
|
+
setIsLoading(true);
|
|
30
|
+
setModificationActivated(checked);
|
|
31
|
+
setModificationMetadata(studyUuid, currentNodeId, modificationUuid, {
|
|
32
|
+
activated: checked,
|
|
33
|
+
type: data.type
|
|
34
|
+
}).catch((error) => {
|
|
35
|
+
setModificationActivated(data.activated);
|
|
36
|
+
snackWithFallback(snackError, error, { headerId: "networkModificationActivationError" });
|
|
37
|
+
}).finally(() => {
|
|
38
|
+
setIsLoading(false);
|
|
39
|
+
});
|
|
40
|
+
},
|
|
41
|
+
[modificationUuid, studyUuid, currentNodeId, data.type, data.activated, snackError]
|
|
42
|
+
);
|
|
43
|
+
return /* @__PURE__ */ jsx(
|
|
44
|
+
Tooltip,
|
|
45
|
+
{
|
|
46
|
+
title: /* @__PURE__ */ jsx(FormattedMessage, { id: modificationActivated ? "deactivateModification" : "activateModification" }),
|
|
47
|
+
arrow: true,
|
|
48
|
+
enterDelay: 250,
|
|
49
|
+
children: /* @__PURE__ */ jsx("span", { children: /* @__PURE__ */ jsx(
|
|
50
|
+
Switch,
|
|
51
|
+
{
|
|
52
|
+
size: "small",
|
|
53
|
+
disabled: isLoading || isDisabled,
|
|
54
|
+
checked: modificationActivated,
|
|
55
|
+
onChange: toggleModificationActive
|
|
56
|
+
}
|
|
57
|
+
) })
|
|
58
|
+
}
|
|
59
|
+
);
|
|
60
|
+
}
|
|
61
|
+
export {
|
|
62
|
+
SwitchCell
|
|
63
|
+
};
|
package/dist/index.js
CHANGED
|
@@ -243,7 +243,7 @@ import { MAX_CHAR_DESCRIPTION } from "./utils/constants/uiConstants.js";
|
|
|
243
243
|
import { AMPERE, DEGREE, KILO_AMPERE, KILO_METER, KILO_VOLT, MEGA_VAR, MEGA_VOLT_AMPERE, MEGA_WATT, MICRO_SIEMENS, OHM, PERCENTAGE, SIEMENS } from "./utils/constants/unitsConstants.js";
|
|
244
244
|
import { COMMON_APP_NAME, COMMON_CONFIG_PARAMS_NAMES, LAST_SELECTED_DIRECTORY, PARAM_DEVELOPER_MODE, PARAM_LANGUAGE, PARAM_THEME } from "./utils/constants/configConstants.js";
|
|
245
245
|
import { FILTERS, FILTER_ID, FILTER_NAME, ID } from "./utils/constants/filterConstant.js";
|
|
246
|
-
import { DUPLICATED_PROPS_ERROR, YUP_NOT_TYPE_NUMBER, YUP_REQUIRED } from "./utils/constants/translationKeys.js";
|
|
246
|
+
import { DUPLICATED_PROPS_ERROR, YUP_NOT_TYPE_DEFAULT, YUP_NOT_TYPE_NUMBER, YUP_REQUIRED } from "./utils/constants/translationKeys.js";
|
|
247
247
|
import { GRIDSUITE_DEFAULT_PRECISION, convertInputValue, convertOutputValue, isBlankOrEmpty, kiloUnitToUnit, microUnitToUnit, roundToDefaultPrecision, roundToPrecision, toModificationOperation, unitToKiloUnit, unitToMicroUnit } from "./utils/conversionUtils.js";
|
|
248
248
|
import { catchErrorHandler, extractErrorMessageDescriptor, snackWithFallback } from "./utils/error.js";
|
|
249
249
|
import { areArrayElementsUnique, arraysContainIdenticalStrings, isEmpty, isObjectEmpty, keyGenerator } from "./utils/functions.js";
|
|
@@ -259,7 +259,7 @@ import { ProblemDetailError } from "./utils/types/ProblemDetailError.js";
|
|
|
259
259
|
import { NetworkTimeoutError } from "./utils/types/NetworkTimeoutError.js";
|
|
260
260
|
import { ElementType } from "./utils/types/elementType.js";
|
|
261
261
|
import { ALL_EQUIPMENTS, BASE_EQUIPMENTS, CONNECTION_DIRECTIONS, EQUIPMENTS_WITH_ONE_NOMINAL_VOLTAGE, EQUIPMENTS_WITH_ONE_SUBSTATION, EQUIPMENTS_WITH_THREE_NOMINAL_VOLTAGES, EQUIPMENTS_WITH_TWO_NOMINAL_VOLTAGES, EQUIPMENTS_WITH_TWO_SUBSTATIONS, EquipmentType, ExtendedEquipmentType, HvdcType, LOAD_TYPES, OperatingStatus, SEARCH_EQUIPMENTS, TYPE_TAG_MAX_SIZE, UNDEFINED_CONNECTION_DIRECTION, UNDEFINED_LOAD_TYPE, VL_TAG_MAX_SIZE, equipmentStyles, getConnectionDirectionLabel, getEquipmentsInfosForSearchBar, getLoadTypeLabel } from "./utils/types/equipmentType.js";
|
|
262
|
-
import { Battery, BoundaryLine, BusBar, Generator, Hvdc, LCC, Line, Load, SVC, ShuntCompensator, Substation, ThreeWindingTransfo, TwoWindingTransfo, VSC, VoltageLevel } from "./utils/types/equipmentTypes.js";
|
|
262
|
+
import { Battery, BoundaryLine, BusBar, Generator, Hvdc, LCC, Line, Load, SVC, ShuntCompensator, Substation, ThreeWindingTransfo, TwoWindingTransfo, VSC, VoltageLevel, isInjection } from "./utils/types/equipmentTypes.js";
|
|
263
263
|
import { AnnouncementSeverity, ArrayAction } from "./utils/types/types.js";
|
|
264
264
|
import { MODIFICATION_TYPES, ModificationType } from "./utils/types/modificationType.js";
|
|
265
265
|
import { FieldType } from "./utils/types/fieldType.js";
|
|
@@ -287,7 +287,7 @@ import { fetchCurrentAnnouncement, fetchUserDetails } from "./services/userAdmin
|
|
|
287
287
|
import { DEFAULT_TIMEOUT_MS, IGNORE_SIGNAL, backendFetch, backendFetchFile, backendFetchJson, backendFetchText, getRequestParamFromList, handleNotOkResponse, parseError, safeEncodeURIComponent } from "./services/utils.js";
|
|
288
288
|
import { getVoltageInitParameters, getVoltageInitUrl } from "./services/voltage-init.js";
|
|
289
289
|
import { fetchShortCircuitParameters, getShortCircuitSpecificParametersDescription, updateShortCircuitParameters } from "./services/short-circuit-analysis.js";
|
|
290
|
-
import { changeCompositeSubModificationOrder, changeNetworkModificationOrder, fetchBusBarSectionsForNewCoupler, fetchNetworkModification, getBaseNetworkModificationUrl, getNetworkModificationsFromComposite, getStudyUrlWithNodeUuid, updateModification } from "./services/networkModification.js";
|
|
290
|
+
import { changeCompositeSubModificationOrder, changeNetworkModificationOrder, fetchBusBarSectionsForNewCoupler, fetchNetworkModification, getBaseNetworkModificationUrl, getNetworkModificationsFromComposite, getStudyUrlWithNodeUuid, setModificationMetadata, updateModification, updateModificationStatusByRootNetwork, updateNetworkModificationsMetadata } from "./services/networkModification.js";
|
|
291
291
|
import { fetchDynamicSimulationModels, getDynamicMappings } from "./services/dynamic-mapping.js";
|
|
292
292
|
import { fetchDynamicSimulationParameters, fetchDynamicSimulationProviders, updateDynamicSimulationParameters } from "./services/dynamic-simulation.js";
|
|
293
293
|
import { fetchContingencyAndFiltersLists, fetchDynamicSecurityAnalysisProviders } from "./services/dynamic-security-analysis.js";
|
|
@@ -324,12 +324,16 @@ import { COLUMNS_WITHOUT_BORDER, DEPTH_CELL_WIDTH, DROP_FORBIDDEN_INDICATOR_BOTT
|
|
|
324
324
|
import { AUTO_EXTENSIBLE_COLUMNS, BASE_MODIFICATION_TABLE_COLUMNS, computeTagMinSize } from "./components/network-modification-table/columns-definition.js";
|
|
325
325
|
import { NetworkModificationsTable } from "./components/network-modification-table/network-modifications-table.js";
|
|
326
326
|
import { useModificationsDragAndDrop } from "./components/network-modification-table/use-modifications-drag-and-drop.js";
|
|
327
|
+
import { DescriptionCellRenderer, DragHandleRenderer, NameCellRenderer, NameHeaderRenderer, RootNetworkCellRenderer, RootNetworkHeaderRenderer, SelectCellRenderer, SelectHeaderRenderer, SwitchCellRenderer } from "./components/network-modification-table/renderers/cell-renderers.js";
|
|
327
328
|
import { DepthBox } from "./components/network-modification-table/renderers/depth-box.js";
|
|
329
|
+
import { DescriptionCell } from "./components/network-modification-table/renderers/description-cell.js";
|
|
328
330
|
import { DragHandleCell } from "./components/network-modification-table/renderers/drag-handle-cell.js";
|
|
329
331
|
import { NameCell } from "./components/network-modification-table/renderers/name-cell.js";
|
|
330
332
|
import { NetworkModificationEditorNameHeader } from "./components/network-modification-table/renderers/network-modification-node-editor-name-header.js";
|
|
333
|
+
import { RootNetworkChipCell } from "./components/network-modification-table/renderers/root-network-chip-cell.js";
|
|
331
334
|
import { SelectCell } from "./components/network-modification-table/renderers/select-cell.js";
|
|
332
335
|
import { SelectHeaderCell } from "./components/network-modification-table/renderers/select-header-cell.js";
|
|
336
|
+
import { SwitchCell } from "./components/network-modification-table/renderers/switch-cell.js";
|
|
333
337
|
import { DragCloneRow } from "./components/network-modification-table/row/drag-row-clone.js";
|
|
334
338
|
import { ModificationRow } from "./components/network-modification-table/row/modification-row.js";
|
|
335
339
|
import { MAX_COMPOSITE_NESTING_DEPTH, fetchSubModificationsForExpandedRows, findAllLoadedCompositeModifications, findModificationInTree, formatToComposedModification, isCompositeModification, mergeSubModificationsIntoTree, moveSubModificationInTree, updateModificationFieldInTree, updateSubModificationsOfACompositeInTree } from "./components/network-modification-table/utils.js";
|
|
@@ -536,6 +540,8 @@ export {
|
|
|
536
540
|
DataType,
|
|
537
541
|
DefaultCellRenderer,
|
|
538
542
|
DepthBox,
|
|
543
|
+
DescriptionCell,
|
|
544
|
+
DescriptionCellRenderer,
|
|
539
545
|
DescriptionField,
|
|
540
546
|
DescriptionInput,
|
|
541
547
|
DescriptionModificationDialog,
|
|
@@ -550,6 +556,7 @@ export {
|
|
|
550
556
|
DndTableBottomRightButtons,
|
|
551
557
|
DragCloneRow,
|
|
552
558
|
DragHandleCell,
|
|
559
|
+
DragHandleRenderer,
|
|
553
560
|
DynamicMarginCalculationInline,
|
|
554
561
|
DynamicSecurityAnalysisInline,
|
|
555
562
|
DynamicSimulationInline,
|
|
@@ -714,6 +721,8 @@ export {
|
|
|
714
721
|
NO_ITEM_SELECTION_FOR_COPY,
|
|
715
722
|
NadPositionsGenerationMode,
|
|
716
723
|
NameCell,
|
|
724
|
+
NameCellRenderer,
|
|
725
|
+
NameHeaderRenderer,
|
|
717
726
|
NetworkModificationEditorNameHeader,
|
|
718
727
|
NetworkModificationNameCellRenderer,
|
|
719
728
|
NetworkModificationsTable,
|
|
@@ -810,6 +819,9 @@ export {
|
|
|
810
819
|
ReadOnlyInput,
|
|
811
820
|
RemoveButton,
|
|
812
821
|
ResizeHandle,
|
|
822
|
+
RootNetworkCellRenderer,
|
|
823
|
+
RootNetworkChipCell,
|
|
824
|
+
RootNetworkHeaderRenderer,
|
|
813
825
|
RuleValueEditor,
|
|
814
826
|
SCENARIO_DURATION,
|
|
815
827
|
SEARCH_EQUIPMENTS,
|
|
@@ -849,8 +861,10 @@ export {
|
|
|
849
861
|
SecurityAnalysisParametersDialog,
|
|
850
862
|
SecurityAnalysisParametersInline,
|
|
851
863
|
SelectCell,
|
|
864
|
+
SelectCellRenderer,
|
|
852
865
|
SelectClearable,
|
|
853
866
|
SelectHeaderCell,
|
|
867
|
+
SelectHeaderRenderer,
|
|
854
868
|
SelectInput,
|
|
855
869
|
SelectWithConfirmationInput,
|
|
856
870
|
SensiBranchesTabValues,
|
|
@@ -877,6 +891,8 @@ export {
|
|
|
877
891
|
SubstationLayout,
|
|
878
892
|
SubstationModificationForm,
|
|
879
893
|
SusceptanceAdornment,
|
|
894
|
+
SwitchCell,
|
|
895
|
+
SwitchCellRenderer,
|
|
880
896
|
SwitchInput,
|
|
881
897
|
SwitchKind,
|
|
882
898
|
SwitchWithLabel,
|
|
@@ -931,6 +947,7 @@ export {
|
|
|
931
947
|
VoltageLevelCreationForm,
|
|
932
948
|
VoltageLevelModificationForm,
|
|
933
949
|
WRITE_SLACK_BUS,
|
|
950
|
+
YUP_NOT_TYPE_DEFAULT,
|
|
934
951
|
YUP_NOT_TYPE_NUMBER,
|
|
935
952
|
YUP_REQUIRED,
|
|
936
953
|
alertThresholdMarks,
|
|
@@ -1204,6 +1221,7 @@ export {
|
|
|
1204
1221
|
isExploreMetadata,
|
|
1205
1222
|
isFieldRequired,
|
|
1206
1223
|
isFloatNumber,
|
|
1224
|
+
isInjection,
|
|
1207
1225
|
isIntegerNumber,
|
|
1208
1226
|
isObjectEmpty,
|
|
1209
1227
|
isStudyMetadata,
|
|
@@ -1269,6 +1287,7 @@ export {
|
|
|
1269
1287
|
setLoadFlowParameters,
|
|
1270
1288
|
setLoggedUser,
|
|
1271
1289
|
setLogoutError,
|
|
1290
|
+
setModificationMetadata,
|
|
1272
1291
|
setSecurityAnalysisParameters,
|
|
1273
1292
|
setSelectedReactiveLimits,
|
|
1274
1293
|
setSensitivityAnalysisParameters,
|
|
@@ -1319,6 +1338,8 @@ export {
|
|
|
1319
1338
|
updateDynamicSimulationParameters,
|
|
1320
1339
|
updateModification,
|
|
1321
1340
|
updateModificationFieldInTree,
|
|
1341
|
+
updateModificationStatusByRootNetwork,
|
|
1342
|
+
updateNetworkModificationsMetadata,
|
|
1322
1343
|
updateParameter,
|
|
1323
1344
|
updatePccMinParameters,
|
|
1324
1345
|
updateSecurityAnalysisParameters,
|
package/dist/services/index.js
CHANGED
|
@@ -12,7 +12,7 @@ import { fetchCurrentAnnouncement, fetchUserDetails } from "./userAdmin.js";
|
|
|
12
12
|
import { DEFAULT_TIMEOUT_MS, IGNORE_SIGNAL, backendFetch, backendFetchFile, backendFetchJson, backendFetchText, getRequestParamFromList, handleNotOkResponse, parseError, safeEncodeURIComponent } from "./utils.js";
|
|
13
13
|
import { getVoltageInitParameters, getVoltageInitUrl } from "./voltage-init.js";
|
|
14
14
|
import { fetchShortCircuitParameters, getShortCircuitSpecificParametersDescription, updateShortCircuitParameters } from "./short-circuit-analysis.js";
|
|
15
|
-
import { changeCompositeSubModificationOrder, changeNetworkModificationOrder, fetchBusBarSectionsForNewCoupler, fetchNetworkModification, getBaseNetworkModificationUrl, getNetworkModificationsFromComposite, getStudyUrlWithNodeUuid, updateModification } from "./networkModification.js";
|
|
15
|
+
import { changeCompositeSubModificationOrder, changeNetworkModificationOrder, fetchBusBarSectionsForNewCoupler, fetchNetworkModification, getBaseNetworkModificationUrl, getNetworkModificationsFromComposite, getStudyUrlWithNodeUuid, setModificationMetadata, updateModification, updateModificationStatusByRootNetwork, updateNetworkModificationsMetadata } from "./networkModification.js";
|
|
16
16
|
import { fetchDynamicSimulationModels, getDynamicMappings } from "./dynamic-mapping.js";
|
|
17
17
|
import { fetchDynamicSimulationParameters, fetchDynamicSimulationProviders, updateDynamicSimulationParameters } from "./dynamic-simulation.js";
|
|
18
18
|
import { fetchContingencyAndFiltersLists, fetchDynamicSecurityAnalysisProviders } from "./dynamic-security-analysis.js";
|
|
@@ -96,6 +96,7 @@ export {
|
|
|
96
96
|
safeEncodeURIComponent,
|
|
97
97
|
saveFilter,
|
|
98
98
|
setLoadFlowParameters,
|
|
99
|
+
setModificationMetadata,
|
|
99
100
|
setSecurityAnalysisParameters,
|
|
100
101
|
setSensitivityAnalysisParameters,
|
|
101
102
|
setStudyNetworkVisualizationParameters,
|
|
@@ -103,6 +104,8 @@ export {
|
|
|
103
104
|
updateDynamicMarginCalculationParameters,
|
|
104
105
|
updateDynamicSimulationParameters,
|
|
105
106
|
updateModification,
|
|
107
|
+
updateModificationStatusByRootNetwork,
|
|
108
|
+
updateNetworkModificationsMetadata,
|
|
106
109
|
updateParameter,
|
|
107
110
|
updatePccMinParameters,
|
|
108
111
|
updateSecurityAnalysisParameters,
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { UUID } from 'node:crypto';
|
|
2
|
-
import { NetworkModificationMetadata } from '../utils';
|
|
2
|
+
import { ComposedModificationMetadata, NetworkModificationMetadata } from '../utils';
|
|
3
3
|
export declare const getBaseNetworkModificationUrl: () => string;
|
|
4
4
|
export declare const getStudyUrlWithNodeUuid: (studyUuid: string | null | undefined, nodeUuid: string | undefined) => string;
|
|
5
5
|
export declare function fetchNetworkModification(modificationUuid: UUID): Promise<Response>;
|
|
@@ -8,6 +8,11 @@ export declare function updateModification({ modificationUuid, body }: {
|
|
|
8
8
|
modificationUuid: UUID;
|
|
9
9
|
body: string;
|
|
10
10
|
}): Promise<string>;
|
|
11
|
+
/**
|
|
12
|
+
* Update only the metadata (e.g. the name) of network modifications, directly on the network-modification-server.
|
|
13
|
+
* Fields left out of `metadata` are not modified.
|
|
14
|
+
*/
|
|
15
|
+
export declare function updateNetworkModificationsMetadata(modificationUuids: UUID[], metadata: Partial<ComposedModificationMetadata>): Promise<Response>;
|
|
11
16
|
export declare function getNetworkModificationsFromComposite(compositeModificationUuids: string[], onlyMetadata?: boolean): Promise<Record<UUID, NetworkModificationMetadata[]>>;
|
|
12
17
|
/**
|
|
13
18
|
* Move a composite sub-modification within or between composites, or between a composite and the group root.
|
|
@@ -26,3 +31,5 @@ export declare function getNetworkModificationsFromComposite(compositeModificati
|
|
|
26
31
|
*/
|
|
27
32
|
export declare function changeCompositeSubModificationOrder(studyUuid: UUID | null, nodeUuid: UUID | undefined, modificationUuid: UUID, sourceCompositeUuid: UUID | null, targetCompositeUuid: UUID | null, beforeUuid: UUID | null): Promise<Response>;
|
|
28
33
|
export declare function changeNetworkModificationOrder(studyUuid: UUID | null, nodeUuid: UUID | undefined, itemUuid: UUID, beforeUuid: UUID | null): Promise<Response>;
|
|
34
|
+
export declare function setModificationMetadata(studyUuid: UUID | null, nodeUuid: UUID | undefined, modificationUuid: UUID | undefined, metadata: Partial<NetworkModificationMetadata | ComposedModificationMetadata>): Promise<Response>;
|
|
35
|
+
export declare function updateModificationStatusByRootNetwork(studyUuid: UUID, nodeUuid: UUID, rootNetworkUuid: UUID, modificationUuid: UUID, activated: boolean): Promise<Response>;
|
|
@@ -36,6 +36,20 @@ function updateModification({ modificationUuid, body }) {
|
|
|
36
36
|
body
|
|
37
37
|
});
|
|
38
38
|
}
|
|
39
|
+
function updateNetworkModificationsMetadata(modificationUuids, metadata) {
|
|
40
|
+
const urlSearchParams = new URLSearchParams();
|
|
41
|
+
modificationUuids.forEach((uuid) => urlSearchParams.append("uuids", uuid));
|
|
42
|
+
const url = `${getUrl()}?${urlSearchParams.toString()}`;
|
|
43
|
+
console.debug(url);
|
|
44
|
+
return backendFetch(url, {
|
|
45
|
+
method: "PUT",
|
|
46
|
+
headers: {
|
|
47
|
+
Accept: "application/json",
|
|
48
|
+
"Content-Type": "application/json"
|
|
49
|
+
},
|
|
50
|
+
body: JSON.stringify(metadata)
|
|
51
|
+
});
|
|
52
|
+
}
|
|
39
53
|
function getNetworkModificationsFromComposite(compositeModificationUuids, onlyMetadata = true) {
|
|
40
54
|
const urlSearchParams = new URLSearchParams();
|
|
41
55
|
compositeModificationUuids.forEach((uuid) => urlSearchParams.append("uuids", uuid));
|
|
@@ -62,6 +76,33 @@ function changeNetworkModificationOrder(studyUuid, nodeUuid, itemUuid, beforeUui
|
|
|
62
76
|
console.debug(url);
|
|
63
77
|
return backendFetch(url, { method: "put" });
|
|
64
78
|
}
|
|
79
|
+
const getStudyUrlWithNodeUuidAndRootNetworkUuid = (studyUuid, nodeUuid, rootNetworkUuid) => `${PREFIX_STUDY_QUERIES}/v1/studies/${safeEncodeURIComponent(studyUuid)}/root-networks/${safeEncodeURIComponent(
|
|
80
|
+
rootNetworkUuid
|
|
81
|
+
)}/nodes/${safeEncodeURIComponent(nodeUuid)}`;
|
|
82
|
+
function setModificationMetadata(studyUuid, nodeUuid, modificationUuid, metadata) {
|
|
83
|
+
if (!modificationUuid) {
|
|
84
|
+
return Promise.reject(new Error("modificationUuid is required"));
|
|
85
|
+
}
|
|
86
|
+
const urlSearchParams = new URLSearchParams();
|
|
87
|
+
urlSearchParams.append("uuids", String([modificationUuid]));
|
|
88
|
+
const url = `${getStudyUrlWithNodeUuid(studyUuid, nodeUuid)}/network-modifications?${urlSearchParams.toString()}`;
|
|
89
|
+
return backendFetch(url, {
|
|
90
|
+
method: "PUT",
|
|
91
|
+
headers: {
|
|
92
|
+
Accept: "application/json",
|
|
93
|
+
"Content-Type": "application/json"
|
|
94
|
+
},
|
|
95
|
+
body: JSON.stringify(metadata)
|
|
96
|
+
});
|
|
97
|
+
}
|
|
98
|
+
function updateModificationStatusByRootNetwork(studyUuid, nodeUuid, rootNetworkUuid, modificationUuid, activated) {
|
|
99
|
+
const urlSearchParams = new URLSearchParams();
|
|
100
|
+
urlSearchParams.append("activated", String(activated));
|
|
101
|
+
urlSearchParams.append("uuids", String([modificationUuid]));
|
|
102
|
+
const url = `${getStudyUrlWithNodeUuidAndRootNetworkUuid(studyUuid, nodeUuid, rootNetworkUuid)}/network-modifications?${urlSearchParams.toString()}`;
|
|
103
|
+
console.debug(url);
|
|
104
|
+
return backendFetch(url, { method: "PUT" });
|
|
105
|
+
}
|
|
65
106
|
export {
|
|
66
107
|
changeCompositeSubModificationOrder,
|
|
67
108
|
changeNetworkModificationOrder,
|
|
@@ -70,5 +111,8 @@ export {
|
|
|
70
111
|
getBaseNetworkModificationUrl,
|
|
71
112
|
getNetworkModificationsFromComposite,
|
|
72
113
|
getStudyUrlWithNodeUuid,
|
|
73
|
-
|
|
114
|
+
setModificationMetadata,
|
|
115
|
+
updateModification,
|
|
116
|
+
updateModificationStatusByRootNetwork,
|
|
117
|
+
updateNetworkModificationsMetadata
|
|
74
118
|
};
|
|
@@ -32,7 +32,6 @@ const filterEn = {
|
|
|
32
32
|
AddFreePropCrit: "Add a filtering by property",
|
|
33
33
|
FreeProps: "Equipment properties",
|
|
34
34
|
SubstationFreeProps: "Equipment substation properties",
|
|
35
|
-
YupRequired: "This field is required",
|
|
36
35
|
filterPropertiesNameUniquenessError: "It is not possible to add multiple filters for the same property",
|
|
37
36
|
emptyFilterError: "Filter should contain at least one equipment",
|
|
38
37
|
distributionKeyWithMissingIdError: "Missing ID with defined distribution key",
|
|
@@ -185,8 +185,6 @@ export declare const filterExpertEn: {
|
|
|
185
185
|
greaterOrEqual: string;
|
|
186
186
|
lessThan: string;
|
|
187
187
|
lessOrEqual: string;
|
|
188
|
-
YupNotTypeNumber: string;
|
|
189
|
-
YupNotTypeDefault: string;
|
|
190
188
|
changeOperatorMessage: string;
|
|
191
189
|
lowShortCircuitCurrentLimit: string;
|
|
192
190
|
highShortCircuitCurrentLimit: string;
|
|
@@ -179,8 +179,6 @@ const filterExpertEn = {
|
|
|
179
179
|
greaterOrEqual: ">=",
|
|
180
180
|
lessThan: "<",
|
|
181
181
|
lessOrEqual: "<=",
|
|
182
|
-
YupNotTypeNumber: "This field only accepts numeric values",
|
|
183
|
-
YupNotTypeDefault: "Field value format is incorrect",
|
|
184
182
|
changeOperatorMessage: "The operator will be changed and will be applied to all the criteria already created in the group.",
|
|
185
183
|
lowShortCircuitCurrentLimit: "Low short-circuit current limit",
|
|
186
184
|
highShortCircuitCurrentLimit: "High short-circuit current limit",
|