From acbf82c2dace74fe6c8ec725da012a8587a6287d Mon Sep 17 00:00:00 2001 From: liyi Date: Thu, 23 Jan 2025 10:43:37 +0800 Subject: [PATCH] =?UTF-8?q?fix:=E8=B0=83=E6=95=B4=E8=8E=B7=E5=8F=96?= =?UTF-8?q?=E9=85=8D=E7=BD=91=E7=BB=93=E6=9E=9C=E6=97=B6=E7=9A=84=E9=80=BB?= =?UTF-8?q?=E8=BE=91?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- lib/main/lockDetail/lockDetail/lockDetail_page.dart | 5 +++-- lib/network/api_provider.dart | 1 + 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/lib/main/lockDetail/lockDetail/lockDetail_page.dart b/lib/main/lockDetail/lockDetail/lockDetail_page.dart index 91cd15a5..5e5a253c 100755 --- a/lib/main/lockDetail/lockDetail/lockDetail_page.dart +++ b/lib/main/lockDetail/lockDetail/lockDetail_page.dart @@ -1584,11 +1584,12 @@ class _LockDetailPageState extends State if (mac != null && mac.isNotEmpty) { final DeviceNetwork deviceNetworkInfo = await ApiRepository.to .getDeviceNetwork(deviceType: 2, deviceMac: mac); - if (deviceNetworkInfo.data?.wifiName == null) { + if (deviceNetworkInfo.data?.wifiName == null || + deviceNetworkInfo.data?.wifiName == '') { return; } else { final peerId = deviceNetworkInfo?.data?.peerId; - if (peerId == null || peerId.isEmpty) { + if (peerId == null || peerId.isEmpty || peerId == '') { throw Exception('设备peerId为空'); } // 设置锁的peerID diff --git a/lib/network/api_provider.dart b/lib/network/api_provider.dart index e31b9522..855df195 100755 --- a/lib/network/api_provider.dart +++ b/lib/network/api_provider.dart @@ -2747,6 +2747,7 @@ class ApiProvider extends BaseProvider { 'deviceMac': deviceMac, }), isShowNetworkErrorMsg: false, + isShowErrMsg: false, isUnShowLoading: true); }