Commit 5f675328 authored by wdy's avatar wdy

Merge branch 'wangdingyi' into 'dev'

根据章节号查询用例

See merge request !341
parents 6e08ce32 521af958
...@@ -219,6 +219,15 @@ public class TestUseCaseServiceImpl extends ServiceImpl<TestUseCaseMapper, TestU ...@@ -219,6 +219,15 @@ public class TestUseCaseServiceImpl extends ServiceImpl<TestUseCaseMapper, TestU
List<UseCaseUrlVO> list = new ArrayList<>(); List<UseCaseUrlVO> list = new ArrayList<>();
if (jsonObject.getJSONObject("data").getJSONObject("node") != null) { if (jsonObject.getJSONObject("data").getJSONObject("node") != null) {
list = jsonObject.getJSONObject("data").getJSONObject("node").getList("useCases", UseCaseUrlVO.class); list = jsonObject.getJSONObject("data").getJSONObject("node").getList("useCases", UseCaseUrlVO.class);
for (UseCaseUrlVO useCaseUrlVO : list) {
if (useCaseUrlVO.getMethod() != null) {
useCaseUrlVO.setTestMethod(useCaseUrlVO.getMethod().getName());
}
if (useCaseUrlVO.getScenario() != null) {
useCaseUrlVO.setTestScenario(useCaseUrlVO.getScenario().getName());
}
}
} }
return list; return list;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment