mirror of
https://github.com/infiniflow/ragflow.git
synced 2025-12-08 20:42:30 +08:00
Fix: The nodes on the canvas were not updated in time after the operator name was modified. #10866 (#10911)
### What problem does this PR solve? Fix: The nodes on the canvas were not updated in time after the operator name was modified. #10866 ### Type of change - [x] Bug Fix (non-breaking change which fixes an issue)
This commit is contained in:
@ -476,14 +476,13 @@ const useGraphStore = create<RFState>()(
|
||||
},
|
||||
updateNodeName: (id, name) => {
|
||||
if (id) {
|
||||
set({
|
||||
nodes: get().nodes.map((node) => {
|
||||
set((state) => {
|
||||
for (const node of state.nodes) {
|
||||
if (node.id === id) {
|
||||
node.data.name = name;
|
||||
break;
|
||||
}
|
||||
|
||||
return node;
|
||||
}),
|
||||
}
|
||||
});
|
||||
}
|
||||
},
|
||||
|
||||
Reference in New Issue
Block a user