fix: 接口用例统计了回收站里的接口

修复接口用例统计了回收站里的接口的问题
This commit is contained in:
song.tianyang 2020-12-24 17:06:37 +08:00
parent 921fe7d212
commit 03172b05ec
1 changed files with 2 additions and 2 deletions

View File

@ -279,14 +279,14 @@
<select id="countProtocolByProjectID" resultType="io.metersphere.api.dto.datacount.ApiDataCountResult">
SELECT apiDef.protocol AS groupField,COUNT(testCase.id) AS countNumber FROM api_test_case testCase
INNER JOIN api_definition apiDef ON testCase.api_definition_id = apiDef.id
WHERE testCase.project_id = #{0}
WHERE testCase.project_id = #{0} AND apiDef.status != "Trash"
GROUP BY apiDef.protocol
</select>
<select id="countByProjectIDAndCreateInThisWeek" resultType="java.lang.Long">
SELECT count(testCase.id) AS countNumber FROM api_test_case testCase
INNER JOIN api_definition apiDef ON testCase.api_definition_id = apiDef.id
WHERE testCase.project_id = #{projectId}
WHERE testCase.project_id = #{projectId} AND apiDef.status != "Trash"
AND testCase.create_time BETWEEN #{firstDayTimestamp} AND #{lastDayTimestamp}
</select>