[update] 修改bug80351

This commit is contained in:
lideqin
2024-01-09 15:18:37 +08:00
parent 44c59a7b9b
commit 6be9d90835
7 changed files with 55 additions and 22 deletions
@@ -150,9 +150,10 @@ export default {
dataIndex: 'transferUser',
customRender: (value, row, index) => {
return <user-selection v-model={this.dataSource[index].transferUser}
ref={'userSelection'}
disabled={this.disabled} type={'radio'}
filedName={this.dataSource[index].id + '-' + this.dataSource[index].type}
nameStr={this.dataSource[index].transferUser_dictText}
onNameChange={this.userNameChange} showBtn={false}
placeholder={this.$t('pleaseSelect')} onChange={this.transferUserChange} />
}
}
@@ -194,15 +195,15 @@ export default {
if (res.success) {
this.$message.success(res.message)
this.loadData()
this.$forceUpdate()
this.$refs.userSelection.$forceUpdate()
} else {
this.$message.warning(res.message)
}
}).finally(() => {
this.loading = false
})
},
userNameChange (value, fieldName) {
const data = this.dataSource.find(item => item.id === fieldName.split('-')[0])
data.transferUser_dictText = value
},
// 批量转交
handleTransfer () {
if (this.selectedRowKeys.length <= 0) {
@@ -22,6 +22,7 @@
<j-dict-select-tag
:placeholder="$t('pleaseSelect')+$t('workCenter.processCenter.processType')"
dict-code="prc_type"
:dropdownMatchSelectWidth="false"
v-model="queryParam.prcType">
</j-dict-select-tag>
</a-form-item>
@@ -152,10 +153,11 @@ export default {
customRender: (value, row, index) => {
if (row.state) {
return <user-selection v-model={this.dataSource[index].transferUser}
nameStr={this.dataSource[index].transferUser_dictText}
filedName={this.dataSource[index].taskId}
onChange={this.transferUserChange}
disabled={this.disabled} type={'radio'} placeholder={this.$t('pleaseSelect')} />
nameStr={this.dataSource[index].transferUser_dictText}
filedName={this.dataSource[index].taskId}
onChange={this.transferUserChange}
onNameChange={this.userNameChange} showBtn={false}
disabled={this.disabled} type={'radio'} placeholder={this.$t('pleaseSelect')} />
} else {
return this.global.emptyLine
}
@@ -185,10 +187,12 @@ export default {
} else {
this.$message.warning(res.message)
}
}).finally(() => {
this.loading = false
})
},
userNameChange (value, fieldName) {
const data = this.dataSource.find(item => item.taskId === fieldName)
data.transferUser_dictText = value
},
// 批量转交
handleTransfer () {
if (this.selectedRowKeys.length <= 0) {
@@ -205,7 +205,7 @@ export default {
customRender: (value, row, index) => {
return <user-selection v-model={this.dataSource[index].approvalUser}
filedName={index + ''} onNameChange={this.userNameChange}
nameStr={this.dataSource[index].approvalUser_dictText}
nameStr={this.dataSource[index].approvalUser_dictText} showBtn={false}
disabled={this.disabled} type={'radio'} placeholder={this.$t('pleaseSelect')} />
}
}
@@ -252,7 +252,7 @@ export default {
} else {
// 不是被驳回的待办,可以设置联络人
return <user-select-by-contact v-model={this.dataSource[index].contactUser}
nameStr={this.dataSource[index].contactUser_dictText}
nameStr={this.dataSource[index].contactUser_dictText} showBtn={false}
disabled={this.disabled} type={'radio'} placeholder={this.$t('pleaseSelect')} />
}
}
@@ -196,7 +196,7 @@ export default {
customRender: (value, row, index) => {
return <user-selection v-model={this.dataSource[index].prcMainDraftUser}
filedName={index + ''} onNameChange={this.userNameChange}
nameStr={this.dataSource[index].prcMainDraftUser_dictText}
nameStr={this.dataSource[index].prcMainDraftUser_dictText} showBtn={false}
disabled={this.disabled} type={'radio'} placeholder={this.$t('pleaseSelect')} />
}
}