From 5ea544a1b1247095641cc72b4128943364b965b3 Mon Sep 17 00:00:00 2001 From: Ahmed yasser <26207361+1AhmedYasser@users.noreply.github.com> Date: Thu, 21 Aug 2025 15:34:25 +0300 Subject: [PATCH 1/3] chore(10): Fixed nok dsl open api spec (#695) --- DSL/Ruuter/services/GET/services/services-detailed/nok.yml | 3 +++ 1 file changed, 3 insertions(+) diff --git a/DSL/Ruuter/services/GET/services/services-detailed/nok.yml b/DSL/Ruuter/services/GET/services/services-detailed/nok.yml index 4a2d2a713..5fea87121 100644 --- a/DSL/Ruuter/services/GET/services/services-detailed/nok.yml +++ b/DSL/Ruuter/services/GET/services/services-detailed/nok.yml @@ -17,6 +17,9 @@ declaration: - field: sorting type: string description: "Parameter 'sorting'" + - field: order + type: string + description: "Parameter 'order'" getFaults: call: http.post From acd6494a8cd1a50d356174c19a0436e1b903c12c Mon Sep 17 00:00:00 2001 From: Ahmed yasser <26207361+1AhmedYasser@users.noreply.github.com> Date: Fri, 22 Aug 2025 12:18:27 +0300 Subject: [PATCH 2/3] fix(697): Fixed Assign Variables keys/values on drag (#698) --- GUI/src/components/FlowElementsPopup/PreviousVariables.tsx | 5 ++++- GUI/src/components/OutputElementBox/index.tsx | 6 +++++- 2 files changed, 9 insertions(+), 2 deletions(-) diff --git a/GUI/src/components/FlowElementsPopup/PreviousVariables.tsx b/GUI/src/components/FlowElementsPopup/PreviousVariables.tsx index b0d553ae2..be1f786a7 100644 --- a/GUI/src/components/FlowElementsPopup/PreviousVariables.tsx +++ b/GUI/src/components/FlowElementsPopup/PreviousVariables.tsx @@ -129,6 +129,7 @@ const PreviousVariables: FC = ({ nodeId }) => { setAssignedObjectTree={setAssignedObjectTree} popupBodyCss={popupBodyCss} border={border} + isAssignSection={true} /> )} @@ -235,6 +236,7 @@ const VariableSection = ({ setAssignedObjectTree, popupBodyCss, border, + isAssignSection = false, }: any) => { const { t } = useTranslation(); @@ -280,7 +282,7 @@ const VariableSection = ({ : { data: variable.data, path: variable.value, - }, + } ); }} > @@ -298,6 +300,7 @@ const VariableSection = ({ dragData={variable.key ? variable : undefined} style={{ cursor: variable.key ? "grab" : "default" }} borderColor={typeColor.color} + isAssignElement={isAssignSection ? !predefinedInputKeys.includes(variable.id) : false} > {name} diff --git a/GUI/src/components/OutputElementBox/index.tsx b/GUI/src/components/OutputElementBox/index.tsx index 8448bd2bd..a50286ac5 100644 --- a/GUI/src/components/OutputElementBox/index.tsx +++ b/GUI/src/components/OutputElementBox/index.tsx @@ -11,6 +11,7 @@ type OutputElementBoxProps = { readonly onClick?: () => void; readonly style?: CSSProperties; readonly className?: string; + readonly isAssignElement?: boolean; }; const OutputElementBox: FC = ({ @@ -20,6 +21,7 @@ const OutputElementBox: FC = ({ style, className, children, + isAssignElement = false, }) => { const node = useServiceStore((state) => state.selectedNode); const mergedStyle: CSSProperties = { @@ -36,12 +38,14 @@ const OutputElementBox: FC = ({ const handleDragStart = (event: DragEvent) => { if (!dragData) return; + const dragValue = isAssignElement ? `\${${dragData.key}}` : dragData.value; + event.dataTransfer.setData( ASSIGN_DRAG_TYPE, // Need to check for StepType.Assign here since ReactQuill does not support custom onDrop events node?.data.stepType === StepType.Assign || node?.data.stepType === StepType.DynamicChoices ? JSON.stringify(dragData) - : dragData.value + : dragValue ); }; From ad364b77d877472478e4bbdbce549ede35b423b1 Mon Sep 17 00:00:00 2001 From: Ahmed yasser <26207361+1AhmedYasser@users.noreply.github.com> Date: Fri, 22 Aug 2025 12:19:56 +0300 Subject: [PATCH 3/3] fix(692): Enhanced useLayout to address edge case (#696) --- GUI/src/hooks/flow/useLayout.ts | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/GUI/src/hooks/flow/useLayout.ts b/GUI/src/hooks/flow/useLayout.ts index 141c773c6..2782f7401 100644 --- a/GUI/src/hooks/flow/useLayout.ts +++ b/GUI/src/hooks/flow/useLayout.ts @@ -2,6 +2,7 @@ import { useCallback, useEffect, useRef } from "react"; import { useReactFlow, useStore, Node, Edge, ReactFlowState } from "@xyflow/react"; import { stratify, tree } from "d3-hierarchy"; import { timer } from "d3-timer"; +import { StepType } from "types"; const layout = tree() .nodeSize([400, 180]) @@ -67,17 +68,22 @@ function layoutNodes(nodes: Node[], edges: Edge[]): Node[] { for (const node of multiParentNodes) { const parentEdges = edgesCopy.filter((e) => e.target === node.id); const parentNodes = resultNodes.filter((n) => parentEdges.some((e) => e.source === n.id)); + const isParentNodesContainMultiPathNode = parentNodes.some( + (n) => n.data.stepType === StepType.MultiChoiceQuestion || n.data.stepType === StepType.Condition + ); if (parentNodes.length > 0) { const avgX = parentNodes.reduce((sum, parent) => sum + parent.position.x, 0) / parentNodes.length; const maxParentY = Math.max(...parentNodes.map((p) => p.position.y)); const newY = maxParentY + 180; + const multipathNewY = maxParentY + 300; + console.log(isParentNodesContainMultiPathNode); resultNodes.push({ ...node, position: { x: avgX, - y: newY, + y: isParentNodesContainMultiPathNode ? multipathNewY : newY, }, }); } else {