From 8176e68c1484ddabd289424c355df3b69ab08b3d Mon Sep 17 00:00:00 2001 From: Rohit Date: Sat, 1 Feb 2025 11:36:19 +0530 Subject: [PATCH] feat: set rerender true on duplicate --- src/components/robot/RobotDuplicate.tsx | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/components/robot/RobotDuplicate.tsx b/src/components/robot/RobotDuplicate.tsx index 4e0ef887..2591f95f 100644 --- a/src/components/robot/RobotDuplicate.tsx +++ b/src/components/robot/RobotDuplicate.tsx @@ -56,7 +56,7 @@ interface RobotSettingsProps { export const RobotDuplicationModal = ({ isOpen, handleStart, handleClose, initialSettings }: RobotSettingsProps) => { const { t } = useTranslation(); const [targetUrl, setTargetUrl] = useState(''); - const { recordingId, notify, robot, setRobot } = useGlobalInfoStore(); + const { recordingId, notify, robot, setRobot, setRerenderRobots } = useGlobalInfoStore(); useEffect(() => { if (isOpen) { @@ -95,6 +95,8 @@ export const RobotDuplicationModal = ({ isOpen, handleStart, handleClose, initia const success = await duplicateRecording(robot.recording_meta.id, targetUrl); if (success) { + setRerenderRobots(true); + notify('success', t('robot_duplication.notifications.duplicate_success')); handleStart(robot); handleClose();