update 强制撤回
This commit is contained in:
@@ -252,17 +252,6 @@ export default {
|
||||
loadPage () {
|
||||
const { projectId, taskId, draftId } = this.$route.query
|
||||
this.loading = true
|
||||
// 获取业务数据
|
||||
getPostMeetingManageDataById({ projectId: this.projectId }).then(res => {
|
||||
if (res.success) {
|
||||
const data = res.result || {}
|
||||
// 保存并回显表单信息
|
||||
this.formInfo = data
|
||||
this.$nextTick(() => {
|
||||
this.$refs.baseInfoForm.initData(data)
|
||||
})
|
||||
}
|
||||
})
|
||||
getPostMeetingManageDetail({
|
||||
projectId,
|
||||
taskId
|
||||
@@ -285,13 +274,31 @@ export default {
|
||||
|
||||
// 草稿状态回显
|
||||
if (draftId) {
|
||||
const { draftData, personInfo } = JSON.parse(data.infoJsonStr || '{}')
|
||||
console.log('草稿回显', JSON.parse(data.infoJsonStr || '{}'), draftData, personInfo)
|
||||
const infoJson = JSON.parse(data.infoJsonStr || '{}')
|
||||
console.log('草稿回显', JSON.parse(data.infoJsonStr || '{}'), infoJson)
|
||||
// 节点1 回显人员信息
|
||||
if (this.isInitiate) {
|
||||
this.draftInitPersonInfo(personInfo)
|
||||
this.draftInitPersonInfo(infoJson.personInfo)
|
||||
}
|
||||
// 回显业务信息(需要等后端调整)
|
||||
// 回显业务信息,如果有标识属性就是强制撤回
|
||||
if (Object.hasOwnProperty.call(infoJson, 'revocation')) {
|
||||
this.formInfo = infoJson.draftData
|
||||
this.$nextTick(() => {
|
||||
this.$refs.baseInfoForm.initData(this.formInfo)
|
||||
})
|
||||
}
|
||||
} else {
|
||||
// 非草稿获取业务数据
|
||||
getPostMeetingManageDataById({ projectId: this.projectId }).then(res => {
|
||||
if (res.success) {
|
||||
const data = res.result || {}
|
||||
// 保存并回显表单信息
|
||||
this.formInfo = data
|
||||
this.$nextTick(() => {
|
||||
this.$refs.baseInfoForm.initData(data)
|
||||
})
|
||||
}
|
||||
})
|
||||
}
|
||||
}
|
||||
}).finally(() => {
|
||||
@@ -382,6 +389,14 @@ export default {
|
||||
if (this.currentNode === PostMeetingManage.attendeesUploadMaterials.value) {
|
||||
params.fileIds = params.processMeetingManage.fileIds
|
||||
}
|
||||
|
||||
// 保存草稿信息
|
||||
params.infoJsonStr = JSON.stringify({
|
||||
// 人员信息(要重新获取,流程里的信息不能直接用,后端需要多选人员处理成数组了)
|
||||
personInfo: this.$refs.personnelInfo.getDataObj(),
|
||||
// 业务数据,用于强制撤回后回显
|
||||
draftData: params.processMeetingManage
|
||||
})
|
||||
return params
|
||||
},
|
||||
/**
|
||||
@@ -418,13 +433,6 @@ export default {
|
||||
if (this.loading) return
|
||||
this.loading = true
|
||||
this.getPageParams(false).then(res => {
|
||||
// 保存草稿信息
|
||||
res.infoJsonStr = JSON.stringify({
|
||||
// 人员信息(要重新获取,流程里的信息不能直接用,后端需要多选人员处理成数组了)
|
||||
personInfo: this.$refs.personnelInfo.getDataObj()
|
||||
// 业务数据(需要等后端调整)
|
||||
// draftData:
|
||||
})
|
||||
// 1待办 2草稿
|
||||
res.saveSource = (this.$route.query.draftId || !this.$route.query.projectId) ? 2 : 1
|
||||
console.log(res)
|
||||
|
||||
Reference in New Issue
Block a user