作业批阅:习题训练类型 新增客观题自动批阅逻辑更改
This commit is contained in:
parent
7c9b2755f2
commit
743d8e05d3
|
@ -390,17 +390,29 @@ const getClassWorkStudentList = (rowId) => {
|
|||
tableRadio.value = '1'
|
||||
tableRadio.num0 = classWorkAnalysis.classworkdata.length - tableRadio.list.length
|
||||
tableRadio.num1 = tableRadio.list.length
|
||||
tableRadio.list = tableRadio.list.map((item) => {
|
||||
return {
|
||||
...item,
|
||||
teacherRating : checkWorkType(item)
|
||||
}
|
||||
})
|
||||
// 自动批阅判断
|
||||
teacherCriticism();
|
||||
})
|
||||
.catch(() => {
|
||||
loading_dt_table.value = false
|
||||
})
|
||||
}
|
||||
/**
|
||||
* 自动批阅判断:
|
||||
* 已交 并 作业类型为习题训练
|
||||
*/
|
||||
const teacherCriticism = ()=>{
|
||||
// 已交的list才自动批阅判断
|
||||
if(tableRadio.value == '1'&& classWorkAnalysis.worktype == '习题训练'){
|
||||
// 只有习题训练才会自动批阅
|
||||
tableRadio.list = tableRadio.list.map((item) => {
|
||||
return {
|
||||
...item,
|
||||
teacherRating : checkWorkType(item)
|
||||
}
|
||||
})
|
||||
}
|
||||
}
|
||||
const checkWorkType = (item) => {
|
||||
//这里判断题目类型
|
||||
const subType = classWorkActiveData.quizlist.map(item => item.worktype)
|
||||
|
@ -408,7 +420,7 @@ const checkWorkType = (item) => {
|
|||
let rating = 0
|
||||
//判断题目是不是客观题
|
||||
if(subType.every(item => objectiveQuestion.includes(item))){
|
||||
// 获取学生答题列表
|
||||
// 获取学生答题列表 scoingRate 得分率
|
||||
const score = extractedNumber(item.scoingRate)
|
||||
if(0<=score && score<=59){
|
||||
rating = 5
|
||||
|
@ -551,6 +563,8 @@ const tableRadioChange = (e) => {
|
|||
tableRadio.value = '1';
|
||||
tableRadio.num0 = classWorkAnalysis.classworkdata.length - tableRadio.list.length;
|
||||
tableRadio.num1 = tableRadio.list.length;
|
||||
// 自动批阅判断
|
||||
teacherCriticism();
|
||||
}else if(e=='0'){
|
||||
tableRadio.list = classWorkAnalysis.classworkdata.filter(item => item.finishtimelength == '0')
|
||||
tableRadio.value = '0';
|
||||
|
|
Loading…
Reference in New Issue