From 8f997184b1698d7e28625ddd0df6ae09d496823e Mon Sep 17 00:00:00 2001 From: Administrator <Administrator@DESKTOP-5BIMHQ3> Date: 星期日, 23 六月 2024 16:58:59 +0800 Subject: [PATCH] 编写RCS任务完成反馈接口 --- Wms/WMS.BLL/BllTransServer/NoticeServer.cs | 59 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++- 1 files changed, 58 insertions(+), 1 deletions(-) diff --git a/Wms/WMS.BLL/BllTransServer/NoticeServer.cs b/Wms/WMS.BLL/BllTransServer/NoticeServer.cs index c029acf..2a8f453 100644 --- a/Wms/WMS.BLL/BllTransServer/NoticeServer.cs +++ b/Wms/WMS.BLL/BllTransServer/NoticeServer.cs @@ -464,12 +464,69 @@ //淇敼璧峰鍌ㄤ綅鐘舵�� Db.Updateable(startLocatInfo).ExecuteCommand(); - endLocatInfo.Status = "1";//绌哄偍浣� + endLocatInfo.Status = "1";//鏈夌墿鍝� //淇敼鐩爣鍌ㄤ綅鐘舵�� Db.Updateable(endLocatInfo).ExecuteCommand(); break; #endregion + + #region 浠诲姟瀹屾垚 + case "2": + //璧峰鍌ㄤ綅淇℃伅 + var startLocatInfo2 = Db.Queryable<SysStorageLocat>().First(w => w.LocatNo == taskInfo.StartLocat && w.IsDel == "0"); + if (startLocatInfo2 == null) + { + resultModel.Message = "璧峰鍌ㄤ綅淇℃伅涓嶅瓨鍦�!"; + return resultModel; + } + //鐩爣鍌ㄤ綅淇℃伅 + var endLocatInfo2 = Db.Queryable<SysStorageLocat>().First(w => w.LocatNo == taskInfo.EndLocat && w.IsDel == "0"); + if (endLocatInfo2 == null) + { + resultModel.Message = "鐩爣鍌ㄤ綅淇℃伅涓嶅瓨鍦�!"; + return resultModel; + } + //搴撳瓨鏄庣粏 + var sd3 = Db.Queryable<DataStockDetail>().First(w => w.PalletNo == taskInfo.PalletNo); + if (sd3 == null) + { + resultModel.Message = "搴撳瓨淇℃伅涓嶅瓨鍦�!"; + return resultModel; + } + sd3.WareHouseNo = endLocatInfo2.WareHouseNo;//鎵�灞炰粨搴� + sd3.RoadwayNo = endLocatInfo2.RoadwayNo;//鎵�灞炲贩閬� + sd3.AreaNo = endLocatInfo2.AreaNo;//鎵�灞炲尯鍩� + sd3.LocatNo = endLocatInfo2.LocatNo;//鍌ㄤ綅鍦板潃 + if (endLocatInfo2.AreaNo == "A01")//娲佸噣鍖� + { + sd3.PalletStatus = "0"; + } + else if (endLocatInfo2.AreaNo == "A02")//棰勬贩鍖� + { + sd3.PalletStatus = "1"; + } + else if (endLocatInfo2.AreaNo == "A03")//鍗婃垚鍝佸尯 + { + sd3.PalletStatus = "2"; + } + else if (endLocatInfo2.AreaNo == "A04")//鑴忔《鍖� + { + sd3.PalletStatus = "3"; + } + + //淇敼搴撳瓨鏄庣粏 + Db.Updateable(sd3).ExecuteCommand(); + + startLocatInfo2.Status = "0";//绌哄偍浣� + //淇敼璧峰鍌ㄤ綅鐘舵�� + Db.Updateable(startLocatInfo2).ExecuteCommand(); + + endLocatInfo2.Status = "1";//鏈夌墿鍝� + //淇敼鐩爣鍌ㄤ綅鐘舵�� + Db.Updateable(endLocatInfo2).ExecuteCommand(); + break; + #endregion } taskInfo.Status = "2";//鎵ц瀹屾垚 //淇敼浠诲姟鐘舵�� -- Gitblit v1.8.0