diff --git a/lan/lan_en.json b/lan/lan_en.json index 3627dc85..12d66206 100755 --- a/lan/lan_en.json +++ b/lan/lan_en.json @@ -57,9 +57,11 @@ "删除公司": "Delete Company", "密码详情": "Password Detail", "修改密码": "Modify Password", + "添加虹膜": "Add Iris", + "添加门磁": "Add Door Magnetic", + "添加无线键盘": "Add Wireless Keyboard", + "添加手掌": "Add Palm", - "cancel": "Cancel", - "add": "Add", "accountNumber": "AccountNumber", "volumeAuthorizationLock": "Volume Authorization Lock", "authorizedAdminTip": "The authorized administrator has important access to this lock, so make sure you only send it to people you trust", diff --git a/lan/lan_keys.json b/lan/lan_keys.json index b30d9a75..0445b481 100755 --- a/lan/lan_keys.json +++ b/lan/lan_keys.json @@ -57,9 +57,11 @@ "删除公司": "删除公司", "密码详情": "密码详情", "修改密码": "修改密码", + "添加虹膜": "添加虹膜", + "添加门磁": "添加门磁", + "添加无线键盘": "添加无线键盘", + "添加手掌": "添加手掌", - "cancel":"cancel", - "add":"add", "accountNumber":"accountNumber", "volumeAuthorizationLock":"volumeAuthorizationLock", "authorizedAdminTip":"authorizedAdminTip", diff --git a/lan/lan_zh.json b/lan/lan_zh.json index ea4843b2..6b833cb2 100755 --- a/lan/lan_zh.json +++ b/lan/lan_zh.json @@ -57,9 +57,11 @@ "删除公司": "删除公司", "密码详情": "密码详情", "修改密码": "修改密码", + "添加虹膜": "添加虹膜", + "添加门磁": "添加门磁", + "添加无线键盘": "添加无线键盘", + "添加手掌": "添加手掌", - "cancel": "取消", - "add": "添加", "accountNumber": "账号", "volumeAuthorizationLock": "批量授权锁", "authorizedAdminTip": "授权管理员拥有操作这把锁的重要权限,请确保只发给我你信任的人", diff --git a/lib/main/lockDetail/authorizedAdmin/volumeAuthorizationLock/volumeAuthorizationLockManage/volumeAuthorizationLockManage_page.dart b/lib/main/lockDetail/authorizedAdmin/volumeAuthorizationLock/volumeAuthorizationLockManage/volumeAuthorizationLockManage_page.dart index 400d9ba5..60eb53ce 100755 --- a/lib/main/lockDetail/authorizedAdmin/volumeAuthorizationLock/volumeAuthorizationLockManage/volumeAuthorizationLockManage_page.dart +++ b/lib/main/lockDetail/authorizedAdmin/volumeAuthorizationLock/volumeAuthorizationLockManage/volumeAuthorizationLockManage_page.dart @@ -23,8 +23,7 @@ class _VolumeAuthorizationLockManagePageState return Scaffold( backgroundColor: AppColors.mainBackgroundColor, appBar: TitleAppBar( - barTitle: - "${TranslationLoader.lanKeys!.add!.tr}${TranslationLoader.lanKeys!.authorizedAdmin!.tr}", + barTitle: '添加授权管理员'.tr, haveBack: true, backgroundColor: AppColors.mainColor), body: Column( diff --git a/lib/main/lockDetail/checkingIn/checkingInHolidays/checkingInSetHolidays/checkingInSetHolidays_page.dart b/lib/main/lockDetail/checkingIn/checkingInHolidays/checkingInSetHolidays/checkingInSetHolidays_page.dart index 8176833b..2042376e 100755 --- a/lib/main/lockDetail/checkingIn/checkingInHolidays/checkingInSetHolidays/checkingInSetHolidays_page.dart +++ b/lib/main/lockDetail/checkingIn/checkingInHolidays/checkingInSetHolidays/checkingInSetHolidays_page.dart @@ -228,7 +228,7 @@ class _CheckingInSetHolidaysPageState extends State { child: Container( alignment: Alignment.center, padding: const EdgeInsets.only(left: 22, right: 12), - child: Text(TranslationLoader.lanKeys!.cancel!.tr, + child: Text('取消'.tr, style: const TextStyle(color: Colors.black, fontSize: 16.0)), ), ), diff --git a/lib/main/lockDetail/checkingIn/checkingInList/checkingInList_page.dart b/lib/main/lockDetail/checkingIn/checkingInList/checkingInList_page.dart index 20ad51cb..0864fc3b 100755 --- a/lib/main/lockDetail/checkingIn/checkingInList/checkingInList_page.dart +++ b/lib/main/lockDetail/checkingIn/checkingInList/checkingInList_page.dart @@ -535,7 +535,7 @@ class _CheckingInListPageState extends State { //默认的索引 normalIndex: 0, title: TranslationLoader.lanKeys!.rankingList!.tr, - cancelTitle: TranslationLoader.lanKeys!.cancel!.tr, + cancelTitle: '取消'.tr, sureTitle: '确定'.tr, //要显示的列表 //可自定义数据适配器 diff --git a/lib/main/lockDetail/checkingIn/checkingInStaff/checkingInSetAddStaff/checkingInAddStaff_page.dart b/lib/main/lockDetail/checkingIn/checkingInStaff/checkingInSetAddStaff/checkingInAddStaff_page.dart index bba3fb01..839054b7 100755 --- a/lib/main/lockDetail/checkingIn/checkingInStaff/checkingInSetAddStaff/checkingInAddStaff_page.dart +++ b/lib/main/lockDetail/checkingIn/checkingInStaff/checkingInSetAddStaff/checkingInAddStaff_page.dart @@ -34,7 +34,7 @@ class _CheckingInAddStaffPageState extends State { backgroundColor: AppColors.mainBackgroundColor, appBar: TitleAppBar( barTitle: - "${state.isAdd.value == "1" ? TranslationLoader.lanKeys!.add!.tr : "编辑".tr}${TranslationLoader.lanKeys!.staff!.tr}", + "${state.isAdd.value == "1" ? '添加'.tr : "编辑".tr}${TranslationLoader.lanKeys!.staff!.tr}", haveBack: true, backgroundColor: AppColors.mainColor), body: Column( @@ -365,7 +365,7 @@ class _CheckingInAddStaffPageState extends State { //默认的索引 normalIndex: 0, title: title, - cancelTitle: TranslationLoader.lanKeys!.cancel!.tr, + cancelTitle: '取消'.tr, sureTitle: '确定'.tr, //要显示的列表 //可自定义数据适配器 diff --git a/lib/main/lockDetail/iris/irisList/irisList_page.dart b/lib/main/lockDetail/iris/irisList/irisList_page.dart index 299ea3a7..229c5b88 100755 --- a/lib/main/lockDetail/iris/irisList/irisList_page.dart +++ b/lib/main/lockDetail/iris/irisList/irisList_page.dart @@ -4,6 +4,7 @@ import 'package:flutter_screenutil/flutter_screenutil.dart'; import 'package:get/get.dart'; import 'package:star_lock/main/lockDetail/fingerprint/fingerprintList/fingerprintListData_entity.dart'; import 'package:star_lock/main/lockDetail/iris/irisList/irisList_logic.dart'; +import 'package:star_lock/main/lockDetail/iris/irisList/irisList_state.dart'; import 'package:star_lock/main/lockMian/lockMain/lockMain_logic.dart'; import 'package:star_lock/tools/keySearchWidget.dart'; import 'package:star_lock/tools/left_slide/left_slide_actions.dart'; @@ -25,8 +26,8 @@ class IrisListPage extends StatefulWidget { } class _IrisListPageState extends State { - final logic = Get.put(IrisListLogic()); - final state = Get.find().state; + final IrisListLogic logic = Get.put(IrisListLogic()); + final IrisListState state = Get.find().state; @override Widget build(BuildContext context) { @@ -36,14 +37,14 @@ class _IrisListPageState extends State { barTitle: '虹膜'.tr, haveBack: true, backgroundColor: AppColors.mainColor, - actionsList: [ + actionsList: [ TextButton( child: Text( '重置'.tr, style: TextStyle(color: Colors.white, fontSize: 24.sp), ), onPressed: () async { - final isDemoMode = await Storage.getBool(ifIsDemoModeOrNot); + final bool? isDemoMode = await Storage.getBool(ifIsDemoModeOrNot); if (isDemoMode == false) { final bool isNetWork = await LockMainLogic.to()?.judgeTheNetwork() ?? false; @@ -53,14 +54,14 @@ class _IrisListPageState extends State { showDeletAlertDialog(context); } else { // Get.toNamed(Routers.selectLockTypePage); - logic.showToast("演示模式"); + logic.showToast('演示模式'); } }, ), ], ), body: Column( - children: [ + children: [ KeySearchWidget( editingController: state.searchController, onSubmittedAction: () { @@ -72,7 +73,7 @@ class _IrisListPageState extends State { ), Expanded(child: _buildMainUI()), AddBottomWhiteBtn( - btnName: '${TranslationLoader.lanKeys!.add!.tr}${'虹膜'.tr}', + btnName: '添加虹膜'.tr, onClick: () async { // var data = // await Get.toNamed(Routers.addFaceTypeManagePage, arguments: { @@ -80,9 +81,9 @@ class _IrisListPageState extends State { // "fromType": 1 // 1从添加钥匙列表进入 2从考勤添加员工入口进入 // }); final data = - await Get.toNamed(Routers.addIrisTypeManagePage, arguments: { - "lockId": state.lockId.value, - "fromType": 1 // 1从添加钥匙列表进入 2从考勤添加员工入口进入 + await Get.toNamed(Routers.addIrisTypeManagePage, arguments: { + 'lockId': state.lockId.value, + 'fromType': 1 // 1从添加钥匙列表进入 2从考勤添加员工入口进入 }); if (data != null) { // logic.getFaceListData(); @@ -100,7 +101,7 @@ class _IrisListPageState extends State { return Obx(() => state.faceItemListData.value.isNotEmpty ? ListView.separated( itemCount: state.faceItemListData.value.length, - itemBuilder: (c, index) { + itemBuilder: (BuildContext c, int index) { final FingerprintItemData getFaceItemData = state.faceItemListData.value[index]; // 人脸 @@ -109,7 +110,7 @@ class _IrisListPageState extends State { tag: getFaceItemData.faceName!, key: Key(getFaceItemData.faceName!), actionsWidth: 60, - actions: [ + actions: [ _buildDeleteBtn(getFaceItemData), ], decoration: const BoxDecoration( @@ -121,17 +122,17 @@ class _IrisListPageState extends State { (getFaceItemData.faceType! != 1) ? (getFaceItemData.endDate! < DateTime.now().millisecondsSinceEpoch - ? "已失效" - : "") - : "", + ? '已失效' + : '') + : '', getFaceItemData.validTimeStr!, // fingerprintItemData.fingerprintType! == 1 // ? "永久" // : "${DateTool().dateToYMDHNString(fingerprintItemData.startDate.toString())} - ${DateTool().dateToYMDHNString(fingerprintItemData.endDate.toString())}", () async { final data = - await Get.toNamed(Routers.faceDetailPage, arguments: { - "faceItemData": getFaceItemData, + await Get.toNamed(Routers.faceDetailPage, arguments: { + 'faceItemData': getFaceItemData, }); if (data != null) { // logic.getFaceListData(); @@ -182,8 +183,8 @@ class _IrisListPageState extends State { context: context, builder: (BuildContext context) { return ShowIosTipView( - title: "提示", - tipTitle: "确定要删除吗?", + title: '提示', + tipTitle: '确定要删除吗?', sureClick: () async { Get.back(); state.isDeletFaceData = true; @@ -212,17 +213,17 @@ class _IrisListPageState extends State { // // borderRadius: BorderRadius.circular(10.w), // ), child: Row( - children: [ + children: [ SizedBox(width: 30.w), Image.asset(lockTypeIcon, width: 60.w, height: 60.w), SizedBox(width: 20.w), Expanded( child: Column( mainAxisAlignment: MainAxisAlignment.center, - children: [ + children: [ Row( // mainAxisAlignment: MainAxisAlignment.spaceBetween, - children: [ + children: [ Text(lockTypeTitle, style: TextStyle( fontSize: 24.sp, color: AppColors.blackColor)), @@ -235,7 +236,7 @@ class _IrisListPageState extends State { SizedBox(height: 5.h), Row( mainAxisAlignment: MainAxisAlignment.start, - children: [ + children: [ Text(showTime, style: TextStyle( fontSize: 18.sp, @@ -256,13 +257,13 @@ class _IrisListPageState extends State { void showDeletAlertDialog(BuildContext context) { showCupertinoDialog( context: context, - builder: (context) { + builder: (BuildContext context) { return CupertinoAlertDialog( - title: const Text("提示"), + title: const Text('提示'), content: const Text('重置后,该锁的人脸都将被删除哦,确认要重置吗?'), - actions: [ + actions: [ CupertinoDialogAction( - child: Text(TranslationLoader.lanKeys!.cancel!.tr), + child: Text('取消'.tr), onPressed: () { Navigator.pop(context); }, @@ -273,8 +274,8 @@ class _IrisListPageState extends State { Navigator.pop(context); state.isDeletFaceData = true; state.isDeletAll = true; - state.deletKeyID = "1"; - state.deletUserID = "DeleteAll!@#"; + state.deletKeyID = '1'; + state.deletUserID = 'DeleteAll!@#'; state.deletFaceNo = 255; // logic.senderAddFace(); }, diff --git a/lib/main/lockDetail/lockSet/automaticBlocking/automaticBlocking_page.dart b/lib/main/lockDetail/lockSet/automaticBlocking/automaticBlocking_page.dart index 0051a7b4..51e85f47 100755 --- a/lib/main/lockDetail/lockSet/automaticBlocking/automaticBlocking_page.dart +++ b/lib/main/lockDetail/lockSet/automaticBlocking/automaticBlocking_page.dart @@ -104,8 +104,7 @@ class _AutomaticBlockingPageState extends State //默认的索引 normalIndex: 0, title: TranslationLoader.lanKeys!.time!.tr, - cancelTitle: - TranslationLoader.lanKeys!.cancel!.tr, + cancelTitle:'取消'.tr, sureTitle: '确定'.tr, //要显示的列表 data: list, diff --git a/lib/main/lockDetail/lockSet/doorMagnetic/addDoorMagnetic/addDoorMagnetic_page.dart b/lib/main/lockDetail/lockSet/doorMagnetic/addDoorMagnetic/addDoorMagnetic_page.dart index 64c5e62b..f6069b4e 100755 --- a/lib/main/lockDetail/lockSet/doorMagnetic/addDoorMagnetic/addDoorMagnetic_page.dart +++ b/lib/main/lockDetail/lockSet/doorMagnetic/addDoorMagnetic/addDoorMagnetic_page.dart @@ -21,8 +21,7 @@ class _AddDoorMagneticPageState extends State { return Scaffold( backgroundColor: AppColors.mainBackgroundColor, appBar: TitleAppBar( - barTitle: - "${TranslationLoader.lanKeys!.add!.tr}${TranslationLoader.lanKeys!.doorMagnetic!.tr}", + barTitle: '添加门磁'.tr, haveBack: true, backgroundColor: AppColors.mainColor), body: ListView( diff --git a/lib/main/lockDetail/lockSet/doorMagnetic/doorMagneticList/doorMagnetic_page.dart b/lib/main/lockDetail/lockSet/doorMagnetic/doorMagneticList/doorMagnetic_page.dart index 5ac03168..7f215ddd 100755 --- a/lib/main/lockDetail/lockSet/doorMagnetic/doorMagneticList/doorMagnetic_page.dart +++ b/lib/main/lockDetail/lockSet/doorMagnetic/doorMagneticList/doorMagnetic_page.dart @@ -46,8 +46,7 @@ class _DoorMagneticPageState extends State with BaseWidget { Container( margin: EdgeInsets.only(left: 200.w, right: 200.w), child: SubmitBtn( - btnName: - "${TranslationLoader.lanKeys!.add!.tr}${TranslationLoader.lanKeys!.doorMagnetic!.tr}", + btnName:'添加门磁'.tr, onClick: () { Navigator.pushNamed(context, Routers.addDoorMagneticPage); }), diff --git a/lib/main/lockDetail/lockSet/wirelessKeyboard/addWirelessKeyboard/addWirelessKeyboard_page.dart b/lib/main/lockDetail/lockSet/wirelessKeyboard/addWirelessKeyboard/addWirelessKeyboard_page.dart index 11c5a8fe..32e05b3a 100755 --- a/lib/main/lockDetail/lockSet/wirelessKeyboard/addWirelessKeyboard/addWirelessKeyboard_page.dart +++ b/lib/main/lockDetail/lockSet/wirelessKeyboard/addWirelessKeyboard/addWirelessKeyboard_page.dart @@ -22,8 +22,7 @@ class _AddWirelessKeyboardPageState extends State { return Scaffold( backgroundColor: AppColors.mainBackgroundColor, appBar: TitleAppBar( - barTitle: - "${TranslationLoader.lanKeys!.add!.tr}${TranslationLoader.lanKeys!.wirelessKeyboard!.tr}", + barTitle:'添加无线键盘'.tr, haveBack: true, backgroundColor: AppColors.mainColor), body: ListView( diff --git a/lib/main/lockDetail/lockSet/wirelessKeyboard/addWirelessKeyboardScreenNotLightOn/addWirelessKeyboardScreenNotLightOn_page.dart b/lib/main/lockDetail/lockSet/wirelessKeyboard/addWirelessKeyboardScreenNotLightOn/addWirelessKeyboardScreenNotLightOn_page.dart index 22b46edc..de13ec84 100755 --- a/lib/main/lockDetail/lockSet/wirelessKeyboard/addWirelessKeyboardScreenNotLightOn/addWirelessKeyboardScreenNotLightOn_page.dart +++ b/lib/main/lockDetail/lockSet/wirelessKeyboard/addWirelessKeyboardScreenNotLightOn/addWirelessKeyboardScreenNotLightOn_page.dart @@ -23,8 +23,7 @@ class _AddWirelessKeyboardScreenNotLightOnPageState return Scaffold( backgroundColor: AppColors.mainBackgroundColor, appBar: TitleAppBar( - barTitle: - "${TranslationLoader.lanKeys!.add!.tr}${TranslationLoader.lanKeys!.wirelessKeyboard!.tr}", + barTitle:'添加无线键盘'.tr, haveBack: true, backgroundColor: AppColors.mainColor), body: ListView( diff --git a/lib/main/lockDetail/lockSet/wirelessKeyboard/wirelessKeyboardList/wirelessKeyboard_page.dart b/lib/main/lockDetail/lockSet/wirelessKeyboard/wirelessKeyboardList/wirelessKeyboard_page.dart index befe0901..031883ad 100755 --- a/lib/main/lockDetail/lockSet/wirelessKeyboard/wirelessKeyboardList/wirelessKeyboard_page.dart +++ b/lib/main/lockDetail/lockSet/wirelessKeyboard/wirelessKeyboardList/wirelessKeyboard_page.dart @@ -41,7 +41,7 @@ class _WirelessKeyboardPageState extends State { if (!isNetWork) { return; } - _showDialog(context); + _showDialog(); }, ), ], @@ -50,8 +50,7 @@ class _WirelessKeyboardPageState extends State { children: [ Expanded(child: _buildMainUI()), SubmitBtn( - btnName: - "${TranslationLoader.lanKeys!.add!.tr}${TranslationLoader.lanKeys!.wirelessKeyboard!.tr}", + btnName:'添加无线键盘'.tr, onClick: () { Navigator.pushNamed(context, Routers.addWirelessKeyboardPage); }), @@ -143,15 +142,15 @@ class _WirelessKeyboardPageState extends State { } //是否重置弹窗 - void _showDialog(widgetContext) { + void _showDialog() { showCupertinoDialog( - context: widgetContext, + context: Get.context!, builder: (context) { return CupertinoAlertDialog( title: const Text('该锁的无线键盘都将被删除'), actions: [ CupertinoDialogAction( - child: Text(TranslationLoader.lanKeys!.cancel!.tr), + child: Text('取消'.tr), onPressed: () { Navigator.of(context).pop(); }, diff --git a/lib/main/lockDetail/palm/palmList/palmList_page.dart b/lib/main/lockDetail/palm/palmList/palmList_page.dart index 0f35826f..814ea8bb 100755 --- a/lib/main/lockDetail/palm/palmList/palmList_page.dart +++ b/lib/main/lockDetail/palm/palmList/palmList_page.dart @@ -53,7 +53,7 @@ class _PalmListPageState extends State { showDeletAlertDialog(context); } else { // Get.toNamed(Routers.selectLockTypePage); - logic.showToast("演示模式"); + logic.showToast('演示模式'); } }, ), @@ -72,7 +72,7 @@ class _PalmListPageState extends State { ), Expanded(child: _buildMainUI()), AddBottomWhiteBtn( - btnName: '${TranslationLoader.lanKeys!.add!.tr}手掌', + btnName: '添加手掌'.tr, onClick: () async { // var data = // await Get.toNamed(Routers.addFaceTypeManagePage, arguments: { @@ -81,8 +81,8 @@ class _PalmListPageState extends State { // }); var data = await Get.toNamed(Routers.addPalmTypeManagePage, arguments: { - "lockId": state.lockId.value, - "fromType": 1 // 1从添加钥匙列表进入 2从考勤添加员工入口进入 + 'lockId': state.lockId.value, + 'fromType': 1 // 1从添加钥匙列表进入 2从考勤添加员工入口进入 }); if (data != null) { // logic.getFaceListData(); @@ -121,9 +121,9 @@ class _PalmListPageState extends State { (getFaceItemData.faceType! != 1) ? (getFaceItemData.endDate! < DateTime.now().millisecondsSinceEpoch - ? "已失效" - : "") - : "", + ? '已失效' + : '') + : '', getFaceItemData.validTimeStr!, // fingerprintItemData.fingerprintType! == 1 // ? "永久" @@ -131,7 +131,7 @@ class _PalmListPageState extends State { () async { var data = await Get.toNamed(Routers.faceDetailPage, arguments: { - "faceItemData": getFaceItemData, + 'faceItemData': getFaceItemData, }); if (data != null) { // logic.getFaceListData(); @@ -182,8 +182,8 @@ class _PalmListPageState extends State { context: context, builder: (BuildContext context) { return ShowIosTipView( - title: "提示", - tipTitle: "确定要删除吗?", + title: '提示', + tipTitle: '确定要删除吗?', sureClick: () async { Get.back(); state.isDeletFaceData = true; @@ -258,11 +258,11 @@ class _PalmListPageState extends State { context: context, builder: (context) { return CupertinoAlertDialog( - title: const Text("提示"), + title: const Text('提示'), content: const Text('重置后,该锁的人脸都将被删除哦,确认要重置吗?'), actions: [ CupertinoDialogAction( - child: Text(TranslationLoader.lanKeys!.cancel!.tr), + child: Text('取消'.tr), onPressed: () { Navigator.pop(context); }, @@ -273,8 +273,8 @@ class _PalmListPageState extends State { Navigator.pop(context); state.isDeletFaceData = true; state.isDeletAll = true; - state.deletKeyID = "1"; - state.deletUserID = "DeleteAll!@#"; + state.deletKeyID = '1'; + state.deletUserID = 'DeleteAll!@#'; state.deletFaceNo = 255; // logic.senderAddFace(); }, diff --git a/lib/mine/mineSet/authorizedAdministrator/addAuthorizedAdministrator/addAuthorizedAdministrator_logic.dart b/lib/mine/mineSet/authorizedAdministrator/addAuthorizedAdministrator/addAuthorizedAdministrator_logic.dart index fab92204..b2373937 100755 --- a/lib/mine/mineSet/authorizedAdministrator/addAuthorizedAdministrator/addAuthorizedAdministrator_logic.dart +++ b/lib/mine/mineSet/authorizedAdministrator/addAuthorizedAdministrator/addAuthorizedAdministrator_logic.dart @@ -96,7 +96,7 @@ class AddAuthorizedAdministratorLogic extends BaseGetXController { title: const Text('接收者号码未注册,请重新发送'), actions: [ CupertinoDialogAction( - child: Text(TranslationLoader.lanKeys!.cancel!.tr), + child: Text('取消'.tr), onPressed: Get.back, ), CupertinoDialogAction( diff --git a/lib/mine/mineSet/lockGroup/groupEditLock/groupEditLock_page.dart b/lib/mine/mineSet/lockGroup/groupEditLock/groupEditLock_page.dart index 9ee28a8f..a7f60c98 100755 --- a/lib/mine/mineSet/lockGroup/groupEditLock/groupEditLock_page.dart +++ b/lib/mine/mineSet/lockGroup/groupEditLock/groupEditLock_page.dart @@ -36,7 +36,7 @@ class _GroupEditLockPageState extends State { backgroundColor: AppColors.mainBackgroundColor, appBar: TitleAppBar( barTitle: state.type == 0 - ? TranslationLoader.lanKeys!.add!.tr + ? '添加'.tr : '删除'.tr, haveBack: true, backgroundColor: AppColors.mainColor), diff --git a/lib/mine/mineSet/lockGroup/lockGroupDetailList/lockItemList_page.dart b/lib/mine/mineSet/lockGroup/lockGroupDetailList/lockItemList_page.dart index d28054ea..f6c28e84 100755 --- a/lib/mine/mineSet/lockGroup/lockGroupDetailList/lockItemList_page.dart +++ b/lib/mine/mineSet/lockGroup/lockGroupDetailList/lockItemList_page.dart @@ -25,9 +25,9 @@ class _LockItemListPageState extends State { @override Widget build(BuildContext context) { Map map = Get.arguments; - GroupListItem groupListItem = map["groupListItem"]; + GroupListItem groupListItem = map['groupListItem']; lockList = groupListItem.lockList!; - ungrouped = map["ungrouped"]; + ungrouped = map['ungrouped']; return Scaffold( backgroundColor: AppColors.mainBackgroundColor, @@ -84,7 +84,7 @@ class _LockItemListPageState extends State { left: (ScreenUtil().screenWidth - 200.w) / 2, width: 200.w, child: SubmitBtn( - btnName: TranslationLoader.lanKeys!.add!.tr, + btnName: '添加'.tr, onClick: () { //选择要添加到分组的锁 Get.toNamed(Routers.groupEditLockPage, arguments: {'groupListItem': groupListItem, 'ungrouped': ungrouped, 'type': 0}); @@ -139,7 +139,7 @@ class _LockItemListPageState extends State { builder: (BuildContext context) { return AlertBottomWidget( topTitle: '', - items: [TranslationLoader.lanKeys!.add!.tr, '删除'.tr], + items: ['添加'.tr, '删除'.tr], chooseCallback: (value) { int getSelectIndex = value; if (getSelectIndex == 0) { diff --git a/lib/mine/mineSet/transferSmartLock/recipientInformation/recipientInformation_logic.dart b/lib/mine/mineSet/transferSmartLock/recipientInformation/recipientInformation_logic.dart index 047071e9..c3e29c97 100755 --- a/lib/mine/mineSet/transferSmartLock/recipientInformation/recipientInformation_logic.dart +++ b/lib/mine/mineSet/transferSmartLock/recipientInformation/recipientInformation_logic.dart @@ -105,7 +105,7 @@ class RecipientInformationLogic extends BaseGetXController{ content: const Text('确定要移除所选中的坏锁吗?'), actions: [ CupertinoDialogAction( - child: Text(TranslationLoader.lanKeys!.cancel!.tr), + child: Text('取消'.tr), onPressed: Get.back, ), CupertinoDialogAction( diff --git a/lib/mine/mineSet/transferSmartLock/transferSmartLockList/transferSmartLock_page.dart b/lib/mine/mineSet/transferSmartLock/transferSmartLockList/transferSmartLock_page.dart index 5e317610..fc4aca6e 100755 --- a/lib/mine/mineSet/transferSmartLock/transferSmartLockList/transferSmartLock_page.dart +++ b/lib/mine/mineSet/transferSmartLock/transferSmartLockList/transferSmartLock_page.dart @@ -65,7 +65,7 @@ class _TransferSmartLockPageState extends State with Rout } }); }, - child: Text(state.isSelectAll == true ? TranslationLoader.lanKeys!.cancel!.tr : TranslationLoader.lanKeys!.checkAll!.tr, style: TextStyle(color: Colors.white, fontSize: 24.sp))) + child: Text(state.isSelectAll == true ? '取消'.tr : TranslationLoader.lanKeys!.checkAll!.tr, style: TextStyle(color: Colors.white, fontSize: 24.sp))) ], ), body: EasyRefreshTool( diff --git a/lib/mine/valueAddedServices/valueAddedServicesSMSTemplate/valueAddedServicesAddSMSTemplate/newSMSTemplate_page.dart b/lib/mine/valueAddedServices/valueAddedServicesSMSTemplate/valueAddedServicesAddSMSTemplate/newSMSTemplate_page.dart index d77af580..c609d0db 100755 --- a/lib/mine/valueAddedServices/valueAddedServicesSMSTemplate/valueAddedServicesAddSMSTemplate/newSMSTemplate_page.dart +++ b/lib/mine/valueAddedServices/valueAddedServicesSMSTemplate/valueAddedServicesAddSMSTemplate/newSMSTemplate_page.dart @@ -283,7 +283,7 @@ class _NewSMSTemplatePageState extends State { context, normalIndex: 0, title: TranslationLoader.lanKeys!.type!.tr, - cancelTitle: TranslationLoader.lanKeys!.cancel!.tr, + cancelTitle: '取消'.tr, sureTitle: '确定'.tr, data: titleList, clickCallBack: (int index, Object str) { @@ -306,7 +306,7 @@ class _NewSMSTemplatePageState extends State { context, normalIndex: 0, title: TranslationLoader.lanKeys!.type!.tr, - cancelTitle: TranslationLoader.lanKeys!.cancel!.tr, + cancelTitle: '取消'.tr, sureTitle: '确定'.tr, data: langNames, clickCallBack: (int index, Object str) { diff --git a/lib/tools/custom_bottom_sheet.dart b/lib/tools/custom_bottom_sheet.dart index cb41c01e..bb47dff0 100755 --- a/lib/tools/custom_bottom_sheet.dart +++ b/lib/tools/custom_bottom_sheet.dart @@ -6,17 +6,14 @@ import 'package:star_lock/app_settings/app_colors.dart'; import '../translations/trans_lib.dart'; class AlertBottomWidget extends StatelessWidget { + + AlertBottomWidget( + {required this.items, required this.chooseCallback, required this.topTitle, Key? key}) + : super(key: key); List items; ValueChanged chooseCallback; String topTitle; - AlertBottomWidget( - {Key? key, - required this.items, - required this.chooseCallback, - required this.topTitle}) - : super(key: key); - List itemsWidget(context) { List list = []; @@ -92,9 +89,8 @@ class AlertBottomWidget extends StatelessWidget { style: ButtonStyle( overlayColor: MaterialStateProperty.all(Colors.white)), child: Text( - TranslationLoader.lanKeys!.cancel!.tr, - style: - TextStyle(color: Colors.black, fontSize: ScreenUtil().setSp(24)), + '取消'.tr, + style: TextStyle(color: Colors.black, fontSize: ScreenUtil().setSp(24)), ), onPressed: () { Navigator.pop(context); diff --git a/lib/tools/showIosTipView.dart b/lib/tools/showIosTipView.dart index 23d84f4f..739392c0 100755 --- a/lib/tools/showIosTipView.dart +++ b/lib/tools/showIosTipView.dart @@ -26,7 +26,7 @@ class ShowIosTipView extends StatelessWidget { content: Text(tipTitle!), actions: [ CupertinoDialogAction( - child: Text(TranslationLoader.lanKeys!.cancel!.tr), + child: Text('取消'.tr), onPressed: () { if (cancelClick != null) { cancelClick!(); diff --git a/lib/tools/showSeletDateTime.dart b/lib/tools/showSeletDateTime.dart index ddfd0ded..b0381147 100755 --- a/lib/tools/showSeletDateTime.dart +++ b/lib/tools/showSeletDateTime.dart @@ -21,7 +21,7 @@ class ShowSelectDateTime { context, onMonthChangeStartWithFirstDate: true, pickerTheme: DateTimePickerTheme( - cancel: Text(TranslationLoader.lanKeys!.cancel!.tr, style: const TextStyle(color: Colors.black)), + cancel: Text('取消'.tr, style: const TextStyle(color: Colors.black)), showTitle: true, confirm: Text('确定'.tr, style: const TextStyle(color: Colors.black)), ), diff --git a/lib/tools/showTFView.dart b/lib/tools/showTFView.dart index eb71a4f2..0b7ace17 100755 --- a/lib/tools/showTFView.dart +++ b/lib/tools/showTFView.dart @@ -77,7 +77,7 @@ class ShowTFView extends StatelessWidget { ), actions: [ CupertinoDialogAction( - child: Text(leftBtnTitle ?? TranslationLoader.lanKeys!.cancel!.tr, + child: Text(leftBtnTitle ?? '取消'.tr, style: TextStyle(color: AppColors.mainColor)), onPressed: () { // Navigator.pop(context); diff --git a/lib/tools/showTipView.dart b/lib/tools/showTipView.dart index bb072886..d2cc2369 100755 --- a/lib/tools/showTipView.dart +++ b/lib/tools/showTipView.dart @@ -53,7 +53,7 @@ class ShowTipView { ), actions: [ CupertinoDialogAction( - child: Text(TranslationLoader.lanKeys!.cancel!.tr), + child: Text('取消'.tr), onPressed: Get.back, ), CupertinoDialogAction( diff --git a/lib/translations/lanKeyEntity.dart b/lib/translations/lanKeyEntity.dart index bddaedf2..7065149a 100755 --- a/lib/translations/lanKeyEntity.dart +++ b/lib/translations/lanKeyEntity.dart @@ -77,8 +77,9 @@ class LanKeyEntity { // this.share, // this.amend, // this.sure, - this.cancel, - this.add, + // this.cancel, + + // this.add, this.accountNumber, this.volumeAuthorizationLock, this.authorizedAdminTip, @@ -537,8 +538,8 @@ class LanKeyEntity { // share = json['share']; // amend = json['amend']; // sure = json['sure']; - cancel = json['cancel']; - add = json['add']; + // cancel = json['cancel']; + // add = json['add']; accountNumber = json['accountNumber']; volumeAuthorizationLock = json['volumeAuthorizationLock']; authorizedAdminTip = json['authorizedAdminTip']; @@ -1046,8 +1047,8 @@ class LanKeyEntity { // String? share; // String? amend; // String? sure; - String? cancel; - String? add; + // String? cancel; + // String? add; String? accountNumber; String? volumeAuthorizationLock; String? authorizedAdminTip; @@ -1544,8 +1545,8 @@ class LanKeyEntity { // map['share'] = share; // map['amend'] = amend; // map['sure'] = sure; - map['cancel'] = cancel; - map['add'] = add; + // map['cancel'] = cancel; + // map['add'] = add; map['accountNumber'] = accountNumber; map['volumeAuthorizationLock'] = volumeAuthorizationLock; map['authorizedAdminTip'] = authorizedAdminTip;