组卷策略提交限制

This commit is contained in:
Yjhon 2022-04-14 17:39:31 +08:00
parent 2d4150b21b
commit f5eff86650
1 changed files with 10 additions and 0 deletions

View File

@ -150,6 +150,11 @@ export default {
//
toSave() {
this.form.testPaperTactics = this.tableData.filter((Item) => { return Item.topicNum && Item.topicScore });
console.log('testPaperTactics',this.form.testPaperTactics,this.form.testPaperTactics.length)
if (this.form.testPaperTactics.length == 0) {
this.$message.error("组卷策略详情数据不能为空,如当前列表为空,请返回“选择课程”页面添加有题目的课程");
return;
}
this.form.projectStatus = 1
this.$refs.form.validate(validate => {
if (validate) {
@ -160,6 +165,11 @@ export default {
//
toIssue() {
this.form.testPaperTactics = this.tableData.filter((Item) => { return Item.topicNum && Item.topicScore });
console.log('testPaperTactics',this.form.testPaperTactics,this.form.testPaperTactics.length)
if (this.form.testPaperTactics.length == 0) {
this.$message.error("组卷策略详情数据不能为空,如当前列表为空,请返回”课程选择“页面添加有题目的课程");
return;
}
this.form.projectStatus = 2
this.$refs.form.validate(validate => {
if (validate) {