diff --git a/SlnMesnac.Business/ProdMgmtBusiness.cs b/SlnMesnac.Business/ProdMgmtBusiness.cs index 537f9ca..ea4e0c3 100644 --- a/SlnMesnac.Business/ProdMgmtBusiness.cs +++ b/SlnMesnac.Business/ProdMgmtBusiness.cs @@ -242,7 +242,13 @@ namespace SlnMesnac.Business //查询下发agv的主键 WmsRawOutstock wmsRaw = _wmsOutStockService.GetProdPlanByPlanCode(prodPlan.PlanCode); + if (wmsRaw == null) + { + RefreshMessage("查询不到该计划......"); + Thread.Sleep(5000); + continue; + } //进行叫料 if (ApplyDeliveryHandle(wmsRaw.rawOutstockId.ToString())) diff --git a/SlnMesnac.WPF/Converter/AgvAndTask/AgvNameConverter.cs b/SlnMesnac.WPF/Converter/AgvAndTask/AgvNameConverter.cs index c6b8ee2..e80844e 100644 --- a/SlnMesnac.WPF/Converter/AgvAndTask/AgvNameConverter.cs +++ b/SlnMesnac.WPF/Converter/AgvAndTask/AgvNameConverter.cs @@ -16,8 +16,8 @@ namespace SlnMesnac.WPF.Converter.AgvAndTask { return nextPointId switch { - 8 => "3楼叉车", - 9 => "2楼叉车", + 8 => "2楼叉车", + 9 => "3楼叉车", _ => "未知AGV", }; } diff --git a/SlnMesnac.WPF/Page/DevMonitorPage.xaml.cs b/SlnMesnac.WPF/Page/DevMonitorPage.xaml.cs index 0bfccb7..f1ddf4a 100644 --- a/SlnMesnac.WPF/Page/DevMonitorPage.xaml.cs +++ b/SlnMesnac.WPF/Page/DevMonitorPage.xaml.cs @@ -851,6 +851,8 @@ namespace SlnMesnac.WPF.Page /// private void StopButton_Click(object sender, RoutedEventArgs e) { + + var result = MessageBox.Show("是否确认停止?", "确认", MessageBoxButton.YesNo, MessageBoxImage.Warning); if (result == MessageBoxResult.Yes) { @@ -873,6 +875,11 @@ namespace SlnMesnac.WPF.Page MessageBoxAndLog("一键停止所有机器成功!"); + //清空投料系统运行时间 + BaseConfigInfo configInfo = _configInfoBusiness.GetConfigInfos().Where(x => x.ConfigKey == "系统运行时长").FirstOrDefault(); + configInfo.ConfigValue = "0"; + _configInfoBusiness.UpdateConfigInfo(configInfo); + App.Current.Dispatcher.BeginInvoke((Action)(() => { StopButton.IsEnabled = true;