From 944b87b6bcccb095cd73f13f4410fb20faf48f74 Mon Sep 17 00:00:00 2001 From: gxc <guoxuecheng@guoxuechengdeMacBook-Pro.local> Date: 星期三, 25 十二月 2019 11:21:06 +0800 Subject: [PATCH] 2019.12.25 --- ZigbeeApp/Shared/Phone/UserCenter/DoorLock/MemberFrozenPage.cs | 58 ++++++++++++++++++++++++++++++++-------------------------- 1 files changed, 32 insertions(+), 26 deletions(-) diff --git a/ZigbeeApp/Shared/Phone/UserCenter/DoorLock/MemberFrozenPage.cs b/ZigbeeApp/Shared/Phone/UserCenter/DoorLock/MemberFrozenPage.cs old mode 100755 new mode 100644 index e7881a5..262fec2 --- a/ZigbeeApp/Shared/Phone/UserCenter/DoorLock/MemberFrozenPage.cs +++ b/ZigbeeApp/Shared/Phone/UserCenter/DoorLock/MemberFrozenPage.cs @@ -21,11 +21,32 @@ #region 鈼� 鍙橀噺鐢虫槑__________________________ ZigBee.Device.DoorLock doorLock; Shared.Phone.UserCenter.MemberInfoRes curAccountObj; - VerticalScrolViewLayout bodyView; + VerticalRefreshLayout bodyView; #endregion + void ReadDoorLockUserInfo() + { + System.Threading.Tasks.Task.Run(async () => + { + try + { + var list = await Shared.Phone.UserCenter.DoorLock.DoorLockCommonInfo.GetDoorLockAllAcountUserlist(doorLock); + var result = await Shared.Phone.UserCenter.DoorLock.DoorLockCommonInfo.GetDoorLockOperateAccess(doorLock, curAccountObj.SubAccountDistributedMark); + var result1 = await Shared.Phone.UserCenter.DoorLock.DoorLockCommonInfo.GetDoorLockUnlockAccess(doorLock, curAccountObj.SubAccountDistributedMark); + } + catch { } + finally + { + Application.RunOnMainThread(() => + { + MidRefresh(); + }); + } + }); + } + /// <summary> - /// UI鏄剧ず + /// UI鏄剧ず /// </summary> public void Show() { @@ -48,12 +69,18 @@ this.btnBackFrameLayout.MouseUpEventHandler += eHandlerBack; this.MidFrameLayout(this); - bodyView = new VerticalScrolViewLayout() + bodyView = new VerticalRefreshLayout() { }; this.midFrameLayout.AddChidren(bodyView); + MidRefresh(); - ReadDoorLockUserInfo(); + bodyView.BeginHeaderRefreshingAction += () => + { + bodyView.BeginHeaderRefreshing(); + ReadDoorLockUserInfo(); + bodyView.EndHeaderRefreshing(); + }; } public async void MidRefresh() @@ -663,7 +690,7 @@ } else { - //鏂板锛屼笖涓嶅喕缁� + //鏂板锛屼笖涓嶅喕缁� var addLockInfo = new ZigBee.Device.DoorLock.AddDoorLockData(); if (UserCenterResourse.UserInfo.AuthorityNo != 1) { @@ -746,27 +773,6 @@ MidRefresh(); } }; - } - - void ReadDoorLockUserInfo() - { - System.Threading.Tasks.Task.Run(async () => - { - Application.RunOnMainThread(() => { CommonPage.Loading.Start("Loading..."); }); - try - { - await Shared.Phone.UserCenter.DoorLock.DoorLockCommonInfo.GetLocaDoorLocklist(doorLock, curAccountObj); - } - catch { } - finally - { - Application.RunOnMainThread(() => - { - MidRefresh(); - CommonPage.Loading.Hide(); - }); - } - }); } #region 鈼� 鎺ュ彛瀹炵幇__________________________ -- Gitblit v1.8.0