Commit af1f344c authored by 李苏's avatar 李苏 💬

count

parent 60f4e679
......@@ -35,7 +35,7 @@
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item :rules="[{ required: false,pattern: /^[1-9]\d*$/,message: '请输入大于0的整数!'}]" label="单选题分值" ref="sscore" prop="sscore">
<el-form-item :rules="[{ required: (form.scount>0)?true:false,message: '请输入大于0的整数!'}]" label="单选题分值" ref="sscore" prop="sscore">
<el-input type="number" :readonly="readonly" v-model="form.sscore" ></el-input>
</el-form-item>
</el-col>
......@@ -45,7 +45,7 @@
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item :rules="[{ required: false,pattern: /^[1-9]\d*$/,message: '请输入大于0的整数!'}]" label="多选题分值" ref="mscore" prop="mscore">
<el-form-item :rules="[{ required: (form.mcount>0)?true:false,message: '请输入大于0的整数!'}]" label="多选题分值" ref="mscore" prop="mscore">
<el-input type="number" :readonly="readonly" v-model="form.mscore" ></el-input>
</el-form-item>
</el-col>
......@@ -57,7 +57,7 @@
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item :rules="[{ required: false,pattern: /^[1-9]\d*$/,message: '请输入大于0的整数!'}]" label="判断题分值" ref="jscore" prop="jscore">
<el-form-item :rules="[{ required:(form.jcount>0)?true:false,message: '请输入大于0的整数!'}]" label="判断题分值" ref="jscore" prop="jscore">
<el-input type="number" :readonly="readonly" v-model="form.jscore" ></el-input>
</el-form-item>
</el-col>
......@@ -67,7 +67,7 @@
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item :rules="[{ required: false,pattern: /^[1-9]\d*$/,message: '请输入大于0的整数!'}]" label="填空题分值" ref="fscore" prop="fscore">
<el-form-item :rules="[{ required:(form.fcount>0)?true:false,message: '请输入大于0的整数!'}]" label="填空题分值" ref="fscore" prop="fscore">
<el-input type="number" :readonly="readonly" v-model="form.fscore" ></el-input>
</el-form-item>
</el-col>
......@@ -229,19 +229,19 @@
//总分
score:'',
//单选题量
scount:'',
scount:'0',
//单选题分值
sscore:'0',
//多选题量
mcount:'',
mcount:'0',
//多选题分值
mscore:'0',
//判断题量
jcount:'',
jcount:'0',
//判断题分值
jscore:'0',
//填空题量
fcount:'',
fcount:'0',
//填空题分值
fscore:'0',
//考试时长
......@@ -279,16 +279,16 @@
required: true,
trigger: 'blur'
}, ],
// jssj: [{
// required: true,
// trigger: 'blur'
// }, ],
// kssc:[
// {
// required: true,
// trigger: 'blur'
// }
// ],
jssj: [{
required: true,
trigger: 'blur'
}, ],
kssc:[
{
required: true,
trigger: 'blur'
}
],
}
}
},
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment