job_report_revision #2
|
|
@ -0,0 +1,23 @@
|
||||||
|
import 'package:json_annotation/json_annotation.dart';
|
||||||
|
|
||||||
|
part 'job_level_set_params.g.dart';
|
||||||
|
|
||||||
|
|
||||||
|
@JsonSerializable()
|
||||||
|
class JobLevelSetParams extends Object {
|
||||||
|
|
||||||
|
@JsonKey(name: 'studentGroupDetailId')
|
||||||
|
int studentGroupDetailId;
|
||||||
|
|
||||||
|
@JsonKey(name: 'readLevel')
|
||||||
|
int readLevel;
|
||||||
|
|
||||||
|
JobLevelSetParams(this.studentGroupDetailId,this.readLevel,);
|
||||||
|
|
||||||
|
factory JobLevelSetParams.fromJson(Map<String, dynamic> srcJson) => _$JobLevelSetParamsFromJson(srcJson);
|
||||||
|
|
||||||
|
Map<String, dynamic> toJson() => _$JobLevelSetParamsToJson(this);
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
@ -0,0 +1,26 @@
|
||||||
|
import 'package:json_annotation/json_annotation.dart';
|
||||||
|
|
||||||
|
part "job_student_goups.g.dart";
|
||||||
|
|
||||||
|
|
||||||
|
@JsonSerializable()
|
||||||
|
class JobStudentGroups extends Object {
|
||||||
|
|
||||||
|
@JsonKey(name: 'groupId')
|
||||||
|
int groupId;
|
||||||
|
|
||||||
|
@JsonKey(name: 'groupName')
|
||||||
|
String groupName;
|
||||||
|
|
||||||
|
@JsonKey(name: 'classNames')
|
||||||
|
List<String> classNames;
|
||||||
|
|
||||||
|
JobStudentGroups(this.groupId,this.groupName,this.classNames,);
|
||||||
|
|
||||||
|
factory JobStudentGroups.fromJson(Map<String, dynamic> srcJson) => _$JobStudentGroupsFromJson(srcJson);
|
||||||
|
|
||||||
|
Map<String, dynamic> toJson() => _$JobStudentGroupsToJson(this);
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
@ -0,0 +1,32 @@
|
||||||
|
import 'package:json_annotation/json_annotation.dart';
|
||||||
|
|
||||||
|
part 'job_student_level.g.dart';
|
||||||
|
|
||||||
|
|
||||||
|
@JsonSerializable()
|
||||||
|
class JobStudentLevel extends Object {
|
||||||
|
|
||||||
|
@JsonKey(name: 'studentGroupDetailId')
|
||||||
|
int studentGroupDetailId;
|
||||||
|
|
||||||
|
@JsonKey(name: 'studentId')
|
||||||
|
int studentId;
|
||||||
|
|
||||||
|
@JsonKey(name: 'studentName')
|
||||||
|
String studentName;
|
||||||
|
|
||||||
|
@JsonKey(name: 'createTime')
|
||||||
|
String createTime;
|
||||||
|
|
||||||
|
@JsonKey(name: 'readLevel')
|
||||||
|
int readLevel;
|
||||||
|
|
||||||
|
JobStudentLevel(this.studentGroupDetailId,this.studentId,this.studentName,this.createTime,this.readLevel,);
|
||||||
|
|
||||||
|
factory JobStudentLevel.fromJson(Map<String, dynamic> srcJson) => _$JobStudentLevelFromJson(srcJson);
|
||||||
|
|
||||||
|
Map<String, dynamic> toJson() => _$JobStudentLevelToJson(this);
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
@ -261,7 +261,7 @@ class _HomeworkCorrectionState extends ConsumerState<HomeworkCorrection>
|
||||||
flex: 1,
|
flex: 1,
|
||||||
child: InkWell(
|
child: InkWell(
|
||||||
onTap: () {
|
onTap: () {
|
||||||
RouterManager.router.navigateTo(context, RouterManager.jobPriorityReviewSetPath,transition: getTransition());
|
RouterManager.router.navigateTo(context, RouterManager.jobStudentGroupPath,transition: getTransition());
|
||||||
},
|
},
|
||||||
child: Icon(Icons.settings_outlined, color: Color.fromRGBO(44, 48, 63, 1), size: 24.sp),
|
child: Icon(Icons.settings_outlined, color: Color.fromRGBO(44, 48, 63, 1), size: 24.sp),
|
||||||
),
|
),
|
||||||
|
|
|
||||||
|
|
@ -1,26 +1,62 @@
|
||||||
import 'package:flutter/material.dart';
|
import 'package:flutter/material.dart';
|
||||||
|
import 'package:flutter_easyloading/flutter_easyloading.dart';
|
||||||
import 'package:flutter_easyrefresh/easy_refresh.dart';
|
import 'package:flutter_easyrefresh/easy_refresh.dart';
|
||||||
import 'package:flutter_screenutil/flutter_screenutil.dart';
|
import 'package:flutter_screenutil/flutter_screenutil.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/job/job_level_set_params.dart';
|
||||||
|
import 'package:marking_app/common/model/job/job_review_submission.dart';
|
||||||
|
import 'package:marking_app/common/model/job/job_student_level.dart';
|
||||||
|
import 'package:marking_app/utils/easy_refresh/MyEmptyWidget.dart';
|
||||||
|
import 'package:marking_app/utils/index.dart';
|
||||||
|
import 'package:marking_app/utils/request/rest_client.dart';
|
||||||
|
|
||||||
class JobPriorityReviewSet extends StatefulWidget {
|
class JobPriorityReviewSet extends StatefulWidget {
|
||||||
const JobPriorityReviewSet({Key? key}) : super(key: key);
|
final String groupId;
|
||||||
|
const JobPriorityReviewSet({Key? key,required this.groupId}) : super(key: key);
|
||||||
|
|
||||||
@override
|
@override
|
||||||
State<JobPriorityReviewSet> createState() => _JobPriorityReviewSetState();
|
State<JobPriorityReviewSet> createState() => _JobPriorityReviewSetState();
|
||||||
}
|
}
|
||||||
|
|
||||||
class _JobPriorityReviewSetState extends State<JobPriorityReviewSet>
|
class _JobPriorityReviewSetState extends State<JobPriorityReviewSet>
|
||||||
with SingleTickerProviderStateMixin {
|
with CommonMixin,SingleTickerProviderStateMixin {
|
||||||
late final EasyRefreshController refreshController;
|
late final EasyRefreshController refreshController;
|
||||||
late TabController tabController;
|
late TabController tabController;
|
||||||
int tabIndex = 0;
|
int tabIndex = 0;
|
||||||
|
List levelList = [];
|
||||||
|
|
||||||
@override
|
@override
|
||||||
void initState() {
|
void initState() {
|
||||||
super.initState();
|
super.initState();
|
||||||
|
EasyLoading.show(status: 'loading...');
|
||||||
refreshController = EasyRefreshController();
|
refreshController = EasyRefreshController();
|
||||||
tabController =
|
tabController =
|
||||||
TabController(initialIndex: tabIndex, length: 2, vsync: this);
|
TabController(initialIndex: tabIndex, length: 2, vsync: this);
|
||||||
|
getReadLevel();
|
||||||
|
}
|
||||||
|
|
||||||
|
void getReadLevel() async{
|
||||||
|
RestClient _client = await getClient();
|
||||||
|
BaseStructureResult<List<JobStudentLevel>> res = await _client.getJobReadLevel(widget.groupId,tabIndex == 0?1:0);
|
||||||
|
setState(() {
|
||||||
|
if(res.code == 200){
|
||||||
|
levelList = res.data!;
|
||||||
|
}else{
|
||||||
|
levelList = [];
|
||||||
|
}
|
||||||
|
EasyLoading.dismiss();
|
||||||
|
});
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
void setJobReadLevel(int studentId,int level) async{
|
||||||
|
RestClient _client = await getClient();
|
||||||
|
JobLevelSetParams params = JobLevelSetParams(studentId, level);
|
||||||
|
BaseStructureResult res = await _client.getSetJobReadLevel(params);
|
||||||
|
if(res.code == 200){
|
||||||
|
getReadLevel();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@override
|
@override
|
||||||
|
|
@ -32,6 +68,7 @@ class _JobPriorityReviewSetState extends State<JobPriorityReviewSet>
|
||||||
|
|
||||||
@override
|
@override
|
||||||
Widget build(BuildContext context) {
|
Widget build(BuildContext context) {
|
||||||
|
bool isPadFlag = isPad();
|
||||||
return Scaffold(
|
return Scaffold(
|
||||||
backgroundColor: Color.fromRGBO(245, 245, 245, 1),
|
backgroundColor: Color.fromRGBO(245, 245, 245, 1),
|
||||||
appBar: AppBar(
|
appBar: AppBar(
|
||||||
|
|
@ -46,25 +83,19 @@ class _JobPriorityReviewSetState extends State<JobPriorityReviewSet>
|
||||||
onPressed: () => Navigator.of(context).pop(),
|
onPressed: () => Navigator.of(context).pop(),
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
body: EasyRefresh(
|
body: Column(
|
||||||
firstRefresh: true,
|
|
||||||
taskIndependence: true,
|
|
||||||
enableControlFinishLoad: true,
|
|
||||||
enableControlFinishRefresh: true,
|
|
||||||
// emptyWidget: data.isEmpty ? const MyEmptyWidget() : null,
|
|
||||||
controller: refreshController,
|
|
||||||
header: MaterialHeader(),
|
|
||||||
footer: TaurusFooter(),
|
|
||||||
child: Column(
|
|
||||||
crossAxisAlignment: CrossAxisAlignment.start,
|
crossAxisAlignment: CrossAxisAlignment.start,
|
||||||
children: [
|
children: [
|
||||||
Padding(
|
Padding(
|
||||||
padding: EdgeInsets.symmetric(horizontal: 14.r),
|
padding: EdgeInsets.symmetric(horizontal: 14.r),
|
||||||
child: TabBar(
|
child: TabBar(
|
||||||
onTap: (int val) {
|
onTap: (int val) {
|
||||||
|
print(val);
|
||||||
setState(() {
|
setState(() {
|
||||||
tabIndex = val;
|
tabIndex = val;
|
||||||
});
|
});
|
||||||
|
EasyLoading.show(status: 'loading...');
|
||||||
|
getReadLevel();
|
||||||
},
|
},
|
||||||
tabs: [
|
tabs: [
|
||||||
SizedBox(
|
SizedBox(
|
||||||
|
|
@ -94,7 +125,26 @@ class _JobPriorityReviewSetState extends State<JobPriorityReviewSet>
|
||||||
labelPadding: const EdgeInsets.all(0),
|
labelPadding: const EdgeInsets.all(0),
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
Container(
|
Expanded(
|
||||||
|
child:Padding(
|
||||||
|
padding: EdgeInsets.symmetric(vertical:14.r,horizontal: 14.r),
|
||||||
|
child: EasyRefresh(
|
||||||
|
firstRefresh: true,
|
||||||
|
taskIndependence: true,
|
||||||
|
enableControlFinishLoad: true,
|
||||||
|
enableControlFinishRefresh: true,
|
||||||
|
// emptyWidget: data.isEmpty ? const MyEmptyWidget() : null,
|
||||||
|
controller: refreshController,
|
||||||
|
header: MaterialHeader(),
|
||||||
|
footer: TaurusFooter(),
|
||||||
|
child: levelList.length>0?isPadFlag?GridView(gridDelegate: SliverGridDelegateWithFixedCrossAxisCount(
|
||||||
|
crossAxisCount: 2,
|
||||||
|
mainAxisSpacing: 10.r,
|
||||||
|
crossAxisSpacing: 10.r,
|
||||||
|
childAspectRatio: 556 / 112,
|
||||||
|
),children: List.generate(levelList.length, (index) {
|
||||||
|
JobStudentLevel item = levelList[index];
|
||||||
|
return Container(
|
||||||
padding: EdgeInsets.symmetric(horizontal: 15.r),
|
padding: EdgeInsets.symmetric(horizontal: 15.r),
|
||||||
decoration: BoxDecoration(
|
decoration: BoxDecoration(
|
||||||
borderRadius: BorderRadius.all(Radius.circular(10.r)),
|
borderRadius: BorderRadius.all(Radius.circular(10.r)),
|
||||||
|
|
@ -103,23 +153,101 @@ class _JobPriorityReviewSetState extends State<JobPriorityReviewSet>
|
||||||
child: Row(
|
child: Row(
|
||||||
mainAxisAlignment: MainAxisAlignment.spaceBetween,
|
mainAxisAlignment: MainAxisAlignment.spaceBetween,
|
||||||
children: [
|
children: [
|
||||||
Text('张小凡',style: TextStyle(fontSize: 12.sp,color: Color(0xFF6888FD)),),
|
Text(item.studentName,style: TextStyle(fontSize: 12.sp,color: Color(0xFF6888FD)),),
|
||||||
Container(
|
tabIndex == 0?InkWell(
|
||||||
padding: EdgeInsets.symmetric(vertical: 2.r,horizontal: 10.r),
|
onTap: (){
|
||||||
|
setJobReadLevel(item.studentGroupDetailId,0);
|
||||||
|
EasyLoading.show(status: 'loading...');
|
||||||
|
},
|
||||||
|
child: Container(
|
||||||
|
height: 20.r,
|
||||||
|
width: 70.r,
|
||||||
decoration: BoxDecoration(
|
decoration: BoxDecoration(
|
||||||
borderRadius: BorderRadius.all(Radius.circular(20.r)),
|
borderRadius: BorderRadius.all(Radius.circular(20.r)),
|
||||||
color: Color(0xFF6888FD),
|
color: Color(0xFF6888FD),
|
||||||
),
|
),
|
||||||
child: Center(
|
child: Center(
|
||||||
child: Text('取消优先',style: TextStyle(fontSize: 10.sp,color: Colors.white),),
|
child:Text('取消优先',style: TextStyle(fontSize: 10.sp,color: Colors.white),),
|
||||||
|
),
|
||||||
|
),
|
||||||
|
):InkWell(
|
||||||
|
onTap: (){
|
||||||
|
setJobReadLevel(item.studentGroupDetailId,1);
|
||||||
|
EasyLoading.show(status: 'loading...');
|
||||||
|
},
|
||||||
|
child: Container(
|
||||||
|
height: 20.r,
|
||||||
|
width: 70.r,
|
||||||
|
decoration: BoxDecoration(
|
||||||
|
borderRadius: BorderRadius.all(Radius.circular(20.r)),
|
||||||
|
color: Color(0xFFFFFFFF),
|
||||||
|
border: Border.all(width: 1.r,color: Color(0xFF6888FD)),
|
||||||
|
),
|
||||||
|
child: Center(
|
||||||
|
child:Text('设为优先',style: TextStyle(fontSize: 10.sp,color: Color(0xFF6888FD)),),
|
||||||
|
),
|
||||||
),
|
),
|
||||||
)
|
)
|
||||||
],
|
],
|
||||||
),
|
),
|
||||||
|
);
|
||||||
|
}),):ListView.builder(itemBuilder: (context,index){
|
||||||
|
JobStudentLevel item = levelList[index];
|
||||||
|
return Container(
|
||||||
|
padding: EdgeInsets.symmetric(vertical:20.r,horizontal: 15.r),
|
||||||
|
margin: EdgeInsets.only(bottom: 15.r),
|
||||||
|
decoration: BoxDecoration(
|
||||||
|
borderRadius: BorderRadius.all(Radius.circular(10.r)),
|
||||||
|
color: Colors.white,
|
||||||
|
),
|
||||||
|
child: Row(
|
||||||
|
mainAxisAlignment: MainAxisAlignment.spaceBetween,
|
||||||
|
children: [
|
||||||
|
Text(item.studentName,style: TextStyle(fontSize: 12.sp,color: Color(0xFF6888FD)),),
|
||||||
|
tabIndex == 0?InkWell(
|
||||||
|
onTap: (){
|
||||||
|
setJobReadLevel(item.studentGroupDetailId,0);
|
||||||
|
EasyLoading.show(status: 'loading...');
|
||||||
|
},
|
||||||
|
child: Container(
|
||||||
|
height: 24.r,
|
||||||
|
width: 82.r,
|
||||||
|
decoration: BoxDecoration(
|
||||||
|
borderRadius: BorderRadius.all(Radius.circular(20.r)),
|
||||||
|
color: Color(0xFF6888FD),
|
||||||
|
),
|
||||||
|
child: Center(
|
||||||
|
child:Text('取消优先',style: TextStyle(fontSize: 10.sp,color: Colors.white),),
|
||||||
|
),
|
||||||
|
),
|
||||||
|
):InkWell(
|
||||||
|
onTap: (){
|
||||||
|
setJobReadLevel(item.studentGroupDetailId,1);
|
||||||
|
EasyLoading.show(status: 'loading...');
|
||||||
|
},
|
||||||
|
child: Container(
|
||||||
|
height: 24.r,
|
||||||
|
width: 82.r,
|
||||||
|
decoration: BoxDecoration(
|
||||||
|
borderRadius: BorderRadius.all(Radius.circular(20.r)),
|
||||||
|
color: Color(0xFFFFFFFF),
|
||||||
|
border: Border.all(width: 1.r,color: Color(0xFF6888FD)),
|
||||||
|
),
|
||||||
|
child: Center(
|
||||||
|
child:Text('设为优先',style: TextStyle(fontSize: 10.sp,color: Color(0xFF6888FD)),),
|
||||||
|
),
|
||||||
|
),
|
||||||
)
|
)
|
||||||
],
|
],
|
||||||
),
|
),
|
||||||
|
);
|
||||||
|
},itemCount: levelList.length,):MyEmptyWidget(),
|
||||||
|
),
|
||||||
|
),
|
||||||
|
)
|
||||||
|
],
|
||||||
),
|
),
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -0,0 +1,223 @@
|
||||||
|
import 'dart:convert';
|
||||||
|
|
||||||
|
import 'package:flutter/material.dart';
|
||||||
|
import 'package:flutter_easyrefresh/easy_refresh.dart';
|
||||||
|
import 'package:flutter_screenutil/flutter_screenutil.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/job/job_student_goups.dart';
|
||||||
|
import 'package:marking_app/common/model/user/user_info.dart';
|
||||||
|
import 'package:marking_app/routes/RouterManager.dart';
|
||||||
|
import 'package:marking_app/utils/easy_refresh/MyEmptyWidget.dart';
|
||||||
|
import 'package:marking_app/utils/fast_data.dart';
|
||||||
|
import 'package:marking_app/utils/index.dart';
|
||||||
|
import 'package:marking_app/utils/request/rest_client.dart';
|
||||||
|
|
||||||
|
class JobStudentGroup extends StatefulWidget {
|
||||||
|
const JobStudentGroup({Key? key}) : super(key: key);
|
||||||
|
|
||||||
|
@override
|
||||||
|
State<JobStudentGroup> createState() => _JobStudentGroupState();
|
||||||
|
}
|
||||||
|
|
||||||
|
class _JobStudentGroupState extends State<JobStudentGroup> with CommonMixin {
|
||||||
|
late final EasyRefreshController refreshController;
|
||||||
|
late String loginName;
|
||||||
|
List studentGroups = [];
|
||||||
|
|
||||||
|
@override
|
||||||
|
void initState() {
|
||||||
|
super.initState();
|
||||||
|
refreshController = EasyRefreshController();
|
||||||
|
FastData fastData = FastData.getInstance();
|
||||||
|
fastData.getUser().then((value) {
|
||||||
|
if (value == null || value == '') return;
|
||||||
|
Map<String, dynamic> userInfo = json.decode(value);
|
||||||
|
setState(() {
|
||||||
|
loginName = userInfo['loginName'];
|
||||||
|
});
|
||||||
|
getStudentGroups();
|
||||||
|
print(userInfo);
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
void getStudentGroups() async {
|
||||||
|
RestClient _client = await getClient();
|
||||||
|
BaseStructureResult<List<JobStudentGroups>> res =
|
||||||
|
await _client.getJobLevelStudentGroups(loginName);
|
||||||
|
setState(() {
|
||||||
|
if(res.code == 200){
|
||||||
|
studentGroups = res.data!;
|
||||||
|
}else{
|
||||||
|
studentGroups = [];
|
||||||
|
}
|
||||||
|
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
@override
|
||||||
|
void dispose() {
|
||||||
|
super.dispose();
|
||||||
|
refreshController.dispose();
|
||||||
|
}
|
||||||
|
|
||||||
|
@override
|
||||||
|
Widget build(BuildContext context) {
|
||||||
|
bool isPadFlag = isPad();
|
||||||
|
return Scaffold(
|
||||||
|
backgroundColor: Color.fromRGBO(245, 245, 245, 1),
|
||||||
|
appBar: AppBar(
|
||||||
|
backgroundColor: Colors.white,
|
||||||
|
title: Text(
|
||||||
|
'我的学生分组',
|
||||||
|
style: TextStyle(fontSize: 16.sp, color: Color(0xFF333333)),
|
||||||
|
),
|
||||||
|
centerTitle: true,
|
||||||
|
leading: IconButton(
|
||||||
|
icon: Icon(Icons.arrow_back_ios, color: Colors.black),
|
||||||
|
onPressed: () => Navigator.of(context).pop(),
|
||||||
|
),
|
||||||
|
),
|
||||||
|
body: Padding(
|
||||||
|
padding: EdgeInsets.only(top: 15.r, left: 14.r, right: 14.r),
|
||||||
|
child: EasyRefresh(
|
||||||
|
firstRefresh: true,
|
||||||
|
taskIndependence: true,
|
||||||
|
enableControlFinishLoad: true,
|
||||||
|
enableControlFinishRefresh: true,
|
||||||
|
// emptyWidget: data.isEmpty ? const MyEmptyWidget() : null,
|
||||||
|
controller: refreshController,
|
||||||
|
header: MaterialHeader(),
|
||||||
|
footer: TaurusFooter(),
|
||||||
|
child: studentGroups != null && studentGroups.length > 0
|
||||||
|
? isPadFlag?GridView(
|
||||||
|
gridDelegate: SliverGridDelegateWithFixedCrossAxisCount(
|
||||||
|
crossAxisCount: 2,
|
||||||
|
mainAxisSpacing: 10.r,
|
||||||
|
crossAxisSpacing: 10.r,
|
||||||
|
childAspectRatio: 556 / 112,
|
||||||
|
),
|
||||||
|
children: List.generate(studentGroups.length, (index) {
|
||||||
|
JobStudentGroups item = studentGroups[index];
|
||||||
|
String classNames = item.classNames.join(" ");
|
||||||
|
return Container(
|
||||||
|
padding: EdgeInsets.symmetric(horizontal: 10.r),
|
||||||
|
decoration: BoxDecoration(
|
||||||
|
borderRadius: BorderRadius.all(Radius.circular(10.r)),
|
||||||
|
color: Colors.white,
|
||||||
|
),
|
||||||
|
child: Row(
|
||||||
|
mainAxisAlignment: MainAxisAlignment.start,
|
||||||
|
children: [
|
||||||
|
Padding(
|
||||||
|
padding: EdgeInsets.only(right: 8.r),
|
||||||
|
child: Text(
|
||||||
|
item.groupName,
|
||||||
|
style: TextStyle(
|
||||||
|
fontSize: 10.sp, color: Color(0xFF6888FD)),
|
||||||
|
),
|
||||||
|
),
|
||||||
|
Expanded(
|
||||||
|
child: Text(
|
||||||
|
classNames,
|
||||||
|
style: TextStyle(
|
||||||
|
fontSize: 10.sp,
|
||||||
|
color: Color(0xFF999999),
|
||||||
|
overflow: TextOverflow.ellipsis,
|
||||||
|
),
|
||||||
|
textAlign: TextAlign.end,
|
||||||
|
),
|
||||||
|
),
|
||||||
|
InkWell(
|
||||||
|
onTap: (){
|
||||||
|
RouterManager.router.navigateTo(context, '${RouterManager.jobPriorityReviewSetPath}?&groupId=${item.groupId}',transition: getTransition());
|
||||||
|
},
|
||||||
|
child: Container(
|
||||||
|
margin: EdgeInsets.only(left: 5.r),
|
||||||
|
height: 20.r,
|
||||||
|
width: 55.r,
|
||||||
|
decoration: BoxDecoration(
|
||||||
|
borderRadius:
|
||||||
|
BorderRadius.all(Radius.circular(20.r)),
|
||||||
|
color: Color(0xFF6888FD),
|
||||||
|
),
|
||||||
|
child: Center(
|
||||||
|
child: Text(
|
||||||
|
'设置',
|
||||||
|
style: TextStyle(
|
||||||
|
fontSize: 10.sp, color: Colors.white),
|
||||||
|
),
|
||||||
|
),
|
||||||
|
),
|
||||||
|
)
|
||||||
|
],
|
||||||
|
),
|
||||||
|
);
|
||||||
|
}),
|
||||||
|
):ListView.builder(
|
||||||
|
itemBuilder: (context,index){
|
||||||
|
JobStudentGroups item = studentGroups[index];
|
||||||
|
String classNames = item.classNames.join(" ");
|
||||||
|
return Container(
|
||||||
|
padding: EdgeInsets.symmetric(vertical:15.r,horizontal: 10.r),
|
||||||
|
margin: EdgeInsets.only(bottom: 10.r),
|
||||||
|
decoration: BoxDecoration(
|
||||||
|
borderRadius: BorderRadius.all(Radius.circular(10.r)),
|
||||||
|
color: Colors.white,
|
||||||
|
),
|
||||||
|
child: Row(
|
||||||
|
mainAxisAlignment: MainAxisAlignment.start,
|
||||||
|
children: [
|
||||||
|
Padding(
|
||||||
|
padding: EdgeInsets.only(right: 8.r),
|
||||||
|
child: Text(
|
||||||
|
item.groupName,
|
||||||
|
style: TextStyle(
|
||||||
|
fontSize: 14.sp, color: Color(0xFF6888FD)),
|
||||||
|
),
|
||||||
|
),
|
||||||
|
Expanded(
|
||||||
|
child: Text(
|
||||||
|
classNames,
|
||||||
|
style: TextStyle(
|
||||||
|
fontSize: 12.sp,
|
||||||
|
color: Color(0xFF999999),
|
||||||
|
overflow: TextOverflow.ellipsis,
|
||||||
|
),
|
||||||
|
textAlign: TextAlign.end,
|
||||||
|
),
|
||||||
|
),
|
||||||
|
InkWell(
|
||||||
|
onTap: (){
|
||||||
|
RouterManager.router.navigateTo(context, '${RouterManager.jobPriorityReviewSetPath}?&groupId=${item.groupId}',transition: getTransition());
|
||||||
|
},
|
||||||
|
child: Container(
|
||||||
|
margin: EdgeInsets.only(left: 5.r),
|
||||||
|
height: 24.r,
|
||||||
|
width: 55.r,
|
||||||
|
decoration: BoxDecoration(
|
||||||
|
borderRadius:
|
||||||
|
BorderRadius.all(Radius.circular(20.r)),
|
||||||
|
color: Color(0xFF6888FD),
|
||||||
|
),
|
||||||
|
child: Center(
|
||||||
|
child: Text(
|
||||||
|
'设置',
|
||||||
|
style: TextStyle(
|
||||||
|
fontSize: 10.sp, color: Colors.white),
|
||||||
|
),
|
||||||
|
),
|
||||||
|
),
|
||||||
|
)
|
||||||
|
],
|
||||||
|
),
|
||||||
|
);
|
||||||
|
},
|
||||||
|
itemCount: studentGroups.length,
|
||||||
|
)
|
||||||
|
: MyEmptyWidget(),
|
||||||
|
),
|
||||||
|
),
|
||||||
|
);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
@ -11,7 +11,7 @@ class TopUserInfo extends ConsumerWidget {
|
||||||
|
|
||||||
@override
|
@override
|
||||||
Widget build(BuildContext context, WidgetRef ref) {
|
Widget build(BuildContext context, WidgetRef ref) {
|
||||||
final userState = ref.watch(userProvider);
|
final userState = ref.read(userProvider);
|
||||||
|
|
||||||
return InkWell(
|
return InkWell(
|
||||||
onTap: () {
|
onTap: () {
|
||||||
|
|
|
||||||
|
|
@ -16,6 +16,7 @@ import 'package:marking_app/pages/common/startUpPage.dart';
|
||||||
import 'package:marking_app/pages/homework_correction/do_papers_job_exam.dart';
|
import 'package:marking_app/pages/homework_correction/do_papers_job_exam.dart';
|
||||||
import 'package:marking_app/pages/homework_correction/job_priority_review_set.dart';
|
import 'package:marking_app/pages/homework_correction/job_priority_review_set.dart';
|
||||||
import 'package:marking_app/pages/homework_correction/job_report.dart';
|
import 'package:marking_app/pages/homework_correction/job_report.dart';
|
||||||
|
import 'package:marking_app/pages/homework_correction/job_student_group.dart';
|
||||||
import 'package:marking_app/pages/homework_correction/pages/job_list_participate_in_class.dart';
|
import 'package:marking_app/pages/homework_correction/pages/job_list_participate_in_class.dart';
|
||||||
import 'package:marking_app/pages/homework_correction/review_job.dart';
|
import 'package:marking_app/pages/homework_correction/review_job.dart';
|
||||||
import 'package:marking_app/pages/homework_correction/quick_check_personal.dart';
|
import 'package:marking_app/pages/homework_correction/quick_check_personal.dart';
|
||||||
|
|
@ -67,6 +68,7 @@ class RouterManager {
|
||||||
static const String quickDataCheckPath = '/homework_correction/quick_data_check';
|
static const String quickDataCheckPath = '/homework_correction/quick_data_check';
|
||||||
static const String quickCheckPersonalPath = '/homework_correction/quick_check_personal';
|
static const String quickCheckPersonalPath = '/homework_correction/quick_check_personal';
|
||||||
static const String jobPriorityReviewSetPath = '/homework_correction/job_priority_review_set';
|
static const String jobPriorityReviewSetPath = '/homework_correction/job_priority_review_set';
|
||||||
|
static const String jobStudentGroupPath = '/homework_correction/job_student_group';
|
||||||
|
|
||||||
// TheMine
|
// TheMine
|
||||||
|
|
||||||
|
|
@ -281,10 +283,19 @@ class RouterManager {
|
||||||
//优先配置
|
//优先配置
|
||||||
static final _jobPriorityReviewSetPageHandler = Handler(
|
static final _jobPriorityReviewSetPageHandler = Handler(
|
||||||
handlerFunc: (BuildContext? context, Map<String, List<String>> params){
|
handlerFunc: (BuildContext? context, Map<String, List<String>> params){
|
||||||
return JobPriorityReviewSet();
|
String groupId = params['groupId']![0];
|
||||||
|
return JobPriorityReviewSet(groupId:groupId);
|
||||||
},
|
},
|
||||||
);
|
);
|
||||||
|
|
||||||
|
//学生分组
|
||||||
|
static final _jobStudentGroupPageHandler = Handler(
|
||||||
|
handlerFunc: (BuildContext? context, Map<String, List<String>> params){
|
||||||
|
return JobStudentGroup();
|
||||||
|
},
|
||||||
|
);
|
||||||
|
|
||||||
|
|
||||||
// 开始阅卷页面
|
// 开始阅卷页面
|
||||||
// static final _doMarkingPapers = Handler(handlerFunc: (BuildContext? context, Map<String, List<String>> params) => MarkingPapers());
|
// static final _doMarkingPapers = Handler(handlerFunc: (BuildContext? context, Map<String, List<String>> params) => MarkingPapers());
|
||||||
|
|
||||||
|
|
@ -325,6 +336,7 @@ class RouterManager {
|
||||||
router.define(quickCheckPersonalPath,
|
router.define(quickCheckPersonalPath,
|
||||||
handler: _quickCheckPersonalPageHandler, transitionType: TransitionType.material);
|
handler: _quickCheckPersonalPageHandler, transitionType: TransitionType.material);
|
||||||
router.define(jobPriorityReviewSetPath, handler: _jobPriorityReviewSetPageHandler, transitionType: TransitionType.material);
|
router.define(jobPriorityReviewSetPath, handler: _jobPriorityReviewSetPageHandler, transitionType: TransitionType.material);
|
||||||
|
router.define(jobStudentGroupPath, handler: _jobStudentGroupPageHandler, transitionType: TransitionType.material);
|
||||||
|
|
||||||
// getTransition()
|
// getTransition()
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -17,6 +17,7 @@ import 'package:marking_app/common/model/job/job_concerned_with_student.dart';
|
||||||
import 'package:marking_app/common/model/job/job_concerned_with_student_params.dart';
|
import 'package:marking_app/common/model/job/job_concerned_with_student_params.dart';
|
||||||
import 'package:marking_app/common/model/job/job_data_report.dart';
|
import 'package:marking_app/common/model/job/job_data_report.dart';
|
||||||
import 'package:marking_app/common/model/job/job_do_marking_status_info.dart';
|
import 'package:marking_app/common/model/job/job_do_marking_status_info.dart';
|
||||||
|
import 'package:marking_app/common/model/job/job_level_set_params.dart';
|
||||||
import 'package:marking_app/common/model/job/job_note_taking_trajectory.dart';
|
import 'package:marking_app/common/model/job/job_note_taking_trajectory.dart';
|
||||||
import 'package:marking_app/common/model/job/job_page_tab.dart';
|
import 'package:marking_app/common/model/job/job_page_tab.dart';
|
||||||
import 'package:marking_app/common/model/job/job_report_join_class.dart';
|
import 'package:marking_app/common/model/job/job_report_join_class.dart';
|
||||||
|
|
@ -24,6 +25,8 @@ import 'package:marking_app/common/model/job/job_report_knowledge_model.dart';
|
||||||
import 'package:marking_app/common/model/job/job_report_model.dart';
|
import 'package:marking_app/common/model/job/job_report_model.dart';
|
||||||
import 'package:marking_app/common/model/job/job_report_question_deatil_model.dart';
|
import 'package:marking_app/common/model/job/job_report_question_deatil_model.dart';
|
||||||
import 'package:marking_app/common/model/job/job_review_submission.dart';
|
import 'package:marking_app/common/model/job/job_review_submission.dart';
|
||||||
|
import 'package:marking_app/common/model/job/job_student_goups.dart';
|
||||||
|
import 'package:marking_app/common/model/job/job_student_level.dart';
|
||||||
import 'package:marking_app/common/model/job/job_task_item.dart';
|
import 'package:marking_app/common/model/job/job_task_item.dart';
|
||||||
import 'package:marking_app/common/model/job/marking_text_question_job.dart';
|
import 'package:marking_app/common/model/job/marking_text_question_job.dart';
|
||||||
import 'package:marking_app/common/model/job/marking_text_question_job_params.dart';
|
import 'package:marking_app/common/model/job/marking_text_question_job_params.dart';
|
||||||
|
|
@ -299,5 +302,21 @@ abstract class RestClient {
|
||||||
// 作业 => 数据快查--个人
|
// 作业 => 数据快查--个人
|
||||||
@the_retrofit.GET("/api/read/job-data-center-student-report")
|
@the_retrofit.GET("/api/read/job-data-center-student-report")
|
||||||
Future<BaseStructureResult<StudentDetails>> getJobPersonalReport(@the_retrofit.Queries() Map<String, dynamic> params);
|
Future<BaseStructureResult<StudentDetails>> getJobPersonalReport(@the_retrofit.Queries() Map<String, dynamic> params);
|
||||||
|
|
||||||
|
// 作业 => 优先批阅,学生分组列表
|
||||||
|
@the_retrofit.GET("/api/read/job-read-level-student-groups")
|
||||||
|
Future<BaseStructureResult<List<JobStudentGroups>>> getJobLevelStudentGroups(
|
||||||
|
@the_retrofit.Query("account") String account);
|
||||||
|
|
||||||
|
// 作业 => 优先批阅,优先批阅列表
|
||||||
|
@the_retrofit.GET("/api/read/job-read-level")
|
||||||
|
Future<BaseStructureResult<List<JobStudentLevel>>> getJobReadLevel(
|
||||||
|
@the_retrofit.Query("GroupId") String groupId, @the_retrofit.Query("ReadLevel") int readLevel);
|
||||||
|
|
||||||
|
// 作业 => 取消/设置优先
|
||||||
|
@the_retrofit.POST("/api/read/jc-job-read-level")
|
||||||
|
Future<BaseStructureResult> getSetJobReadLevel(@the_retrofit.Body() JobLevelSetParams params);
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue