From 4fef29b9ab9f2632f15a0d45005f92d91de5d4e5 Mon Sep 17 00:00:00 2001 From: Davin <591807572@qq.com> Date: 星期四, 27 七月 2023 14:26:59 +0800 Subject: [PATCH] feature 萤石sdk更新 --- HDL_ON/UI/UI2/FuntionControlView/VideoDoorLock/VideoDoorlockUserManagerPage.cs | 35 +++++++++++++++++++++++++---------- 1 files changed, 25 insertions(+), 10 deletions(-) diff --git a/HDL_ON/UI/UI2/FuntionControlView/VideoDoorLock/VideoDoorlockUserManagerPage.cs b/HDL_ON/UI/UI2/FuntionControlView/VideoDoorLock/VideoDoorlockUserManagerPage.cs index 9520088..e718b92 100644 --- a/HDL_ON/UI/UI2/FuntionControlView/VideoDoorLock/VideoDoorlockUserManagerPage.cs +++ b/HDL_ON/UI/UI2/FuntionControlView/VideoDoorLock/VideoDoorlockUserManagerPage.cs @@ -48,6 +48,8 @@ }; bodyView.AddChidren(contentView); + + #region 鐢ㄦ埛鍚嶇О var userNameView = new FrameLayout() { @@ -128,8 +130,8 @@ { try { - var resultObj = ApiUtlis.Ins.HttpRequest.EditDoorlockUserName(device.deviceId, doorlockUser.extUserId, str); - if (resultObj.Code == StateCode.SUCCESS) + var pack = ApiUtlis.Ins.HttpRequest.EditDoorlockUserName(device.deviceId, doorlockUser.extUserId, str); + if (pack.Code == StateCode.SUCCESS) { Application.RunOnMainThread(() => { @@ -139,7 +141,20 @@ else { //澶辫触鎻愮ず - IMessageCommon.Current.ShowErrorInfoAlter(resultObj.Code); + Application.RunOnMainThread(() => + { + if (!string.IsNullOrEmpty(pack.message)) + { + var tip = new Tip() + { + MaxWidth = Application.GetRealWidth(300), + Text = $"{pack.message}({pack.Code})", + CloseTime = 3, + Direction = AMPopTipDirection.None + }; + tip.Show(MainPage.BaseView); + } + }); } } catch (Exception ex) @@ -157,8 +172,8 @@ { IsBackground = true }.Start(); }; var pa = new PublicAssmebly(); - pa.entryMaxLength = 20; - pa.LoadDialog_EditParater(StringId.ChangeName, doorlockUser.lockUserName, callBack, StringId.UesrNameCannotBeEmpty, 0, new List<string>()); + pa.entryMaxLength = 30; + pa.LoadDialog_EditParater(StringId.ChangeName, "", callBack, StringId.UesrNameCannotBeEmpty, 0, new List<string>()); }; btnUserName.MouseUpEventHandler = eventHandler; btnEditUserNameIcon.MouseUpEventHandler = eventHandler; @@ -169,7 +184,7 @@ void initOptionView(bool isEdit) { if(doorlockUser.faceCount == 0&& - doorlockUser.faceCount == 0 && + doorlockUser.fingerCount == 0 && doorlockUser.pwdCount == 0 && doorlockUser.cardCount == 0) { @@ -183,17 +198,17 @@ int childrenViewHeight = Application.GetRealWidth(116); - int permissionsViewHeight = Application.GetRealHeight(291 + 92); + int permissionsViewHeight = Application.GetRealHeight(291 + 92 + 100); if (userPermissionsView!= null) { userPermissionsView.RemoveAll(); if (isEdit) { - permissionsViewHeight = Application.GetRealHeight(391 + 50); + permissionsViewHeight = Application.GetRealHeight(391 + 50 + 100); childrenViewHeight = Application.GetRealWidth(156); } - userPermissionsView.Height = permissionsViewHeight; + userPermissionsView.Height = permissionsViewHeight ; } else { @@ -699,7 +714,7 @@ var delUserView = new FrameLayout() { Y = unlockOptionView.Bottom, - Height = Application.GetRealHeight(110), + Height = Application.GetRealHeight(310), BackgroundColor = CSS_Color.BackgroundColor, }; userPermissionsView.AddChidren(delUserView); -- Gitblit v1.8.0