切换 清空检测状态 和 检测结果

This commit is contained in:
北枳 2025-08-13 23:29:14 +08:00
parent 7c16179288
commit 06840ab17a

View File

@ -56,6 +56,9 @@ export function ShotTabContent({
useEffect(() => {
console.log('shotTabContent-----shotData', shotData);
if (shotData.length > 0) {
// 清空检测状态 和 检测结果
setScanState('idle');
setDetections([]);
setSelectedSegment(shotData[selectedIndex]);
}
}, [selectedIndex, shotData]);