fix(测试跟踪): 修复测试计划失败top10 的用例是跨项目的,该用例跳转链接页面是当前项目问题

--bug=1025817 --user=郭雨琦
https://www.tapd.cn/55049933/bugtrace/bugs/view/1155049933001025817
This commit is contained in:
guoyuqi 2023-05-05 18:42:17 +08:00 committed by jianxing
parent 8f743300ce
commit 0b6e43fd10
3 changed files with 19 additions and 13 deletions

View File

@ -56,13 +56,15 @@
apiScene.testPlanName AS testPlan,
apiScene.testPlanId AS testPlanId,
count(executionInfo.id) AS failureTimes,
'scenario' AS caseType
'scenario' AS caseType,
scene.project_id AS projectId
FROM scenario_execution_info executionInfo
INNER JOIN (
SELECT testPlanScenario.id, testPlanScenario.api_scenario_id, testPlan.id AS testPlanId, testPlan.`name` AS testPlanName
FROM test_plan_api_scenario testPlanScenario
INNER JOIN test_plan testPlan ON testPlan.id = testPlanScenario.test_plan_id
WHERE testPlan.project_id = #{projectId}
SELECT testPlanScenario.id, testPlanScenario.api_scenario_id, testPlan.id AS testPlanId, testPlan.`name` AS
testPlanName
FROM test_plan_api_scenario testPlanScenario
INNER JOIN test_plan testPlan ON testPlan.id = testPlanScenario.test_plan_id
WHERE testPlan.project_id = #{projectId}
) apiScene ON apiScene.id = executionInfo.source_id
INNER JOIN api_scenario scene ON scene.id = apiScene.api_scenario_id
WHERE scene.`status` != 'Trash'

View File

@ -101,13 +101,15 @@ export default {
case "scenarioWithQuery":
home = this.$router.resolve(
"/api/automation/" +
defaultVersion +
"/" +
uuid +
"/" +
dataType +
"/" +
selectType
defaultVersion +
"/" +
uuid +
"/" +
dataType +
"/" +
selectType +
"/" +
projectId
);
break;
case "api":

View File

@ -205,7 +205,9 @@ export default {
"redirectPage",
"scenarioWithQuery",
"scenario",
"edit:" + param
"edit:" + param,
projectId,
null
);
break;
case "testCase":