Skip to content

Commit

Permalink
[fix] 修复了多个bug
Browse files Browse the repository at this point in the history
# Conflicts:
#	lib/home/view/home_page.dart
  • Loading branch information
steven12138 committed May 11, 2024
1 parent 656bf17 commit de44733
Show file tree
Hide file tree
Showing 9 changed files with 36 additions and 39 deletions.
Binary file added flutter_01.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
30 changes: 14 additions & 16 deletions lib/auth/view/message/user_mails_page.dart
Original file line number Diff line number Diff line change
Expand Up @@ -30,22 +30,20 @@ class _UserMailboxPageState extends State<UserMailboxPage> {
backgroundColor:
WpyTheme.of(context).get(WpyColorKey.secondaryBackgroundColor),
appBar: AppBar(
title: Text('消息',
style: TextUtil.base.bold.sp(16).blue52hz(context)),
elevation: 0,
centerTitle: true,
backgroundColor:
WpyTheme.of(context).get(WpyColorKey.primaryBackgroundColor),
leading: Padding(
padding: const EdgeInsets.only(left: 15),
child: WButton(
child: Icon(Icons.arrow_back,
color:
WpyTheme.of(context).get(WpyColorKey.oldActionColor),
size: 32),
onPressed: () => Navigator.pop(context)),
),
systemOverlayStyle: SystemUiOverlayStyle.dark),
title: Text('消息', style: TextUtil.base.bold.sp(16).blue52hz(context)),
elevation: 0,
centerTitle: true,
backgroundColor:
WpyTheme.of(context).get(WpyColorKey.primaryBackgroundColor),
leading: Padding(
padding: const EdgeInsets.only(left: 15),
child: WButton(
child: Icon(Icons.arrow_back,
color: WpyTheme.of(context).get(WpyColorKey.oldActionColor),
size: 32),
onPressed: () => Navigator.pop(context)),
),
),
body: UserMailList(),
),
);
Expand Down
1 change: 1 addition & 0 deletions lib/auth/view/settings/toolbar_manage_page.dart
Original file line number Diff line number Diff line change
Expand Up @@ -269,6 +269,7 @@ class _ToolbarManagePageState extends State<ToolbarManagePage> {
AnimatedAppear(
duration: Duration(milliseconds: 300),
child: ReorderableBuilder(
dragChildBoxDecoration: BoxDecoration(),
children: [
for (int i = 0;
i < CommonPreferences.displayedTool.value.length;
Expand Down
2 changes: 1 addition & 1 deletion lib/commons/environment/config.dart
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ class EnvConfig {
/// 微北洋版本信息,请勿修改代码,这里的默认值由脚本生成
static const VERSIONCODE = int.fromEnvironment(
"VERSIONCODE",
defaultValue: 143,
defaultValue: 140,
);

/// 青年湖底域名 "https://www.zrzz.site:7013/" (DEFAULT) 或 "https://qnhd.twt.edu.cn/"
Expand Down
6 changes: 2 additions & 4 deletions lib/feedback/view/post_detail_page.dart
Original file line number Diff line number Diff line change
Expand Up @@ -907,8 +907,7 @@ class _PostDetailPageState extends State<PostDetailPage>
// lake.tabList[lake.currentTab].id]!
// .refreshController
// .requestRefresh();
ToastProvider.success(
'删除成功');
ToastProvider.success('删除成功');
Navigator.of(context).popAndPushNamed(
FeedbackRouter.home,
arguments: 2);
Expand Down Expand Up @@ -1028,7 +1027,6 @@ class _PostDetailPageState extends State<PostDetailPage>
),
),
elevation: 0,
systemOverlayStyle: SystemUiOverlayStyle.dark,
);

return AnnotatedRegion<SystemUiOverlayStyle>(
Expand All @@ -1038,7 +1036,7 @@ class _PostDetailPageState extends State<PostDetailPage>
: SystemUiOverlayStyle.light)
.copyWith(
systemNavigationBarColor: WpyTheme.of(context)
.get(WpyColorKey.primaryBackgroundColor));
.get(WpyColorKey.secondaryBackgroundColor));
})(),
child: PopScope(
canPop: true,
Expand Down
1 change: 0 additions & 1 deletion lib/home/view/home_page.dart
Original file line number Diff line number Diff line change
Expand Up @@ -240,7 +240,6 @@ class _HomePageState extends State<HomePage> with TickerProviderStateMixin {
onPopInvoked: (didPop) {
if (didPop) return;


CommonPreferences.lastActivityDialogShownDate.value = "";
if (_tabController.index == 0) {
if (_lastPressedAt == null ||
Expand Down
32 changes: 17 additions & 15 deletions lib/main.dart
Original file line number Diff line number Diff line change
Expand Up @@ -237,7 +237,6 @@ class WePeiYangAppState extends State<WePeiYangApp>
_listenForShortcutActions();
}


void _onBrightnessChanged() async =>
await Future.delayed(Duration(milliseconds: 400)).then(
(_) => WpyTheme.updateAutoDarkTheme(context),
Expand All @@ -248,14 +247,15 @@ class WePeiYangAppState extends State<WePeiYangApp>
if (state == AppLifecycleState.resumed) {
_listenForShortcutActions();
if (_shortcutResumeActionType == "com.twt.service.courses") {
WePeiYangApp.navigatorState.currentState?.pushNamed(ScheduleRouter.course);
WePeiYangApp.navigatorState.currentState
?.pushNamed(ScheduleRouter.course);
_shortcutResumeActionType = "";
}
else if(_shortcutResumeActionType == "com.twt.service.qr") {
} else if (_shortcutResumeActionType == "com.twt.service.qr") {
WePeiYangApp.navigatorState.currentState?.pushNamed(HomeRouter.casQR);
_shortcutResumeActionType = "";
}
checkEventList();
WpyTheme.updateAutoDarkTheme(context);
}
}

Expand Down Expand Up @@ -508,15 +508,16 @@ class _StartUpWidgetState extends State<StartUpWidget> {
Navigator.pushNamedAndRemoveUntil(
context, HomeRouter.home, (route) => false);
if (_shortcutActionType == "com.twt.service.courses") {
WePeiYangApp.navigatorState.currentState?.pushNamed(ScheduleRouter.course);
WePeiYangApp.navigatorState.currentState
?.pushNamed(ScheduleRouter.course);
_shortcutResumeActionType = "";
}
else if(_shortcutActionType == "com.twt.service.qr") {
WePeiYangApp.navigatorState.currentState?.pushNamed(HomeRouter.casQR);
} else if (_shortcutActionType == "com.twt.service.qr") {
WePeiYangApp.navigatorState.currentState
?.pushNamed(HomeRouter.casQR);
_shortcutResumeActionType = "";
}
}
if(Platform.isAndroid){
if (Platform.isAndroid) {
Navigator.pushNamedAndRemoveUntil(
context, HomeRouter.home, (route) => false);
}
Expand All @@ -533,15 +534,16 @@ class _StartUpWidgetState extends State<StartUpWidget> {
Navigator.pushNamedAndRemoveUntil(
context, HomeRouter.home, (route) => false);
if (_shortcutActionType == "com.twt.service.courses") {
WePeiYangApp.navigatorState.currentState?.pushNamed(ScheduleRouter.course);
WePeiYangApp.navigatorState.currentState
?.pushNamed(ScheduleRouter.course);
_shortcutResumeActionType = "";
}
else if(_shortcutActionType == "com.twt.service.qr") {
WePeiYangApp.navigatorState.currentState?.pushNamed(HomeRouter.casQR);
} else if (_shortcutActionType == "com.twt.service.qr") {
WePeiYangApp.navigatorState.currentState
?.pushNamed(HomeRouter.casQR);
_shortcutResumeActionType = "";
}
}
if(Platform.isAndroid){
if (Platform.isAndroid) {
Navigator.pushNamedAndRemoveUntil(
context, HomeRouter.home, (route) => false);
}
Expand All @@ -554,4 +556,4 @@ class _StartUpWidgetState extends State<StartUpWidget> {
(_) => Navigator.pushReplacementNamed(context, AuthRouter.login));
}
}
}
}
1 change: 0 additions & 1 deletion lib/message/feedback_message_page.dart
Original file line number Diff line number Diff line change
Expand Up @@ -204,7 +204,6 @@ class _FeedbackMessagePageState extends State<FeedbackMessagePage>
),
),
),
systemOverlayStyle: SystemUiOverlayStyle.dark,
),
),
body: TabBarView(
Expand Down
2 changes: 1 addition & 1 deletion pubspec.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ publish_to: "none" # Remove this line if you wish to publish to pub.dev

# 请保证 'package:we_pei_yang_flutter/commons/environment/config.dart'
# 中的 version 和 versionCode 保持一致
version: 4.4.3+143
version: 4.4.4+144

# 打包代码 flutter build apk --split-per-abi
# flutter build apk --target-platform android-arm,android-arm64 --split-per-abi
Expand Down

0 comments on commit de44733

Please sign in to comment.