Daisy 76ceab6f34 1,星锁主界面UI更新
2,锁列表UI更新
3,侧边栏 个人信息模块UI更新
4,添加锁模块UI更新
5,我的-设置模块UI更新
6,新增“添加授权管理员”页面UI布局
2023-07-27 15:26:30 +08:00

106 lines
4.1 KiB
Dart

import 'dart:async';
import 'package:flutter/material.dart';
import 'package:flutter_screenutil/flutter_screenutil.dart';
import 'package:get/get.dart';
import '../../../../appRouters.dart';
import '../../../../app_settings/app_colors.dart';
import '../../../../tools/submitBtn.dart';
import '../../../../tools/tf_input_haveBorder.dart';
import '../../../../tools/titleAppBar.dart';
import '../../../../translations/trans_lib.dart';
class MinePersonInfoEditAccountNextPage extends StatefulWidget {
const MinePersonInfoEditAccountNextPage({Key? key}) : super(key: key);
@override
State<MinePersonInfoEditAccountNextPage> createState() =>
_MinePersonInfoEditAccountNextPageState();
}
class _MinePersonInfoEditAccountNextPageState
extends State<MinePersonInfoEditAccountNextPage> {
final TextEditingController _editAccountController = TextEditingController();
late Timer _timer;
int _seconds = 60;
@override
Widget build(BuildContext context) {
return Scaffold(
backgroundColor: AppColors.mainBackgroundColor,
appBar: TitleAppBar(
barTitle: TranslationLoader.lanKeys!.modifyAccount!.tr,
haveBack: true,
backgroundColor: AppColors.mainColor),
body: Column(
children: [
Container(
width: 1.sw,
// color: Colors.grey,
padding: EdgeInsets.only(left: 30.w, top: 15.h, bottom: 15.h),
child: Text(
TranslationLoader.lanKeys!.pleaseEnterNewAccountNumber!.tr,
style:
TextStyle(fontWeight: FontWeight.w600, fontSize: 24.sp),
)),
Container(
padding: EdgeInsets.only(
left: 30.w, right: 30.w, top: 10.h, bottom: 10.h),
child: TFInputHaveBorder(
controller: _editAccountController,
label: TranslationLoader.lanKeys!.pleaseEnterNumberOrEmail!.tr,
),
),
Container(
padding: EdgeInsets.only(
left: 30.w, right: 30.w, top: 20.h, bottom: 10.h),
child: TFInputHaveBorder(
controller: _editAccountController,
label:
"${TranslationLoader.lanKeys!.pleaseEnter!.tr} ${TranslationLoader.lanKeys!.verificationCode!.tr}",
rightSlot: GestureDetector(
child: Container(
width: 180.w,
height: 90.h,
padding: EdgeInsets.all(5.h),
margin: EdgeInsets.only(right: 10.w),
// decoration: BoxDecoration(
// color: AppColors.mainColor,
// borderRadius: BorderRadius.circular(5)
// ),
child: Center(
child: Text(
_seconds == 60
? '${TranslationLoader.lanKeys!.getTip!.tr}${TranslationLoader.lanKeys!.verificationCode!.tr}'
: (_seconds < 10)
? '0$_seconds s'
: '$_seconds s',
textAlign: TextAlign.center,
style: TextStyle(
color: Colors.grey,
fontSize: 26.sp,
)),
),
),
onTap: () {
if (_seconds == 60) {
// _setVerify();
} else {
// Toast.show(msg: '正在获取验证码');
}
},
)),
),
SizedBox(height: 50.w),
SubmitBtn(
btnName: TranslationLoader.lanKeys!.sure!.tr,
fontSize: 28.sp,
borderRadius: 20.w,
padding: EdgeInsets.only(top: 25.w, bottom: 25.w),
onClick: () {}),
],
));
}
}