From bdd84cc48ba7b2527584c44d174da8e7d20c5375 Mon Sep 17 00:00:00 2001 From: zhaowc <526854230@qq.com> Date: 星期三, 18 九月 2024 16:37:13 +0800 Subject: [PATCH] 增加对申请入库时对平库库位的校验 --- Wms/WMS.BLL/SysServer/StorageLocatServer.cs | 24 +++++++++++++++++++++--- 1 files changed, 21 insertions(+), 3 deletions(-) diff --git a/Wms/WMS.BLL/SysServer/StorageLocatServer.cs b/Wms/WMS.BLL/SysServer/StorageLocatServer.cs index d886a35..ec36530 100644 --- a/Wms/WMS.BLL/SysServer/StorageLocatServer.cs +++ b/Wms/WMS.BLL/SysServer/StorageLocatServer.cs @@ -247,12 +247,30 @@ try { var q = 0; + var depth = 0; + var depthString = ""; // 鎺�(缁�)寰幆 for (int i = 1; i <= model.Row; i++) { // 鍒楀惊鐜� for (int z = 1; z <= model.Col; z++) { + if (z == 1) + { + depth += 1; + if (depth >= 10) + { + depthString = depth.ToString(); + } + else if (depth < 10) + { + depthString = "0" + depth.ToString(); + } + else { + //鍏朵綑鏉′欢 + } + } + q += await LocatRst.AddAsync(new SysStorageLocat() { // 鍖哄煙+鎺�+鍒�+灞� @@ -264,7 +282,7 @@ AisleOne = "1", AisleTwo = "", Flag = "0", - Depth = z.ToString(), + Depth = depthString, Row = i, Column = z, Layer = 1, @@ -861,8 +879,8 @@ // "B14", // "B15", //}; - string row1 = "'B01','B02','B03','B04','B05','B06','B07'"; - string row3 = "'B11','B12','B13','B14','B15'"; + string row1 = "'A06'"; + string row3 = "'A08'"; string str = $"select * from SysStorageLocat where IsDel = '0' and WareHouseNo = '{wareHouseNo}' and "; if (row == "1") { -- Gitblit v1.8.0