From a8d0e805557e76395f8889a52c2bd2a4c226bb11 Mon Sep 17 00:00:00 2001 From: machuanyu <840649825@qq.com> Date: Wed, 23 Apr 2025 14:49:07 +0800 Subject: [PATCH] -- --- .../lib/common/utils/utils.dart | 15 +++++++++------ .../quick_data_check/widget/report_table.dart | 3 ++- 2 files changed, 11 insertions(+), 7 deletions(-) diff --git a/making_school_asignment_app/lib/common/utils/utils.dart b/making_school_asignment_app/lib/common/utils/utils.dart index bbbf694..4a040a9 100644 --- a/making_school_asignment_app/lib/common/utils/utils.dart +++ b/making_school_asignment_app/lib/common/utils/utils.dart @@ -340,7 +340,6 @@ class Utils { ]; Map optInfos = {}; - print('opt====${que.questionNo}'); for (var d in ques .where((w) => w.questionType == 1 && w.studentAnswer != null)) { final key = d.studentAnswer!; @@ -353,7 +352,8 @@ class Utils { List student = []; optInfos.forEach((key, value) { // optInfos[key] = Utils.calcRate(value, ques.length).round(); - List currentOptionStudents = data.students.where((s) => ques + List currentOptionStudents = data.students + .where((s) => ques .where( (w) => w.studentAnswer == key && w.studentId == s.studentId) .isNotEmpty) @@ -363,12 +363,15 @@ class Utils { List chars = upStr.split('')..sort(); String sortedStr = chars.join(); - student.add(SelectionRate(sortedStr, Utils.calcRate(value, ques.length).round(),false, currentOptionStudents)); + student.add(SelectionRate( + sortedStr, + Utils.calcRate(value, ques.length).round(), + false, + currentOptionStudents)); }); - print('optitems=$optInfos'); - /* var ARate = Utils.calcRate( + /* print('optitems=$optInfos'); + var ARate = Utils.calcRate( ques.where((w) => w.studentAnswer == "A").length, ques.length);*/ - que.options = student; } diff --git a/making_school_asignment_app/lib/page/home_page/children/quick_data_check/widget/report_table.dart b/making_school_asignment_app/lib/page/home_page/children/quick_data_check/widget/report_table.dart index df7360e..9ffe151 100644 --- a/making_school_asignment_app/lib/page/home_page/children/quick_data_check/widget/report_table.dart +++ b/making_school_asignment_app/lib/page/home_page/children/quick_data_check/widget/report_table.dart @@ -897,7 +897,8 @@ class _ReportTableState extends State { .r, horizontal: 8.r), - color:const Color(0xFFF0ECFF), + color: const Color( + 0xFFF0ECFF), child: quickText( e .studentName,