|
@@ -54,12 +54,18 @@
|
|
|
<el-table-column label="通知人" align="center" prop="recipients" width="360">
|
|
|
<template #default="{ row }">
|
|
|
<div class="tag-container">
|
|
|
- <el-tooltip v-for="(recipient, index) in row.recipients" :key="index"
|
|
|
- :content="recipient.voteReason || '暂无无备注信息'" placement="top">
|
|
|
- <el-tag :type="getTagTypeMap[String(recipient.status)]">
|
|
|
+ <template v-for="(recipient, index) in row.recipients" :key="index">
|
|
|
+ <!-- 仅当 voteReason 有值时显示 tooltip -->
|
|
|
+ <el-tooltip v-if="recipient.voteReason" :content="recipient.voteReason" placement="top" :hide-after="0">
|
|
|
+ <el-tag :type="getTagTypeMap[String(recipient.status)]">
|
|
|
+ {{ recipient.userName }}
|
|
|
+ </el-tag>
|
|
|
+ </el-tooltip>
|
|
|
+ <!-- 否则直接显示 el-tag(无 tooltip) -->
|
|
|
+ <el-tag v-else :type="getTagTypeMap[String(recipient.status)]">
|
|
|
{{ recipient.userName }}
|
|
|
</el-tag>
|
|
|
- </el-tooltip>
|
|
|
+ </template>
|
|
|
</div>
|
|
|
</template>
|
|
|
</el-table-column>
|
|
@@ -450,6 +456,7 @@ getCompany()
|
|
|
.tag-container {
|
|
|
display: flex;
|
|
|
flex-wrap: wrap;
|
|
|
- gap: 6px; /* 调整标签间距 */
|
|
|
+ gap: 6px;
|
|
|
+ /* 调整标签间距 */
|
|
|
}
|
|
|
</style>
|