From e8dff3d9ad3f39088886173da44fff6cc1ae3e13 Mon Sep 17 00:00:00 2001 From: DESKTOP-9BNTV8O <DESKTOP-9BNTV8O@163.com> Date: 星期六, 14 十二月 2024 17:13:50 +0800 Subject: [PATCH] 修改问题 --- Wms/WMS.BLL/BllTransServer/RcsServer.cs | 18 ++++++++++++++++-- 1 files changed, 16 insertions(+), 2 deletions(-) diff --git a/Wms/WMS.BLL/BllTransServer/RcsServer.cs b/Wms/WMS.BLL/BllTransServer/RcsServer.cs index 9c651a2..0f0c2f1 100644 --- a/Wms/WMS.BLL/BllTransServer/RcsServer.cs +++ b/Wms/WMS.BLL/BllTransServer/RcsServer.cs @@ -7,6 +7,7 @@ using System.Linq; using System.Security.Policy; using System.Text; +using System.Threading.Tasks; using Utility.Tools; using WMS.DAL; using WMS.Entity.BllAsnEntity; @@ -87,7 +88,6 @@ throw new Exception("鏆傛棤娣锋枡妗跺彲鍒嗛厤"); } pallet.Status = "2";//鍒嗛厤鐘舵�� 0:寰呭垎閰嶏紝1锛氶儴鍒嗗垎閰� 锛� 2:宸插垎閰� - pallet.LotNo = model.LotNo;//鎵规鍙� //鏇存柊妗跺簱瀛樻槑缁� Db.Updateable(pallet).ExecuteCommand(); @@ -348,6 +348,12 @@ } var houseNo = deviceLocatInfo.WareHouseNo;//鐢宠鍌ㄤ綅璁惧鎵�鍦ㄨ溅闂寸紪鍙� var noticeno = "0";//鍑哄叆搴撳崟鎹槑缁咺D + //妗跺簱瀛樹俊鎭� + var palletInfo = Db.Queryable<DataStockDetail>().First(w => w.IsDel == "0" && w.PalletNo == model.PalletNo); + if (palletInfo == null) + { + throw new Exception($"鏈煡璇㈠埌璇ユ《鐨勫簱瀛樹俊鎭紝PalletNo:{model.PalletNo}"); + } var storageLocat = Db.Queryable<SysStorageLocat>().Where(w => w.IsDel == "0" && w.Status == "0"); //寮�鍚簨鍔� @@ -380,6 +386,9 @@ { throw new Exception("璇ヨ溅闂撮娣峰尯鏆傛棤绌轰綑鍌ㄤ綅"); } + palletInfo.LotNo = model.LotNo;//鎵规鍙� + //鏇存柊妗跺簱瀛樹俊鎭� + Db.Updateable(palletInfo).ExecuteCommand(); taskMsg = "鎺ユ枡璁惧锛堥娣锋枡妗讹級鐢宠鍌ㄤ綅浠诲姟"; break; @@ -440,7 +449,7 @@ SendDate = DateTime.Now, //鍙戦�佹椂闂� //BackDate = DateTime.Now, //杩斿洖鏃堕棿 StartLocat = model.Location,//璧峰浣嶇疆 - EndLocat = model.Location,//鐩爣浣嶇疆 + EndLocat = loction.LocatNo,//鐩爣浣嶇疆 PalletNo = model.PalletNo,//妗跺彿 IsSend = 1,//鏄惁鍙啀娆′笅鍙� IsCancel = 1,//鏄惁鍙彇娑� @@ -453,6 +462,7 @@ }; var task = new TaskDetial { + Taskno = taskNo,//浠诲姟鍙� Startport = model.Location, Endport = loction.LocatNo, Pallno = model.PalletNo, @@ -825,6 +835,10 @@ #endregion taskInfo.Status = "2";//鎵ц瀹屾垚 + taskInfo.IsSend = 0; + taskInfo.IsCancel = 0; + taskInfo.IsFinish = 0; + taskInfo.FinishDate = DateTime.Now;//瀹屾垚鏃堕棿 //淇敼浠诲姟鐘舵�� Db.Updateable(taskInfo).ExecuteCommand(); -- Gitblit v1.8.0