* [bug] add fromCaseID link.

This commit is contained in:
sunguangming
2024-11-22 15:33:48 +08:00
committed by 王怡栋
parent 7357935c82
commit 605fe5b2db
2 changed files with 10 additions and 0 deletions
+5
View File
@@ -161,6 +161,11 @@ window.onRenderCell = function(result, {row, col})
{
if(data.auto == 'auto') result.unshift({html: '<span class="label gray-pale rounded-full nowrap">' + automated + '</span>'}); // 添加自动化标签
if(module) result.unshift({html: '<span class="label gray-pale rounded-full nowrap">' + module + '</span>'}); // 添加模块标签
if(row.data.fromCaseID)
{
let caseLink = $.createLink('testcase', 'view', `id=${row.data.fromCaseID}`);
result.push({html: `[<a href=${caseLink} data-app='qa'><i class='icon icon-share'></i> #${row.data.fromCaseID}</a>]`}); // 添加来源用例链接
}
}
}
if(col.name == 'pri' && row.data.isScene)
+5
View File
@@ -71,6 +71,11 @@ window.onRenderCell = function(result, {row, col})
const data = row.data;
const module = this.options.customData.modules[data.module];
if(module) result.unshift({html: '<span class="label gray-pale rounded-full">' + module + '</span>'}); // 添加模块标签
if(row.data.fromCaseID)
{
let caseLink = $.createLink('testcase', 'view', `id=${row.data.fromCaseID}`);
result.push({html: `[<a href=${caseLink} data-app='qa'><i class='icon icon-share'></i> #${row.data.fromCaseID}</a>]`}); // 添加来源用例链接
}
}
}