fix(测试跟踪): 用例列表-模块创建子模块但未输入名称,打开脑图,模块显示有误

--bug=1025944 --user=陈建星 【测试跟踪】github#24115,功能用例创建子模块不输入名称,点击脑图,该模块会展示其他模块用例 https://www.tapd.cn/55049933/s/1367979
This commit is contained in:
chenjianxing 2023-04-28 15:17:52 +08:00 committed by jianxing
parent 852fe75881
commit 5ab14b4d0a
2 changed files with 4 additions and 1 deletions

View File

@ -240,6 +240,9 @@ export default {
}
children.forEach((item) => {
if (!item.id) {
return;
}
let node = {
data: {
text: item.name,

View File

@ -68,7 +68,7 @@ export function loadNode(node, param, getCaseFuc, setParamCallback, getExtraNode
// 加载用例
getCaseFuc(request, (testCases) => {
initNodeCase(node, testCases, param, setParamCallback);
if (getExtraNodeFuc) {
if (getExtraNodeFuc && data.id) {
param.result.loading = true;
// 加载临时节点
getExtraNodeFuc(getCurrentProjectID(), data.id)