From 30470e6a44e05993bd1c63610af4fec3f0fda960 Mon Sep 17 00:00:00 2001
From: yangpeixing <yangpeixing@hnkhzn.com>
Date: 星期一, 27 四月 2026 14:35:46 +0800
Subject: [PATCH] 1
---
WMS/WIDESEA_WMSServer/WIDESEA_TaskInfoService/PartialTaskService_Inbound.cs | 20 ++++++++++++++++++++
1 files changed, 20 insertions(+), 0 deletions(-)
diff --git a/WMS/WIDESEA_WMSServer/WIDESEA_TaskInfoService/PartialTaskService_Inbound.cs b/WMS/WIDESEA_WMSServer/WIDESEA_TaskInfoService/PartialTaskService_Inbound.cs
index 85139cd..aa230b4 100644
--- a/WMS/WIDESEA_WMSServer/WIDESEA_TaskInfoService/PartialTaskService_Inbound.cs
+++ b/WMS/WIDESEA_WMSServer/WIDESEA_TaskInfoService/PartialTaskService_Inbound.cs
@@ -1,4 +1,5 @@
锘縰sing MailKit.Search;
+using Microsoft.AspNetCore.SignalR;
using Microsoft.Extensions.Logging;
using System;
using System.Collections.Generic;
@@ -235,12 +236,15 @@
Dt_Task task = Repository.QueryFirst(x => x.PalletCode == palletCode);
if (task != null)
{
+ _hubContext.Clients.All.SendAsync("ReceiveMessage", $"璇ユ墭鐩榹palletCode}宸茬敓鎴愪换鍔�");
return WebResponseContent.Instance.Error($"璇ユ墭鐩榹palletCode}宸茬敓鎴愪换鍔�");
}
Dt_StockInfo stockInfo = _stockRepository.StockInfoRepository.Db.Queryable<Dt_StockInfo>().Where(x => x.PalletCode == palletCode).Includes(x => x.Details).First();
if (stockInfo == null)
{
+ _hubContext.Clients.All.SendAsync("ReceiveMessage", $"鏈壘鍒扮粍鐩樹俊鎭�");
+
return WebResponseContent.Instance.Error($"鏈壘鍒扮粍鐩樹俊鎭�");
}
@@ -250,6 +254,8 @@
Dt_LocationInfo locationInfo1 = _locationInfoService.Repository.QueryFirst(x => x.LocationCode == stockInfo.LocationCode);
if (locationInfo1 == null)
{
+ _hubContext.Clients.All.SendAsync("ReceiveMessage", $"鍥炲簱鍗曚腑璇ュ簱浣峽stockInfo.LocationCode}鏈壘鍒�");
+
return WebResponseContent.Instance.Error($"鍥炲簱鍗曚腑璇ュ簱浣峽stockInfo.LocationCode}鏈壘鍒�");
}
returnRoadwayInfo = _basicRepository.RoadwayInfoRepository.QueryFirst(x => x.RoadwayNo == locationInfo1.RoadwayNo && x.InStationCode == (returnRoadwayInfo.InStationCode != null ? returnRoadwayInfo.InStationCode : stationCode));
@@ -262,6 +268,8 @@
Dt_LocationInfo locationInfo1 = _locationInfoService.Repository.QueryFirst(x => x.LocationCode == returnOrder.LocationCode);
if (locationInfo1 == null)
{
+ _hubContext.Clients.All.SendAsync("ReceiveMessage", $"鍥炲簱鍗曚腑璇ュ簱浣峽returnOrder.LocationCode}鏈壘鍒�");
+
return WebResponseContent.Instance.Error($"鍥炲簱鍗曚腑璇ュ簱浣峽returnOrder.LocationCode}鏈壘鍒�");
}
returnRoadwayInfo = _basicRepository.RoadwayInfoRepository.QueryFirst(x => x.RoadwayNo == locationInfo1.RoadwayNo && x.InStationCode == (returnRoadwayInfo.InStationCode != null ? returnRoadwayInfo.InStationCode : stationCode));
@@ -269,23 +277,31 @@
if (Repository.QueryFirst(x => x.SourceAddress == (returnRoadwayInfo.InStationCode != null ? returnRoadwayInfo.InStationCode : stationCode) && x.TaskStatus == TaskStatusEnum.New.ObjToInt()) != null)
{
+ _hubContext.Clients.All.SendAsync("ReceiveMessage", $"璇ョ珯鐐瑰凡鏈夋湭鎵ц鐨勪换鍔�");
+
return WebResponseContent.Instance.Error($"璇ョ珯鐐瑰凡鏈夋湭鎵ц鐨勪换鍔�");
}
var details = stockInfo.Details.FirstOrDefault();
if (!string.IsNullOrEmpty(stockInfo.LocationCode))
{
+ _hubContext.Clients.All.SendAsync("ReceiveMessage", $"璇ユ墭鐩樺凡缁戝畾璐т綅");
+
return WebResponseContent.Instance.Error($"璇ユ墭鐩樺凡缁戝畾璐т綅");
}
Dt_RoadwayInfo roadwayInfo = _basicRepository.RoadwayInfoRepository.QueryFirst(x => x.InStationCode == (returnRoadwayInfo.InStationCode != null ? returnRoadwayInfo.InStationCode : stationCode));
if (roadwayInfo == null)
{
+ _hubContext.Clients.All.SendAsync("ReceiveMessage", $"鏈壘鍒拌鍏ュ簱绔欏彴鍦板潃");
+
return WebResponseContent.Instance.Error($"鏈壘鍒拌鍏ュ簱绔欏彴鍦板潃");
}
Dt_Warehouse warehouse = _basicRepository.WarehouseRepository.QueryFirst(x => x.WarehouseCode == roadwayInfo.RoadwayNo);
if (warehouse == null)
{
+ _hubContext.Clients.All.SendAsync("ReceiveMessage", $"鏈壘鍒拌浠撳簱");
+
return WebResponseContent.Instance.Error("鏈壘鍒拌浠撳簱");
}
@@ -295,6 +311,8 @@
locationInfo = _locationInfoService.Repository.QueryFirst(x => x.LocationCode == returnOrder.LocationCode);
if (locationInfo.LocationStatus != LocationStatusEnum.Lock.ObjToInt() || locationInfo.EnableStatus == EnableStatusEnum.Disable.ObjToInt() || locationInfo.EnableStatus == EnableStatusEnum.OnlyOut.ObjToInt())
{
+ _hubContext.Clients.All.SendAsync("ReceiveMessage", $"璇ュ洖搴撳崟璐т綅{locationInfo.LocationCode}闈為攣瀹氱姸鎬佹垨璐т綅鍚敤鐘舵�佷笉姝g‘锛岃妫�鏌�");
+
return WebResponseContent.Instance.Error($"璇ュ洖搴撳崟璐т綅{locationInfo.LocationCode}闈為攣瀹氱姸鎬佹垨璐т綅鍚敤鐘舵�佷笉姝g‘锛岃妫�鏌�");
}
}
@@ -303,6 +321,8 @@
locationInfo = _basicService.LocationInfoService.AssignLocation(roadwayInfo.RoadwayNo, stockInfo.PalletType, warehouse.WarehouseId, "", heightType);//, stockInfo.WarehouseId
if (locationInfo == null)
{
+ _hubContext.Clients.All.SendAsync("ReceiveMessage", $"璐т綅鍒嗛厤澶辫触,鏈壘鍒板彲鍒嗛厤璐т綅");
+
return WebResponseContent.Instance.Error($"璐т綅鍒嗛厤澶辫触,鏈壘鍒板彲鍒嗛厤璐т綅");
}
}
--
Gitblit v1.9.3