diff --git a/Aucma.Scada.Business/InStoreBusiness.cs b/Aucma.Scada.Business/InStoreBusiness.cs index f1a39034..f31bef0a 100644 --- a/Aucma.Scada.Business/InStoreBusiness.cs +++ b/Aucma.Scada.Business/InStoreBusiness.cs @@ -258,6 +258,8 @@ namespace Aucma.Scada.Business { string str = storeCode == appConfig.shellStoreCode ? "箱壳异常入库" : "内胆异常入库"; PrintLogInfoMessage(str + "; 未获取到可用的异常货道"); + CreateInStoreTask(spaceList.First(), null); + PrintLogInfoMessage(str + "; 创建异常任务暂存等待异常道进入"); } } else diff --git a/Aucma.Scada.Business/InStoreTaskHandle.cs b/Aucma.Scada.Business/InStoreTaskHandle.cs index d4a76b85..275a6036 100644 --- a/Aucma.Scada.Business/InStoreTaskHandle.cs +++ b/Aucma.Scada.Business/InStoreTaskHandle.cs @@ -157,29 +157,36 @@ namespace Aucma.Scada.Business _spaceInfoService.UpdateSpaceInfo(spaceInfo); RefreshShellStockEvent?.Invoke(); RefreshLinerStockEvent?.Invoke(); + } - if ((spaceInfo.spaceCapacity - spaceInfo.spaceStock) <= 5) + if ((spaceInfo.spaceCapacity - spaceInfo.spaceStock) <= 5) + { + if (spaceInfo.storeCode == appConfig.shellStoreCode) + { + ShellAlarmSpaceName.Add(spaceInfo.spaceName); + } + else { - if (spaceInfo.storeCode == appConfig.shellStoreCode) - { - ShellAlarmSpaceName.Add(spaceInfo.spaceName); - } - else - { - LinerAlarmSpaceName.Add(spaceInfo.spaceName); - } + LinerAlarmSpaceName.Add(spaceInfo.spaceName); } } } + string str = string.Empty; if (ShellAlarmSpaceName.Count > 0) { - SpaceCapacityAlarmEvent?.Invoke(appConfig.shellStoreCode, jsonChange.ModeToJson(ShellAlarmSpaceName)); + str += $"箱壳库货道:{jsonChange.ModeToJson(ShellAlarmSpaceName)};"; } if (LinerAlarmSpaceName.Count > 0) { - SpaceCapacityAlarmEvent?.Invoke(appConfig.linerStoreCode, jsonChange.ModeToJson(LinerAlarmSpaceName)); + str += $"内胆库货道:{jsonChange.ModeToJson(LinerAlarmSpaceName)};"; + } + + if (!string.IsNullOrEmpty(str)) + { + + SpaceCapacityAlarmEvent?.Invoke(appConfig.shellStoreCode, str); } } diff --git a/Aucma.Scada.Business/bin/Debug/Aucma.Scada.Business.dll b/Aucma.Scada.Business/bin/Debug/Aucma.Scada.Business.dll index d7b79d30..66a1b97b 100644 Binary files a/Aucma.Scada.Business/bin/Debug/Aucma.Scada.Business.dll and b/Aucma.Scada.Business/bin/Debug/Aucma.Scada.Business.dll differ diff --git a/Aucma.Scada.Business/bin/Debug/Aucma.Scada.Business.pdb b/Aucma.Scada.Business/bin/Debug/Aucma.Scada.Business.pdb index 9e576b18..e990fdd4 100644 Binary files a/Aucma.Scada.Business/bin/Debug/Aucma.Scada.Business.pdb and b/Aucma.Scada.Business/bin/Debug/Aucma.Scada.Business.pdb differ diff --git a/Aucma.Scada.UI/Page/InStoreInfo/InStoreInfoControl.xaml b/Aucma.Scada.UI/Page/InStoreInfo/InStoreInfoControl.xaml index e5e35722..407a0deb 100644 --- a/Aucma.Scada.UI/Page/InStoreInfo/InStoreInfoControl.xaml +++ b/Aucma.Scada.UI/Page/InStoreInfo/InStoreInfoControl.xaml @@ -107,9 +107,8 @@ - - + @@ -136,7 +135,7 @@ - + @@ -163,6 +162,21 @@ + + + + + + + + + + + + + + + @@ -236,8 +250,7 @@