diff --git a/CommonLibrary/AccountSupport/ServerAccount.cs b/CommonLibrary/AccountSupport/ServerAccount.cs
index 31ba40c..e0b4033 100644
--- a/CommonLibrary/AccountSupport/ServerAccount.cs
+++ b/CommonLibrary/AccountSupport/ServerAccount.cs
@@ -13,6 +13,8 @@ namespace CommonLibrary
/// 账户类,该类必须派生自UserAccount类
public class ServerAccounts : HslCommunication.BasicFramework.SoftFileSaveBase where T : UserAccount, new()
{
+ #region Constructor
+
///
/// 初始化构造方法
///
@@ -28,14 +30,20 @@ namespace CommonLibrary
all_list_accounts.AddRange(accounts);
}
- private List all_list_accounts = new List();
-
+ #endregion
+ #region Private Member
+
+ private List all_list_accounts = new List();
///
/// 一个简单的混合锁,相比Lock速度更快
///
private HslCommunication.SimpleHybirdLock hybirdLock = new HslCommunication.SimpleHybirdLock();
+ #endregion
+
+ #region Public Method
+
///
/// 更新指定账户的密码
///
@@ -126,15 +134,16 @@ namespace CommonLibrary
{
if (item.Password != code)
{
+ item.LoginFailedCount++;
result.ForbidMessage = "密码错误!";
break;
}
else
{
- //说明已经登录成功,需要进行进一步操作
+ // 说明已经登录成功,需要进行进一步操作
item.LoginFrequency++;
result = item.DeepCopy();
- //下面两个数据应该是旧的数据
+ // 下面两个数据应该是旧的数据
item.LastLoginIpAddress = ipAddress;
item.LastLoginTime = DateTime.Now;
item.LastLoginWay = way;
@@ -161,7 +170,7 @@ namespace CommonLibrary
/// 新增一个账户,如果账户名称已经存在,则返回False,注册成功返回True
///
/// 账户对象
- /// 成功True,失败False
+ /// 成功True,失败False
public bool AddNewAccount(T account)
{
bool result = true;
@@ -246,7 +255,9 @@ namespace CommonLibrary
hybirdLock.Leave();
}
+ #endregion
+ #region Override Method
@@ -280,5 +291,8 @@ namespace CommonLibrary
{
SaveToFile(m => m);
}
+
+
+ #endregion
}
}
diff --git a/CommonLibrary/ProtocolSupport/CommonProtocol.cs b/CommonLibrary/ProtocolSupport/CommonProtocol.cs
index 03364d8..a3e27aa 100644
--- a/CommonLibrary/ProtocolSupport/CommonProtocol.cs
+++ b/CommonLibrary/ProtocolSupport/CommonProtocol.cs
@@ -43,7 +43,7 @@ namespace CommonLibrary
*
**************************************************************************/
- SoftBasic.FrameworkVersion = new SystemVersion("1.4.7");
+ SoftBasic.FrameworkVersion = new SystemVersion("1.4.8");
}