|
|
|
@ -37,6 +37,8 @@ namespace formula_manage |
|
|
|
|
|
|
|
DataTable STUFFdataTable = new DataTable(); //建立STUFF缓存
|
|
|
|
DataTable MACHINEdataTable = new DataTable(); //建立Machine缓存
|
|
|
|
DataTable RRODUCTdataTable = new DataTable(); //建立RRODUCT缓存
|
|
|
|
DataTable RecipedataTable = new DataTable(); //建立Recipe缓存
|
|
|
|
|
|
|
|
public string INIPath = Convert.ToString(System.AppDomain.CurrentDomain.BaseDirectory) + "formula.ini"; //配置文件路径
|
|
|
|
|
|
|
|
@ -77,10 +79,19 @@ namespace formula_manage |
|
|
|
|
|
|
|
sql_();//查询stuff表
|
|
|
|
Permissions_(); //权限管理
|
|
|
|
|
|
|
|
CountDown();//执行循环方法
|
|
|
|
|
|
|
|
DataTable RRODUCTdataTable = new DataTable(); |
|
|
|
RecipedataTable.Columns.Add("DYELOT", typeof(int)); |
|
|
|
RecipedataTable.Columns.Add("STEP", typeof(string)); |
|
|
|
RecipedataTable.Columns.Add("PRODUCT_CODE", typeof(string)); |
|
|
|
RecipedataTable.Columns.Add("PRODUCT_CODE", typeof(string)); |
|
|
|
RecipedataTable.Columns.Add("CONC", typeof(string)); |
|
|
|
RecipedataTable.Columns.Add("SHIFT", typeof(string)); |
|
|
|
RecipedataTable.Columns.Add("PRODUCT_NAME", typeof(string)); |
|
|
|
RecipedataTable.Columns.Add("TARGET_WT", typeof(float)); |
|
|
|
RecipedataTable.Columns.Add("UNIT", typeof(string)); |
|
|
|
RecipedataTable.Columns.Add("REMARK", typeof(string)); |
|
|
|
|
|
|
|
RRODUCTdataTable.Columns.Add("ID", typeof(int)); |
|
|
|
RRODUCTdataTable.Columns.Add("STEP", typeof(string)); |
|
|
|
RRODUCTdataTable.Columns.Add("PRODUCT_CODE", typeof(string)); |
|
|
|
@ -100,7 +111,7 @@ namespace formula_manage |
|
|
|
{ |
|
|
|
row = RRODUCTdataTable.NewRow(); |
|
|
|
row["ID"] = ID_N; |
|
|
|
row["STEP"] = Procedures_P.Text; |
|
|
|
// row["STEP"] = Procedures_P.Text;
|
|
|
|
RRODUCTdataTable.Rows.Add(row); |
|
|
|
} |
|
|
|
|
|
|
|
@ -108,7 +119,6 @@ namespace formula_manage |
|
|
|
|
|
|
|
this.DataContext = STUFFdataTable; |
|
|
|
|
|
|
|
|
|
|
|
/* DataGridTemplateColumn tempColumn = Grid_RRODUCT.Columns[1] as DataGridTemplateColumn; |
|
|
|
FrameworkElement element1 = Grid_RRODUCT.Columns[1].GetCellContent(Grid_RRODUCT.Items[1]); |
|
|
|
System.Windows.Controls.ComboBox comboBox1 = tempColumn.CellTemplate.FindName("CP_PRODUCT_CODE", element1) as System.Windows.Controls.ComboBox; |
|
|
|
@ -116,7 +126,6 @@ namespace formula_manage |
|
|
|
comboBox1.ItemsSource = STUFFdataTable.DefaultView;*/ |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
/* private int g_TypeNameDicNo; //枪型号名
|
|
|
|
|
|
|
|
public int G_TypeNameDicNo |
|
|
|
@ -291,13 +300,15 @@ namespace formula_manage |
|
|
|
public void DisTimer_Tick(object sender, EventArgs e)//循环事件
|
|
|
|
{ |
|
|
|
USERTIME.Text = DateTime.Now.ToString("yyyy-MM-dd HH:mm:ss"); |
|
|
|
|
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
public void CountDown() |
|
|
|
{ |
|
|
|
//设置定时器
|
|
|
|
disTimer.Tick += new EventHandler(DisTimer_Tick);//每一秒执行的方法
|
|
|
|
disTimer.Interval = new TimeSpan(10000000); //时间间隔为一秒。
|
|
|
|
disTimer.Interval = new TimeSpan(1000000); //时间间隔为一秒。
|
|
|
|
disTimer.Start();//计时开始
|
|
|
|
} |
|
|
|
|
|
|
|
|