feat(history): 添加首页历史项目展示组件
- 新增 HistoryDatabase.vue 组件,实现扇形堆叠到网格展开的动画效果 - 后端 simulation.py 添加历史模拟数据 API 支持 - 修复 SimulationManager 过滤隐藏文件问题 - 前端 simulation.js 添加获取历史模拟数据的 API 方法 - Home.vue 集成历史项目展示组件 - 实现正方形网格背景装饰效果
This commit is contained in:
@@ -465,6 +465,11 @@ class SimulationManager:
|
||||
|
||||
if os.path.exists(self.SIMULATION_DATA_DIR):
|
||||
for sim_id in os.listdir(self.SIMULATION_DATA_DIR):
|
||||
# 跳过隐藏文件(如 .DS_Store)和非目录文件
|
||||
sim_path = os.path.join(self.SIMULATION_DATA_DIR, sim_id)
|
||||
if sim_id.startswith('.') or not os.path.isdir(sim_path):
|
||||
continue
|
||||
|
||||
state = self._load_simulation_state(sim_id)
|
||||
if state:
|
||||
if project_id is None or state.project_id == project_id:
|
||||
|
||||
Reference in New Issue
Block a user