From a6aa8a449c9b7d8b769bc334e97e64791fe32e7f Mon Sep 17 00:00:00 2001 From: WinUser01 Date: Sat, 9 Jul 2022 11:18:04 +0800 Subject: [PATCH] =?UTF-8?q?hyzp=5Fybqx-Commit171=EF=BC=9A=E5=B7=B2?= =?UTF-8?q?=E7=BB=8F=E6=B7=BB=E5=8A=A0=20=E7=94=A8=E6=88=B7=E7=99=BB?= =?UTF-8?q?=E5=BD=95=E6=88=90=E6=A0=87=E5=BF=97=20userLogin=EF=BC=8C?= =?UTF-8?q?=E7=94=A8=E4=BA=8E=E8=A7=A3=E5=86=B3=E7=94=A8=E6=88=B7=E6=8F=90?= =?UTF-8?q?=E5=87=BA=E7=9A=84iOS=20App=E6=9C=AA=E7=99=BB=E5=BD=95=E8=AF=AD?= =?UTF-8?q?=E9=9F=B3=E6=8F=90=E9=86=92=E7=9A=84=E9=97=AE=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit userLogin = -1; //设置用户登录成功标志:1 成功,0 失败,-1 处理中 问题:山不在高水不在深: iOS App好像有点问题,就是登陆一次后,如果退出并切换其它程序,再切换回黑烟,虽然没有登陆,也会语音提醒,有新的黑烟车 --- android/app/release/output.json | 2 +- lib/components/commonFun.dart | 3 +++ lib/components/dioFun.dart | 2 ++ lib/pages/Login/LoginByName3.dart | 2 ++ 4 files changed, 8 insertions(+), 1 deletion(-) diff --git a/android/app/release/output.json b/android/app/release/output.json index 6063f44..940283b 100644 --- a/android/app/release/output.json +++ b/android/app/release/output.json @@ -1 +1 @@ -[{"outputType":{"type":"APK"},"apkData":{"type":"MAIN","splits":[],"versionCode":20220531,"versionName":"1.5.2","enabled":true,"outputFile":"app-release.apk","fullName":"release","baseName":"release"},"path":"app-release.apk","properties":{}}] \ No newline at end of file +[{"outputType":{"type":"APK"},"apkData":{"type":"MAIN","splits":[],"versionCode":20220620,"versionName":"1.5.3","enabled":true,"outputFile":"app-release.apk","fullName":"release","baseName":"release"},"path":"app-release.apk","properties":{}}] \ No newline at end of file diff --git a/lib/components/commonFun.dart b/lib/components/commonFun.dart index 96fc6cf..0326651 100644 --- a/lib/components/commonFun.dart +++ b/lib/components/commonFun.dart @@ -199,6 +199,7 @@ clear_user_info() { // 区县中心地址 center_latitude = -1; // 区县中心纬度 center_longitude = -1; // 区县中心经度 + userLogin = -1; //设置用户登录成功标志:1 成功,0 失败,-1 处理中 } // 511528、兴文县 @@ -320,6 +321,8 @@ Future sysPop() async { await SystemChannels.platform.invokeMethod('SystemNavigator.pop'); } +int userLogin = -1; //用户登录成功标志:1 成功,0 失败,-1 处理中 + //人脸注册和人脸识别登录成功标志 int faceReg = -1; //1 成功,0 失败,-1 处理中 int faceLogin = -1; //1 成功,0 失败,-1 处理中 diff --git a/lib/components/dioFun.dart b/lib/components/dioFun.dart index fe2edb3..89b74a6 100644 --- a/lib/components/dioFun.dart +++ b/lib/components/dioFun.dart @@ -2678,6 +2678,7 @@ Future faceLoginFun({@required String filePath, @required BuildContext context}) g_userInfo.setUserInfoFaceLogin(_mapGetData).then((value) { // 一套APP适应多个区县登录过程04、登录成功,开始使用保存的登录信息预加载数据,并设置faceLogin = 1 faceLogin = 1; //设置人脸验证成功标志。1 成功,0 失败,-1 处理中 + userLogin = 1; //设置用户登录成功标志:1 成功,0 失败,-1 处理中 startGetStatisDataNew(); // 2、登录前提前获取统计数据,改善用户登录体验 }); //获取其他用户信息 @@ -2695,6 +2696,7 @@ Future faceLoginFun({@required String filePath, @required BuildContext context}) }); } else { faceLogin = 0; //设置人脸验证成功标志。1 成功,0 失败,-1 处理中 + userLogin = 0; //设置用户登录成功标志:1 成功,0 失败,-1 处理中 print('人脸验证失败。'); Navigator.pushNamed(context, '/'); Fluttertoast.showToast( diff --git a/lib/pages/Login/LoginByName3.dart b/lib/pages/Login/LoginByName3.dart index af90f12..391f501 100644 --- a/lib/pages/Login/LoginByName3.dart +++ b/lib/pages/Login/LoginByName3.dart @@ -160,6 +160,7 @@ class _LoginPageState extends State { if (true == response.data["data"]["is_login"]) { print('登录成功'); print('response.data = ${response.data}'); + userLogin = 1; //设置用户登录成功标志:1 成功,0 失败,-1 处理中 // 一套APP适应多个区县登录过程02、进行登录验证,保存登录信息 if (bRemmberPW) { @@ -207,6 +208,7 @@ class _LoginPageState extends State { // Navigator.pushNamed(context, '/tabs', arguments: g_iIndex); } else { print('登录失败:${response.data["data"]}'); + userLogin = 0; //设置用户登录成功标志:1 成功,0 失败,-1 处理中 bLoginVerify = false; //处理延时登录,判断用户名登录是否验证通过 bPreLoading = false; try_setState(); // 登录失败后,刷新页面