fix(测试跟踪): 首页最近测试跳转错误

This commit is contained in:
chenjianxing 2020-11-27 13:39:22 +08:00
parent 320ca1c542
commit 8333c3f77d
4 changed files with 14 additions and 5 deletions

View File

@ -38,4 +38,5 @@ public interface ExtTestPlanTestCaseMapper {
*/ */
List<TestPlanCaseDTO> listTestCaseByProjectIds(@Param("ids") List<String> ids); List<TestPlanCaseDTO> listTestCaseByProjectIds(@Param("ids") List<String> ids);
TestPlanCaseDTO get(String testPlanTestCaseId);
} }

View File

@ -307,6 +307,16 @@
</if> </if>
</where> </where>
</select> </select>
<select id="get" resultType="io.metersphere.track.dto.TestPlanCaseDTO">
select test_case.remark, test_plan_test_case.id as id, test_plan_test_case.*,test_case.*,test_case_node.name as model, project.name as projectName
from test_plan_test_case
inner join test_case on test_plan_test_case.case_id = test_case.id
left join test_case_node on test_case_node.id=test_case.node_id
inner join project on project.id = test_case.project_id
where test_plan_test_case.id = #{testPlanTestCaseId}
</select>
<update id="updateTestCaseStates" parameterType="java.lang.String"> <update id="updateTestCaseStates" parameterType="java.lang.String">
update test_plan_test_case update test_plan_test_case
<set> <set>

View File

@ -129,10 +129,8 @@ public class TestPlanTestCaseService {
request.setExecutor(user.getId()); request.setExecutor(user.getId());
} }
public TestPlanCaseDTO get(String caseId) { public TestPlanCaseDTO get(String testplanTestCaseId) {
QueryTestPlanCaseRequest request = new QueryTestPlanCaseRequest(); return extTestPlanTestCaseMapper.get(testplanTestCaseId);
request.setId(caseId);
return extTestPlanTestCaseMapper.list(request).get(0);
} }
public void deleteTestCaseBath(TestPlanCaseBatchRequest request) { public void deleteTestCaseBath(TestPlanCaseBatchRequest request) {

View File

@ -85,7 +85,7 @@
}); });
}, },
editTestCase(row, event, column) { editTestCase(row, event, column) {
this.$router.push('/track/plan/view/edit/' + row.caseId) this.$router.push('/track/plan/view/edit/' + row.id)
} }
} }
} }