protected override void Statistics() { ReadyCheckAnswers.ForEach(s => { s.FinalScore = TeacherChecks.SingleOrDefault().Score[s.QuestionInfo.QuestionId.ToString()]; }); IsAllFinish = true; }
protected override void Statistics() { if (ThirdCounter < 2) { return; } if (!IsArbitration) { // IsAllow = OnlineHelper.GetMinThreshold(TeacherChecks.Select(s => s.Score).ToArray()) > Threshold; Boolean flag = false; foreach (var readyCheckAnswer in ReadyCheckAnswers) { Double f = OnlineHelper.GetMinThreshold( TeacherChecks.Select(s => s.Score[readyCheckAnswer.QuestionInfo.QuestionId.ToString()]).ToArray()); flag = flag || f > readyCheckAnswer.QuestionInfo.Threshold; if (flag) { break; } } IsAllow = flag; if (IsAllow) { EnoughCount = EnoughCount + 1; if (ThirdCounter == 3) { IsArbitration = true; IsAllow = false; } return; } } IsAllFinish = true; ReadyCheckAnswers.ForEach(s => { s.FinalScore = TeacherChecks.Capacity == TeacherChecks.Count ? TeacherChecks.Last().Score[s.AnswerId] : OnlineHelper.GetMiddleScore(TeacherChecks.Select(a => a.Score[s.QuestionInfo.QuestionId.ToString()]).ToArray()); }); //FinalScore = TeacherChecks.Capacity == TeacherChecks.Count // ? TeacherChecks.Last().Score // : OnlineHelper.GetMiddleScore(TeacherChecks.Select(s => s.Score).ToArray()); }
protected override void Statistics() { if (ThirdCounter != TeacherChecks.Capacity) { return; } ReadyCheckAnswers.ForEach(s => { s.FinalScore = TeacherChecks.Average(a => a.Score[s.QuestionInfo.QuestionId.ToString()]); }); IsAllFinish = true; }
/// <summary> /// 对问题卷进行处理 /// </summary> /// <param name="teacherCheck"></param> public void SetFinalScoreForDoubt(TeacherCheck teacherCheck) { if (!IsDoubt && IsAllFinish) { return; } ReadyCheckAnswers.ForEach(s => { s.FinalScore = teacherCheck.Score[s.QuestionInfo.QuestionId.ToString()]; }); TeacherChecks.Add(teacherCheck); IsAllFinish = true; }
protected override void Statistics() { if (ThirdCounter < 2) { return; } if (ThirdCounter == 2) { Boolean flag = false; foreach (var readyCheckAnswer in ReadyCheckAnswers) { Boolean a = (OnlineHelper.GetMinThreshold( TeacherChecks.Select(s => s.Score[readyCheckAnswer.QuestionInfo.QuestionId.ToString()]).ToArray()) > readyCheckAnswer.QuestionInfo.Threshold); flag = flag || a; if (flag) { break;; } } IsAllow = flag; // IsAllow = OnlineHelper.GetMinThreshold(TeacherChecks.Select(s => s.Score).ToArray()) > Threshold; if (IsAllow) { EnoughCount = EnoughCount + 1; return; } } IsAllFinish = true; ReadyCheckAnswers.ForEach(s => { s.FinalScore = OnlineHelper.GetMiddleScore(TeacherChecks.Select(a => a.Score[s.QuestionInfo.QuestionId.ToString()]).ToArray()); }); //FinalScore = OnlineHelper.GetMiddleScore(TeacherChecks.Select(s => s.Score).ToArray()); }