diff --git a/Admin.Core.sln b/Admin.Core.sln
index bbd02f6e..ddfa7af9 100644
--- a/Admin.Core.sln
+++ b/Admin.Core.sln
@@ -224,6 +224,7 @@ Global
HideSolutionNode = FALSE
EndGlobalSection
GlobalSection(NestedProjects) = preSolution
+ {CB159E16-8DA0-4125-B42F-BB5381AEDD4D} = {01AE8F7E-F6CB-4B8F-9B04-F9205E2CA3DB}
{14F9C421-C016-4D1F-A0D7-9C1AAB989FCB} = {36DDDB80-7DE0-4A50-991D-24456D673E75}
{33802553-78BF-4D8C-8925-9F7E4E7B6E9B} = {36DDDB80-7DE0-4A50-991D-24456D673E75}
{3A639D2E-F8E1-4E71-B75F-BCE7D02B0FA6} = {36DDDB80-7DE0-4A50-991D-24456D673E75}
diff --git a/Aucma.Core.Palletiz/Business/InstoreBusiness.cs b/Aucma.Core.Palletiz/Business/InstoreBusiness.cs
index 262068a9..1e8df4a1 100644
--- a/Aucma.Core.Palletiz/Business/InstoreBusiness.cs
+++ b/Aucma.Core.Palletiz/Business/InstoreBusiness.cs
@@ -26,7 +26,7 @@ namespace Aucma.Core.Palletiz.Business
{
internal class InStoreBusiness
{
- private static readonly log4net.ILog _logger = LogManager.GetLogger(typeof(InStoreBusiness));
+ private static readonly log4net.ILog log = LogManager.GetLogger(typeof(InStoreBusiness));
private readonly IProductOffLineServices _offlineService;
@@ -118,7 +118,7 @@ namespace Aucma.Core.Palletiz.Business
}
catch (Exception e)
{
- _logger.Error($"Buffer缓冲异常:{e.Message}");
+ log.Error($"Buffer缓冲异常:{e.Message}");
}
}
@@ -154,9 +154,14 @@ namespace Aucma.Core.Palletiz.Business
RefreshProductInfoEvent?.Invoke(asciiStr,prodInfo.ProductModel,prodInfo.ProductOrderNo);
- GetSpaceInfoByMaterialType(spaceArea, prodInfo, out BaseSpaceInfo laseSpaceinfo,
+ bool getSpaceResult = GetSpaceInfoByMaterialType(spaceArea, prodInfo, out BaseSpaceInfo laseSpaceinfo,
out BaseSpaceInfo spaceinfo);
-
+ if(!getSpaceResult)
+ {
+ msg = $"未找到货道,请检查该型号是否有货道";
+ RefreshMsgEvent?.Invoke(msg);
+ return;
+ }
bool result = false;
@@ -266,8 +271,9 @@ namespace Aucma.Core.Palletiz.Business
///
///
///
- private void GetSpaceInfoByMaterialType(string spaceArea, ProductOffline prodInfo, out BaseSpaceInfo laseSpaceinfo, out BaseSpaceInfo spaceinfo, bool isBig = false)
+ private bool GetSpaceInfoByMaterialType(string spaceArea, ProductOffline prodInfo, out BaseSpaceInfo laseSpaceinfo, out BaseSpaceInfo spaceinfo, bool isBig = false)
{
+ bool result = false;
List spaceinfos = null;
if (isBig)
{
@@ -282,7 +288,10 @@ namespace Aucma.Core.Palletiz.Business
if (spaceinfos == null || spaceinfos.Count==0)
{
- throw new ArgumentException($"通过物料型号获取货道信息异常:根据成品信息获取货道信息为空");
+ log.Info($"通过物料型号获取货道信息异常:根据成品信息获取货道信息为空");
+ laseSpaceinfo = null;
+ spaceinfo = null;
+ return false;
}
spaceinfos = spaceinfos.OrderBy(x => x.ObjId).ToList();
@@ -291,15 +300,22 @@ namespace Aucma.Core.Palletiz.Business
if (spaceinfos == null || spaceinfos.Count==0)
{
- throw new ArgumentException($"通过物料型号获取货道信息异常:通过PLC匹配可用货道信息为空");
+ log.Info($"通过物料型号获取货道信息异常:根据成品信息获取货道信息为空");
+ laseSpaceinfo = null;
+ spaceinfo = null;
+ return false;
}
FiltrateSpaceInfo(spaceinfos, out laseSpaceinfo, out spaceinfo);
if (spaceinfo == null || spaceinfos.Count==0)
{
- throw new ArgumentException($"通过物料型号获取货道信息异常:未获取到匹配的货道信息");
+ log.Info($"通过物料型号获取货道信息异常:根据成品信息获取货道信息为空");
+ laseSpaceinfo = null;
+ spaceinfo = null;
+ return false;
}
+ return true;
}
@@ -512,7 +528,7 @@ namespace Aucma.Core.Palletiz.Business
///
private void NoReadHandle(string client)
{
- _logger.Error($"客户端:{client};读取失败!!!!!!");
+ log.Error($"客户端:{client};读取失败!!!!!!");
}
///
diff --git a/Aucma.Core.ProductOffLine/Views/IndexPageView.xaml b/Aucma.Core.ProductOffLine/Views/IndexPageView.xaml
index 6d1392cd..0612a3af 100644
--- a/Aucma.Core.ProductOffLine/Views/IndexPageView.xaml
+++ b/Aucma.Core.ProductOffLine/Views/IndexPageView.xaml
@@ -256,7 +256,7 @@
-
+
@@ -288,7 +288,7 @@
-
+