浏览代码

feat(firmware): clean state data

Lind 4 年之前
父节点
当前提交
1ba314f8c1
共有 1 个文件被更改,包括 4 次插入0 次删除
  1. 4 0
      src/pages/device/Firmware/Detail/History/index.tsx

+ 4 - 0
src/pages/device/Firmware/Detail/History/index.tsx

@@ -13,6 +13,10 @@ const History = () => {
     if (state.historyParams) {
       setParams({ ...state.historyParams });
     }
+    return () => {
+      state.historyParams = undefined;
+      state.taskItem = undefined;
+    };
   }, []);
   const columns: ProColumns<HistoryItem>[] = [
     {