|
@@ -999,7 +999,7 @@ export default {
|
|
callback: (action) => {
|
|
callback: (action) => {
|
|
if (action == "confirm") {
|
|
if (action == "confirm") {
|
|
this.loading = true;
|
|
this.loading = true;
|
|
- this.$http
|
|
|
|
|
|
+ this.$httpWithMsg
|
|
.put(
|
|
.put(
|
|
QUESTION_API +
|
|
QUESTION_API +
|
|
"/paperDetail/" +
|
|
"/paperDetail/" +
|
|
@@ -1016,8 +1016,8 @@ export default {
|
|
message: vectorStr + "成功",
|
|
message: vectorStr + "成功",
|
|
type: "success",
|
|
type: "success",
|
|
});
|
|
});
|
|
- this.loading = false;
|
|
|
|
- });
|
|
|
|
|
|
+ })
|
|
|
|
+ .finally(() => (this.loading = false));
|
|
}
|
|
}
|
|
},
|
|
},
|
|
});
|
|
});
|
|
@@ -1219,7 +1219,8 @@ export default {
|
|
}
|
|
}
|
|
}
|
|
}
|
|
setTimeout(() => {
|
|
setTimeout(() => {
|
|
- document.documentElement.scrollTop = document.body.scrollTop = scrollPosition;
|
|
|
|
|
|
+ document.documentElement.scrollTop = document.body.scrollTop =
|
|
|
|
+ scrollPosition;
|
|
console.log(scrollPosition);
|
|
console.log(scrollPosition);
|
|
}, 1000);
|
|
}, 1000);
|
|
this.loading = false;
|
|
this.loading = false;
|
|
@@ -1251,7 +1252,7 @@ export default {
|
|
callback: (action) => {
|
|
callback: (action) => {
|
|
if (action == "confirm") {
|
|
if (action == "confirm") {
|
|
this.loading = true;
|
|
this.loading = true;
|
|
- this.$http
|
|
|
|
|
|
+ this.$httpWithMsg
|
|
.delete(
|
|
.delete(
|
|
QUESTION_API +
|
|
QUESTION_API +
|
|
"/paperDetail/" +
|
|
"/paperDetail/" +
|
|
@@ -1266,8 +1267,8 @@ export default {
|
|
message: "删除成功",
|
|
message: "删除成功",
|
|
type: "success",
|
|
type: "success",
|
|
});
|
|
});
|
|
- this.loading = false;
|
|
|
|
- });
|
|
|
|
|
|
+ })
|
|
|
|
+ .finally(() => (this.loading = false));
|
|
}
|
|
}
|
|
},
|
|
},
|
|
});
|
|
});
|
|
@@ -1643,7 +1644,7 @@ export default {
|
|
type: "warning",
|
|
type: "warning",
|
|
}).then(() => {
|
|
}).then(() => {
|
|
this.dialogLoading = true;
|
|
this.dialogLoading = true;
|
|
- this.$http
|
|
|
|
|
|
+ this.$httpWithMsg
|
|
.delete(
|
|
.delete(
|
|
QUESTION_API +
|
|
QUESTION_API +
|
|
"/paper/deleteQuestion/" +
|
|
"/paper/deleteQuestion/" +
|
|
@@ -1667,8 +1668,8 @@ export default {
|
|
type: "success",
|
|
type: "success",
|
|
});
|
|
});
|
|
}
|
|
}
|
|
- this.dialogLoading = false;
|
|
|
|
- });
|
|
|
|
|
|
+ })
|
|
|
|
+ .finally(() => (this.loading = false));
|
|
});
|
|
});
|
|
} else {
|
|
} else {
|
|
this.dialogLoading = true;
|
|
this.dialogLoading = true;
|
|
@@ -1728,7 +1729,7 @@ export default {
|
|
}
|
|
}
|
|
}
|
|
}
|
|
paperDetailUnitExp.question.quesAnswer = this.answer;
|
|
paperDetailUnitExp.question.quesAnswer = this.answer;
|
|
- this.$http
|
|
|
|
|
|
+ this.$httpWithMsg
|
|
.put(QUESTION_API + "/paperDetailUnit", paperDetailUnitExp)
|
|
.put(QUESTION_API + "/paperDetailUnit", paperDetailUnitExp)
|
|
.then(() => {
|
|
.then(() => {
|
|
this.$notify({
|
|
this.$notify({
|
|
@@ -1739,13 +1740,7 @@ export default {
|
|
this.closeQuesDialog();
|
|
this.closeQuesDialog();
|
|
this.initPaper();
|
|
this.initPaper();
|
|
})
|
|
})
|
|
- .catch((err) => {
|
|
|
|
- this.dialogLoading = false;
|
|
|
|
- this.$notify({
|
|
|
|
- type: "error",
|
|
|
|
- message: err.response.data.desc,
|
|
|
|
- });
|
|
|
|
- });
|
|
|
|
|
|
+ .finally(() => (this.dialogLoading = false));
|
|
}
|
|
}
|
|
},
|
|
},
|
|
//在正确的option上设置isCorrect=1
|
|
//在正确的option上设置isCorrect=1
|
|
@@ -1785,7 +1780,7 @@ export default {
|
|
callback: (action) => {
|
|
callback: (action) => {
|
|
if (action == "confirm") {
|
|
if (action == "confirm") {
|
|
this.loading = true;
|
|
this.loading = true;
|
|
- this.$http
|
|
|
|
|
|
+ this.$httpWithMsg
|
|
.delete(QUESTION_API + "/paperDetailUnit/" + paperDetailUnitId)
|
|
.delete(QUESTION_API + "/paperDetailUnit/" + paperDetailUnitId)
|
|
.then(() => {
|
|
.then(() => {
|
|
this.initPaper();
|
|
this.initPaper();
|
|
@@ -1796,8 +1791,8 @@ export default {
|
|
message: "删除成功",
|
|
message: "删除成功",
|
|
type: "success",
|
|
type: "success",
|
|
});
|
|
});
|
|
- this.loading = false;
|
|
|
|
- });
|
|
|
|
|
|
+ })
|
|
|
|
+ .finally(() => (this.loading = false));
|
|
}
|
|
}
|
|
},
|
|
},
|
|
});
|
|
});
|