首页待办顶部对齐,活动管理整改,职工福利复测整改

This commit is contained in:
2026-11-02 10:49:42 +08:00
parent 9590ad5f8c
commit 4271924a2f
7 changed files with 107 additions and 14 deletions
@@ -181,7 +181,7 @@ layout("/layouts/v4/baseLayout.html"){
</style>
<link rel="stylesheet" href="${base!}/assets/platform/css/home-portal.css?v=20261030-1" />
<link rel="stylesheet" href="${base!}/assets/platform/css/home-portal.css?v=20261102-1" />
<!-- 登录资料仅在 HTML 属性中输出并转义;放在 Vue 挂载区域外,避免名称被当作模板表达式解析。 -->
<div id="v4-home-profile-data" hidden
@@ -1050,7 +1050,14 @@ const ACTIVITY_CULTURE_APPLY_ACTIVITY = {
if (code === 0) {
if (data.userId) {
const user = await this.queryUserByIds([data.userId])
await this.remoteMethod(user[0].loginname)
// 历史模板的负责人可能已删除;清空失效选择并继续回填,避免空数组中断整个表单。
if (Array.isArray(user) && user.length > 0 && user[0].loginname) {
await this.remoteMethod(user[0].loginname)
} else {
this.$set(data, "userId", null)
this.userList = []
this.$message.warning("原负责人已不存在,请重新选择负责人")
}
}
if (data.goods) data.goods = JSON.parse(data.goods)
if (data.billFiles && data.billFiles.length > 0) data.billFiles = JSON.parse(data.billFiles)
@@ -82,6 +82,7 @@ layout("/layouts/platform.html"){
</el-popover>
</table-tool>
<el-table
ref="memberTableRef"
:data="tableData"
style="width: 100%"
stripe
@@ -102,12 +103,12 @@ layout("/layouts/platform.html"){
<el-table-column
align="center"
header-align="center"
v-for="column in tableColumns"
v-for="column in showColumns"
:key="column.prop"
show-overflow-tooltip
v-if="checkedFields.includes(column.prop)"
:label="column.label"
:prop="column.prop"
:width="column.width"
:min-width="column.width || 120"
:fixed="column.fixed"
:sortable="column.sortable"
>
@@ -268,6 +269,16 @@ layout("/layouts/platform.html"){
this.checkedFields = all.filter(p => !this.checkedFields.includes(p));
}
},
watch: {
checkedFields() {
// 可见列更新后重新计算列宽,保证右侧固定操作列与表头、数据行对齐。
this.$nextTick(() => {
if (this.$refs.memberTableRef) {
this.$refs.memberTableRef.doLayout()
}
})
}
},
computed: {
showColumns() {
return this.tableColumns.filter(c => this.checkedFields.includes(c.prop));