Browse Source

增加同步起始表位置

大厂分支
zhichao lei 4 years ago
parent
commit
73e1897349
4 changed files with 35 additions and 0 deletions
  1. +22
    -0
      Learun.Framework.Ultimate V7/Quanjiang.DigitalScholl.DataSync/Form1.Designer.cs
  2. +2
    -0
      Learun.Framework.Ultimate V7/Quanjiang.DigitalScholl.DataSync/Form1.cs
  3. +1
    -0
      Learun.Framework.Ultimate V7/Quanjiang.DigitalScholl.DataSync/Program.cs
  4. +10
    -0
      Learun.Framework.Ultimate V7/Quanjiang.DigitalScholl.DataSync/SyncWindow.cs

+ 22
- 0
Learun.Framework.Ultimate V7/Quanjiang.DigitalScholl.DataSync/Form1.Designer.cs View File

@@ -45,6 +45,8 @@
this.menuStrip1 = new System.Windows.Forms.MenuStrip(); this.menuStrip1 = new System.Windows.Forms.MenuStrip();
this.系统工具ToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem(); this.系统工具ToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
this.查找密码为123456的ToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem(); this.查找密码为123456的ToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
this.txtBeginTable = new System.Windows.Forms.TextBox();
this.label5 = new System.Windows.Forms.Label();
this.menuStrip1.SuspendLayout(); this.menuStrip1.SuspendLayout();
this.SuspendLayout(); this.SuspendLayout();
// //
@@ -204,11 +206,29 @@
this.查找密码为123456的ToolStripMenuItem.Text = "查找密码为123456的"; this.查找密码为123456的ToolStripMenuItem.Text = "查找密码为123456的";
this.查找密码为123456的ToolStripMenuItem.Click += new System.EventHandler(this.查找密码为123456的ToolStripMenuItem_Click); this.查找密码为123456的ToolStripMenuItem.Click += new System.EventHandler(this.查找密码为123456的ToolStripMenuItem_Click);
// //
// txtBeginTable
//
this.txtBeginTable.Location = new System.Drawing.Point(305, 189);
this.txtBeginTable.Name = "txtBeginTable";
this.txtBeginTable.Size = new System.Drawing.Size(128, 21);
this.txtBeginTable.TabIndex = 13;
//
// label5
//
this.label5.AutoSize = true;
this.label5.Location = new System.Drawing.Point(222, 192);
this.label5.Name = "label5";
this.label5.Size = new System.Drawing.Size(77, 12);
this.label5.TabIndex = 14;
this.label5.Text = "由此开始同步";
//
// Form1 // Form1
// //
this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 12F); this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 12F);
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font; this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
this.ClientSize = new System.Drawing.Size(800, 561); this.ClientSize = new System.Drawing.Size(800, 561);
this.Controls.Add(this.label5);
this.Controls.Add(this.txtBeginTable);
this.Controls.Add(this.btsyncmis); this.Controls.Add(this.btsyncmis);
this.Controls.Add(this.btsynccore); this.Controls.Add(this.btsynccore);
this.Controls.Add(this.clbmodule); this.Controls.Add(this.clbmodule);
@@ -254,6 +274,8 @@
private System.Windows.Forms.MenuStrip menuStrip1; private System.Windows.Forms.MenuStrip menuStrip1;
private System.Windows.Forms.ToolStripMenuItem 系统工具ToolStripMenuItem; private System.Windows.Forms.ToolStripMenuItem 系统工具ToolStripMenuItem;
private System.Windows.Forms.ToolStripMenuItem 查找密码为123456的ToolStripMenuItem; private System.Windows.Forms.ToolStripMenuItem 查找密码为123456的ToolStripMenuItem;
private System.Windows.Forms.TextBox txtBeginTable;
private System.Windows.Forms.Label label5;
} }
} }



+ 2
- 0
Learun.Framework.Ultimate V7/Quanjiang.DigitalScholl.DataSync/Form1.cs View File

@@ -116,6 +116,7 @@ namespace Quanjiang.DigitalScholl.DataSync
Thread mainthread = null; Thread mainthread = null;
private void btsynccore_Click(object sender, EventArgs e) private void btsynccore_Click(object sender, EventArgs e)
{ {
Program.beginTable = txtBeginTable.Text;
ThreadStart threadstart = new ThreadStart(TransferCoreData); ThreadStart threadstart = new ThreadStart(TransferCoreData);
mainthread = new Thread(threadstart); mainthread = new Thread(threadstart);
mainthread.Name = "main"; mainthread.Name = "main";
@@ -124,6 +125,7 @@ namespace Quanjiang.DigitalScholl.DataSync


private void btsyncmis_Click(object sender, EventArgs e) private void btsyncmis_Click(object sender, EventArgs e)
{ {
Program.beginTable = txtBeginTable.Text;
ThreadStart threadstart = new ThreadStart(TransferMisData); ThreadStart threadstart = new ThreadStart(TransferMisData);
mainthread = new Thread(threadstart); mainthread = new Thread(threadstart);
mainthread.Name = "main"; mainthread.Name = "main";


+ 1
- 0
Learun.Framework.Ultimate V7/Quanjiang.DigitalScholl.DataSync/Program.cs View File

@@ -7,6 +7,7 @@ namespace Quanjiang.DigitalScholl.DataSync
{ {
static class Program static class Program
{ {
public static string beginTable = "";
/// <summary> /// <summary>
/// 应用程序的主入口点。 /// 应用程序的主入口点。
/// </summary> /// </summary>


+ 10
- 0
Learun.Framework.Ultimate V7/Quanjiang.DigitalScholl.DataSync/SyncWindow.cs View File

@@ -88,6 +88,11 @@ namespace Quanjiang.DigitalScholl.DataSync
{ {
AppendTextValue("正在检测" + sourcetable.Name + "表结构...\r\n"); AppendTextValue("正在检测" + sourcetable.Name + "表结构...\r\n");
SetValueProgressBar(SetValue, GetProgressValue()+1); SetValueProgressBar(SetValue, GetProgressValue()+1);
if (Program.beginTable != "")
{
if(sourcetable.Name!=Program.beginTable)
continue;
}
if (targettables.Contains(sourcetable.Name)) if (targettables.Contains(sourcetable.Name))
{ {
ColumnCollection sourcecolumns = sourcetable.Columns; ColumnCollection sourcecolumns = sourcetable.Columns;
@@ -194,6 +199,11 @@ namespace Quanjiang.DigitalScholl.DataSync
{ {
AppendTextValue("正在检测" + sourcetable.Name + "表结构...\r\n"); AppendTextValue("正在检测" + sourcetable.Name + "表结构...\r\n");
SetValueProgressBar(SetValue, GetProgressValue() + 1); SetValueProgressBar(SetValue, GetProgressValue() + 1);
if (Program.beginTable != "")
{
if (sourcetable.Name != Program.beginTable)
continue;
}
if (targettables.Contains(sourcetable.Name)) if (targettables.Contains(sourcetable.Name))
{ {
ColumnCollection sourcecolumns = sourcetable.Columns; ColumnCollection sourcecolumns = sourcetable.Columns;


Loading…
Cancel
Save