From 72e1b4e4626315ebd4b879a68c94e7738fd0473e Mon Sep 17 00:00:00 2001
From: WJC <wjc@hdlchina.com.cn>
Date: 星期一, 28 十月 2019 11:00:28 +0800
Subject: [PATCH] 2019-10-28-1
---
ZigbeeApp/Shared/Phone/UserCenter/Member/MemberListForm.cs | 63 +++++++++++++++----------------
1 files changed, 31 insertions(+), 32 deletions(-)
diff --git a/ZigbeeApp/Shared/Phone/UserCenter/Member/MemberListForm.cs b/ZigbeeApp/Shared/Phone/UserCenter/Member/MemberListForm.cs
index f2c6cd8..cbfe08e 100755
--- a/ZigbeeApp/Shared/Phone/UserCenter/Member/MemberListForm.cs
+++ b/ZigbeeApp/Shared/Phone/UserCenter/Member/MemberListForm.cs
@@ -34,17 +34,17 @@
titleIcon.InitControl();
titleIcon.ButtonClickEvent += (sender, e) =>
{
- var menuContr = new TopRightMenuControl(this, 2);
+ var menuContr = new TopRightMenuControl(2, 449);
//鎵弿浜岀淮鐮�
string msg1 = Language.StringByID(R.MyInternationalizationString.uScanQRcode);
- menuContr.AddRowMenu(msg1,"","", () =>
+ menuContr.AddRowMenu(msg1, "Item/ScanQRcodeIcon.png", "Item/ScanQRcodeIconSelected.png", () =>
{
var form = new AddMemberByIdForm();
form.AddForm();
});
//杈撳叆璐﹀彿
string msg2 = Language.StringByID(R.MyInternationalizationString.uInputAccount);
- menuContr.AddRowMenu(msg2,"","", () =>
+ menuContr.AddRowMenu(msg2, "Item/InputAccountIcon.png", "Item/InputAccountIconSelected.png", () =>
{
var form = new AddMemberByIdForm();
form.AddForm();
@@ -69,9 +69,6 @@
//鍒濆鍖栧垪琛ㄦ帶浠�
this.InitMemberListControl();
-
- //鎬讳箣鍏堟竻绌哄叡浜枃浠跺す鍑嗘病閿�
- HdlShardLogic.Current.ClearShardDirectory();
}
#endregion
@@ -132,15 +129,26 @@
btnMenberTile.TextSize = 15;
bodyFrameLayout.AddChidren(btnMenberTile);
+ var frameBack = new FrameLayout();
+ frameBack.Y = btnMenberTile.Bottom + Application.GetRealHeight(23);
+ frameBack.Height = Application.GetRealHeight(11);
+ frameBack.BackgroundColor = UserCenterColor.Current.White;
+ bodyFrameLayout.AddChidren(frameBack);
+
//娣诲姞鍙互鍚戜笅婊氬姩鐨勬帶浠�
listView = new VerticalListControl(12);
- listView.Height = bodyFrameLayout.Height - Application.GetRealHeight(567);
+ listView.Height = bodyFrameLayout.Height - frameBack.Bottom;
listView.BackgroundColor = UserCenterColor.Current.White;
- listView.Y = Application.GetRealHeight(567);
+ listView.Y = frameBack.Bottom;
bodyFrameLayout.AddChidren(listView);
- //鍒濆鍖栨垚鍛樺垪琛�
- this.InitMemberList();
+ HdlThreadLogic.Current.RunMainInThread(() =>
+ {
+ //鎬讳箣鍏堟竻绌哄叡浜枃浠跺す鍑嗘病閿�
+ HdlShardLogic.Current.ClearShardDirectory();
+ //鍒濆鍖栨垚鍛樺垪琛�
+ this.InitMemberList();
+ });
}
/// <summary>
@@ -184,12 +192,17 @@
{
if (listCheck.Contains(infoRes.DistributedMark) == true
|| infoRes.Account == UserCenterResourse.UserInfo.Phone
- || infoRes.Account == UserCenterResourse.UserInfo.Email
- || infoRes.AccountType != 0)
+ || infoRes.Account == UserCenterResourse.UserInfo.Email)
{
- //濡傛灉鏄畠鑷繁鐨勮瘽,鎴栬�呮潈闄愮瓑绾ф瘮浠栭珮鐨勶紝涓嶆樉绀�
+ //濡傛灉鏄畠鑷繁鐨勮瘽锛屼笉鏄剧ず
continue;
}
+ if (UserCenterResourse.UserInfo.AuthorityNo != 1 && infoRes.AccountType != 0)
+ {
+ //涓嶈兘澶熻幏鍙栨潈闄愮瓑绾ф瘮浠栭珮鐨�(涓讳汉鑷繁鍙互鏃犺杩欎釜鍒ゆ柇)
+ continue;
+ }
+
listCheck.Add(infoRes.DistributedMark);
//娣诲姞鎴愬憳淇℃伅鐨勭紦瀛�
UserCenterResourse.ListMemberInfo.Add(infoRes);
@@ -224,13 +237,7 @@
this.AddRowLayout(listNewInfo[i], i != count);
}
//璋冩暣鍒楄〃鎺т欢鐨勯珮搴�
- var realHeight = listNewInfo.Count * listView.GetChildren(listView.ChildrenCount - 1).Height;
- realHeight += Application.GetRealHeight(23) - listView.rowSpace + Application.GetRealHeight(23);
- if (realHeight < listView.Height)
- {
- //缂╁皬鎺т欢楂樺害
- listView.Height = realHeight;
- }
+ listView.AdjustRealHeight(Application.GetRealHeight(23));
}
#endregion
@@ -244,16 +251,6 @@
/// <param name="addLine">addLine</param>
private void AddRowLayout(MemberInfoRes info, bool addLine)
{
- if (listView.ChildrenCount == 0)
- {
- //濉炰竴涓┖鐧界殑杩涘幓鍗犵┖闂�
- var rowTemp = new FrameRowControl();
- rowTemp.UseClickStatu = false;
- rowTemp.Height = Application.GetRealHeight(23) - listView.rowSpace;
- rowTemp.MainKeys = string.Empty;
- listView.AddChidren(rowTemp);
- }
-
var rowlayout = new FrameRowControl(listView.rowSpace / 2);
rowlayout.Height = Application.GetRealHeight(138);
rowlayout.MainKeys = info.Account;
@@ -277,7 +274,7 @@
rowlayout.AddBottomLine();
}
//鍙冲浘鏍�
- rowlayout.AddRightIconControl();
+ rowlayout.AddRightArrow();
rowlayout.ButtonClickEvent += (sender, e) =>
{
var form = new MemberManagementForm();
@@ -317,7 +314,7 @@
/// <summary>
/// 鑷韩鐨勪笂灞傜晫闈㈠叧闂悗,瀹冭嚜韬浜庢渶涓婂眰鏃�,瑙﹀彂鐨勪簨浠�
/// </summary>
- public override void FormActionAgainEvent()
+ public override int FormActionAgainEvent()
{
//娓呯┖鍏变韩鏂囦欢澶�
HdlShardLogic.Current.ClearShardDirectory();
@@ -327,6 +324,8 @@
//娣诲姞鎴愬憳鍒楄〃
this.AddMemberListRowByData();
+
+ return 1;
}
#endregion
--
Gitblit v1.8.0