|
Before Width: | Height: | Size: 395 B After Width: | Height: | Size: 747 B |
|
Before Width: | Height: | Size: 352 B After Width: | Height: | Size: 932 B |
|
After Width: | Height: | Size: 328 KiB |
|
After Width: | Height: | Size: 25 KiB |
|
After Width: | Height: | Size: 25 KiB |
|
After Width: | Height: | Size: 19 KiB |
|
After Width: | Height: | Size: 26 KiB |
|
After Width: | Height: | Size: 23 KiB |
|
After Width: | Height: | Size: 754 B |
|
Before Width: | Height: | Size: 839 B After Width: | Height: | Size: 889 B |
|
Before Width: | Height: | Size: 948 B After Width: | Height: | Size: 797 B |
|
Before Width: | Height: | Size: 722 B After Width: | Height: | Size: 1.1 KiB |
|
Before Width: | Height: | Size: 803 B After Width: | Height: | Size: 772 B |
|
Before Width: | Height: | Size: 891 B After Width: | Height: | Size: 928 B |
|
Before Width: | Height: | Size: 997 B After Width: | Height: | Size: 888 B |
|
Before Width: | Height: | Size: 483 B After Width: | Height: | Size: 811 B |
|
Before Width: | Height: | Size: 107 KiB After Width: | Height: | Size: 45 KiB |
|
Before Width: | Height: | Size: 432 B After Width: | Height: | Size: 641 B |
|
After Width: | Height: | Size: 291 KiB |
|
|
@ -63,8 +63,8 @@ class MyApp extends StatelessWidget {
|
||||||
debugShowCheckedModeBanner: false,
|
debugShowCheckedModeBanner: false,
|
||||||
theme: ThemeData(
|
theme: ThemeData(
|
||||||
brightness: Brightness.light,
|
brightness: Brightness.light,
|
||||||
primarySwatch: createMaterialColor(const Color.fromRGBO(76, 199, 147, 1)),
|
primarySwatch: createMaterialColor(const Color(0xFF8C68FF)),
|
||||||
primaryColor: const Color.fromRGBO(76, 199, 147, 1),
|
primaryColor: const Color(0xFF8C68FF),
|
||||||
// textTheme: Typography.englishLike2018.apply(fontSizeFactor: 1.sp,),
|
// textTheme: Typography.englishLike2018.apply(fontSizeFactor: 1.sp,),
|
||||||
primaryTextTheme: TextTheme(
|
primaryTextTheme: TextTheme(
|
||||||
bodyLarge: TextStyle(fontSize: 14.sp, color: Colors.black87),
|
bodyLarge: TextStyle(fontSize: 14.sp, color: Colors.black87),
|
||||||
|
|
@ -72,7 +72,7 @@ class MyApp extends StatelessWidget {
|
||||||
useMaterial3: false,
|
useMaterial3: false,
|
||||||
colorScheme: const ColorScheme.light(
|
colorScheme: const ColorScheme.light(
|
||||||
// 修改亮色主题的主题颜色
|
// 修改亮色主题的主题颜色
|
||||||
primary: Color.fromRGBO(76, 199, 147, 1),
|
primary: Color(0xFF8C68FF),
|
||||||
)),
|
)),
|
||||||
enableLog: true,
|
enableLog: true,
|
||||||
logWriterCallback: (text, {bool isError = false}) {
|
logWriterCallback: (text, {bool isError = false}) {
|
||||||
|
|
|
||||||
|
|
@ -28,12 +28,12 @@ class HomeLogic extends GetxController with RequestToolMixin, GetTickerProviderS
|
||||||
WorkStudent data = await getClient().getUnAnnotateList(params);
|
WorkStudent data = await getClient().getUnAnnotateList(params);
|
||||||
state.totalCount.value = data.totalCount;
|
state.totalCount.value = data.totalCount;
|
||||||
state.readOver.value = data.items.length;
|
state.readOver.value = data.items.length;
|
||||||
if(params.pageNumber == 1){
|
/* if(params.pageNumber == 1){
|
||||||
state.workList.value = data.items;
|
state.workList.value = data.items;
|
||||||
}else{
|
}else{
|
||||||
state.workList.addAll(data.items);
|
state.workList.addAll(data.items);
|
||||||
}
|
}
|
||||||
refreshController.finishRefresh();
|
refreshController.finishRefresh();*/
|
||||||
}
|
}
|
||||||
|
|
||||||
@override
|
@override
|
||||||
|
|
|
||||||
|
|
@ -24,9 +24,12 @@ class HomePage extends StatefulWidget {
|
||||||
State<HomePage> createState() => _HomePageState();
|
State<HomePage> createState() => _HomePageState();
|
||||||
}
|
}
|
||||||
|
|
||||||
class _HomePageState extends State<HomePage> with AutomaticKeepAliveClientMixin {
|
class _HomePageState extends State<HomePage>
|
||||||
|
with AutomaticKeepAliveClientMixin {
|
||||||
final logic = Get.find<HomeLogic>();
|
final logic = Get.find<HomeLogic>();
|
||||||
final state = Get.find<HomeLogic>().state;
|
final state = Get
|
||||||
|
.find<HomeLogic>()
|
||||||
|
.state;
|
||||||
|
|
||||||
@override
|
@override
|
||||||
bool get wantKeepAlive => true;
|
bool get wantKeepAlive => true;
|
||||||
|
|
@ -44,8 +47,9 @@ class _HomePageState extends State<HomePage> with AutomaticKeepAliveClientMixin
|
||||||
Widget build(BuildContext context) {
|
Widget build(BuildContext context) {
|
||||||
super.build(context);
|
super.build(context);
|
||||||
var spaceWidth = SizedBox(height: ScreenUtil().screenWidth / 30);
|
var spaceWidth = SizedBox(height: ScreenUtil().screenWidth / 30);
|
||||||
return SafeArea(
|
return Scaffold(
|
||||||
child: OrientationBuilder(
|
backgroundColor: Colors.white,
|
||||||
|
body: OrientationBuilder(
|
||||||
builder: (BuildContext context, Orientation orientation) {
|
builder: (BuildContext context, Orientation orientation) {
|
||||||
return EasyRefresh(
|
return EasyRefresh(
|
||||||
firstRefresh: false,
|
firstRefresh: false,
|
||||||
|
|
@ -63,198 +67,102 @@ class _HomePageState extends State<HomePage> with AutomaticKeepAliveClientMixin
|
||||||
return logic.getList();
|
return logic.getList();
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
child: Column(
|
child: Stack(
|
||||||
children: [
|
children: [
|
||||||
SizedBox(
|
Image.asset(
|
||||||
height: 15.r,
|
'assets/images/home_banner.png',
|
||||||
|
width: Get.width,
|
||||||
|
fit: BoxFit.fill,
|
||||||
),
|
),
|
||||||
/* Container(
|
Container(
|
||||||
height: 200.h,
|
margin: EdgeInsets.only(top: 300.h),
|
||||||
width: double.infinity,
|
padding: EdgeInsets.symmetric(vertical: 0, horizontal: 20.r),
|
||||||
decoration: const BoxDecoration(
|
decoration: BoxDecoration(
|
||||||
image: DecorationImage(
|
color: Colors.white,
|
||||||
image: AssetImage('assets/images/job_home_top_bgm.png'),
|
borderRadius: BorderRadius.only(
|
||||||
fit: BoxFit.fill, // 完全填充
|
topLeft: Radius.circular(30.r),
|
||||||
),
|
topRight: Radius.circular(30.r))),
|
||||||
),
|
child: Column(
|
||||||
),*/
|
children: [
|
||||||
SizedBox(height: MediaQuery.of(context).padding.top / 2),
|
SizedBox(
|
||||||
Obx(() {
|
height: 15.r,
|
||||||
return $TermRow([
|
),
|
||||||
EntranceModel(title: '作业批阅', image: 'assets/images/job_home_marking.png', navigationUrl: Routes.readOverPage),
|
Text(
|
||||||
EntranceModel(
|
'我的作业管理',
|
||||||
title: '学生历史作业',
|
style: TextStyle(
|
||||||
image: 'assets/images/job_home_history.png',
|
fontSize: 20.sp,
|
||||||
navigationUrl: Routes.studentHistoryWorkPage,
|
color: const Color(0xFF676666),
|
||||||
page: 'history',
|
fontWeight: FontWeight.w600),
|
||||||
),
|
),
|
||||||
// EntranceModel(title: '知识点点掌握', image: 'assets/images/job_home_knowledge.png', navigationUrl: Routes.knowledgePointsGraspPage)
|
SizedBox(
|
||||||
EntranceModel(
|
height: 15.r,
|
||||||
title: '知识点点掌握',
|
),
|
||||||
image: 'assets/images/job_home_knowledge.png',
|
Row(
|
||||||
navigationUrl: Routes.studentHistoryWorkPage,
|
children: [
|
||||||
page: 'points',
|
Expanded(
|
||||||
)
|
child: Obx(() {
|
||||||
], state.totalCount.value);
|
return menuItem(
|
||||||
}),
|
bgImg: 'assets/images/home_bg_01.png',
|
||||||
spaceWidth,
|
name: '作业批阅',
|
||||||
$TermRow([
|
value: state.totalCount.value.toString(),
|
||||||
EntranceModel(title: '答题轨迹', image: 'assets/images/job_home_answer_record.png', navigationUrl: Routes.answerTrajectoryPage),
|
url: Routes.readOverPage);
|
||||||
EntranceModel(
|
|
||||||
title: '优先批阅设定',
|
|
||||||
image: 'assets/images/job_home_youxian.png',
|
|
||||||
navigationUrl: Routes.studentHistoryWorkPage,
|
|
||||||
page: 'set',
|
|
||||||
)
|
|
||||||
], 0),
|
|
||||||
|
|
||||||
/* $TermRow(
|
|
||||||
context,
|
|
||||||
[
|
|
||||||
EntranceModel(
|
|
||||||
title: '批阅设置',
|
|
||||||
image: 'assets/images/job_home_marking_set.png',
|
|
||||||
navigationUrl: '')
|
|
||||||
],
|
|
||||||
0),*/
|
|
||||||
SizedBox(height: 15.h),
|
|
||||||
Obx(() {
|
|
||||||
return Container(
|
|
||||||
padding: EdgeInsets.symmetric(horizontal: 12.w),
|
|
||||||
child: state.workList.isNotEmpty
|
|
||||||
? Column(
|
|
||||||
children: List.generate(state.workList.length, (index) {
|
|
||||||
Items item = state.workList[index];
|
|
||||||
return InkWell(
|
|
||||||
onTap: () {
|
|
||||||
Get.toNamed(Routes.annotateClassPage, arguments: {
|
|
||||||
'id': item.id,
|
|
||||||
'name': item.name,
|
|
||||||
'grade': item.grade,
|
|
||||||
'subject': item.subject,
|
|
||||||
});
|
|
||||||
},
|
|
||||||
child: Container(
|
|
||||||
margin: EdgeInsets.only(bottom: 15.h),
|
|
||||||
child: Column(
|
|
||||||
children: [
|
|
||||||
SizedBox(height: 4.h),
|
|
||||||
Container(
|
|
||||||
padding: EdgeInsets.symmetric(vertical: 15.h, horizontal: 10.w),
|
|
||||||
width: double.infinity,
|
|
||||||
decoration: BoxDecoration(
|
|
||||||
borderRadius: BorderRadius.circular(6.r),
|
|
||||||
color: const Color.fromRGBO(255, 255, 255, 1),
|
|
||||||
boxShadow: const [
|
|
||||||
BoxShadow(
|
|
||||||
color: Color.fromRGBO(210, 216, 241, 1),
|
|
||||||
offset: Offset.zero, //阴影y轴偏移量
|
|
||||||
blurRadius: 5.8, //阴影模糊程度
|
|
||||||
spreadRadius: 0, //阴影扩散程度
|
|
||||||
)
|
|
||||||
],
|
|
||||||
),
|
|
||||||
child: Column(
|
|
||||||
mainAxisAlignment: MainAxisAlignment.spaceBetween,
|
|
||||||
children: [
|
|
||||||
Row(
|
|
||||||
crossAxisAlignment: CrossAxisAlignment.start,
|
|
||||||
children: [
|
|
||||||
Container(
|
|
||||||
width: Utils.isPad() ? 32.w : 38.w,
|
|
||||||
height: 18.h,
|
|
||||||
alignment: Alignment.center,
|
|
||||||
padding: EdgeInsets.only(left: Utils.isPad() ? 2.w : 3.w),
|
|
||||||
decoration: BoxDecoration(
|
|
||||||
color: state.type == 1 ? const Color(0xFF4CC793) : const Color.fromRGBO(255, 175, 56, 1),
|
|
||||||
borderRadius: BorderRadius.only(
|
|
||||||
topLeft: Radius.circular(14.r),
|
|
||||||
topRight: Radius.circular(3.r),
|
|
||||||
bottomLeft: Radius.circular(4.r),
|
|
||||||
bottomRight: Radius.circular(4.r),
|
|
||||||
),
|
|
||||||
),
|
|
||||||
margin: EdgeInsets.only(top: 3.h, right: 4.w),
|
|
||||||
child: quickText(state.type == 1 ? '作业' : '考试', color: Colors.white, size: 10.sp),
|
|
||||||
),
|
|
||||||
Expanded(
|
|
||||||
child: quickText(
|
|
||||||
item.name,
|
|
||||||
maxLines: 2,
|
|
||||||
size: Utils.isPad() ? 14.sp : 16.sp,
|
|
||||||
color: const Color.fromRGBO(70, 70, 70, 1),
|
|
||||||
fontWeight: FontWeight.bold,
|
|
||||||
),
|
|
||||||
)
|
|
||||||
],
|
|
||||||
),
|
|
||||||
SizedBox(height: 10.h),
|
|
||||||
Row(
|
|
||||||
crossAxisAlignment: CrossAxisAlignment.end,
|
|
||||||
children: [
|
|
||||||
quickText(
|
|
||||||
EnumUtils.formatSubject(item.subject),
|
|
||||||
color: const Color.fromRGBO(97, 97, 97, 1),
|
|
||||||
size: 12.sp,
|
|
||||||
),
|
|
||||||
quickText(' / ',
|
|
||||||
color: const Color.fromRGBO(130, 130, 130, 1), size: 11.sp, fontWeight: FontWeight.w500),
|
|
||||||
Row(
|
|
||||||
crossAxisAlignment: CrossAxisAlignment.end,
|
|
||||||
children: [
|
|
||||||
quickText('题量:', color: const Color.fromRGBO(130, 130, 130, 1), size: 11.sp),
|
|
||||||
quickText(
|
|
||||||
'${item.questionCount! - item.annotateCount!}',
|
|
||||||
color: const Color.fromRGBO(97, 97, 97, 1),
|
|
||||||
size: 13.sp,
|
|
||||||
),
|
|
||||||
],
|
|
||||||
),
|
|
||||||
quickText(' / ',
|
|
||||||
color: const Color.fromRGBO(130, 130, 130, 1), size: 11.sp, fontWeight: FontWeight.w500),
|
|
||||||
quickText(DateTime.parse(item.publishTime).toString().substring(0, 10),
|
|
||||||
color: const Color.fromRGBO(97, 97, 97, 1), size: 12.sp),
|
|
||||||
],
|
|
||||||
),
|
|
||||||
SizedBox(height: 10.h),
|
|
||||||
Row(
|
|
||||||
children: [
|
|
||||||
Expanded(
|
|
||||||
child: Container(
|
|
||||||
decoration: BoxDecoration(
|
|
||||||
borderRadius: BorderRadius.circular(10.r),
|
|
||||||
),
|
|
||||||
child: LinearPercentIndicator(
|
|
||||||
padding: EdgeInsets.zero,
|
|
||||||
animation: true,
|
|
||||||
lineHeight: 8.h,
|
|
||||||
animationDuration: 2500,
|
|
||||||
percent: item.annotateRate == null ? 0 : item.annotateRate! / 100,
|
|
||||||
progressColor: const Color(0xFF4CC793),
|
|
||||||
backgroundColor: const Color(0xFFE8E8E8),
|
|
||||||
barRadius: Radius.circular(10.r),
|
|
||||||
),
|
|
||||||
),
|
|
||||||
),
|
|
||||||
SizedBox(
|
|
||||||
width: 10.r,
|
|
||||||
),
|
|
||||||
quickText('${item.annotateRate!.toStringAsFixed(0)}%', size: 10.sp, color: const Color(0xFF464646)),
|
|
||||||
],
|
|
||||||
),
|
|
||||||
// FavoriteButton(jobTaskItem.id, jobTaskItem.title),
|
|
||||||
],
|
|
||||||
),
|
|
||||||
),
|
|
||||||
],
|
|
||||||
),
|
|
||||||
),
|
|
||||||
);
|
|
||||||
}),
|
}),
|
||||||
)
|
),
|
||||||
: const MyEmptyWidget(),
|
SizedBox(
|
||||||
);
|
width: 20.r,
|
||||||
}),
|
),
|
||||||
|
Expanded(
|
||||||
|
child: menuItem(
|
||||||
|
bgImg: 'assets/images/home_bg_02.png',
|
||||||
|
name: '知识点点掌握',
|
||||||
|
url: Routes.studentHistoryWorkPage,
|
||||||
|
page: 'points'),
|
||||||
|
),
|
||||||
|
],
|
||||||
|
),
|
||||||
|
SizedBox(
|
||||||
|
height: 20.r,
|
||||||
|
),
|
||||||
|
Row(
|
||||||
|
children: [
|
||||||
|
Expanded(
|
||||||
|
child: menuItem(
|
||||||
|
bgImg: 'assets/images/home_bg_03.png',
|
||||||
|
name: '学生历史作业',
|
||||||
|
url: Routes.studentHistoryWorkPage,
|
||||||
|
page: 'history'),
|
||||||
|
),
|
||||||
|
SizedBox(
|
||||||
|
width: 20.r,
|
||||||
|
),
|
||||||
|
Expanded(
|
||||||
|
child: menuItem(
|
||||||
|
bgImg: 'assets/images/home_bg_04.png',
|
||||||
|
name: '答题轨迹',
|
||||||
|
url: Routes.answerTrajectoryPage),
|
||||||
|
),
|
||||||
|
],
|
||||||
|
),
|
||||||
|
SizedBox(
|
||||||
|
height: 20.r,
|
||||||
|
),
|
||||||
|
Row(
|
||||||
|
children: [
|
||||||
|
menuItem(
|
||||||
|
bgImg: 'assets/images/home_bg_05.png',
|
||||||
|
name: '优先批阅设定',
|
||||||
|
url: Routes.studentHistoryWorkPage,
|
||||||
|
page: 'set',),
|
||||||
|
SizedBox(
|
||||||
|
width: 20.r,
|
||||||
|
),
|
||||||
|
|
||||||
|
],
|
||||||
|
),
|
||||||
|
SizedBox(height: 15.h),
|
||||||
|
],
|
||||||
|
),
|
||||||
|
)
|
||||||
],
|
],
|
||||||
),
|
),
|
||||||
);
|
);
|
||||||
|
|
@ -270,13 +178,84 @@ class _HomePageState extends State<HomePage> with AutomaticKeepAliveClientMixin
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Widget menuItem({required String bgImg, required String name, String? value,required String url,String? page}) {
|
||||||
|
return InkWell(
|
||||||
|
onTap: (){
|
||||||
|
Get.toNamed(url, arguments: {'page': page ?? ''});
|
||||||
|
},
|
||||||
|
child: Container(
|
||||||
|
width: (Get.width - 60.r) / 2,
|
||||||
|
height: (Get.width - 60.r) / 2 * 86 / 164,
|
||||||
|
padding: EdgeInsets.symmetric(
|
||||||
|
vertical: 15.r, horizontal: 15.r),
|
||||||
|
decoration: BoxDecoration(
|
||||||
|
image: DecorationImage(
|
||||||
|
image: AssetImage(
|
||||||
|
bgImg),
|
||||||
|
fit: BoxFit.contain,
|
||||||
|
),
|
||||||
|
),
|
||||||
|
child: Column(
|
||||||
|
crossAxisAlignment: CrossAxisAlignment.start,
|
||||||
|
children: [
|
||||||
|
Row(
|
||||||
|
mainAxisAlignment: MainAxisAlignment
|
||||||
|
.spaceBetween,
|
||||||
|
crossAxisAlignment: CrossAxisAlignment
|
||||||
|
.center,
|
||||||
|
children: [
|
||||||
|
Text(
|
||||||
|
name,
|
||||||
|
style: TextStyle(
|
||||||
|
fontSize: 14.sp,
|
||||||
|
color: const Color(0xFF4F4F4F),
|
||||||
|
fontWeight: FontWeight.w600),
|
||||||
|
),
|
||||||
|
if(value != null && value != '')
|
||||||
|
Container(
|
||||||
|
width: 18.r,
|
||||||
|
height: 18.r,
|
||||||
|
alignment: Alignment.center,
|
||||||
|
decoration: BoxDecoration(
|
||||||
|
color: const Color(0xFFFF6969),
|
||||||
|
borderRadius: BorderRadius.all(
|
||||||
|
Radius.circular(9.r)),
|
||||||
|
),
|
||||||
|
child: Text(
|
||||||
|
value!,
|
||||||
|
style: TextStyle(fontSize: 10.sp,
|
||||||
|
color: Colors.white,
|
||||||
|
fontWeight: FontWeight.w600),),
|
||||||
|
)
|
||||||
|
],
|
||||||
|
),
|
||||||
|
const Spacer(),
|
||||||
|
Row(
|
||||||
|
mainAxisAlignment: MainAxisAlignment.end,
|
||||||
|
children: [
|
||||||
|
Image.asset(
|
||||||
|
'assets/images/home_right_icon.png',
|
||||||
|
width: 16.r,
|
||||||
|
height: 16.r,
|
||||||
|
),
|
||||||
|
],
|
||||||
|
),
|
||||||
|
],
|
||||||
|
),
|
||||||
|
),
|
||||||
|
);
|
||||||
|
}
|
||||||
|
|
||||||
class EntranceModel extends Object {
|
class EntranceModel extends Object {
|
||||||
String title;
|
String title;
|
||||||
String image;
|
String image;
|
||||||
String navigationUrl;
|
String navigationUrl;
|
||||||
String? page;
|
String? page;
|
||||||
|
|
||||||
EntranceModel({required this.title, required this.image, required this.navigationUrl, this.page});
|
EntranceModel({required this.title,
|
||||||
|
required this.image,
|
||||||
|
required this.navigationUrl,
|
||||||
|
this.page});
|
||||||
}
|
}
|
||||||
|
|
||||||
@swidget
|
@swidget
|
||||||
|
|
@ -285,7 +264,8 @@ Widget $termRow(BuildContext context, List<EntranceModel> items, int? data) {
|
||||||
Widget childWidget;
|
Widget childWidget;
|
||||||
switch (leng) {
|
switch (leng) {
|
||||||
case 1:
|
case 1:
|
||||||
childWidget = Row(children: [Expanded(child: $TermItem(items[0], data!))]);
|
childWidget =
|
||||||
|
Row(children: [Expanded(child: $TermItem(items[0], data!))]);
|
||||||
break;
|
break;
|
||||||
case 2:
|
case 2:
|
||||||
childWidget = Row(children: [
|
childWidget = Row(children: [
|
||||||
|
|
@ -320,11 +300,13 @@ Widget $termRow(BuildContext context, List<EntranceModel> items, int? data) {
|
||||||
childWidget = Container();
|
childWidget = Container();
|
||||||
}
|
}
|
||||||
|
|
||||||
return Container(padding: EdgeInsets.symmetric(horizontal: 14.w), child: childWidget);
|
return Container(
|
||||||
|
padding: EdgeInsets.symmetric(horizontal: 14.w), child: childWidget);
|
||||||
}
|
}
|
||||||
|
|
||||||
@swidget
|
@swidget
|
||||||
Widget $termItem(BuildContext context, EntranceModel e, int data, {double? theHeight}) {
|
Widget $termItem(BuildContext context, EntranceModel e, int data,
|
||||||
|
{double? theHeight}) {
|
||||||
bool isJob = e.title == '作业批阅';
|
bool isJob = e.title == '作业批阅';
|
||||||
|
|
||||||
return Material(
|
return Material(
|
||||||
|
|
@ -353,10 +335,14 @@ Widget $termItem(BuildContext context, EntranceModel e, int data, {double? theHe
|
||||||
badgeStyle: badges.BadgeStyle(
|
badgeStyle: badges.BadgeStyle(
|
||||||
badgeColor: const Color.fromRGBO(255, 105, 105, 1),
|
badgeColor: const Color.fromRGBO(255, 105, 105, 1),
|
||||||
shape: badges.BadgeShape.square,
|
shape: badges.BadgeShape.square,
|
||||||
borderRadius: BorderRadius.only(topLeft: Radius.circular(10.r), topRight: Radius.circular(8.5.r), bottomRight: Radius.circular(8.5.r)),
|
borderRadius: BorderRadius.only(
|
||||||
|
topLeft: Radius.circular(10.r),
|
||||||
|
topRight: Radius.circular(8.5.r),
|
||||||
|
bottomRight: Radius.circular(8.5.r)),
|
||||||
// borderSide: BorderSide(color: Colors.white, width: 2),
|
// borderSide: BorderSide(color: Colors.white, width: 2),
|
||||||
elevation: 1,
|
elevation: 1,
|
||||||
padding: EdgeInsets.symmetric(horizontal: Utils.isPad() ? 11.w : 16.w, vertical: 2.h),
|
padding: EdgeInsets.symmetric(
|
||||||
|
horizontal: Utils.isPad() ? 11.w : 16.w, vertical: 2.h),
|
||||||
),
|
),
|
||||||
position: badges.BadgePosition.topEnd(top: 10.r, end: 10.r),
|
position: badges.BadgePosition.topEnd(top: 10.r, end: 10.r),
|
||||||
child: Container(
|
child: Container(
|
||||||
|
|
@ -377,21 +363,29 @@ Widget $termItem(BuildContext context, EntranceModel e, int data, {double? theHe
|
||||||
alignment: Alignment.center,
|
alignment: Alignment.center,
|
||||||
child: isJob
|
child: isJob
|
||||||
? Column(
|
? Column(
|
||||||
mainAxisAlignment: MainAxisAlignment.center,
|
mainAxisAlignment: MainAxisAlignment.center,
|
||||||
children: [
|
children: [
|
||||||
Image.asset(e.image, height: 32.r, width: 32.r, fit: BoxFit.cover),
|
Image.asset(e.image,
|
||||||
SizedBox(height: 6.r),
|
height: 32.r, width: 32.r, fit: BoxFit.cover),
|
||||||
quickText(e.title, size: 12.sp, color: const Color.fromRGBO(79, 79, 79, 1), fontWeight: FontWeight.w500),
|
SizedBox(height: 6.r),
|
||||||
],
|
quickText(e.title,
|
||||||
)
|
size: 12.sp,
|
||||||
|
color: const Color.fromRGBO(79, 79, 79, 1),
|
||||||
|
fontWeight: FontWeight.w500),
|
||||||
|
],
|
||||||
|
)
|
||||||
: Row(
|
: Row(
|
||||||
mainAxisAlignment: MainAxisAlignment.center,
|
mainAxisAlignment: MainAxisAlignment.center,
|
||||||
children: [
|
children: [
|
||||||
Image.asset(e.image, height: 32.r, width: 32.r, fit: BoxFit.cover),
|
Image.asset(e.image,
|
||||||
SizedBox(width: 6.r),
|
height: 32.r, width: 32.r, fit: BoxFit.cover),
|
||||||
quickText(e.title, size: 12.sp, color: const Color.fromRGBO(79, 79, 79, 1), fontWeight: FontWeight.w500),
|
SizedBox(width: 6.r),
|
||||||
],
|
quickText(e.title,
|
||||||
),
|
size: 12.sp,
|
||||||
|
color: const Color.fromRGBO(79, 79, 79, 1),
|
||||||
|
fontWeight: FontWeight.w500),
|
||||||
|
],
|
||||||
|
),
|
||||||
),
|
),
|
||||||
)),
|
)),
|
||||||
);
|
);
|
||||||
|
|
|
||||||
|
|
@ -56,58 +56,52 @@ class _LoginPageState extends State<LoginPage> {
|
||||||
statusBarBrightness: Brightness.dark,
|
statusBarBrightness: Brightness.dark,
|
||||||
),
|
),
|
||||||
child: Scaffold(
|
child: Scaffold(
|
||||||
backgroundColor: Colors.transparent,
|
backgroundColor: Colors.white,
|
||||||
resizeToAvoidBottomInset: false,
|
resizeToAvoidBottomInset: false,
|
||||||
body: Container(
|
body: Stack(
|
||||||
width: double.infinity,
|
children: [
|
||||||
height: double.infinity,
|
Positioned(
|
||||||
alignment: Alignment.center,
|
top: 0,
|
||||||
decoration: const BoxDecoration(
|
left: 0,
|
||||||
image: DecorationImage(
|
child: Image.asset('assets/images/logo_banner.png',width: Get.width,fit: BoxFit.fill,)),
|
||||||
image: AssetImage('assets/images/login_bg.png'),
|
SingleChildScrollView(
|
||||||
fit: BoxFit.fill, // 完全填充
|
|
||||||
),
|
|
||||||
),
|
|
||||||
child: SingleChildScrollView(
|
|
||||||
child: Column(
|
child: Column(
|
||||||
children: [
|
children: [
|
||||||
|
SizedBox(height: 130.r,),
|
||||||
Container(
|
Container(
|
||||||
width: 86.w,
|
width: 77.w,
|
||||||
height: 86.w,
|
height: 77.w,
|
||||||
alignment: Alignment.center,
|
alignment: Alignment.center,
|
||||||
child: SizedBox(
|
child: SizedBox(
|
||||||
height: 86.w,
|
height: 77.w,
|
||||||
width: 86.w,
|
width: 77.w,
|
||||||
child: Image.asset('assets/images/login_logo.png',
|
child: Image.asset('assets/images/login_logo.png',
|
||||||
fit: BoxFit.cover),
|
fit: BoxFit.cover),
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
Container(
|
Container(
|
||||||
margin: EdgeInsets.symmetric(
|
margin: EdgeInsets.only(top: 90.r),
|
||||||
horizontal: 32.w, vertical: 24.h),
|
|
||||||
padding: EdgeInsets.only(
|
padding: EdgeInsets.only(
|
||||||
top: 34.h, bottom: 16.h, left: 22.w, right: 22.w),
|
top: 50.h, bottom: 16.h, left: 40.w, right: 40.w),
|
||||||
color: Colors.transparent,
|
decoration: BoxDecoration(
|
||||||
/* decoration: BoxDecoration(
|
color: Colors.white,
|
||||||
color: Colors.transparent,
|
borderRadius: BorderRadius.only(topLeft: Radius.circular(30.r),topRight: Radius.circular(30.r)),
|
||||||
border: Border.all(width: 1.w, color: Colors.white),
|
/*boxShadow: const [
|
||||||
borderRadius: BorderRadius.all(Radius.circular(10.w)),
|
|
||||||
boxShadow: const [
|
|
||||||
BoxShadow(
|
BoxShadow(
|
||||||
color: Color.fromRGBO(46, 91, 255, 0.1),
|
color: Color.fromRGBO(46, 91, 255, 0.1),
|
||||||
offset: Offset.zero, //阴影y轴偏移量
|
offset: Offset.zero, //阴影y轴偏移量
|
||||||
blurRadius: 100, //阴影模糊程度
|
blurRadius: 100, //阴影模糊程度
|
||||||
spreadRadius: 100, //阴影扩散程度
|
spreadRadius: 100, //阴影扩散程度
|
||||||
)
|
)
|
||||||
],
|
],*/
|
||||||
),*/
|
),
|
||||||
child: Column(children: [
|
child: Column(children: [
|
||||||
Container(
|
Container(
|
||||||
padding: EdgeInsets.symmetric(horizontal: 20.h),
|
padding: EdgeInsets.symmetric(horizontal: 15.w,),
|
||||||
decoration: BoxDecoration(
|
decoration: BoxDecoration(
|
||||||
color: Colors.transparent,
|
color: Colors.transparent,
|
||||||
border: Border.all(
|
border: Border.all(
|
||||||
width: 1.w, color: const Color(0xFFFFFFFF)),
|
width: 1.w, color: const Color(0xFF434343)),
|
||||||
borderRadius:
|
borderRadius:
|
||||||
BorderRadius.all(Radius.circular(17.w)),
|
BorderRadius.all(Radius.circular(17.w)),
|
||||||
),
|
),
|
||||||
|
|
@ -121,19 +115,19 @@ class _LoginPageState extends State<LoginPage> {
|
||||||
// FocusScope.of(context).requestFocus(_pwdFocus);
|
// FocusScope.of(context).requestFocus(_pwdFocus);
|
||||||
},
|
},
|
||||||
style: TextStyle(
|
style: TextStyle(
|
||||||
color: Colors.white,
|
color: const Color(0xFF434343),
|
||||||
fontSize: 14.sp,
|
fontSize: 14.sp,
|
||||||
),
|
),
|
||||||
decoration: InputDecoration(
|
decoration: InputDecoration(
|
||||||
hintText: "请输入账号",
|
hintText: "请输入账号",
|
||||||
hintStyle: TextStyle(
|
hintStyle: TextStyle(
|
||||||
fontSize: 14.sp,
|
fontSize: 14.sp,
|
||||||
color: Colors.white,
|
color: const Color(0xFF434343),
|
||||||
),
|
),
|
||||||
// labelText: "账号",
|
// labelText: "账号",
|
||||||
labelStyle: TextStyle(
|
labelStyle: TextStyle(
|
||||||
fontSize: 14.sp,
|
fontSize: 14.sp,
|
||||||
color: Colors.white,
|
color: const Color(0xFF434343),
|
||||||
),
|
),
|
||||||
border: InputBorder.none,
|
border: InputBorder.none,
|
||||||
isDense: true,
|
isDense: true,
|
||||||
|
|
@ -153,15 +147,15 @@ class _LoginPageState extends State<LoginPage> {
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
SizedBox(
|
SizedBox(
|
||||||
height: 15.r,
|
height: 20.r,
|
||||||
),
|
),
|
||||||
Obx(() {
|
Obx(() {
|
||||||
return Container(
|
return Container(
|
||||||
padding: EdgeInsets.symmetric(horizontal: 20.h),
|
padding: EdgeInsets.symmetric(horizontal: 15.w),
|
||||||
decoration: BoxDecoration(
|
decoration: BoxDecoration(
|
||||||
color: Colors.transparent,
|
color: Colors.transparent,
|
||||||
border: Border.all(
|
border: Border.all(
|
||||||
width: 1.w, color: const Color(0xFFFFFFFF)),
|
width: 1.w, color: const Color(0xFF434343)),
|
||||||
borderRadius:
|
borderRadius:
|
||||||
BorderRadius.all(Radius.circular(17.w)),
|
BorderRadius.all(Radius.circular(17.w)),
|
||||||
),
|
),
|
||||||
|
|
@ -175,7 +169,7 @@ class _LoginPageState extends State<LoginPage> {
|
||||||
// textInputAction: state.isShowPwd.value?TextInputAction.go:TextInputAction.next,
|
// textInputAction: state.isShowPwd.value?TextInputAction.go:TextInputAction.next,
|
||||||
// onSubmitted: (val) => toLogin(),
|
// onSubmitted: (val) => toLogin(),
|
||||||
style: TextStyle(
|
style: TextStyle(
|
||||||
color: Colors.white,
|
color: const Color(0xFF434343),
|
||||||
fontSize: 14.sp,
|
fontSize: 14.sp,
|
||||||
),
|
),
|
||||||
decoration: InputDecoration(
|
decoration: InputDecoration(
|
||||||
|
|
@ -214,7 +208,7 @@ class _LoginPageState extends State<LoginPage> {
|
||||||
),
|
),
|
||||||
hintStyle: TextStyle(
|
hintStyle: TextStyle(
|
||||||
fontSize: 14.sp,
|
fontSize: 14.sp,
|
||||||
color: Colors.white,
|
color: const Color(0xFF434343),
|
||||||
),
|
),
|
||||||
border: InputBorder.none,
|
border: InputBorder.none,
|
||||||
// labelText: "密码",
|
// labelText: "密码",
|
||||||
|
|
@ -268,8 +262,8 @@ class _LoginPageState extends State<LoginPage> {
|
||||||
}
|
}
|
||||||
//修改默认时边框颜色为绿色
|
//修改默认时边框颜色为绿色
|
||||||
return BorderSide(
|
return BorderSide(
|
||||||
width: 1.5.r,
|
width: 1.r,
|
||||||
color: Colors.white);
|
color: const Color(0xFF434343));
|
||||||
},
|
},
|
||||||
)),
|
)),
|
||||||
);
|
);
|
||||||
|
|
@ -291,7 +285,7 @@ class _LoginPageState extends State<LoginPage> {
|
||||||
'记住密码',
|
'记住密码',
|
||||||
style: TextStyle(
|
style: TextStyle(
|
||||||
fontSize: 12.sp,
|
fontSize: 12.sp,
|
||||||
color: Colors.white,
|
color:const Color(0xFF434343),
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
|
|
@ -300,7 +294,7 @@ class _LoginPageState extends State<LoginPage> {
|
||||||
),
|
),
|
||||||
InkWell(
|
InkWell(
|
||||||
onTap: () => Get.toNamed(Routes.register),
|
onTap: () => Get.toNamed(Routes.register),
|
||||||
child: quickText('账号注册', color: Colors.white),
|
child: quickText('账号注册', color: const Color(0xFF434343)),
|
||||||
)
|
)
|
||||||
],
|
],
|
||||||
),
|
),
|
||||||
|
|
@ -314,9 +308,9 @@ class _LoginPageState extends State<LoginPage> {
|
||||||
margin: EdgeInsets.symmetric(vertical: 10.h),
|
margin: EdgeInsets.symmetric(vertical: 10.h),
|
||||||
decoration: BoxDecoration(
|
decoration: BoxDecoration(
|
||||||
color: state.canLogin.value
|
color: state.canLogin.value
|
||||||
? const Color(0xFF4CC793)
|
? const Color(0xFF8C68FF)
|
||||||
: const Color(0xFFdddddd),
|
: const Color(0xFFdddddd),
|
||||||
boxShadow: [
|
/*boxShadow: [
|
||||||
BoxShadow(
|
BoxShadow(
|
||||||
color:
|
color:
|
||||||
const Color.fromRGBO(76, 199, 147, 0.5),
|
const Color.fromRGBO(76, 199, 147, 0.5),
|
||||||
|
|
@ -324,7 +318,7 @@ class _LoginPageState extends State<LoginPage> {
|
||||||
blurRadius: 14, //阴影模糊程度
|
blurRadius: 14, //阴影模糊程度
|
||||||
spreadRadius: 0.5, //阴影扩散程度
|
spreadRadius: 0.5, //阴影扩散程度
|
||||||
)
|
)
|
||||||
],
|
],*/
|
||||||
borderRadius: BorderRadius.all(
|
borderRadius: BorderRadius.all(
|
||||||
Radius.circular(17.w),
|
Radius.circular(17.w),
|
||||||
),
|
),
|
||||||
|
|
@ -371,7 +365,7 @@ class _LoginPageState extends State<LoginPage> {
|
||||||
}
|
}
|
||||||
//修改默认时边框颜色为绿色
|
//修改默认时边框颜色为绿色
|
||||||
return BorderSide(
|
return BorderSide(
|
||||||
width: 1.5.r, color: Colors.white);
|
width: 1.r, color: const Color(0xFF434343));
|
||||||
},
|
},
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
|
|
@ -408,7 +402,9 @@ class _LoginPageState extends State<LoginPage> {
|
||||||
)
|
)
|
||||||
],
|
],
|
||||||
),
|
),
|
||||||
)),
|
),
|
||||||
|
],
|
||||||
|
),
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
);
|
);
|
||||||
|
|
|
||||||