This commit is contained in:
熊成强 2020-11-06 16:42:26 +08:00
parent e3cd9db93c
commit 0d8104a304

View File

@ -91,17 +91,33 @@ export default {
return this.$message.error('权重评分总和不得大于100')
}
}
if (this.$route.query.copy) {
this.templateForm.modelItems = this.templateForm.modelItems.map(i => {
delete i.id
return i
})
}
this.loadings = true
try {
this.$loadingStart()
let res1 = await apiCheckStaff(Object.assign({}, this.basisForm, {confirm: 1}))
console.log('res1: ', res1)
let res = await saveBaseSet(this.basisForm)
if (res.code !== 200) {
this.$loadingEnd()
return this.$message.error(res.msg)
}
res = res.data
this.basisForm = res
this.templateForm.evaluationGroupId = res.id
for (let i in this.processInfo) {
try {
if (this.$route.query.copy) {
this.processInfo[i].chartDetails.recordSimpleDtos = this.processInfo[i].chartDetails.recordSimpleDtos.map(i => {
delete i.id
return i
})
}
let res1 = await saveDetailProcs(Object.assign({}, this.processInfo[i].chartDetails, {evaluationGroupId: res.id}))
console.log('res: ', res1)
} catch (error) {