fix(场景自动化): 高级搜索问题

--bug=1006717 --user=lyh 【测试跟踪】测试用例关联接口的高级搜索,根据创建人搜索没生效
https://www.tapd.cn/55049933/s/1084002
This commit is contained in:
shiziyuan9527 2021-12-21 10:56:29 +08:00 committed by 刘瑞斌
parent 20ea661962
commit c71abc5c4d
4 changed files with 11 additions and 3 deletions

View File

@ -30,4 +30,5 @@ public class ApiScenarioDTO extends ApiScenarioWithBLOBs {
*/
private String env;
private Map<String, String> environmentMap;
private String creator;
}

View File

@ -161,7 +161,8 @@
api_scenario.status, api_scenario.principal, api_scenario.step_total,
api_scenario.last_result,api_scenario.pass_rate,api_scenario.report_id,
api_scenario.schedule, api_scenario.description, api_scenario.create_time, api_scenario.update_time,
project.name as project_name, user.name as user_name,deleteUser.name AS delete_user,api_scenario.delete_time ,u2.name as principal_name
project.name as project_name, user.name as user_name,deleteUser.name AS delete_user,api_scenario.delete_time ,u2.name as principal_name,
api_scenario.create_user as creator
from api_scenario
left join project on api_scenario.project_id = project.id
left join user on api_scenario.user_id = user.id
@ -279,6 +280,12 @@
#{value}
</foreach>
</when>
<when test="key=='creator'">
and api_scenario.create_user in
<foreach collection="values" item="value" separator="," open="(" close=")">
#{value}
</foreach>
</when>
</choose>
</if>

View File

@ -124,7 +124,7 @@
:field="item"
:fields-width="fieldsWidth"
sortable/>
<ms-table-column prop="userName" min-width="120px"
<ms-table-column prop="creator" min-width="120px"
:label="$t('api_test.automation.creator')"
:filters="userFilters"
:field="item"

View File

@ -70,7 +70,7 @@ export let CUSTOM_TABLE_HEADER = {
{id: 'level', key: '3', label: 'api_test.automation.case_level'},
{id: 'status', key: '4', label: 'test_track.plan.plan_status'},
{id: 'tags', key: '5', label: 'commons.tag'},
{id: 'userName', key: '6', label: 'api_test.automation.creator'},
{id: 'creator', key: '6', label: 'api_test.automation.creator'},
{id: 'principalName', key: '7', label: 'api_test.definition.api_principal'},
{id: 'environmentMap', key: 'e', label: 'commons.environment'},
{id: 'updateTime', key: '8', label: 'api_test.definition.api_last_time'},