update 人员信息样式

This commit is contained in:
赵霄
2023-12-01 15:12:40 +08:00
parent ea093990f2
commit 9cba85a0c7
4 changed files with 374 additions and 19 deletions
+30 -1
View File
@@ -21,7 +21,7 @@
<div class="process-container" v-show="activeTab === 'basic'">
<slot name="process"></slot>
</div>
<!--人员信息可以不用单独封组件了放在这里就行-->
<!--人员信息-->
<div class="process-container" v-show="activeTab === 'person'">
<van-steps direction="vertical">
<van-step v-for="item in personnelInfoData" :key="item.id">
@@ -97,6 +97,32 @@ export default {
this.personnelInfoData = res.result
}
})
},
// 获取人员对象,无校验
getDataObj () {
const personnelObj = {}
for (const item of this.personnelInfoData) {
// 该属性还没有人就给他赋值
if ((item.canChoose || item.sort === 1) && !personnelObj[item.variableName]) {
personnelObj[item.variableName] = item.linkUserIds
}
}
return personnelObj
},
// 有校验的获取人员对象
getDataObjVerify () {
let personnelObj = {}
for (const item of this.personnelInfoData) {
// 该属性还没有人就给他赋值
if ((item.canChoose || item.sort === 1) && !personnelObj[item.variableName]) {
personnelObj[item.variableName] = item.linkUserIds
}
}
if (!Object.values(personnelObj).every(v => !!v)) {
this.$message(this.$t('pleaseEnterPersonnelInfo'))
personnelObj = false
}
return personnelObj
}
}
}
@@ -173,6 +199,9 @@ export default {
margin: 0;
padding: 0.26rem 0.21rem;
color: #1D2129;
font-size: 0.32rem;
font-weight: 600;
line-height: 0.38rem;
}
}
.van-step__circle-container {