1,屏蔽所有标记房态的入口

2,屏蔽项目运行开始调用设备Id的入口
This commit is contained in:
Daisy 2024-03-07 11:41:06 +08:00
parent 77c7168dfa
commit a980f5f250
10 changed files with 124 additions and 86 deletions

View File

@ -20,22 +20,22 @@ FutureOr<void> main() async {
if (AppPlatform.isAndroid) {
SystemUiOverlayStyle systemUiOverlayStyle =
const SystemUiOverlayStyle(statusBarColor: Colors.transparent);
const SystemUiOverlayStyle(statusBarColor: Colors.transparent);
SystemChrome.setSystemUIOverlayStyle(systemUiOverlayStyle);
}
}
//
Future _initTranslation() async => TranslationLoader.loadTranslation(
zhSource: "images/lan/lan_zh.json",
enSource: "images/lan/lan_en.json",
keySource: "images/lan/lan_keys.json",
);
zhSource: "images/lan/lan_zh.json",
enSource: "images/lan/lan_en.json",
keySource: "images/lan/lan_keys.json",
);
//
Future _setCommonServices() async {
await Get.putAsync(() => StoreService().init());
await Get.putAsync(() => PlatformInfoService().init());
await Get.putAsync(() => DeviceInfoService().init());
// await Get.putAsync(() => DeviceInfoService().init());
// Get.log(PlatformInfoService.to.info.version);
}

View File

@ -397,12 +397,13 @@ class _SendElectronicKeyPageState extends State<SendElectronicKeyPage> {
// SizedBox(
// height: 10.h,
// ),
OutLineBtn(
btnName: '标记为已入住',
onClick: () {
updateRoomCheckIn();
},
),
//
// OutLineBtn(
// btnName: '标记为已入住',
// onClick: () {
// updateRoomCheckIn();
// },
// ),
],
);
}

View File

@ -74,7 +74,8 @@ class _LockSetPageState extends State<LockSetPage> with RouteAware {
//
List<Widget> getListWidget() {
// print("state.lockBasicInfo.value.isLockOwner:${state.lockBasicInfo.value.isLockOwner} state.lockBasicInfo.value.keyRight:${state.lockBasicInfo.value.keyRight}");
if (state.lockBasicInfo.value.isLockOwner == 1 || state.lockBasicInfo.value.keyRight == 1) {
if (state.lockBasicInfo.value.isLockOwner == 1 ||
state.lockBasicInfo.value.keyRight == 1) {
//
return getAllWidget();
} else {
@ -449,26 +450,26 @@ class _LockSetPageState extends State<LockSetPage> with RouteAware {
//-----
SizedBox(height: 10.h),
//
Obx(() {
var title = "";
if (state.lockStatus.value.roomStatus == 1) {
title = TranslationLoader.lanKeys!.checkedIn!.tr;
} else if (state.lockStatus.value.roomStatus == 0) {
title = TranslationLoader.lanKeys!.leisure!.tr;
}
return Visibility(
visible: state.lockStatus.value.roomStatus == 1 ? true : false,
child: CommonItem(
leftTitel: TranslationLoader.lanKeys!.markedHouseState!.tr,
rightTitle: title,
isHaveLine: true,
isHaveDirection: true,
action: () {
Get.toNamed(Routers.markedHouseStatePage, arguments: {
'lockSetInfoData': state.lockSetInfoData.value
});
}));
}),
// Obx(() {
// var title = "";
// if (state.lockStatus.value.roomStatus == 1) {
// title = TranslationLoader.lanKeys!.checkedIn!.tr;
// } else if (state.lockStatus.value.roomStatus == 0) {
// title = TranslationLoader.lanKeys!.leisure!.tr;
// }
// return Visibility(
// visible: state.lockStatus.value.roomStatus == 1 ? true : false,
// child: CommonItem(
// leftTitel: TranslationLoader.lanKeys!.markedHouseState!.tr,
// rightTitle: title,
// isHaveLine: true,
// isHaveDirection: true,
// action: () {
// Get.toNamed(Routers.markedHouseStatePage, arguments: {
// 'lockSetInfoData': state.lockSetInfoData.value
// });
// }));
// }),
//
Obx(
() => Visibility(

View File

@ -1,4 +1,3 @@
import 'package:flutter/cupertino.dart';
import 'package:flutter/material.dart';
import 'package:flutter_easyloading/flutter_easyloading.dart';
@ -19,12 +18,10 @@ class DemoModeLockSetPage extends StatefulWidget {
}
class _DemoModeLockSetPageState extends State<DemoModeLockSetPage> {
@override
void initState() {
// TODO: implement initState
super.initState();
}
@override
@ -43,7 +40,7 @@ class _DemoModeLockSetPageState extends State<DemoModeLockSetPage> {
//
CommonItem(
leftTitel:
TranslationLoader.lanKeys!.basicInformation!.tr,
TranslationLoader.lanKeys!.basicInformation!.tr,
rightTitle: "",
isHaveLine: false,
isHaveDirection: true,
@ -53,7 +50,9 @@ class _DemoModeLockSetPageState extends State<DemoModeLockSetPage> {
// 'keyInfo': state.getKeyInfosData.value
// });
}),
SizedBox(height: 10.h,),
SizedBox(
height: 10.h,
),
//
CommonItem(
leftTitel: TranslationLoader.lanKeys!.doorMagnetic!.tr,
@ -68,7 +67,7 @@ class _DemoModeLockSetPageState extends State<DemoModeLockSetPage> {
// 线
CommonItem(
leftTitel:
TranslationLoader.lanKeys!.wirelessKeyboard!.tr,
TranslationLoader.lanKeys!.wirelessKeyboard!.tr,
rightTitle: "",
isHaveLine: false,
isHaveDirection: true,
@ -99,7 +98,7 @@ class _DemoModeLockSetPageState extends State<DemoModeLockSetPage> {
//
CommonItem(
leftTitel:
TranslationLoader.lanKeys!.automaticBlocking!.tr,
TranslationLoader.lanKeys!.automaticBlocking!.tr,
rightTitle: TranslationLoader.lanKeys!.closed!.tr,
isHaveLine: true,
isHaveDirection: true,
@ -133,7 +132,7 @@ class _DemoModeLockSetPageState extends State<DemoModeLockSetPage> {
//
CommonItem(
leftTitel:
TranslationLoader.lanKeys!.normallyOpenMode!.tr,
TranslationLoader.lanKeys!.normallyOpenMode!.tr,
rightTitle: TranslationLoader.lanKeys!.closed!.tr,
isHaveLine: true,
isHaveDirection: true,
@ -216,23 +215,22 @@ class _DemoModeLockSetPageState extends State<DemoModeLockSetPage> {
SizedBox(height: 10.h),
//-----
//
CommonItem(
leftTitel:
TranslationLoader.lanKeys!.markedHouseState!.tr,
rightTitle: "",
isHaveLine: true,
isHaveDirection: true,
action: () {
gotoAddLock();
}),
// CommonItem(
// leftTitel:
// TranslationLoader.lanKeys!.markedHouseState!.tr,
// rightTitle: "",
// isHaveLine: true,
// isHaveDirection: true,
// action: () {
// gotoAddLock();
// }),
//
CommonItem(
leftTitel: TranslationLoader.lanKeys!.checkingIn!.tr,
rightTitle: "",
isHaveLine: true,
isHaveRightWidget: true,
rightWidget: _openCheckInSwitch()
),
rightWidget: _openCheckInSwitch()),
//
CommonItem(
leftTitel: TranslationLoader.lanKeys!.unlockReminder!.tr,
@ -304,7 +302,8 @@ class _DemoModeLockSetPageState extends State<DemoModeLockSetPage> {
}),
SizedBox(height: 30.h),
Container(
padding: EdgeInsets.only(left: 20.w, right: 20.w, bottom: 30.h),
padding:
EdgeInsets.only(left: 20.w, right: 20.w, bottom: 30.h),
child: SubmitBtn(
btnName: "退出演示模式",
isDelete: true,
@ -343,9 +342,8 @@ class _DemoModeLockSetPageState extends State<DemoModeLockSetPage> {
);
}
void gotoAddLock(){
void gotoAddLock() {
// Get.toNamed(Routers.selectLockTypePage);
EasyLoading.showToast("演示模式",duration: 2000.milliseconds);
EasyLoading.showToast("演示模式", duration: 2000.milliseconds);
}
}

View File

@ -13,12 +13,12 @@ class StarLockMinePage extends StatefulWidget {
const StarLockMinePage({Key? key}) : super(key: key);
@override
State<StarLockMinePage> createState() => _StarLockMinePageState();
State<StarLockMinePage> createState() => StarLockMinePageState();
}
GlobalKey<_StarLockMinePageState> starLockMineKey = GlobalKey();
GlobalKey<StarLockMinePageState> starLockMineKey = GlobalKey();
class _StarLockMinePageState extends State<StarLockMinePage> with BaseWidget {
class StarLockMinePageState extends State<StarLockMinePage> with BaseWidget {
final logic = Get.put(StarLockMineLogic());
final state = Get.find<StarLockMineLogic>().state;

View File

@ -0,0 +1,24 @@
import 'package:star_lock/mine/valueAddedServices/valueAddedServicesBuy/valueAddedServicesBuy_state.dart';
import 'package:star_lock/tools/baseGetXController.dart';
class ValueAddedServicesBuyLogic extends BaseGetXController {
final ValueAddedServicesBuyState state = ValueAddedServicesBuyState();
@override
Future<void> onReady() async {
print("ready home");
super.onReady();
}
@override
void onInit() {
print("init home");
super.onInit();
}
@override
void onClose() {
print("close home");
super.onClose();
}
}

View File

@ -1,8 +1,8 @@
import 'package:flutter/material.dart';
import 'package:flutter_screenutil/flutter_screenutil.dart';
import 'package:get/get.dart';
import 'package:star_lock/mine/valueAddedServices/valueAddedServicesBuy/valueAddedServicesBuy_logic.dart';
import '../../../appRouters.dart';
import '../../../app_settings/app_colors.dart';
import '../../../tools/titleAppBar.dart';
import '../../../translations/trans_lib.dart';
@ -16,17 +16,13 @@ class ValueAddedServicesBuyPage extends StatefulWidget {
}
class _ValueAddedServicesBuyPageState extends State<ValueAddedServicesBuyPage> {
final data = [
"1",
"2",
"3",
"4",
];
@override
Widget build(BuildContext context) {
var type = ModalRoute.of(context)?.settings.arguments as int;
final logic = Get.put(ValueAddedServicesBuyLogic());
final state = Get.find<ValueAddedServicesBuyLogic>().state;
return Scaffold(
backgroundColor: AppColors.greyBackgroundColor,
appBar: TitleAppBar(
@ -59,7 +55,9 @@ class _ValueAddedServicesBuyPageState extends State<ValueAddedServicesBuyPage> {
mainAxisSpacing: 10.h,
crossAxisSpacing: 10.w,
childAspectRatio: 1 / 0.5,
children: data.map((title) => _buildItem(title)).toList(),
children: state.topData.value
.map((title) => _buildItem(title))
.toList(),
),
),
),
@ -123,16 +121,21 @@ class _ValueAddedServicesBuyPageState extends State<ValueAddedServicesBuyPage> {
color: AppColors.mainColor,
fontWeight: FontWeight.w500))),
SizedBox(width: 5.w),
Container(
width: 180.w,
height: 100.h,
color: AppColors.mainColor,
child: Center(
child: Text(TranslationLoader.lanKeys!.goToPay!.tr,
style: TextStyle(
fontSize: 24.sp,
color: Colors.white,
fontWeight: FontWeight.w500))))
GestureDetector(
onTap: () {
logic.showToast("支付成功");
},
child: Container(
width: 180.w,
height: 100.h,
color: AppColors.mainColor,
child: Center(
child: Text(TranslationLoader.lanKeys!.goToPay!.tr,
style: TextStyle(
fontSize: 24.sp,
color: Colors.white,
fontWeight: FontWeight.w500)))),
)
],
),
),

View File

@ -0,0 +1,12 @@
import 'package:get/get.dart';
class ValueAddedServicesBuyState {
final topData = [
"1",
"2",
"3",
"4",
].obs;
void onClose() {}
}

View File

@ -152,8 +152,8 @@ class _ValueAddedServicesHighFunctionPageState
TranslationLoader.lanKeys!.lockGroup!.tr),
_buildItem("images/mine/icon_mine_highFunctionContent_bjft.png",
TranslationLoader.lanKeys!.sendGroupKey!.tr),
_buildItem("images/mine/icon_mine_highFunctionContent_bjft.png",
TranslationLoader.lanKeys!.markedHouseState!.tr),
// _buildItem("images/mine/icon_mine_highFunctionContent_bjft.png",
// TranslationLoader.lanKeys!.markedHouseState!.tr),
_buildItem("images/mine/icon_mine_highFunctionContent_fkgj.png",
TranslationLoader.lanKeys!.cardIssuingtool!.tr),
_buildItem(

View File

@ -1,8 +1,6 @@
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/commonItem.dart';
import '../../../tools/titleAppBar.dart';
@ -92,9 +90,9 @@ class _ValueAddedServicesRealNamePageState
),
GestureDetector(
onTap: () {
Navigator.pushNamed(
context, Routers.valueAddedServicesBuyPage,
arguments: 3);
// Navigator.pushNamed(
// context, Routers.valueAddedServicesBuyPage,
// arguments: 3);
},
child: Container(
width: 200.w,
@ -103,7 +101,8 @@ class _ValueAddedServicesRealNamePageState
child: Center(
child: Text(TranslationLoader.lanKeys!.buy!.tr,
style: TextStyle(
color: AppColors.mainColor,
// color: AppColors.mainColor,
color: AppColors.blackColor,
fontSize: 24.sp)))),
),
],