优化
This commit is contained in:
parent
8952f1a97d
commit
aa655a1a80
@ -184,11 +184,14 @@ export default {
|
||||
},
|
||||
async handleGetNext () {
|
||||
this.loadingTi = true
|
||||
let res1 = await apiSaveDetail(Object.assign({}, this.obj, this.score))
|
||||
let paramsObj = this.obj
|
||||
if ((this.tableInfo.score || this.tableAuth.showScore)) {
|
||||
paramsObj = Object.assign({}, paramsObj, this.score)
|
||||
}
|
||||
let res1 = await apiSaveDetail(paramsObj)
|
||||
if (res1.code !== 200) {
|
||||
this.loadingTi = false
|
||||
this.$message.error(res1.msg)
|
||||
return
|
||||
}
|
||||
const obj = {status: 1, menuName: this.tableInfo.result ? '提交了结果值' : '提交了评分'}
|
||||
const params = Object.assign({}, {resultRecordId: this.$route.query.id || ''}, obj)
|
||||
@ -196,7 +199,6 @@ export default {
|
||||
this.loadingTi = false
|
||||
if (res.code !== 200) {
|
||||
this.$message.error(res.msg)
|
||||
return
|
||||
}
|
||||
this.$message({
|
||||
message: res.msg,
|
||||
@ -212,9 +214,13 @@ export default {
|
||||
if (res.code !== 200) return
|
||||
this.scoreList = res.data
|
||||
},
|
||||
async handleSaveDetail (params = Object.assign({}, this.obj, this.score)) {
|
||||
async handleSaveDetail (params = this.obj) {
|
||||
this.loadingZan = true
|
||||
let res = await apiSaveDetail(params)
|
||||
let paramsObj = params
|
||||
if ((this.tableInfo.score || this.tableAuth.showScore)) {
|
||||
paramsObj = Object.assign({}, paramsObj, this.score)
|
||||
}
|
||||
let res = await apiSaveDetail(paramsObj)
|
||||
this.loadingZan = false
|
||||
if (res.code !== 200) {
|
||||
this.$message.error(res.msg)
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user