From edc1a959cdcb80343e1dfb0abe335eb37c6304b8 Mon Sep 17 00:00:00 2001 From: Administrator <Administrator@DESKTOP-5BIMHQ3> Date: 星期一, 11 三月 2024 13:49:42 +0800 Subject: [PATCH] agv转运功能修改 --- Wms/WMS.BLL/BllPdaServer/PdaCrServer.cs | 26 ++++++++++++++++---------- 1 files changed, 16 insertions(+), 10 deletions(-) diff --git a/Wms/WMS.BLL/BllPdaServer/PdaCrServer.cs b/Wms/WMS.BLL/BllPdaServer/PdaCrServer.cs index 958d468..7af1516 100644 --- a/Wms/WMS.BLL/BllPdaServer/PdaCrServer.cs +++ b/Wms/WMS.BLL/BllPdaServer/PdaCrServer.cs @@ -885,18 +885,24 @@ if (!string.IsNullOrEmpty(areaNo) && !string.IsNullOrEmpty(ruku)) { throw new Exception("鐩爣鍖哄煙鍜屽叆搴撳彛涓嶈兘鍚屾椂閫夋嫨锛�"); - } - string EndLocat = string.Empty;//鐩爣浣嶇疆 - if (!string.IsNullOrEmpty(areaNo)) - { - EndLocat = areaNo; - } - else - { - EndLocat = ruku; - } + } try { + string EndLocat = string.Empty;//鐩爣浣嶇疆 + if (!string.IsNullOrEmpty(areaNo)) + { + var storageArea = Db.Queryable<SysStorageArea>().First(w => w.IsDel == "0" && w.AreaNo == areaNo); + if (storageArea == null) + { + throw new Exception("鎵�閫夊尯鍩熶俊鎭笉瀛樺湪,璇锋鏌�!"); + } + EndLocat = Db.Queryable<SysStorageLocat>().Where(w => w.IsDel == "0" && w.AreaNo == storageArea.AreaNo && w.Status == "0" && w.Flag == "0").Select(s => s.LocatNo).First(); + } + else + { + EndLocat = ruku; + } + var stockDetail = Db.Queryable<DataStockDetail>().First(w => w.IsDel == "0" && w.PalletNo == palletNo); if (stockDetail == null) { -- Gitblit v1.8.0