页面刷新逻辑修改
This commit is contained in:
commit
46dd51be3d
3 files changed
+65
-70
No files matched your search
@@ -295,8 +295,14 @@ namespace DyeingComputer.View
|
||||
catch (Exception) { }
|
||||
SQLiteHelpers.Close(); //关闭连接
|
||||
|
||||
// if (sql != null)
|
||||
// if (sql != null)
|
||||
MainWindowViewModel.dt_TP = sql.Tables[0]; //转换显示计划表
|
||||
|
||||
|
||||
DataRow newRow;
|
||||
newRow = MainWindowViewModel.dt_TP.NewRow();
|
||||
newRow["StepName"] = "END";
|
||||
MainWindowViewModel.dt_TP.Rows.Add(newRow);
|
||||
}
|
||||
|
||||
private void UserControl_Loaded(object sender, RoutedEventArgs e)
|
||||
@@ -487,14 +493,31 @@ namespace DyeingComputer.View
|
||||
|
||||
private void ProgramgroupView_run_Click(object sender, RoutedEventArgs e)//运行/暂停
|
||||
{
|
||||
|
||||
if (MainWindowViewModel.WORK_RUN == 2)
|
||||
{
|
||||
MainWindowViewModel.WORK_RUN = 1;// 运行时停止键为暂停
|
||||
}
|
||||
else
|
||||
{
|
||||
MainWindowViewModel.WORK_RUN = 2;// 运行时停止键为
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
private void ProgramgroupView_stop_Click(object sender, RoutedEventArgs e)//结束工艺
|
||||
{
|
||||
MessageBoxResult messageBoxResult = System.Windows.MessageBox.Show(Properties.Resources.StopProcess, "800", MessageBoxButton.OKCancel);
|
||||
if (messageBoxResult == MessageBoxResult.OK)
|
||||
{
|
||||
MainWindowViewModel.WORK_RUN = 0;// 运行时停止键为
|
||||
MainWindowViewModel.DIDETime = 0;
|
||||
|
||||
|
||||
|
||||
MainWindowViewModel.dt_TP.Rows.Clear();
|
||||
//MainWindowViewModel.dt_TP.BeginLoadData();
|
||||
//MainWindowViewModel.dt_TP.Clear();
|
||||
//MainWindowViewModel.dt_TP.EndLoadData();
|
||||
}
|
||||
}
|
||||
|
||||
private void Grid_SelectionChanged(object sender, SelectionChangedEventArgs e)
|
||||
|
||||
Reference in new issue
Block a user