|
|
|
@ -21,7 +21,7 @@ |
|
|
|
<div> |
|
|
|
<el-tag v-for="tag in selfTag" :key="tag.staffId" closable @close="removeTag(tag)" |
|
|
|
style="margin-right: 10px;"> |
|
|
|
<span> {{ tag.name }}</span> |
|
|
|
<span> {{ tag.userName?tag.userName:tag.name }}</span> |
|
|
|
</el-tag> |
|
|
|
</div> |
|
|
|
|
|
|
|
@ -97,50 +97,51 @@ export default { |
|
|
|
created() { }, |
|
|
|
methods: { |
|
|
|
handleConfirm() { |
|
|
|
let userIdList = this.selfTag.map(item => { |
|
|
|
return item.staffId |
|
|
|
}) |
|
|
|
if (this.showType == "adjust") { |
|
|
|
let parms = { |
|
|
|
userIdList: userIdList, |
|
|
|
taskId: this.taskId, |
|
|
|
} |
|
|
|
this.updateState() |
|
|
|
requestPost('/actual/base/communityOneTablePeriodPublish/changeAssignWorker', parms).then(res => { |
|
|
|
if (res.code === 0) { |
|
|
|
this.$message.success('转派成功') |
|
|
|
return this.$emit('handelPersonel') |
|
|
|
} else { |
|
|
|
this.$message.error(res.internalMsg) |
|
|
|
} |
|
|
|
}); |
|
|
|
} else if (this.showType == "adjust1") { |
|
|
|
let parms = { |
|
|
|
userId: userIdList.toString(), |
|
|
|
id: this.taskId, |
|
|
|
reassignedReason: "" |
|
|
|
} |
|
|
|
this.updateState() |
|
|
|
requestPost('/actual/base/communityOneTablePeriodPublish/reAssignWorker', parms).then(res => { |
|
|
|
if (res.code === 0) { |
|
|
|
this.$message.success('转派成功') |
|
|
|
return this.$emit('handelPersonel') |
|
|
|
} else { |
|
|
|
this.$message.error(res.internalMsg) |
|
|
|
} |
|
|
|
}); |
|
|
|
} |
|
|
|
else { |
|
|
|
let parms = { |
|
|
|
userIdList: userIdList, |
|
|
|
id: this.taskId, |
|
|
|
taskIntroduction: this.formData.taskIntroduction |
|
|
|
console.log(this.selfTag),"dsfkljdslk"; |
|
|
|
// let userIdList = this.selfTag.map(item => { |
|
|
|
// return item.staffId |
|
|
|
// }) |
|
|
|
// if (this.showType == "adjust") { |
|
|
|
// let parms = { |
|
|
|
// userIdList: userIdList, |
|
|
|
// taskId: this.taskId, |
|
|
|
// } |
|
|
|
// this.updateState() |
|
|
|
// requestPost('/actual/base/communityOneTablePeriodPublish/changeAssignWorker', parms).then(res => { |
|
|
|
// if (res.code === 0) { |
|
|
|
// this.$message.success('转派成功') |
|
|
|
// return this.$emit('handelPersonel') |
|
|
|
// } else { |
|
|
|
// this.$message.error(res.internalMsg) |
|
|
|
// } |
|
|
|
// }); |
|
|
|
// } else if (this.showType == "adjust1") { |
|
|
|
// let parms = { |
|
|
|
// userId: userIdList.toString(), |
|
|
|
// id: this.taskId, |
|
|
|
// reassignedReason: "" |
|
|
|
// } |
|
|
|
// this.updateState() |
|
|
|
// requestPost('/actual/base/communityOneTablePeriodPublish/reAssignWorker', parms).then(res => { |
|
|
|
// if (res.code === 0) { |
|
|
|
// this.$message.success('转派成功') |
|
|
|
// return this.$emit('handelPersonel') |
|
|
|
// } else { |
|
|
|
// this.$message.error(res.internalMsg) |
|
|
|
// } |
|
|
|
// }); |
|
|
|
// } |
|
|
|
// else { |
|
|
|
// let parms = { |
|
|
|
// userIdList: userIdList, |
|
|
|
// id: this.taskId, |
|
|
|
// taskIntroduction: this.formData.taskIntroduction |
|
|
|
|
|
|
|
} |
|
|
|
requestPost('/actual/base/communityOneTablePublish/update', parms).then(res => { |
|
|
|
return this.$emit('handelPersonel') |
|
|
|
}); |
|
|
|
} |
|
|
|
// } |
|
|
|
// requestPost('/actual/base/communityOneTablePublish/update', parms).then(res => { |
|
|
|
// return this.$emit('handelPersonel') |
|
|
|
// }); |
|
|
|
// } |
|
|
|
|
|
|
|
}, |
|
|
|
async updateState() { |
|
|
|
@ -165,7 +166,7 @@ export default { |
|
|
|
taskNum: 0 |
|
|
|
} |
|
|
|
requestGet('/actual/base/communityOneTablePeriodPublish/page', parms).then(res => { |
|
|
|
this.tableData = res.data.list |
|
|
|
this.selfTag = res.data.list |
|
|
|
}); |
|
|
|
}, |
|
|
|
getLastItem(list, vals, key) { |
|
|
|
@ -232,7 +233,6 @@ export default { |
|
|
|
return this.$message.error('网络错误') |
|
|
|
}) |
|
|
|
}, |
|
|
|
|
|
|
|
handleCancel() { |
|
|
|
this.$emit('handelPersonel') |
|
|
|
}, |
|
|
|
|