|
|
@ -129,15 +129,34 @@ public class EvaluationRecordController implements EvaluationRecordControllerApi |
|
|
|
@Override |
|
|
|
@Override |
|
|
|
@GetMapping("/openExercise") |
|
|
|
@GetMapping("/openExercise") |
|
|
|
public R isOpenExercise(Integer userId){ |
|
|
|
public R isOpenExercise(Integer userId){ |
|
|
|
Integer score = fractionEntityService.queryExerciseRecord(userId); |
|
|
|
Integer id = fractionEntityService.queryScore(userId); |
|
|
|
return R.ok(); |
|
|
|
if (id>0){ |
|
|
|
|
|
|
|
Integer score = fractionEntityService.queryExerciseRecord(userId); |
|
|
|
|
|
|
|
if (score>=60){ |
|
|
|
|
|
|
|
return R.ok("true"); |
|
|
|
|
|
|
|
}else{ |
|
|
|
|
|
|
|
return R.error("false"); |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
}else{ |
|
|
|
|
|
|
|
return R.error("false"); |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
@Override |
|
|
|
@Override |
|
|
|
@GetMapping("/openTeaching") |
|
|
|
@GetMapping("/openTeaching") |
|
|
|
public R isOpenTeaching(Integer userId){ |
|
|
|
public R isOpenTeaching(Integer userId){ |
|
|
|
Integer score = fractionEntityService.queryTeachingRecord(userId); |
|
|
|
Integer id = fractionEntityService.queryScore(userId); |
|
|
|
return R.ok(); |
|
|
|
if (id>0){ |
|
|
|
|
|
|
|
Integer score = fractionEntityService.queryTeachingRecord(userId); |
|
|
|
|
|
|
|
if (score>=60){ |
|
|
|
|
|
|
|
return R.ok("true"); |
|
|
|
|
|
|
|
}else{ |
|
|
|
|
|
|
|
return R.error("false"); |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
}else{ |
|
|
|
|
|
|
|
return R.error("false"); |
|
|
|
|
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
//// @Override
|
|
|
|
//// @Override
|
|
|
|