网络组件更新,用户暗号重新设计,个人信息界面文件上传支持拖拽
This commit is contained in:
@@ -49,7 +49,7 @@ namespace CommonLibrary
|
||||
if (name == all_list_accounts[i].UserName)
|
||||
{
|
||||
all_list_accounts[i].Password = password;
|
||||
ILogNet?.WriteInfo(Resource.StringResouce.AccountModifyPassword + name);
|
||||
ILogNet?.WriteInfo(SoftResources.StringResouce.AccountModifyPassword + name);
|
||||
break;
|
||||
}
|
||||
}
|
||||
@@ -72,7 +72,7 @@ namespace CommonLibrary
|
||||
{
|
||||
all_list_accounts[i].SmallPortraitMD5 = smallPortraitMD5;
|
||||
all_list_accounts[i].LargePortraitMD5 = largePortraitMD5;
|
||||
ILogNet?.WriteInfo(Resource.StringResouce.AccountUploadPortrait + name);
|
||||
ILogNet?.WriteInfo(SoftResources.StringResouce.AccountUploadPortrait + name);
|
||||
break;
|
||||
}
|
||||
}
|
||||
@@ -176,7 +176,7 @@ namespace CommonLibrary
|
||||
}
|
||||
}
|
||||
all_list_accounts.Add(account);
|
||||
ILogNet?.WriteInfo(Resource.StringResouce.AccountAddSuccess + account.UserName);
|
||||
ILogNet?.WriteInfo(SoftResources.StringResouce.AccountAddSuccess + account.UserName);
|
||||
|
||||
hybirdLock.Leave();
|
||||
return result;
|
||||
@@ -194,7 +194,7 @@ namespace CommonLibrary
|
||||
if (name == all_list_accounts[i].UserName)
|
||||
{
|
||||
all_list_accounts.RemoveAt(i);
|
||||
ILogNet?.WriteInfo(Resource.StringResouce.AccountDeleteSuccess + name);
|
||||
ILogNet?.WriteInfo(SoftResources.StringResouce.AccountDeleteSuccess + name);
|
||||
break;
|
||||
}
|
||||
}
|
||||
@@ -241,7 +241,7 @@ namespace CommonLibrary
|
||||
}
|
||||
catch (Exception ex)
|
||||
{
|
||||
ILogNet?.WriteException(Resource.StringResouce.AccountLoadFailed, ex);
|
||||
ILogNet?.WriteException(SoftResources.StringResouce.AccountLoadFailed, ex);
|
||||
}
|
||||
hybirdLock.Leave();
|
||||
}
|
||||
|
||||
@@ -228,7 +228,10 @@ namespace CommonLibrary
|
||||
/// 指示系统的主题色是否是深色,目前只适合于wpf
|
||||
/// </summary>
|
||||
public bool IsThemeDark { get; set; } = false;
|
||||
|
||||
/// <summary>
|
||||
/// 本地保存的密码过期天数
|
||||
/// </summary>
|
||||
public int PasswordOverdueDays { get; set; } = 7;
|
||||
|
||||
/// <summary>
|
||||
/// 当前计算机的机器码,用来判定参数是否是正确的
|
||||
@@ -251,6 +254,7 @@ namespace CommonLibrary
|
||||
json.Add(nameof(SystemInfo), new JValue(SystemInfo));
|
||||
json.Add(nameof(LoginTime), new JValue(LoginTime));
|
||||
json.Add(nameof(IsThemeDark), new JValue(IsThemeDark));
|
||||
json.Add(nameof(PasswordOverdueDays), new JValue(PasswordOverdueDays));
|
||||
return json.ToString();
|
||||
}
|
||||
|
||||
@@ -258,14 +262,17 @@ namespace CommonLibrary
|
||||
{
|
||||
JObject json = JObject.Parse(content);
|
||||
string systemInfo = SoftBasic.GetValueFromJsonObject(json, nameof(SystemInfo), "");
|
||||
// 用户名不会因此更改
|
||||
LoginName = SoftBasic.GetValueFromJsonObject(json, nameof(LoginName), LoginName);
|
||||
|
||||
if (systemInfo == SystemInfo)
|
||||
{
|
||||
//确认账户名及密码是本机的记录,而不是从其他电脑端拷贝过来的
|
||||
LoginName = SoftBasic.GetValueFromJsonObject(json, nameof(LoginName), LoginName);
|
||||
IsNewVersionRunning = SoftBasic.GetValueFromJsonObject(json, nameof(IsNewVersionRunning), IsNewVersionRunning);
|
||||
Password = SoftBasic.GetValueFromJsonObject(json, nameof(Password), Password);
|
||||
LoginTime = SoftBasic.GetValueFromJsonObject(json, nameof(LoginTime), LoginTime);
|
||||
IsThemeDark = SoftBasic.GetValueFromJsonObject(json, nameof(IsThemeDark), IsThemeDark);
|
||||
PasswordOverdueDays = SoftBasic.GetValueFromJsonObject(json, nameof(PasswordOverdueDays), PasswordOverdueDays);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -92,7 +92,7 @@
|
||||
<Compile Include="OrderSupport\ClassOrder.cs" />
|
||||
<Compile Include="PortraitSupport\PortraitSupport.cs" />
|
||||
<Compile Include="Properties\AssemblyInfo.cs" />
|
||||
<Compile Include="Resource.cs" />
|
||||
<Compile Include="ProtocolSupport\Resource.cs" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<EmbeddedResource Include="AccountSupport\FormAccountManage.resx">
|
||||
|
||||
@@ -55,7 +55,7 @@ namespace CommonLibrary
|
||||
*
|
||||
**************************************************************************/
|
||||
|
||||
SoftBasic.FrameworkVersion = new SystemVersion("1.4.0");
|
||||
SoftBasic.FrameworkVersion = new SystemVersion("1.4.1");
|
||||
|
||||
}
|
||||
|
||||
|
||||
@@ -5,26 +5,23 @@ using System.Text;
|
||||
|
||||
namespace CommonLibrary
|
||||
{
|
||||
|
||||
/*********************************************************************************************
|
||||
*
|
||||
* 说明:用于同步网络和异步网络的各种消息头的区别,初始想法使用长度为4的字符串区分,
|
||||
* 目前改为int数据区分,以后需要代码重构
|
||||
*
|
||||
*********************************************************************************************/
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// 用于网络通信的二级协议头说明
|
||||
/// </summary>
|
||||
public class CommonHeadCode
|
||||
{
|
||||
|
||||
/************************************************************************************************
|
||||
*
|
||||
* 注意:您在准备二次开发时,应该重新生成一个自己的GUID码
|
||||
*
|
||||
**************************************************************************************************/
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// 用于整个网络服务交互的身份令牌,可有效的防止来自网络的攻击,重新生成令牌后就无法更改,否则不支持自动升级
|
||||
/// </summary>
|
||||
public static Guid KeyToken { get; set; } = new Guid("1275BB9A-14B2-4A96-9673-B0AF0463D474");
|
||||
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// 同步通信的指令头说明,以10000开头,后面接20000,30000,
|
||||
/// </summary>
|
||||
@@ -61,8 +58,7 @@ namespace CommonLibrary
|
||||
public static int 请求分厂 { get; } = 10016;
|
||||
public static int 上传分厂 { get; } = 10017;
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// 判断指令否是日志相关指令
|
||||
|
||||
@@ -8,7 +8,7 @@ namespace CommonLibrary
|
||||
/// <summary>
|
||||
/// 所有的数据资源中心
|
||||
/// </summary>
|
||||
public class Resource
|
||||
public class SoftResources
|
||||
{
|
||||
/// <summary>
|
||||
/// 字符串资源中心
|
||||
Reference in New Issue
Block a user