fix(测试跟踪): 用例评审标题过长时缩略显示

--bug=1013135 --user=李玉号 【测试跟踪】用例评审标题过长时 建议都显示一行,目前低分辨率 显示不友好
https://www.tapd.cn/55049933/s/1166793
This commit is contained in:
shiziyuan9527 2022-05-27 15:53:22 +08:00 committed by jianxing
parent c94f8f7d31
commit 4c4e5d3215
3 changed files with 52 additions and 13 deletions

View File

@ -1,14 +1,19 @@
<template>
<span class="previous-next-button">
<span v-if="countNum === total"
class="head-right-tip">
<el-tooltip effect="light" placement="top" :enterable="false" v-if="countNum === total">
<div slot="content">{{list[index - 1] ? list[index - 1].name : (prePageData ? prePageData.name : '')}}</div>
<span class="head-right-tip">
{{ $t('test_track.plan_view.pre_case') }} : {{list[index - 1] ? list[index - 1].name : (prePageData ? prePageData.name : '')}}
</span>
<span
v-else
class="head-right-tip">
</el-tooltip>
<el-tooltip effect="light" placement="top" :enterable="false" v-else>
<div slot="content">{{list[index + 1] ? list[index + 1].name : (nextPageData ? nextPageData.name : '')}}</div>
<span class="head-right-tip">
{{ $t('test_track.plan_view.next_case') }} : {{list[index + 1] ? list[index + 1].name : (nextPageData ? nextPageData.name : '')}}
</span>
</el-tooltip>
<el-button
plain
@ -93,6 +98,14 @@ export default {
.head-right-tip {
color: darkgrey;
display: inline-block;
line-height: 1;
max-width: 300px;
white-space: nowrap;
text-overflow: ellipsis;
overflow: hidden;
word-break: break-all;
margin-right: 5px;
}
</style>

View File

@ -46,7 +46,11 @@
<el-row class="head-bar">
<el-col>
<el-divider content-position="left">
<el-button class="test-case-name" type="text" @click="openTestTestCase(testCase)">{{ testCase.customNum }}-{{ testCase.name }}</el-button>
<el-button class="test-case-name" type="text" @click="openTestTestCase(testCase)">
<span class="title-link" :title="testCase.name">
{{ testCase.customNum }}-{{ testCase.name }}
</span>
</el-button>
</el-divider>
</el-col>
</el-row>
@ -607,6 +611,16 @@ p {
text-decoration: underline solid #783887;
}
.title-link {
display: inline-block;
max-width: 300px;
white-space: nowrap;
text-overflow: ellipsis;
overflow: hidden;
word-break: break-all;
margin-right: 5px;
}
/deep/ .el-drawer__body {
overflow: unset;
}

View File

@ -20,14 +20,14 @@
<el-row type="flex" class="head-bar">
<el-col :span="8">
<el-col :span="2">
<el-button plain size="mini"
icon="el-icon-back"
@click="cancel">{{ $t('test_track.return') }}
</el-button>
</el-col>
<el-col :span="14" class="head-right">
<el-col :span="22" class="head-right">
<ms-previous-next-button
:index="index"
@ -62,7 +62,9 @@
<el-col>
<el-divider content-position="left">
<el-button class="test-case-name" type="text" @click="openTestTestCase(testCase)">
<span class="title-link" :title="testCase.name">
{{ testCase.num }}-{{ testCase.name }}
</span>
</el-button>
</el-divider>
</el-col>
@ -584,6 +586,16 @@ export default {
text-decoration: underline solid #783887;
}
.title-link {
display: inline-block;
max-width: 300px;
white-space: nowrap;
text-overflow: ellipsis;
overflow: hidden;
word-break: break-all;
margin-right: 5px;
}
.step-info {
padding-left: 40px;
padding-right: 15px;