Commit 0322031b authored by tr's avatar tr

1、增加更新记录查看功能

parent 6cfcb9e0
...@@ -65,6 +65,7 @@ ...@@ -65,6 +65,7 @@
this.label2 = new System.Windows.Forms.Label(); this.label2 = new System.Windows.Forms.Label();
this.toolTip1 = new System.Windows.Forms.ToolTip(this.components); this.toolTip1 = new System.Windows.Forms.ToolTip(this.components);
this.timer1 = new System.Windows.Forms.Timer(this.components); this.timer1 = new System.Windows.Forms.Timer(this.components);
this.tsmiSysUpdateLog = new System.Windows.Forms.ToolStripMenuItem();
this.panel1.SuspendLayout(); this.panel1.SuspendLayout();
((System.ComponentModel.ISupportInitialize)(this.splitContainer1)).BeginInit(); ((System.ComponentModel.ISupportInitialize)(this.splitContainer1)).BeginInit();
this.splitContainer1.Panel1.SuspendLayout(); this.splitContainer1.Panel1.SuspendLayout();
...@@ -189,6 +190,7 @@ ...@@ -189,6 +190,7 @@
this.toolStripMenuItem1.DropDownItems.AddRange(new System.Windows.Forms.ToolStripItem[] { this.toolStripMenuItem1.DropDownItems.AddRange(new System.Windows.Forms.ToolStripItem[] {
this.tsmiSysUpload, this.tsmiSysUpload,
this.tsmiSysUpdate, this.tsmiSysUpdate,
this.tsmiSysUpdateLog,
this.tsmiSysReLogin, this.tsmiSysReLogin,
this.tsmiSysExit}); this.tsmiSysExit});
this.toolStripMenuItem1.Name = "toolStripMenuItem1"; this.toolStripMenuItem1.Name = "toolStripMenuItem1";
...@@ -198,25 +200,25 @@ ...@@ -198,25 +200,25 @@
// tsmiSysUpload // tsmiSysUpload
// //
this.tsmiSysUpload.Name = "tsmiSysUpload"; this.tsmiSysUpload.Name = "tsmiSysUpload";
this.tsmiSysUpload.Size = new System.Drawing.Size(124, 22); this.tsmiSysUpload.Size = new System.Drawing.Size(180, 22);
this.tsmiSysUpload.Text = "上传更新"; this.tsmiSysUpload.Text = "上传更新";
// //
// tsmiSysUpdate // tsmiSysUpdate
// //
this.tsmiSysUpdate.Name = "tsmiSysUpdate"; this.tsmiSysUpdate.Name = "tsmiSysUpdate";
this.tsmiSysUpdate.Size = new System.Drawing.Size(124, 22); this.tsmiSysUpdate.Size = new System.Drawing.Size(180, 22);
this.tsmiSysUpdate.Text = "检查更新"; this.tsmiSysUpdate.Text = "检查更新";
// //
// tsmiSysReLogin // tsmiSysReLogin
// //
this.tsmiSysReLogin.Name = "tsmiSysReLogin"; this.tsmiSysReLogin.Name = "tsmiSysReLogin";
this.tsmiSysReLogin.Size = new System.Drawing.Size(124, 22); this.tsmiSysReLogin.Size = new System.Drawing.Size(180, 22);
this.tsmiSysReLogin.Text = "重新登录"; this.tsmiSysReLogin.Text = "重新登录";
// //
// tsmiSysExit // tsmiSysExit
// //
this.tsmiSysExit.Name = "tsmiSysExit"; this.tsmiSysExit.Name = "tsmiSysExit";
this.tsmiSysExit.Size = new System.Drawing.Size(124, 22); this.tsmiSysExit.Size = new System.Drawing.Size(180, 22);
this.tsmiSysExit.Text = "退出系统"; this.tsmiSysExit.Text = "退出系统";
// //
// toolStripMenuItem2 // toolStripMenuItem2
...@@ -231,13 +233,13 @@ ...@@ -231,13 +233,13 @@
// tsmiAccPasswordMgr // tsmiAccPasswordMgr
// //
this.tsmiAccPasswordMgr.Name = "tsmiAccPasswordMgr"; this.tsmiAccPasswordMgr.Name = "tsmiAccPasswordMgr";
this.tsmiAccPasswordMgr.Size = new System.Drawing.Size(124, 22); this.tsmiAccPasswordMgr.Size = new System.Drawing.Size(180, 22);
this.tsmiAccPasswordMgr.Text = "密码管理"; this.tsmiAccPasswordMgr.Text = "密码管理";
// //
// tsmiAccPersonalSetting // tsmiAccPersonalSetting
// //
this.tsmiAccPersonalSetting.Name = "tsmiAccPersonalSetting"; this.tsmiAccPersonalSetting.Name = "tsmiAccPersonalSetting";
this.tsmiAccPersonalSetting.Size = new System.Drawing.Size(124, 22); this.tsmiAccPersonalSetting.Size = new System.Drawing.Size(180, 22);
this.tsmiAccPersonalSetting.Text = "个人设置"; this.tsmiAccPersonalSetting.Text = "个人设置";
// //
// toolStripMenuItem3 // toolStripMenuItem3
...@@ -252,13 +254,13 @@ ...@@ -252,13 +254,13 @@
// tsmiHelpDocument // tsmiHelpDocument
// //
this.tsmiHelpDocument.Name = "tsmiHelpDocument"; this.tsmiHelpDocument.Name = "tsmiHelpDocument";
this.tsmiHelpDocument.Size = new System.Drawing.Size(124, 22); this.tsmiHelpDocument.Size = new System.Drawing.Size(180, 22);
this.tsmiHelpDocument.Text = "帮助文档"; this.tsmiHelpDocument.Text = "帮助文档";
// //
// tsmiHelpAboutUs // tsmiHelpAboutUs
// //
this.tsmiHelpAboutUs.Name = "tsmiHelpAboutUs"; this.tsmiHelpAboutUs.Name = "tsmiHelpAboutUs";
this.tsmiHelpAboutUs.Size = new System.Drawing.Size(124, 22); this.tsmiHelpAboutUs.Size = new System.Drawing.Size(180, 22);
this.tsmiHelpAboutUs.Text = "关于我们"; this.tsmiHelpAboutUs.Text = "关于我们";
// //
// Header // Header
...@@ -455,6 +457,12 @@ ...@@ -455,6 +457,12 @@
this.timer1.Interval = 1000; this.timer1.Interval = 1000;
this.timer1.Tick += new System.EventHandler(this.timer1_Tick); this.timer1.Tick += new System.EventHandler(this.timer1_Tick);
// //
// tsmiSysUpdateLog
//
this.tsmiSysUpdateLog.Name = "tsmiSysUpdateLog";
this.tsmiSysUpdateLog.Size = new System.Drawing.Size(180, 22);
this.tsmiSysUpdateLog.Text = "更新记录";
//
// wMain // wMain
// //
this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 12F); this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 12F);
...@@ -520,5 +528,6 @@ ...@@ -520,5 +528,6 @@
private System.Windows.Forms.Label label3; private System.Windows.Forms.Label label3;
private System.Windows.Forms.Timer timer1; private System.Windows.Forms.Timer timer1;
private System.Windows.Forms.WebBrowser webBrowser1; private System.Windows.Forms.WebBrowser webBrowser1;
private System.Windows.Forms.ToolStripMenuItem tsmiSysUpdateLog;
} }
} }
\ No newline at end of file
...@@ -189,6 +189,7 @@ namespace Tools ...@@ -189,6 +189,7 @@ namespace Tools
{ {
case "SysUpload": this.UploadUpdate(); break; case "SysUpload": this.UploadUpdate(); break;
case "SysUpdate": this.CheckUpdate(); break; case "SysUpdate": this.CheckUpdate(); break;
case "SysUpdateLog": this.ViewUpdateLog(); break;
case "SysReLogin": this.ReLogin(); break; case "SysReLogin": this.ReLogin(); break;
case "SysExit": this.Exit(); break; case "SysExit": this.Exit(); break;
case "AccPasswordMgr": this.PasswordMgr(); break; case "AccPasswordMgr": this.PasswordMgr(); break;
...@@ -243,6 +244,22 @@ namespace Tools ...@@ -243,6 +244,22 @@ namespace Tools
} }
} }
/// <summary> /// <summary>
/// 查看更新记录
/// </summary>
private void ViewUpdateLog()
{
StringBuilder sb = new StringBuilder("*注:仅展示最近20条更新记录\r\n");
var link = Utils.GetDbLinkString204("FTT_Work");
var dt = new SmpDB().GetDataTable(link, "SELECT TOP 20 ROW_NUMBER() OVER(ORDER BY ID) AS SN, UDate, URemark FROM dbo.FTT_AutoUpdate ORDER BY ID DESC", "Log", false);
foreach (DataRowView r in dt.DefaultView)
{
var date = (r["UDate"] as DateTime?)?.ToString("yyyy/MM/dd HH:mm:ss.fff");
sb.Append($"{new string('-', 100)}\r\n版本序号:{r["SN"]}\r\n更新时间:{date}\r\n{r["URemark"].ToString().Trim()}\r\n");
}
//
Utils.Tip(sb.ToString(), 600, 400);
}
/// <summary>
/// 系统:重新登录 /// 系统:重新登录
/// </summary> /// </summary>
private void ReLogin() private void ReLogin()
......
...@@ -125,7 +125,7 @@ ...@@ -125,7 +125,7 @@
AAEAAAD/////AQAAAAAAAAAMAgAAAFdTeXN0ZW0uV2luZG93cy5Gb3JtcywgVmVyc2lvbj00LjAuMC4w AAEAAAD/////AQAAAAAAAAAMAgAAAFdTeXN0ZW0uV2luZG93cy5Gb3JtcywgVmVyc2lvbj00LjAuMC4w
LCBDdWx0dXJlPW5ldXRyYWwsIFB1YmxpY0tleVRva2VuPWI3N2E1YzU2MTkzNGUwODkFAQAAACZTeXN0 LCBDdWx0dXJlPW5ldXRyYWwsIFB1YmxpY0tleVRva2VuPWI3N2E1YzU2MTkzNGUwODkFAQAAACZTeXN0
ZW0uV2luZG93cy5Gb3Jtcy5JbWFnZUxpc3RTdHJlYW1lcgEAAAAERGF0YQcCAgAAAAkDAAAADwMAAAAc ZW0uV2luZG93cy5Gb3Jtcy5JbWFnZUxpc3RTdHJlYW1lcgEAAAAERGF0YQcCAgAAAAkDAAAADwMAAAAc
GwAAAk1TRnQBSQFMAgEBCQEAAWABAAFgAQABIAEAASABAAT/AQkBAAj/AUIBTQE2AQQGAAE2AQQCAAEo GwAAAk1TRnQBSQFMAgEBCQEAAWgBAAFoAQABIAEAASABAAT/AQkBAAj/AUIBTQE2AQQGAAE2AQQCAAEo
AwABgAMAAWADAAEBAQABCAYAATAYAAGAAgABgAMAAoABAAGAAwABgAEAAYABAAKAAgADwAEAAcAB3AHA AwABgAMAAWADAAEBAQABCAYAATAYAAGAAgABgAMAAoABAAGAAwABgAEAAYABAAKAAgADwAEAAcAB3AHA
AQAB8AHKAaYBAAEzBQABMwEAATMBAAEzAQACMwIAAxYBAAMcAQADIgEAAykBAANVAQADTQEAA0IBAAM5 AQAB8AHKAaYBAAEzBQABMwEAATMBAAEzAQACMwIAAxYBAAMcAQADIgEAAykBAANVAQADTQEAA0IBAAM5
AQABgAF8Af8BAAJQAf8BAAGTAQAB1gEAAf8B7AHMAQABxgHWAe8BAAHWAucBAAGQAakBrQIAAf8BMwMA AQABgAF8Af8BAAJQAf8BAAGTAQAB1gEAAf8B7AHMAQABxgHWAe8BAAHWAucBAAGQAakBrQIAAf8BMwMA
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment