修复BUG和使用更新APP插件
This commit is contained in:
parent
f638ef23de
commit
c6409b095c
|
|
@ -35,6 +35,7 @@ android {
|
||||||
compileOptions {
|
compileOptions {
|
||||||
sourceCompatibility = JavaVersion.VERSION_1_8
|
sourceCompatibility = JavaVersion.VERSION_1_8
|
||||||
targetCompatibility = JavaVersion.VERSION_1_8
|
targetCompatibility = JavaVersion.VERSION_1_8
|
||||||
|
coreLibraryDesugaringEnabled true
|
||||||
}
|
}
|
||||||
|
|
||||||
kotlinOptions {
|
kotlinOptions {
|
||||||
|
|
@ -84,8 +85,14 @@ android {
|
||||||
shrinkResources false //删除无用资源
|
shrinkResources false //删除无用资源
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
flutter {
|
flutter {
|
||||||
source = "../.."
|
source = "../.."
|
||||||
}
|
}
|
||||||
|
|
||||||
|
dependencies {
|
||||||
|
coreLibraryDesugaring 'com.android.tools:desugar_jdk_libs:2.0.4' // 核心库反糖依赖
|
||||||
|
}
|
||||||
|
|
@ -40,7 +40,7 @@
|
||||||
android:name="flutterEmbedding"
|
android:name="flutterEmbedding"
|
||||||
android:value="2"/>
|
android:value="2"/>
|
||||||
<!-- Provider -->
|
<!-- Provider -->
|
||||||
<provider
|
<!-- <provider
|
||||||
android:name="androidx.core.content.FileProvider"
|
android:name="androidx.core.content.FileProvider"
|
||||||
android:authorities="${applicationId}.fileProvider"
|
android:authorities="${applicationId}.fileProvider"
|
||||||
android:exported="false"
|
android:exported="false"
|
||||||
|
|
@ -48,6 +48,16 @@
|
||||||
<meta-data
|
<meta-data
|
||||||
android:name="android.support.FILE_PROVIDER_PATHS"
|
android:name="android.support.FILE_PROVIDER_PATHS"
|
||||||
android:resource="@xml/file_paths"/>
|
android:resource="@xml/file_paths"/>
|
||||||
|
</provider> -->
|
||||||
|
<!-- ✅ FileProvider 配置 - 这是必需的! -->
|
||||||
|
<provider
|
||||||
|
android:name="androidx.core.content.FileProvider"
|
||||||
|
android:authorities="${applicationId}.fileprovider"
|
||||||
|
android:exported="false"
|
||||||
|
android:grantUriPermissions="true">
|
||||||
|
<meta-data
|
||||||
|
android:name="android.support.FILE_PROVIDER_PATHS"
|
||||||
|
android:resource="@xml/file_paths" />
|
||||||
</provider>
|
</provider>
|
||||||
</application>
|
</application>
|
||||||
<!-- 访问电话状态 -->
|
<!-- 访问电话状态 -->
|
||||||
|
|
|
||||||
|
|
@ -1,5 +1,17 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<paths>
|
<paths xmlns:android="http://schemas.android.com/apk/res/android">
|
||||||
|
<!-- 外部存储 -->
|
||||||
|
<external-path name="external_files" path="." />
|
||||||
|
<!-- 应用内部存储 -->
|
||||||
|
<files-path name="files" path="." />
|
||||||
|
<!-- 缓存目录 -->
|
||||||
|
<cache-path name="cache" path="." />
|
||||||
|
<!-- 外部缓存 -->
|
||||||
|
<external-cache-path name="external_cache" path="." />
|
||||||
|
<!-- 下载目录 -->
|
||||||
|
<external-path name="downloads" path="Download/" />
|
||||||
|
|
||||||
|
<!-- 如果你已有其他配置,请保留它们 -->
|
||||||
<external-path path="Android/data/com.yuanxuan.making_school_asignment_app/" name="files_root" />
|
<external-path path="Android/data/com.yuanxuan.making_school_asignment_app/" name="files_root" />
|
||||||
<external-path path="." name="external_storage_root" />
|
<external-path path="." name="external_storage_root" />
|
||||||
</paths>
|
</paths>
|
||||||
|
|
@ -177,6 +177,23 @@ class PageIndexController extends GetxController with RequestToolMixin {
|
||||||
_pageIndexState = PageIndexState(pageController: PageController());
|
_pageIndexState = PageIndexState(pageController: PageController());
|
||||||
super.onInit();
|
super.onInit();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// TODO 升级插件 暂时不使用
|
||||||
|
// @override
|
||||||
|
// void onReady() {
|
||||||
|
// AppUpgradeSimple.instance.checkUpdate(
|
||||||
|
// context: Get.context!,
|
||||||
|
// url: 'https://dpc-teacher-api.23544.com/api/infra/AppVersion/Get',
|
||||||
|
// params: {
|
||||||
|
// 'appName': 'making_school_asignment_app',
|
||||||
|
// 'ftuType': 1,
|
||||||
|
// },
|
||||||
|
// showNoUpdateToast: true,
|
||||||
|
// autoDownload: false,
|
||||||
|
// autoInstall: true,
|
||||||
|
// );
|
||||||
|
// super.onReady();
|
||||||
|
// }
|
||||||
}
|
}
|
||||||
|
|
||||||
class StartPageIndexBinding extends Bindings {
|
class StartPageIndexBinding extends Bindings {
|
||||||
|
|
|
||||||
|
|
@ -12,7 +12,7 @@ import 'package:making_school_asignment_app/routes/app_pages.dart';
|
||||||
import 'class_student_logic.dart';
|
import 'class_student_logic.dart';
|
||||||
|
|
||||||
class ClassStudentPage extends StatefulWidget {
|
class ClassStudentPage extends StatefulWidget {
|
||||||
const ClassStudentPage({Key? key}) : super(key: key);
|
const ClassStudentPage({super.key});
|
||||||
|
|
||||||
@override
|
@override
|
||||||
State<ClassStudentPage> createState() => _ClassStudentPageState();
|
State<ClassStudentPage> createState() => _ClassStudentPageState();
|
||||||
|
|
@ -24,8 +24,7 @@ class _ClassStudentPageState extends State<ClassStudentPage> {
|
||||||
|
|
||||||
@override
|
@override
|
||||||
Widget build(BuildContext context) {
|
Widget build(BuildContext context) {
|
||||||
return OrientationBuilder(
|
return OrientationBuilder(builder: (BuildContext context, Orientation orientation) {
|
||||||
builder: (BuildContext context, Orientation orientation){
|
|
||||||
return Scaffold(
|
return Scaffold(
|
||||||
backgroundColor: const Color.fromRGBO(245, 245, 245, 1),
|
backgroundColor: const Color.fromRGBO(245, 245, 245, 1),
|
||||||
appBar: AppBar(
|
appBar: AppBar(
|
||||||
|
|
@ -60,21 +59,20 @@ class _ClassStudentPageState extends State<ClassStudentPage> {
|
||||||
? Utils.isPad()
|
? Utils.isPad()
|
||||||
? GridView(
|
? GridView(
|
||||||
shrinkWrap: true,
|
shrinkWrap: true,
|
||||||
|
physics: const NeverScrollableScrollPhysics(),
|
||||||
gridDelegate: SliverGridDelegateWithFixedCrossAxisCount(
|
gridDelegate: SliverGridDelegateWithFixedCrossAxisCount(
|
||||||
crossAxisCount: 2,
|
crossAxisCount: 2,
|
||||||
mainAxisSpacing: 0.r,
|
mainAxisSpacing: 0.r,
|
||||||
crossAxisSpacing: 0.r,
|
crossAxisSpacing: 0.r,
|
||||||
childAspectRatio: 556 / 90,
|
childAspectRatio: 556 / 90,
|
||||||
),
|
),
|
||||||
children:
|
children: List.generate(state.studentList.length, (index) {
|
||||||
List.generate(state.studentList.length, (index) {
|
|
||||||
StudentItem item = state.studentList[index];
|
StudentItem item = state.studentList[index];
|
||||||
return InkWell(
|
return InkWell(
|
||||||
onTap: () {
|
onTap: () {
|
||||||
// RouterManager.router.navigateTo(context,
|
// RouterManager.router.navigateTo(context,
|
||||||
// '${RouterManager.jobPersonalDetailPath}?studentId=${item.studentId}&studentName=${Uri.encodeComponent(item.studentName)}');
|
// '${RouterManager.jobPersonalDetailPath}?studentId=${item.studentId}&studentName=${Uri.encodeComponent(item.studentName)}');
|
||||||
Get.toNamed(Routes.studentWorkDetailPage,
|
Get.toNamed(Routes.studentWorkDetailPage, arguments: {
|
||||||
arguments: {
|
|
||||||
'studentName': item.name,
|
'studentName': item.name,
|
||||||
'studentId': item.id,
|
'studentId': item.id,
|
||||||
'subject': state.subject,
|
'subject': state.subject,
|
||||||
|
|
@ -83,87 +81,63 @@ class _ClassStudentPageState extends State<ClassStudentPage> {
|
||||||
child: Container(
|
child: Container(
|
||||||
padding: EdgeInsets.symmetric(horizontal: 10.r),
|
padding: EdgeInsets.symmetric(horizontal: 10.r),
|
||||||
decoration: BoxDecoration(
|
decoration: BoxDecoration(
|
||||||
borderRadius:
|
borderRadius: BorderRadius.all(Radius.circular(0.r)),
|
||||||
BorderRadius.all(Radius.circular(0.r)),
|
|
||||||
color: Colors.transparent,
|
color: Colors.transparent,
|
||||||
border: Border(left: BorderSide(width:
|
border: Border(
|
||||||
(index + 1)%2 == 0? 1.r:0,color: const Color(0xFFA5A5A5)),bottom: BorderSide(width: 1.r,color: const Color(0xFFA5A5A5)))
|
left: BorderSide(
|
||||||
),
|
width: (index + 1) % 2 == 0 ? 1.r : 0, color: const Color(0xFFA5A5A5)),
|
||||||
|
bottom: BorderSide(width: 1.r, color: const Color(0xFFA5A5A5)))),
|
||||||
child: Row(
|
child: Row(
|
||||||
mainAxisAlignment:
|
mainAxisAlignment: MainAxisAlignment.spaceBetween,
|
||||||
MainAxisAlignment.spaceBetween,
|
|
||||||
children: [
|
children: [
|
||||||
Expanded(
|
Expanded(
|
||||||
child: Text(
|
child: Text(
|
||||||
item.name,
|
item.name,
|
||||||
style: TextStyle(
|
style: TextStyle(fontSize: 12.sp, color: Theme.of(context).primaryColor),
|
||||||
fontSize: 12.sp,
|
|
||||||
color: Theme.of(context).primaryColor),
|
|
||||||
)),
|
)),
|
||||||
state.page == 'answerTrajectory'
|
state.page == 'answerTrajectory'
|
||||||
? Container(
|
? Container(
|
||||||
height: 20.r,
|
height: 20.r,
|
||||||
width: 70.r,
|
width: 70.r,
|
||||||
decoration: BoxDecoration(
|
decoration: BoxDecoration(
|
||||||
border: Border.all(
|
border: Border.all(width: 1.r, color: const Color(0xFFB2DA93)),
|
||||||
width: 1.r,
|
borderRadius: BorderRadius.all(Radius.circular(20.r)),
|
||||||
color: const Color(0xFFB2DA93)),
|
|
||||||
borderRadius: BorderRadius.all(
|
|
||||||
Radius.circular(20.r)),
|
|
||||||
),
|
),
|
||||||
child: Center(
|
child: Center(
|
||||||
child: Text('详情',
|
child: Text('详情',
|
||||||
style: TextStyle(
|
style: TextStyle(fontSize: 10.r, color: const Color(0xFFB2DA93))),
|
||||||
fontSize: 10.r,
|
|
||||||
color: Color(0xFFB2DA93))),
|
|
||||||
))
|
))
|
||||||
: state.page == 'history'
|
: state.page == 'history'
|
||||||
? Container(
|
? Container(
|
||||||
height: 20.r,
|
height: 20.r,
|
||||||
width: 70.r,
|
width: 70.r,
|
||||||
decoration: BoxDecoration(
|
decoration: BoxDecoration(
|
||||||
color:
|
color: Theme.of(context).primaryColor,
|
||||||
Theme.of(context).primaryColor,
|
borderRadius: BorderRadius.all(Radius.circular(20.r))),
|
||||||
borderRadius:
|
|
||||||
BorderRadius.all(
|
|
||||||
Radius.circular(
|
|
||||||
20.r))),
|
|
||||||
child: Center(
|
child: Center(
|
||||||
child: Text(
|
child: Text(
|
||||||
'历史作业',
|
'历史作业',
|
||||||
style: TextStyle(
|
style: TextStyle(fontSize: 10.r, color: Colors.white),
|
||||||
fontSize: 10.r,
|
|
||||||
color: Colors.white),
|
|
||||||
)),
|
)),
|
||||||
)
|
)
|
||||||
: item.priorityAnnotate
|
: item.priorityAnnotate
|
||||||
? InkWell(
|
? InkWell(
|
||||||
onTap: () {
|
onTap: () {
|
||||||
logic.setJobReadLevel(
|
logic.setJobReadLevel(item.id, false);
|
||||||
item.id, false);
|
EasyLoading.show(status: 'loading...');
|
||||||
EasyLoading.show(
|
|
||||||
status: 'loading...');
|
|
||||||
},
|
},
|
||||||
child: Container(
|
child: Container(
|
||||||
height: 20.r,
|
height: 20.r,
|
||||||
width: 80.r,
|
width: 80.r,
|
||||||
decoration: BoxDecoration(
|
decoration: BoxDecoration(
|
||||||
borderRadius:
|
borderRadius: BorderRadius.all(Radius.circular(4.r)),
|
||||||
BorderRadius.all(
|
color: const Color(0xFFEBE4FF),
|
||||||
Radius.circular(
|
|
||||||
4.r)),
|
|
||||||
color: const Color(
|
|
||||||
0xFFEBE4FF),
|
|
||||||
),
|
),
|
||||||
child: Row(
|
child: Row(
|
||||||
crossAxisAlignment:
|
crossAxisAlignment: CrossAxisAlignment.start,
|
||||||
CrossAxisAlignment
|
|
||||||
.start,
|
|
||||||
children: [
|
children: [
|
||||||
Padding(
|
Padding(
|
||||||
padding:
|
padding: EdgeInsets.only(left: 3.r),
|
||||||
EdgeInsets.only(
|
|
||||||
left: 3.r),
|
|
||||||
child: Image.asset(
|
child: Image.asset(
|
||||||
'assets/images/youx_icon_active.png',
|
'assets/images/youx_icon_active.png',
|
||||||
width: 14.r,
|
width: 14.r,
|
||||||
|
|
@ -171,15 +145,11 @@ class _ClassStudentPageState extends State<ClassStudentPage> {
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
Padding(
|
Padding(
|
||||||
padding:
|
padding: EdgeInsets.only(top: 2.r, left: 4.r),
|
||||||
EdgeInsets.only(
|
|
||||||
top: 2.r,
|
|
||||||
left: 4.r),
|
|
||||||
child: Text(
|
child: Text(
|
||||||
'优先批阅',
|
'优先批阅',
|
||||||
style: TextStyle(
|
style: TextStyle(
|
||||||
fontSize: 10.sp,
|
fontSize: 10.sp, color: Theme.of(context).primaryColor),
|
||||||
color: Theme.of(context).primaryColor),
|
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
],
|
],
|
||||||
|
|
@ -188,31 +158,21 @@ class _ClassStudentPageState extends State<ClassStudentPage> {
|
||||||
)
|
)
|
||||||
: InkWell(
|
: InkWell(
|
||||||
onTap: () {
|
onTap: () {
|
||||||
logic.setJobReadLevel(
|
logic.setJobReadLevel(item.id, true);
|
||||||
item.id, true);
|
EasyLoading.show(status: 'loading...');
|
||||||
EasyLoading.show(
|
|
||||||
status: 'loading...');
|
|
||||||
},
|
},
|
||||||
child: Container(
|
child: Container(
|
||||||
height: 20.r,
|
height: 20.r,
|
||||||
width: 80.r,
|
width: 80.r,
|
||||||
decoration: BoxDecoration(
|
decoration: BoxDecoration(
|
||||||
borderRadius:
|
borderRadius: BorderRadius.all(Radius.circular(4.r)),
|
||||||
BorderRadius.all(
|
color: const Color(0xFFE1E1E1),
|
||||||
Radius.circular(
|
|
||||||
4.r)),
|
|
||||||
color: const Color(
|
|
||||||
0xFFE1E1E1),
|
|
||||||
),
|
),
|
||||||
child: Row(
|
child: Row(
|
||||||
crossAxisAlignment:
|
crossAxisAlignment: CrossAxisAlignment.start,
|
||||||
CrossAxisAlignment
|
|
||||||
.start,
|
|
||||||
children: [
|
children: [
|
||||||
Padding(
|
Padding(
|
||||||
padding:
|
padding: EdgeInsets.only(left: 3.r),
|
||||||
EdgeInsets.only(
|
|
||||||
left: 3.r),
|
|
||||||
child: Image.asset(
|
child: Image.asset(
|
||||||
'assets/images/youx_icon_default.png',
|
'assets/images/youx_icon_default.png',
|
||||||
width: 14.r,
|
width: 14.r,
|
||||||
|
|
@ -220,16 +180,11 @@ class _ClassStudentPageState extends State<ClassStudentPage> {
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
Padding(
|
Padding(
|
||||||
padding:
|
padding: EdgeInsets.only(top: 2.r, left: 4.r),
|
||||||
EdgeInsets.only(
|
|
||||||
top: 2.r,
|
|
||||||
left: 4.r),
|
|
||||||
child: Text(
|
child: Text(
|
||||||
'优先批阅',
|
'优先批阅',
|
||||||
style: TextStyle(
|
style: TextStyle(
|
||||||
fontSize: 10.sp,
|
fontSize: 10.sp, color: const Color(0xFF8A9691)),
|
||||||
color: const Color(
|
|
||||||
0xFF8A9691)),
|
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
],
|
],
|
||||||
|
|
@ -245,101 +200,79 @@ class _ClassStudentPageState extends State<ClassStudentPage> {
|
||||||
: Padding(
|
: Padding(
|
||||||
padding: EdgeInsets.symmetric(vertical: 14.r, horizontal: 14.r),
|
padding: EdgeInsets.symmetric(vertical: 14.r, horizontal: 14.r),
|
||||||
child: ListView.builder(
|
child: ListView.builder(
|
||||||
|
shrinkWrap: true,
|
||||||
|
physics: const NeverScrollableScrollPhysics(),
|
||||||
|
itemCount: state.studentList.length,
|
||||||
itemBuilder: (context, index) {
|
itemBuilder: (context, index) {
|
||||||
StudentItem item = state.studentList[index];
|
StudentItem item = state.studentList[index];
|
||||||
return InkWell(
|
return InkWell(
|
||||||
onTap: () {
|
onTap: () {
|
||||||
// RouterManager.router.navigateTo(context,
|
// RouterManager.router.navigateTo(context,
|
||||||
// '${RouterManager.jobPersonalDetailPath}?studentId=${item.studentId}&studentName=${Uri.encodeComponent(item.studentName)}');
|
// '${RouterManager.jobPersonalDetailPath}?studentId=${item.studentId}&studentName=${Uri.encodeComponent(item.studentName)}');
|
||||||
Get.toNamed(Routes.studentWorkDetailPage,
|
Get.toNamed(Routes.studentWorkDetailPage, arguments: {
|
||||||
arguments: {
|
|
||||||
'studentName': item.name,
|
'studentName': item.name,
|
||||||
'studentId': item.id,
|
'studentId': item.id,
|
||||||
'subject': state.subject,
|
'subject': state.subject,
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
child: Container(
|
child: Container(
|
||||||
padding: EdgeInsets.symmetric(
|
padding: EdgeInsets.symmetric(vertical: 20.r, horizontal: 15.r),
|
||||||
vertical: 20.r, horizontal: 15.r),
|
|
||||||
margin: EdgeInsets.only(bottom: 15.r),
|
margin: EdgeInsets.only(bottom: 15.r),
|
||||||
decoration: BoxDecoration(
|
decoration: BoxDecoration(
|
||||||
borderRadius:
|
borderRadius: BorderRadius.all(Radius.circular(10.r)),
|
||||||
BorderRadius.all(Radius.circular(10.r)),
|
|
||||||
color: Colors.white,
|
color: Colors.white,
|
||||||
),
|
),
|
||||||
child: Row(
|
child: Row(
|
||||||
mainAxisAlignment:
|
mainAxisAlignment: MainAxisAlignment.spaceBetween,
|
||||||
MainAxisAlignment.spaceBetween,
|
|
||||||
children: [
|
children: [
|
||||||
Expanded(
|
Expanded(
|
||||||
child: Text(
|
child: Text(
|
||||||
item.name,
|
item.name,
|
||||||
style: TextStyle(
|
style: TextStyle(fontSize: 12.sp, color: const Color(0xFF4CC793)),
|
||||||
fontSize: 12.sp,
|
|
||||||
color: const Color(0xFF4CC793)),
|
|
||||||
)),
|
)),
|
||||||
state.page == 'answerTrajectory'
|
state.page == 'answerTrajectory'
|
||||||
? Container(
|
? Container(
|
||||||
height: 24.r,
|
height: 24.r,
|
||||||
width: 72.r,
|
width: 72.r,
|
||||||
decoration: BoxDecoration(
|
decoration: BoxDecoration(
|
||||||
border: Border.all(
|
border: Border.all(width: 1.r, color: const Color(0xFFB2DA93)),
|
||||||
width: 1.r,
|
borderRadius: BorderRadius.all(Radius.circular(20.r)),
|
||||||
color: const Color(0xFFB2DA93)),
|
|
||||||
borderRadius: BorderRadius.all(
|
|
||||||
Radius.circular(20.r)),
|
|
||||||
),
|
),
|
||||||
child: Center(
|
child: Center(
|
||||||
child: Text('详情',
|
child: Text('详情',
|
||||||
style: TextStyle(
|
style: TextStyle(fontSize: 10.r, color: const Color(0xFFB2DA93))),
|
||||||
fontSize: 10.r,
|
|
||||||
color: Color(0xFFB2DA93))),
|
|
||||||
))
|
))
|
||||||
: state.page == 'history'
|
: state.page == 'history'
|
||||||
? Container(
|
? Container(
|
||||||
height: 24.r,
|
height: 24.r,
|
||||||
width: 82.r,
|
width: 82.r,
|
||||||
decoration: BoxDecoration(
|
decoration: BoxDecoration(
|
||||||
color: Color(0xFF4CC793),
|
color: Theme.of(context).primaryColor,
|
||||||
borderRadius:
|
borderRadius: BorderRadius.all(Radius.circular(20.r))),
|
||||||
BorderRadius.all(
|
|
||||||
Radius.circular(
|
|
||||||
20.r))),
|
|
||||||
child: Center(
|
child: Center(
|
||||||
child: Text(
|
child: Text(
|
||||||
'历史作业',
|
'历史作业',
|
||||||
style: TextStyle(
|
style: TextStyle(fontSize: 10.r, color: Colors.white),
|
||||||
fontSize: 10.r,
|
|
||||||
color: Colors.white),
|
|
||||||
)),
|
)),
|
||||||
)
|
)
|
||||||
: item.priorityAnnotate
|
: item.priorityAnnotate
|
||||||
? InkWell(
|
? InkWell(
|
||||||
onTap: () {
|
onTap: () {
|
||||||
logic.setJobReadLevel(
|
logic.setJobReadLevel(item.id, false);
|
||||||
item.id, false);
|
EasyLoading.show(status: 'loading...');
|
||||||
EasyLoading.show(
|
|
||||||
status: 'loading...');
|
|
||||||
},
|
},
|
||||||
child: Container(
|
child: Container(
|
||||||
height: 24.r,
|
height: 24.r,
|
||||||
width: 82.r,
|
width: 82.r,
|
||||||
decoration: BoxDecoration(
|
decoration: BoxDecoration(
|
||||||
borderRadius:
|
borderRadius: BorderRadius.all(Radius.circular(4.r)),
|
||||||
BorderRadius.all(
|
color: const Color(0xFFB7FFE0),
|
||||||
Radius.circular(
|
|
||||||
4.r)),
|
|
||||||
color: Color(0xFFB7FFE0),
|
|
||||||
),
|
),
|
||||||
child: Row(
|
child: Row(
|
||||||
crossAxisAlignment:
|
crossAxisAlignment: CrossAxisAlignment.start,
|
||||||
CrossAxisAlignment
|
|
||||||
.start,
|
|
||||||
children: [
|
children: [
|
||||||
Padding(
|
Padding(
|
||||||
padding:
|
padding: EdgeInsets.only(left: 3.r),
|
||||||
EdgeInsets.only(
|
|
||||||
left: 3.r),
|
|
||||||
child: Image.asset(
|
child: Image.asset(
|
||||||
'assets/images/youx_icon_active.png',
|
'assets/images/youx_icon_active.png',
|
||||||
width: 14.r,
|
width: 14.r,
|
||||||
|
|
@ -347,16 +280,11 @@ class _ClassStudentPageState extends State<ClassStudentPage> {
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
Padding(
|
Padding(
|
||||||
padding:
|
padding: EdgeInsets.only(top: 5.r, left: 4.r),
|
||||||
EdgeInsets.only(
|
|
||||||
top: 5.r,
|
|
||||||
left: 4.r),
|
|
||||||
child: Text(
|
child: Text(
|
||||||
'优先批阅',
|
'优先批阅',
|
||||||
style: TextStyle(
|
style: TextStyle(
|
||||||
fontSize: 10.sp,
|
fontSize: 10.sp, color: const Color(0xFF4CC793)),
|
||||||
color: const Color(
|
|
||||||
0xFF4CC793)),
|
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
],
|
],
|
||||||
|
|
@ -365,31 +293,21 @@ class _ClassStudentPageState extends State<ClassStudentPage> {
|
||||||
)
|
)
|
||||||
: InkWell(
|
: InkWell(
|
||||||
onTap: () {
|
onTap: () {
|
||||||
logic.setJobReadLevel(
|
logic.setJobReadLevel(item.id, true);
|
||||||
item.id, true);
|
EasyLoading.show(status: 'loading...');
|
||||||
EasyLoading.show(
|
|
||||||
status: 'loading...');
|
|
||||||
},
|
},
|
||||||
child: Container(
|
child: Container(
|
||||||
height: 24.r,
|
height: 24.r,
|
||||||
width: 82.r,
|
width: 82.r,
|
||||||
decoration: BoxDecoration(
|
decoration: BoxDecoration(
|
||||||
borderRadius:
|
borderRadius: BorderRadius.all(Radius.circular(4.r)),
|
||||||
BorderRadius.all(
|
color: const Color(0xFFE1E1E1),
|
||||||
Radius.circular(
|
|
||||||
4.r)),
|
|
||||||
color: const Color(
|
|
||||||
0xFFE1E1E1),
|
|
||||||
),
|
),
|
||||||
child: Row(
|
child: Row(
|
||||||
crossAxisAlignment:
|
crossAxisAlignment: CrossAxisAlignment.start,
|
||||||
CrossAxisAlignment
|
|
||||||
.start,
|
|
||||||
children: [
|
children: [
|
||||||
Padding(
|
Padding(
|
||||||
padding:
|
padding: EdgeInsets.only(left: 3.r),
|
||||||
EdgeInsets.only(
|
|
||||||
left: 3.r),
|
|
||||||
child: Image.asset(
|
child: Image.asset(
|
||||||
'assets/images/youx_icon_default.png',
|
'assets/images/youx_icon_default.png',
|
||||||
width: 14.r,
|
width: 14.r,
|
||||||
|
|
@ -397,16 +315,11 @@ class _ClassStudentPageState extends State<ClassStudentPage> {
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
Padding(
|
Padding(
|
||||||
padding:
|
padding: EdgeInsets.only(top: 5.r, left: 4.r),
|
||||||
EdgeInsets.only(
|
|
||||||
top: 5.r,
|
|
||||||
left: 4.r),
|
|
||||||
child: Text(
|
child: Text(
|
||||||
'优先批阅',
|
'优先批阅',
|
||||||
style: TextStyle(
|
style: TextStyle(
|
||||||
fontSize: 10.sp,
|
fontSize: 10.sp, color: const Color(0xFF8A9691)),
|
||||||
color: const Color(
|
|
||||||
0xFF8A9691)),
|
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
],
|
],
|
||||||
|
|
@ -418,15 +331,13 @@ class _ClassStudentPageState extends State<ClassStudentPage> {
|
||||||
),
|
),
|
||||||
);
|
);
|
||||||
},
|
},
|
||||||
itemCount: state.studentList.length,
|
|
||||||
),
|
),
|
||||||
)
|
)
|
||||||
: const MyEmptyWidget(),
|
: const MyEmptyWidget(),
|
||||||
);
|
);
|
||||||
}),
|
}),
|
||||||
);
|
);
|
||||||
}
|
});
|
||||||
);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
@override
|
@override
|
||||||
|
|
|
||||||
|
|
@ -6,7 +6,8 @@ class PersonalDetailTopBar extends StatefulWidget {
|
||||||
final ValueChanged<int>? onTap;
|
final ValueChanged<int>? onTap;
|
||||||
final String customTimeStr;
|
final String customTimeStr;
|
||||||
final bool? hasAll;
|
final bool? hasAll;
|
||||||
const PersonalDetailTopBar({Key? key,required this.controller, this.onTap, required this.customTimeStr,this.hasAll=false}) : super(key: key);
|
const PersonalDetailTopBar(
|
||||||
|
{super.key, required this.controller, this.onTap, required this.customTimeStr, this.hasAll = false});
|
||||||
|
|
||||||
@override
|
@override
|
||||||
State<PersonalDetailTopBar> createState() => _PersonalDetailTopBarState();
|
State<PersonalDetailTopBar> createState() => _PersonalDetailTopBarState();
|
||||||
|
|
@ -22,9 +23,7 @@ class _PersonalDetailTopBarState extends State<PersonalDetailTopBar> {
|
||||||
Widget build(BuildContext context) {
|
Widget build(BuildContext context) {
|
||||||
return Container(
|
return Container(
|
||||||
alignment: Alignment.centerLeft,
|
alignment: Alignment.centerLeft,
|
||||||
decoration: BoxDecoration(
|
decoration: BoxDecoration(border: Border(bottom: BorderSide(width: 1.r, color: const Color(0xFFCCCCCC)))),
|
||||||
border: Border(bottom: BorderSide(width: 1.r,color: Color(0xFFCCCCCC)))
|
|
||||||
),
|
|
||||||
child: TabBar(
|
child: TabBar(
|
||||||
controller: widget.controller,
|
controller: widget.controller,
|
||||||
dividerHeight: 0,
|
dividerHeight: 0,
|
||||||
|
|
@ -33,26 +32,22 @@ class _PersonalDetailTopBarState extends State<PersonalDetailTopBar> {
|
||||||
labelStyle: TextStyle(
|
labelStyle: TextStyle(
|
||||||
fontSize: 12.sp,
|
fontSize: 12.sp,
|
||||||
fontWeight: FontWeight.bold,
|
fontWeight: FontWeight.bold,
|
||||||
color: const Color(0xFF4CC793),
|
color: Theme.of(context).primaryColor,
|
||||||
),
|
),
|
||||||
isScrollable: true,
|
isScrollable: true,
|
||||||
labelColor: const Color(0xFF4CC793),
|
labelColor: Theme.of(context).primaryColor,
|
||||||
unselectedLabelColor: const Color(0xFF505E6E),
|
unselectedLabelColor: const Color(0xFF505E6E),
|
||||||
padding: EdgeInsets.symmetric(horizontal: 14.r),
|
padding: EdgeInsets.symmetric(horizontal: 14.r),
|
||||||
// indicatorSize: TabBarIndicatorSize.label, // 设置指示器高度和标签一样高
|
// indicatorSize: TabBarIndicatorSize.label, // 设置指示器高度和标签一样高
|
||||||
onTap: widget.onTap,
|
onTap: widget.onTap,
|
||||||
indicator: UnderlineTabIndicator(
|
indicator: UnderlineTabIndicator(
|
||||||
borderSide: BorderSide(
|
borderSide: BorderSide(width: 2.r, color: Theme.of(context).primaryColor),
|
||||||
width: 2.r,
|
|
||||||
color:const Color(0xFF4CC793)
|
|
||||||
),
|
|
||||||
),
|
),
|
||||||
tabs: <Widget>[
|
tabs: <Widget>[
|
||||||
const Tab(text: '近一周'),
|
const Tab(text: '近一周'),
|
||||||
const Tab(text: '近一月'),
|
const Tab(text: '近一月'),
|
||||||
Tab(text: widget.customTimeStr),
|
Tab(text: widget.customTimeStr),
|
||||||
if(widget.hasAll == true)
|
if (widget.hasAll == true) const Tab(text: '全部'),
|
||||||
const Tab(text: '全部'),
|
|
||||||
],
|
],
|
||||||
),
|
),
|
||||||
);
|
);
|
||||||
|
|
|
||||||
|
|
@ -71,6 +71,11 @@ dependencies:
|
||||||
url: https://gitea.23544.com/wangyang/zoom_widget.git
|
url: https://gitea.23544.com/wangyang/zoom_widget.git
|
||||||
# url: https://github.com/semakers/zoom-widget.git
|
# url: https://github.com/semakers/zoom-widget.git
|
||||||
# ref: a35c9da6afe405c23b5897b449683d424016e9f1
|
# ref: a35c9da6afe405c23b5897b449683d424016e9f1
|
||||||
|
# TODO 升级插件 暂时不使用
|
||||||
|
# app_upgrade_plugin:
|
||||||
|
# # path: C:\Users\wy\Desktop\my_project\app_upgrade_plugin
|
||||||
|
# git:
|
||||||
|
# url: https://gitea.23544.com/wangyang/app_upgrade_plugin.git
|
||||||
# start retrofit请求封装
|
# start retrofit请求封装
|
||||||
retrofit: ^4.1.0
|
retrofit: ^4.1.0
|
||||||
json_annotation: 4.9.0
|
json_annotation: 4.9.0
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue