oneao
158eb3c029
refactor(module-management): 阶段一——抽取分组树推导 composable useGroupTree
- 新建 composables/useGroupTree.js:buildGroupTree/sortGroupNodesByXh/groupIdOfRow
纯函数导出 + useGroupTree(groupsRef, rowsRef) 返回 groupTree/groupNodeMap/
groupColumnsMap/bandMeta(统一含 maxLevel)/isDescendantGroup/groupIdOfRow
- ModuleTableEditPanel.vue:删除本地 7 份同体实现,改用 composable;
isDescendantOf 重命名为 isDescendantGroup(两处函数体逐字相同)
- structure-tree/ModuleStructureTree.vue:同样替换;删除「与面板 bandMeta 同源」注释
(复制关系已不成立);bandMeta 多出的 maxLevel 字段对其消费处无害
- ModuleTableEditPanel 中 watch(props.editConfig, …, { immediate: true }) 注册位置
保持不变,仍位于 bandMeta 等 computed 之后(避免 immediate 回调 TDZ)
行为不变;测试结果与基线一致(184 通过,2 个既有失败与本重构无关)
2026-08-28 14:20:58 +08:00
..
2026-07-14 22:08:10 +08:00
2026-08-28 14:14:03 +08:00
2026-08-22 17:18:27 +08:00
2026-08-27 17:32:05 +08:00
2026-08-27 23:06:36 +08:00
2026-08-27 17:32:05 +08:00
2026-08-19 17:32:25 +08:00
2026-08-19 17:32:25 +08:00
2026-08-27 17:32:05 +08:00
2026-08-21 23:06:56 +08:00
2026-08-28 14:20:58 +08:00
2026-08-19 17:32:25 +08:00
2026-08-19 17:32:25 +08:00