Merge pull request '作业批阅:习题训练类型 新增客观题自动批阅逻辑更改' (#371) from baigl into main

Reviewed-on: #371
This commit is contained in:
baigl 2024-10-28 10:50:14 +08:00
commit 346b07e47a
1 changed files with 21 additions and 7 deletions

View File

@ -390,16 +390,28 @@ const getClassWorkStudentList = (rowId) => {
tableRadio.value = '1'
tableRadio.num0 = classWorkAnalysis.classworkdata.length - tableRadio.list.length
tableRadio.num1 = tableRadio.list.length
//
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)
}
})
})
.catch(() => {
loading_dt_table.value = false
})
}
}
const checkWorkType = (item) => {
//
@ -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';