no message

This commit is contained in:
1147192855@qq.com 2024-03-13 18:27:16 +08:00
parent dd8ae7724a
commit c12976ded8
4 changed files with 80 additions and 34 deletions

View File

@ -233,7 +233,7 @@ Widget $completedHomeworkView(BuildContext context,
SizedBox(height: 20.h), SizedBox(height: 20.h),
Container( Container(
padding: EdgeInsets.symmetric(vertical: 8.h), padding: EdgeInsets.symmetric(vertical: 10.h),
decoration: BoxDecoration( decoration: BoxDecoration(
borderRadius: BorderRadius.only(bottomLeft: Radius.circular(6.r), bottomRight: Radius.circular(6.r)), borderRadius: BorderRadius.only(bottomLeft: Radius.circular(6.r), bottomRight: Radius.circular(6.r)),
color: Colors.white, color: Colors.white,
@ -259,7 +259,7 @@ Widget $completedHomeworkView(BuildContext context,
}), }),
child: Container( child: Container(
alignment: Alignment.center, alignment: Alignment.center,
child: quickText('查看报告', color: Color.fromRGBO(118, 118, 118, 1), size: 12.sp), child: quickText('查看报告', color: Color.fromRGBO(118, 118, 118, 1), size: 13.sp),
), ),
)), )),
]), ]),

View File

@ -1,6 +1,7 @@
import 'package:achievement_view/achievement_view.dart'; import 'package:achievement_view/achievement_view.dart';
import 'package:flutter/material.dart'; import 'package:flutter/material.dart';
import 'package:flutter_screenutil/flutter_screenutil.dart'; import 'package:flutter_screenutil/flutter_screenutil.dart';
import 'package:flutter_staggered_grid_view/flutter_staggered_grid_view.dart';
import 'package:functional_widget_annotation/functional_widget_annotation.dart'; import 'package:functional_widget_annotation/functional_widget_annotation.dart';
import 'package:marking_app/common/mixin/common.dart'; import 'package:marking_app/common/mixin/common.dart';
import 'package:marking_app/common/model/common/base_structure_result.dart'; import 'package:marking_app/common/model/common/base_structure_result.dart';
@ -40,10 +41,10 @@ class _JobListParticipateInClassState extends State<JobListParticipateInClass> w
getListOfJobFavoritesData(); getListOfJobFavoritesData();
_future = getData(); _future = getData();
Future.delayed(Duration.zero, () { // Future.delayed(Duration.zero, () {
print(ScreenUtil().scaleWidth); // print(ScreenUtil().scaleWidth);
print(MediaQuery.of(context).devicePixelRatio); // print(MediaQuery.of(context).devicePixelRatio);
}); // });
} }
@override @override
@ -428,6 +429,7 @@ class _JobListParticipateInClassState extends State<JobListParticipateInClass> w
jobViewReport: jobViewReport, jobViewReport: jobViewReport,
quickDataCheck: quickDataCheck, quickDataCheck: quickDataCheck,
oneClickReview: oneClickReview, oneClickReview: oneClickReview,
showStudentList: showStudentList,
); );
return MobileEnd( return MobileEnd(
@ -439,6 +441,7 @@ class _JobListParticipateInClassState extends State<JobListParticipateInClass> w
jobViewReport: jobViewReport, jobViewReport: jobViewReport,
quickDataCheck: quickDataCheck, quickDataCheck: quickDataCheck,
oneClickReview: oneClickReview, oneClickReview: oneClickReview,
showStudentList: showStudentList,
); );
}), }),
); );
@ -456,6 +459,7 @@ class TabletEnd extends StatelessWidget {
final JobViewReport jobViewReport; final JobViewReport jobViewReport;
final OneClickReview oneClickReview; // final OneClickReview oneClickReview; //
final QuickDataCheck quickDataCheck; // final QuickDataCheck quickDataCheck; //
final ShowStudentList showStudentList;
const TabletEnd({ const TabletEnd({
required this.genderName, required this.genderName,
required this.data, required this.data,
@ -467,6 +471,7 @@ class TabletEnd extends StatelessWidget {
required this.jobViewReport, required this.jobViewReport,
required this.oneClickReview, required this.oneClickReview,
required this.quickDataCheck, required this.quickDataCheck,
required this.showStudentList,
super.key, super.key,
}); });
@ -475,22 +480,43 @@ class TabletEnd extends StatelessWidget {
return Container( return Container(
width: ScreenUtil().screenWidth, width: ScreenUtil().screenWidth,
padding: EdgeInsets.symmetric(horizontal: 12.w, vertical: 16.h), padding: EdgeInsets.symmetric(horizontal: 12.w, vertical: 16.h),
child: Wrap( child: MasonryGridView.count(
spacing: 8.0.w, // crossAxisCount: 2, //
runSpacing: 10.h, // mainAxisSpacing: 4.w, //
children: data crossAxisSpacing: 4.h, //
.map((e) => $ItemDataViewOfPad( itemCount: data.length,
task: e, itemBuilder: (context, index) {
bookmarks: bookmarks, var e = data[index];
endReview: endReview, return $ItemDataViewOfPad(
genderName: genderName, task: e,
goToReview: goToReview, bookmarks: bookmarks,
jobViewReport: jobViewReport, endReview: endReview,
quickDataCheck: quickDataCheck, genderName: genderName,
oneClickReview: oneClickReview, goToReview: goToReview,
)) jobViewReport: jobViewReport,
.toList(), quickDataCheck: quickDataCheck,
oneClickReview: oneClickReview,
showStudentList: showStudentList,
);
},
), ),
// Wrap(
// spacing: 8.0.w, //
// runSpacing: 10.h, //
// children: [...data, ...data]
// .map((e) => $ItemDataViewOfPad(
// task: e,
// bookmarks: bookmarks,
// endReview: endReview,
// genderName: genderName,
// goToReview: goToReview,
// jobViewReport: jobViewReport,
// quickDataCheck: quickDataCheck,
// oneClickReview: oneClickReview,
// showStudentList: showStudentList,
// ))
// .toList(),
// ),
); );
} }
} }
@ -858,7 +884,7 @@ class MobileEndCompleted extends StatelessWidget {
), ),
), ),
), ),
Container(width: 1.w, height: 34.h, color: Color.fromRGBO(221, 221, 221, 1)), Container(width: 1.w, height: 36.h, color: Color.fromRGBO(221, 221, 221, 1)),
Expanded( Expanded(
child: InkWell( child: InkWell(
onTap: () => easyThrottle('go_to_end_review_homework', () => jobViewReport(task)), onTap: () => easyThrottle('go_to_end_review_homework', () => jobViewReport(task)),
@ -878,7 +904,7 @@ class MobileEndCompleted extends StatelessWidget {
), ),
), ),
), ),
Container(width: 1.w, height: 32.h, color: Color.fromRGBO(221, 221, 221, 1)), Container(width: 1.w, height: 36.h, color: Color.fromRGBO(221, 221, 221, 1)),
Expanded( Expanded(
child: InkWell( child: InkWell(
onTap: () => easyThrottle('go_to_end_review_homework', () => {}), onTap: () => easyThrottle('go_to_end_review_homework', () => {}),
@ -908,6 +934,7 @@ class MobileEnd extends StatelessWidget {
final JobViewReport jobViewReport; final JobViewReport jobViewReport;
final OneClickReview oneClickReview; // final OneClickReview oneClickReview; //
final QuickDataCheck quickDataCheck; // final QuickDataCheck quickDataCheck; //
final ShowStudentList showStudentList; //
const MobileEnd({ const MobileEnd({
required this.genderName, required this.genderName,
@ -920,6 +947,7 @@ class MobileEnd extends StatelessWidget {
required this.jobViewReport, required this.jobViewReport,
required this.oneClickReview, required this.oneClickReview,
required this.quickDataCheck, required this.quickDataCheck,
required this.showStudentList,
super.key, super.key,
}); });
@ -937,6 +965,7 @@ class MobileEnd extends StatelessWidget {
jobViewReport: jobViewReport, jobViewReport: jobViewReport,
quickDataCheck: quickDataCheck, quickDataCheck: quickDataCheck,
oneClickReview: oneClickReview, oneClickReview: oneClickReview,
showStudentList: showStudentList,
); );
}).toList(), }).toList(),
); );
@ -957,6 +986,7 @@ Widget $itemDataViewOfPad(
required JobViewReport jobViewReport, required JobViewReport jobViewReport,
required OneClickReview oneClickReview, required OneClickReview oneClickReview,
required QuickDataCheck quickDataCheck, required QuickDataCheck quickDataCheck,
required ShowStudentList showStudentList,
}) { }) {
EdgeInsets edgins = EdgeInsets.only(left: 8.w, right: 8.w); EdgeInsets edgins = EdgeInsets.only(left: 8.w, right: 8.w);
return Container( return Container(
@ -976,10 +1006,16 @@ Widget $itemDataViewOfPad(
children: [ children: [
quickText(genderName + task.className, color: Color.fromRGBO(0, 0, 0, 1), size: 10.sp), quickText(genderName + task.className, color: Color.fromRGBO(0, 0, 0, 1), size: 10.sp),
Expanded(child: SizedBox()), Expanded(child: SizedBox()),
quickText('已交:${task.commitStudentCount}', color: Color.fromRGBO(104, 136, 253, 1), size: 8.sp), InkWell(
onTap: () => easyThrottle('OneClickReview', () => showStudentList([task.id], task.className, true)),
child: quickText('已交:${task.commitStudentCount}', color: Color.fromRGBO(104, 136, 253, 1), size: 8.sp),
),
SizedBox(width: 10.w), SizedBox(width: 10.w),
quickText('未交:${task.studentCount - task.commitStudentCount}', InkWell(
color: Color.fromRGBO(255, 86, 86, 1), size: 8.sp), onTap: () => easyThrottle('OneClickReview', () => showStudentList([task.id], task.className)),
child: quickText('未交:${task.studentCount - task.commitStudentCount}',
color: Color.fromRGBO(255, 86, 86, 1), size: 8.sp),
),
], ],
), ),
), ),
@ -1159,7 +1195,7 @@ Widget $itemDataViewOfPad(
), ),
), ),
), ),
Container(width: 1.w, height: 32.h, color: Color.fromRGBO(221, 221, 221, 1)), Container(width: 1.w, height: 30.h, color: Color.fromRGBO(221, 221, 221, 1)),
Expanded( Expanded(
child: InkWell( child: InkWell(
onTap: () => easyThrottle('go_to_end_review_homework', () => jobViewReport(task)), onTap: () => easyThrottle('go_to_end_review_homework', () => jobViewReport(task)),
@ -1179,7 +1215,7 @@ Widget $itemDataViewOfPad(
), ),
), ),
), ),
Container(width: 0.3.w, height: 24.h, color: Color.fromRGBO(221, 221, 221, 1)), Container(width: 0.3.w, height: 30.h, color: Color.fromRGBO(221, 221, 221, 1)),
Expanded( Expanded(
child: InkWell( child: InkWell(
onTap: () => easyThrottle('go_to_end_review_homework', () => endReview(task)), onTap: () => easyThrottle('go_to_end_review_homework', () => endReview(task)),
@ -1210,10 +1246,12 @@ Widget $itemDataView(
required OneClickReview oneClickReview, required OneClickReview oneClickReview,
required QuickDataCheck quickDataCheck, required QuickDataCheck quickDataCheck,
required JobViewReport jobViewReport, required JobViewReport jobViewReport,
required ShowStudentList showStudentList,
}) { }) {
var padingEdg = EdgeInsets.only(left: 10.w, right: 10.w); var padingEdg = EdgeInsets.only(left: 10.w, right: 10.w);
return Container( return Container(
padding: EdgeInsets.only(top: 11.h), padding: EdgeInsets.only(top: 11.h),
margin: EdgeInsets.only(bottom: 12.h),
decoration: BoxDecoration( decoration: BoxDecoration(
color: Colors.white, color: Colors.white,
borderRadius: BorderRadiusDirectional.circular(10.r), borderRadius: BorderRadiusDirectional.circular(10.r),
@ -1228,10 +1266,17 @@ Widget $itemDataView(
children: [ children: [
quickText(genderName + task.className, color: Color.fromRGBO(0, 0, 0, 1), size: 14.sp), quickText(genderName + task.className, color: Color.fromRGBO(0, 0, 0, 1), size: 14.sp),
Expanded(child: SizedBox()), Expanded(child: SizedBox()),
quickText('已交:${task.commitStudentCount}', color: Color.fromRGBO(104, 136, 253, 1), size: 12.sp), InkWell(
onTap: () => easyThrottle('OneClickReview', () => showStudentList([task.id], task.className, true)),
child:
quickText('已交:${task.commitStudentCount}', color: Color.fromRGBO(104, 136, 253, 1), size: 12.sp),
),
SizedBox(width: 16.w), SizedBox(width: 16.w),
quickText('未交:${task.studentCount - task.commitStudentCount}', InkWell(
color: Color.fromRGBO(255, 86, 86, 1), size: 12.sp), onTap: () => easyThrottle('OneClickReview', () => showStudentList([task.id], task.className)),
child: quickText('未交:${task.studentCount - task.commitStudentCount}',
color: Color.fromRGBO(255, 86, 86, 1), size: 12.sp),
),
], ],
), ),
), ),
@ -1415,7 +1460,7 @@ Widget $itemDataView(
), ),
), ),
), ),
Container(width: 1.w, height: 32.h, color: Color.fromRGBO(221, 221, 221, 1)), Container(width: 1.w, height: 36.h, color: Color.fromRGBO(221, 221, 221, 1)),
Expanded( Expanded(
child: InkWell( child: InkWell(
onTap: () => easyThrottle('go_to_end_review_homework', () => jobViewReport(task)), onTap: () => easyThrottle('go_to_end_review_homework', () => jobViewReport(task)),
@ -1435,7 +1480,7 @@ Widget $itemDataView(
), ),
), ),
), ),
Container(width: 1.w, height: 32.h, color: Color.fromRGBO(221, 221, 221, 1)), Container(width: 1.w, height: 36.h, color: Color.fromRGBO(221, 221, 221, 1)),
Expanded( Expanded(
child: InkWell( child: InkWell(
onTap: () => easyThrottle('go_to_end_review_homework', () => endReview(task)), onTap: () => easyThrottle('go_to_end_review_homework', () => endReview(task)),

View File

@ -299,7 +299,7 @@ abstract class RestClient {
@the_retrofit.Query("markingId") int jobId); @the_retrofit.Query("markingId") int jobId);
// => // =>
@the_retrofit.GET("${RequestConfig.hwProxyKeywords}/dpc-api/api/read/job-favorite-count-by-class") @the_retrofit.GET("/dpc-api/api/read/job-favorite-count-by-class")
Future<BaseStructureResult<List<JobFavoriteModel>>> getListOfJobFavoriteNumber( Future<BaseStructureResult<List<JobFavoriteModel>>> getListOfJobFavoriteNumber(
@the_retrofit.Query("jobid") int jobId); @the_retrofit.Query("jobid") int jobId);

View File

@ -111,6 +111,7 @@ dependencies:
horizontal_data_table: ^4.1.1 horizontal_data_table: ^4.1.1
data_table_2: ^2.5.10 data_table_2: ^2.5.10
syncfusion_flutter_datepicker: ^21.2.10 syncfusion_flutter_datepicker: ^21.2.10
flutter_staggered_grid_view: ^0.6.2
dev_dependencies: dev_dependencies:
flutter_test: flutter_test: