fix: 修复测试计划列表页面,“负责人”应展示成员姓名,非展示成员ID

Closes 406
This commit is contained in:
Captain.B 2020-10-09 16:27:37 +08:00
parent 04a022a4f3
commit 446f0cdcde
3 changed files with 7 additions and 4 deletions

View File

@ -4,7 +4,8 @@
<resultMap id="BaseResultMap" type="io.metersphere.track.dto.TestPlanDTO"
extends="io.metersphere.base.mapper.TestPlanMapper.BaseResultMap">
<result column="project_name" property="projectName"/>
<result column="project_name" property="projectName" jdbcType="VARCHAR"/>
<result column="user_name" property="userName" jdbcType="VARCHAR"/>
</resultMap>
<sql id="condition">
<choose>
@ -97,7 +98,8 @@
<select id="list" resultMap="BaseResultMap"
parameterType="io.metersphere.track.request.testcase.QueryTestPlanRequest">
select test_plan.* from test_plan
select test_plan.*, user.name as user_name from test_plan
JOIN user ON user.id = test_plan.principal
<where>
<if test="request.combine != null">
<include refid="combine">

View File

@ -10,5 +10,6 @@ import java.util.List;
@Setter
public class TestPlanDTO extends TestPlan {
private String projectName;
private String userName;
private List<String> projectIds;
}

View File

@ -20,7 +20,7 @@
show-overflow-tooltip>
</el-table-column>
<el-table-column
prop="principal"
prop="userName"
:label="$t('test_track.plan.plan_principal')"
show-overflow-tooltip>
</el-table-column>
@ -141,7 +141,7 @@ import MsTableOperatorButton from "../../../common/components/MsTableOperatorBut
import MsTableOperator from "../../../common/components/MsTableOperator";
import PlanStatusTableItem from "../../common/tableItems/plan/PlanStatusTableItem";
import PlanStageTableItem from "../../common/tableItems/plan/PlanStageTableItem";
import {_filter, _sort, checkoutTestManagerOrTestUser} from "../../../../../common/js/utils";
import {_filter, _sort, checkoutTestManagerOrTestUser} from "@/common/js/utils";
import TestReportTemplateList from "../view/comonents/TestReportTemplateList";
import TestCaseReportView from "../view/comonents/report/TestCaseReportView";
import MsDeleteConfirm from "../../../common/components/MsDeleteConfirm";