diff --git a/Properties/Resources.Designer.cs b/Properties/Resources.Designer.cs index b46b95e..614431c 100644 --- a/Properties/Resources.Designer.cs +++ b/Properties/Resources.Designer.cs @@ -879,6 +879,15 @@ namespace DyeingComputer.Properties { } } + /// + /// 查找类似 Process lock-in 的本地化字符串。 + /// + public static string Process_lock { + get { + return ResourceManager.GetString("Process_lock", resourceCulture); + } + } + /// /// 查找类似 The process does not exist 的本地化字符串。 /// @@ -1050,6 +1059,15 @@ namespace DyeingComputer.Properties { } } + /// + /// 查找类似 Refuse 的本地化字符串。 + /// + public static string refuse { + get { + return ResourceManager.GetString("refuse", resourceCulture); + } + } + /// /// 查找类似 Remark 的本地化字符串。 /// diff --git a/Properties/Resources.en-US.resx b/Properties/Resources.en-US.resx index 5273536..faf4966 100644 --- a/Properties/Resources.en-US.resx +++ b/Properties/Resources.en-US.resx @@ -537,4 +537,10 @@ Fault + + Process lock-in + + + Refuse + \ No newline at end of file diff --git a/Properties/Resources.resx b/Properties/Resources.resx index f9f4769..d57f7ff 100644 --- a/Properties/Resources.resx +++ b/Properties/Resources.resx @@ -537,4 +537,10 @@ Fault + + Process lock-in + + + Refuse + \ No newline at end of file diff --git a/Properties/Resources.zh-CN.resx b/Properties/Resources.zh-CN.resx index 6c272fa..2696785 100644 --- a/Properties/Resources.zh-CN.resx +++ b/Properties/Resources.zh-CN.resx @@ -537,4 +537,10 @@ 故障 + + 工艺已锁定 + + + 拒绝 + \ No newline at end of file diff --git a/Properties/Resources.zh-TW.resx b/Properties/Resources.zh-TW.resx index 02852e2..a54619a 100644 --- a/Properties/Resources.zh-TW.resx +++ b/Properties/Resources.zh-TW.resx @@ -537,4 +537,10 @@ 故障 + + + + + + \ No newline at end of file diff --git a/View/WorkOrderView.xaml.cs b/View/WorkOrderView.xaml.cs index a7846a9..9064f84 100644 --- a/View/WorkOrderView.xaml.cs +++ b/View/WorkOrderView.xaml.cs @@ -235,11 +235,17 @@ namespace DyeingComputer.View private void start_Click(object sender, RoutedEventArgs e)//开始 { + if (string.IsNullOrEmpty(WorkOrder_Numder)) return; + if (_lock == "1") + { + MessageBoxResult messageBox = System.Windows.MessageBox.Show(Properties.Resources.Process_lock, "800", MessageBoxButton.OK); + return; + } + DataTable WorkorderSteps = new DataTable(); DataTable data_t = new DataTable(); int a; - if (string.IsNullOrEmpty(WorkOrder_Numder)) return; SQLiteHelpers = new SQLiteHelper(DBAddress); //数据库连接路径 SQLiteHelpers.Open(); //打开数据库 @@ -247,10 +253,17 @@ namespace DyeingComputer.View if (R_D > 0) { SQLiteHelpers.Close(); //关闭连接 + MessageBoxResult messageBoxResult = System.Windows.MessageBox.Show(Properties.Resources.RunningProcess, "800", MessageBoxButton.YesNo); if (messageBoxResult == MessageBoxResult.No) return; if (messageBoxResult == MessageBoxResult.Yes) { + if(MainWindowViewModel.S17 == 1) //拒绝操作 + { + System.Windows.MessageBox.Show(Properties.Resources.refuse, "800", MessageBoxButton.OK); + return; + } + SQLiteHelpers = new SQLiteHelper(DBAddress); //数据库连接路径 SQLiteHelpers.Open(); //打开数据库 } @@ -323,8 +336,6 @@ namespace DyeingComputer.View Picture.Content = dataGrid; } - - private void TEMP() { //处理计划温度图表 @@ -404,7 +415,6 @@ namespace DyeingComputer.View } Picture.Content = new View.CurveTemp(TEMPTable); } //计划温度图表 - - + } } diff --git a/ViewModel/MainWindowViewModel.cs b/ViewModel/MainWindowViewModel.cs index 40d34e8..d8322e3 100644 --- a/ViewModel/MainWindowViewModel.cs +++ b/ViewModel/MainWindowViewModel.cs @@ -142,13 +142,15 @@ namespace DyeingComputer.ViewModel public static string S03;//设备组 public static string S05;//管控模式 public static string S06;//通讯编码 - public static int S16;//机型 + public static int S16;//风机联动 + public static int S17;// public static int SM01;//副缸 public static int SM02;//副缸 public static int SM03;//副缸 - public int MI01;// - public int MI02;// - public int MI03;// + public int MI01;//布轮信息 + public int MI02;//喷射流量信息 + public int MI03;//动态压力 + public int MI04;//能耗信息 private double MS01;//1缸温度偏差 private double MS02;//2缸温度偏差 @@ -201,6 +203,7 @@ namespace DyeingComputer.ViewModel MI02 = Convert.ToInt16(Selet_sys("MI02"));//工作信息 MI03 = Convert.ToInt16(Selet_sys("MI03"));//工作信息 S16 = Convert.ToInt16(Selet_sys("S16"));//工作信息 + S17 = Convert.ToInt16(Selet_sys("S17"));// SM01 = Convert.ToInt16(Selet_sys("SM01"));//FG SM02 = Convert.ToInt16(Selet_sys("SM02"));//FG