From ab895e7732262e96af6314d5b0555ffc53a8273e Mon Sep 17 00:00:00 2001 From: czz <862977248@qq.com> Date: Tue, 1 Jul 2025 22:19:40 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E6=94=B9=E4=BA=BA=E5=91=98=E8=B5=84?= =?UTF-8?q?=E6=96=99=E7=84=A6=E7=82=B9=E5=86=B2=E7=AA=81?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- assets/mhlangs/zh_CN.json | 6 +- lib/common/color/appConstants.dart | 4 +- lib/pages/mh_page/LanguagePage.dart | 2 +- lib/pages/mh_page/bluetooth.dart | 7 +- lib/pages/mh_page/people_info.dart | 120 ++++---------------------- lib/pages/mh_page/privacy_policy.dart | 1 - 6 files changed, 31 insertions(+), 109 deletions(-) diff --git a/assets/mhlangs/zh_CN.json b/assets/mhlangs/zh_CN.json index e809a21..db843b2 100644 --- a/assets/mhlangs/zh_CN.json +++ b/assets/mhlangs/zh_CN.json @@ -205,6 +205,8 @@ "请选择身高": "请输入身高", "人员资料": "人员资料", "请输入姓名": "请输入姓名", - "解除分享":"解除分享" - + "解除分享": "解除分享", + "最高分": "最高分", + "最低分": "最低分", + "本周平均分":"本周平均分" } \ No newline at end of file diff --git a/lib/common/color/appConstants.dart b/lib/common/color/appConstants.dart index 7ab9256..ed0d07d 100644 --- a/lib/common/color/appConstants.dart +++ b/lib/common/color/appConstants.dart @@ -4,7 +4,7 @@ import 'package:vbvs_app/common/util/FitTool.dart'; import 'package:vbvs_app/common/util/MyUtils.dart'; import 'package:vbvs_app/enum/APPPackageType.dart'; -class AppConstants { +class AppConstants { // App-related constants static const int code_time = 60; //验证码倒计时 static const int limit = 10; //分页数量 @@ -48,5 +48,5 @@ class AppConstants { //系统参数 //运行打包APP模式 - int ent_type = APPPackageType.TH.code;//1.默认太和 2.欢睡 3.眠花糖 + int ent_type = APPPackageType.MHT.code; //1.默认太和 2.欢睡 3.眠花糖 } diff --git a/lib/pages/mh_page/LanguagePage.dart b/lib/pages/mh_page/LanguagePage.dart index 3040719..bb458a4 100644 --- a/lib/pages/mh_page/LanguagePage.dart +++ b/lib/pages/mh_page/LanguagePage.dart @@ -65,7 +65,7 @@ class LanguagePage extends GetView { ), // 左侧图标 Positioned( - left: 20.rpx, + left: 0.rpx, child: returnIconButtomNew, ), ], diff --git a/lib/pages/mh_page/bluetooth.dart b/lib/pages/mh_page/bluetooth.dart index e22fd13..7fb6246 100644 --- a/lib/pages/mh_page/bluetooth.dart +++ b/lib/pages/mh_page/bluetooth.dart @@ -166,8 +166,11 @@ class _BluetoothPageState extends State { context, '详情', "/devicePeopleInfo", arguments: obsData), _buildMenuButton( - context, '人员资料', "/peopleInfoPage", - arguments: obsData,), + context, + '人员资料', + "/peopleInfoPage", + arguments: obsData, + ), _buildMenuButton( context, '房间选择', "/roomPickerPage", arguments: obsData), diff --git a/lib/pages/mh_page/people_info.dart b/lib/pages/mh_page/people_info.dart index 17969a4..d45dfd1 100644 --- a/lib/pages/mh_page/people_info.dart +++ b/lib/pages/mh_page/people_info.dart @@ -310,7 +310,7 @@ class PeopleInfoPage extends GetView { decoration: BoxDecoration(), child: InkWell( onTap: () { - // 触摸收起键盘 + // 延迟执行的代码 FocusScope.of(context) .requestFocus( FocusNode()); @@ -318,7 +318,6 @@ class PeopleInfoPage extends GetView { const Duration( milliseconds: 250), () { - // 延迟执行的代码 showOneSelectionDialog( context, arr: ["女", "男"], @@ -338,12 +337,6 @@ class PeopleInfoPage extends GetView { sindex; // 👈 保存为 0 / 1 controller .updateAll(); - print( - "gender $sindex"); - }).then((d) { - // Timer(Duration.zero, () { - // FocusScope.of(context).unfocus(); - // }); }); }); }, @@ -409,77 +402,6 @@ class PeopleInfoPage extends GetView { )), ), getLine(), - // Container( - // width: double.infinity, - // height: 90.rpx, - // margin: EdgeInsets.only( - // left: 40.rpx, right: 35.rpx), - // decoration: BoxDecoration(), - // child: Row( - // mainAxisSize: MainAxisSize.max, - // mainAxisAlignment: - // MainAxisAlignment.spaceBetween, - // children: [ - // Text( - // '身高(cm)', - // style: TextStyle( - // fontFamily: 'Readex Pro', - // color: Color(0xFF9EA4B7), - // fontSize: 30.rpx, - // letterSpacing: 0, - // ), - // ), - // InkWell( - // onTap: () { - // FocusScope.of(context).unfocus(); - // Future.delayed( - // const Duration( - // milliseconds: 250), () { - // showHeightPickerDialog( - // context, - // initialHeight: controller - // .model - // .peopleList[index] - // ['height'] ?? - // 170, - // onConfirm: - // (int selectedHeight) { - // controller.model.peopleList[ - // index]['height'] = - // selectedHeight - // .toString(); - // controller.updateAll(); - // print( - // "身高: $selectedHeight cm"); - // }, - // ); - // }); - // }, - // child: Row( - // children: [ - // Text( - // controller.model.peopleList[ - // index] - // ['height'] != - // null - // ? "${controller.model.peopleList[index]['height']} cm" - // : '', - // style: TextStyle( - // fontFamily: 'Readex Pro', - // color: Colors.white, - // fontSize: 30.rpx, - // ), - // ), - // SizedBox(width: 16.rpx), - // Icon(Icons.expand_more, - // color: Colors.white, - // size: 48.rpx), - // ], - // ), - // ), - // ], - // ), - // ), Container( width: double.infinity, height: 90.rpx, @@ -489,25 +411,26 @@ class PeopleInfoPage extends GetView { decoration: BoxDecoration(), child: InkWell( onTap: () { + // Convert string height to int for initial value + final currentHeight = + controller.model + .peopleList[ + index]['height']; + final initialHeight = + currentHeight != null + ? int.tryParse( + currentHeight + .toString()) ?? + 170 + : 170; + FocusScope.of(context) - .unfocus(); + .requestFocus( + FocusNode()); Future.delayed( const Duration( milliseconds: 250), () { - // Convert string height to int for initial value - final currentHeight = - controller.model - .peopleList[ - index]['height']; - final initialHeight = - currentHeight != null - ? int.tryParse( - currentHeight - .toString()) ?? - 170 - : 170; - showHeightPickerDialog( context, initialHeight: @@ -591,7 +514,8 @@ class PeopleInfoPage extends GetView { child: InkWell( onTap: () { FocusScope.of(context) - .unfocus(); + .requestFocus( + FocusNode()); Future.delayed( const Duration( milliseconds: @@ -674,7 +598,6 @@ class PeopleInfoPage extends GetView { ), )), ), - getLine(), Obx( () => Container( @@ -686,7 +609,7 @@ class PeopleInfoPage extends GetView { decoration: BoxDecoration(), child: InkWell( onTap: () { - // 触摸收起键盘 + // 延迟执行的代码 FocusScope.of(context) .requestFocus( FocusNode()); @@ -694,7 +617,6 @@ class PeopleInfoPage extends GetView { const Duration( milliseconds: 250), () { - // 延迟执行的代码 showDateSelectionDialog( context, checkDate: controller @@ -718,10 +640,6 @@ class PeopleInfoPage extends GetView { controller .updateAll(); print("$d"); - }).then((d) { - // Timer(Duration.zero, () { - // FocusScope.of(context).unfocus(); - // }); }); }); }, diff --git a/lib/pages/mh_page/privacy_policy.dart b/lib/pages/mh_page/privacy_policy.dart index 1e859d1..7879c0b 100644 --- a/lib/pages/mh_page/privacy_policy.dart +++ b/lib/pages/mh_page/privacy_policy.dart @@ -71,7 +71,6 @@ class _PrivacyPolicyPageState extends State { fontSize: 30.rpx, ), ), - /// 左边返回按钮 Positioned( left: 0,