From df30e8562e49b45e7a9a3497d368cebd6085be87 Mon Sep 17 00:00:00 2001 From: WJC <wjc@hdlchina.com.cn> Date: 星期一, 30 十二月 2019 17:33:33 +0800 Subject: [PATCH] 2019-12-30-2 --- ZigbeeApp/Shared/Phone/UserCenter/DoorLock/EntryStatusPage.cs | 62 ++++++++++++++++++------------ 1 files changed, 37 insertions(+), 25 deletions(-) diff --git a/ZigbeeApp/Shared/Phone/UserCenter/DoorLock/EntryStatusPage.cs b/ZigbeeApp/Shared/Phone/UserCenter/DoorLock/EntryStatusPage.cs index 18e00b1..d8c9401 100755 --- a/ZigbeeApp/Shared/Phone/UserCenter/DoorLock/EntryStatusPage.cs +++ b/ZigbeeApp/Shared/Phone/UserCenter/DoorLock/EntryStatusPage.cs @@ -29,7 +29,7 @@ #endregion /// <summary> - /// UI鏄剧ず + /// UI鏄剧ず /// </summary> public void Show() { @@ -181,7 +181,7 @@ TextColor = Shared.Common.ZigbeeColor.Current.XMWhite, Gravity = Gravity.CenterHorizontal, BackgroundColor = Shared.Common.ZigbeeColor.Current.XMBlack, - Radius = 10, + Radius = (uint)Application.GetRealHeight(127 / 2), TextSize = 16, }; bottomFrameLayout.AddChidren(completeBtn); @@ -213,6 +213,10 @@ completeBtn.MouseDownEventHandler += async (sender, e) => { completeBtn.Enable = false; + if (doorLock.doorLockProgrammingEventNotificationCommand == null) + { + return; + } var addLockInfo = new ZigBee.Device.DoorLock.AddDoorLockData(); if (UserCenterResourse.UserInfo.AuthorityNo != 1) { @@ -246,44 +250,52 @@ { if (doorLock.localDoorLockUserList.ContainsKey(doorLock.doorLockProgrammingEventNotificationCommand.UserID)) { - //瀛樿处鎴蜂俊鎭� - // var resultList1 = await Shared.Phone.UserCenter.DoorLock.DoorLockCommonInfo.GetCloudLocalAccountlist(doorLock, curAccountObj.SubAccountDistributedMark); //瀛橀棬閿佷俊鎭� var resultList = await Shared.Phone.UserCenter.DoorLock.DoorLockCommonInfo.GetCloudLocalDoorLocklist(doorLock, curAccountObj.SubAccountDistributedMark); - if (resultList.ContainsKey(doorLock.doorLockProgrammingEventNotificationCommand.UserID) == true) + if (resultList != null) { - var a = resultList[doorLock.doorLockProgrammingEventNotificationCommand.UserID]; - if (a?.ConnectedAccount == curAccountObj.SubAccountDistributedMark) + if (resultList.ContainsKey(doorLock.doorLockProgrammingEventNotificationCommand.UserID) == true) { - completeBtn.Enable = true; - this.RemoveFromParent(); - for (int i = UserView.HomePage.Instance.ChildrenCount - 1; i >= 0; i--) + var a = resultList[doorLock.doorLockProgrammingEventNotificationCommand.UserID]; + if (a?.ConnectedAccount == curAccountObj.SubAccountDistributedMark) { - var form = UserView.HomePage.Instance.GetChildren(i); + completeBtn.Enable = true; + this.RemoveFromParent(); + for (int i = UserView.HomePage.Instance.ChildrenCount - 1; i >= 0; i--) + { + var form = UserView.HomePage.Instance.GetChildren(i); - if (form is UnLockMethod) - { - ((UnLockMethod)form).RefreshList(); - break; - } - else - { - form.RemoveFromParent(); + if (form is UnLockMethod) + { + doorLock.currentUserDisplayMethod = ""; + ((UnLockMethod)form).RefreshList(); + break; + } + else + { + form.RemoveFromParent(); + } } } - } - else - { - completeBtn.Enable = true; - new Tip() { MaxWidth = 150, Text = Language.StringByID(R.MyInternationalizationString.CloudServerResponseOvertime), Direction = AMPopTipDirection.Up, CloseTime = 1 }.Show(btnPasswordRemarkContent); + else + { + completeBtn.Enable = true; + new Tip() { MaxWidth = 150, Text = Language.StringByID(R.MyInternationalizationString.CloudServerResponseOvertime), Direction = AMPopTipDirection.Up, CloseTime = 1 }.Show(btnPasswordRemarkContent); + } } } + else + { + completeBtn.Enable = true; + new Tip() { MaxWidth = 150, Text = Language.StringByID(R.MyInternationalizationString.CloudServerResponseOvertime), Direction = AMPopTipDirection.Up, CloseTime = 1 }.Show(btnPasswordRemarkContent); + } + } } else { completeBtn.Enable = true; - new Tip() { MaxWidth = 150, Text = Language.StringByID(R.MyInternationalizationString.ModigfyFailed), Direction = AMPopTipDirection.Up, CloseTime = 1 }.Show(btnPasswordRemarkContent); + new Tip() { MaxWidth = 150, Text = Language.StringByID(R.MyInternationalizationString.AddFailed), Direction = AMPopTipDirection.Up, CloseTime = 1 }.Show(btnPasswordRemarkContent); } } else -- Gitblit v1.8.0