clay : 任意节点退回完成 #34
|
|
@ -127,6 +127,7 @@ export default {
|
||||||
},
|
},
|
||||||
getList() {
|
getList() {
|
||||||
getUserTree(this.radio, this.chooseId).then(res => {
|
getUserTree(this.radio, this.chooseId).then(res => {
|
||||||
|
console.log('人员', res.data)
|
||||||
if (res.data) {
|
if (res.data) {
|
||||||
if (this.selectItem.type === -1 || this.selectItem.type === -2) {
|
if (this.selectItem.type === -1 || this.selectItem.type === -2) {
|
||||||
this.dataList = this.setData(res.data)
|
this.dataList = this.setData(res.data)
|
||||||
|
|
@ -141,7 +142,6 @@ export default {
|
||||||
setData(source) {
|
setData(source) {
|
||||||
for (let item of source) {
|
for (let item of source) {
|
||||||
this.$set(item, "value", this.selectItem.value + "-" + item.id)
|
this.$set(item, "value", this.selectItem.value + "-" + item.id)
|
||||||
this.$set(item, "children", [])
|
|
||||||
}
|
}
|
||||||
return source;
|
return source;
|
||||||
},
|
},
|
||||||
|
|
@ -162,8 +162,8 @@ export default {
|
||||||
if (item.type !== 0) {
|
if (item.type !== 0) {
|
||||||
this.chooseId = item.id
|
this.chooseId = item.id
|
||||||
this.getList()
|
this.getList()
|
||||||
|
return
|
||||||
}
|
}
|
||||||
if (!item.children) {
|
|
||||||
if (this.multiple) {
|
if (this.multiple) {
|
||||||
//不添加重复的数据到右边
|
//不添加重复的数据到右边
|
||||||
for (let i = 0; i < this.selectList.length; i++) {
|
for (let i = 0; i < this.selectList.length; i++) {
|
||||||
|
|
@ -176,7 +176,6 @@ export default {
|
||||||
} else {
|
} else {
|
||||||
this.selectList = [item];
|
this.selectList = [item];
|
||||||
}
|
}
|
||||||
}
|
|
||||||
// this._value = this.selectList
|
// this._value = this.selectList
|
||||||
},
|
},
|
||||||
//右侧的×
|
//右侧的×
|
||||||
|
|
|
||||||
|
|
@ -9,11 +9,11 @@
|
||||||
placement="top">
|
placement="top">
|
||||||
<el-card>
|
<el-card>
|
||||||
<div style="display: flex;">
|
<div style="display: flex;">
|
||||||
<div v-for="(user,index) in operation.userInfo" :key="index">
|
<div v-for="(user,index) in operation.userInfo" :key="index" class="avatar_name">
|
||||||
<el-avatar style="margin-right: 5px;" size="large"
|
<el-avatar size="large"
|
||||||
:src="user.avatar"></el-avatar>
|
:src="user.avatar"></el-avatar>
|
||||||
<div v-if="!$slots.dot && operation.userInfo.length > 1"
|
<div v-if="!$slots.dot && operation.userInfo.length > 1"
|
||||||
class="el-timeline-item__node" :style="{
|
class="el-timeline-item__node avatar_icon" :style="{
|
||||||
backgroundColor: user.color
|
backgroundColor: user.color
|
||||||
}">
|
}">
|
||||||
<i v-if="user.icon"
|
<i v-if="user.icon"
|
||||||
|
|
@ -21,6 +21,9 @@
|
||||||
:class="user.icon"
|
:class="user.icon"
|
||||||
></i>
|
></i>
|
||||||
</div>
|
</div>
|
||||||
|
<el-tooltip effect="dark" :content="user.name" placement="bottom-start">
|
||||||
|
<span class="username">{{ user.name }}</span>
|
||||||
|
</el-tooltip>
|
||||||
</div>
|
</div>
|
||||||
<div style="margin-left: 10px;">
|
<div style="margin-left: 10px;">
|
||||||
<div style="color: #c0bebe">{{ operation.operationName }}</div>
|
<div style="color: #c0bebe">{{ operation.operationName }}</div>
|
||||||
|
|
@ -230,5 +233,25 @@ export default {
|
||||||
/deep/ .el-card__body, .el-main {
|
/deep/ .el-card__body, .el-main {
|
||||||
padding: 10px;
|
padding: 10px;
|
||||||
}
|
}
|
||||||
|
.avatar_name{
|
||||||
|
width: 45px;
|
||||||
|
display: flex;
|
||||||
|
flex-direction: column;
|
||||||
|
align-items: center;
|
||||||
|
position: relative;
|
||||||
|
margin-right: 5px;
|
||||||
|
}
|
||||||
|
.avatar_icon{
|
||||||
|
position: absolute;
|
||||||
|
bottom: 16px;
|
||||||
|
right: -2px;
|
||||||
|
}
|
||||||
|
.username{
|
||||||
|
width: 45px;
|
||||||
|
padding-top: 2px;
|
||||||
|
text-align: center;
|
||||||
|
text-overflow: ellipsis;
|
||||||
|
white-space: nowrap;
|
||||||
|
overflow: hidden
|
||||||
|
}
|
||||||
</style>
|
</style>
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue