服务端的TigerApi 框架,基于.NET6 2024 版本
Rodney Chen
2025-04-02 eb29ee75c7f2f4154b7a3d0c475f94e0b964e996
Tiger.Business.WMS/iWMS/iWMS.Minsun.cs
@@ -983,7 +983,7 @@
                                BILLLINE = Convert.ToInt32(item.sfdcseq),
                                UNITCODE = item.sfdc006,
                                MATERIALCODE = item.sfdc004,
                                PRQTY = Convert.ToDecimal(item.sfdc007),
                                PRQTY = Convert.ToDouble(item.sfdc007),
                                DELIVERYDATE = Convert.ToDateTime(item.sfdareqdt),
                                WAREHOUSECODE = item.sfdc012,
                                SOURCETYPE = Convert.ToInt32(item.sfdc003),
@@ -1016,7 +1016,7 @@
                            prd_d = prd_d ?? new WMS_PRDPICK_D()
                            {
                                LINESTATUS = "INIT",
                                QTY = Convert.ToDecimal(0),
                                QTY = Convert.ToDouble(0),
                                CreationTime = DateTime.Now,
                                CreatorUserId = 1,
                            };
@@ -1024,7 +1024,7 @@
                            prd_d.BILLLINE = item_d.BILLLINE;
                            prd_d.UNITCODE = item_d.UNITCODE;
                            prd_d.MATERIALCODE = item_d.MATERIALCODE;
                            prd_d.PRQTY = Convert.ToDecimal(item_d.PRQTY);
                            prd_d.PRQTY = Convert.ToDouble(item_d.PRQTY);
                            prd_d.DELIVERYDATE = Convert.ToDateTime(item_d.DELIVERYDATE);
                            prd_d.WAREHOUSECODE = item_d.WAREHOUSECODE;
                            prd_d.LINESTATUS = prd_d.PRQTY == prd_d.QTY ? "COMPLETE" : Convert.ToDecimal(item_d.PRQTY) == 0 ? "COMPLETE" : prd_d.LINESTATUS == "DELETE" ? "INIT" : prd_d.LINESTATUS;
@@ -1175,7 +1175,7 @@
            // 判断标签数量是否合法
            if (!decimal.TryParse(nLotQty, out decimal nBarcodeQty))
            if (!double.TryParse(nLotQty, out double nBarcodeQty))
            {
                result.Flag = Result.Flags.Failed;
                result.Message = $"条码格式错误:未取到正确的条码数量";
@@ -1310,7 +1310,7 @@
            bool isBox = false;
            var nLotNo = "";
            List<Tuple<string, decimal>> snList = new List<Tuple<string, decimal>>();
            List<Tuple<string, double>> snList = new List<Tuple<string, double>>();
            foreach (string item in nSplitArray)
@@ -1367,11 +1367,11 @@
            if (nInputSnDto.Any())
            {
                isBox = true;
                snList = nInputSnDto.Select(t => new Tuple<string, decimal>(t.SmallBarcode, t.IncludeQty)).ToList();
                snList = nInputSnDto.Select(t => new Tuple<string, double>(t.SmallBarcode, t.IncludeQty)).ToList();
            }
            if (!decimal.TryParse(nLotQty, out decimal nBarcodeQty))
            if (!double.TryParse(nLotQty, out double nBarcodeQty))
            {
                //throw new UserFriendlyException("条码格式错误:未取到正确的条码数量");
                result.Flag = Result.Flags.Failed;
@@ -1494,7 +1494,7 @@
            var nLotNo = "";
            // 最小包装条码列表
            List<Tuple<string, decimal>> snList = new List<Tuple<string, decimal>>();
            List<Tuple<string, double>> snList = new List<Tuple<string, double>>();
            // 送货单行明细
            List<InputAsnLineDto> asnLineList = new List<InputAsnLineDto>();
            // 最小包装条码明细
@@ -1559,7 +1559,7 @@
            if (snBarcodeList.Any())
            {
                snList = snBarcodeList.Select(t => new Tuple<string, decimal>(t.SmallBarcode, t.IncludeQty)).ToList();
                snList = snBarcodeList.Select(t => new Tuple<string, double>(t.SmallBarcode, t.IncludeQty)).ToList();
                snBarcodeList = snBarcodeList.Select(t => new WMS_SRMSNList
                {
                    BILLCODE = t.BILLCODE,
@@ -1600,7 +1600,7 @@
            }
            // 验证条码标签数量格式是否正确
            if (!decimal.TryParse(nLotQty, out decimal nBarcodeQty))
            if (!double.TryParse(nLotQty, out double nBarcodeQty))
            {
                //throw new UserFriendlyException("条码格式错误:未取到正确的条码数量");
                result.Flag = Result.Flags.Failed;
@@ -1609,7 +1609,7 @@
            }
            // 验证条码标签数量与SRM 最小包装数量合计是否一致
            decimal snQtyTotal = snBarcodeList.Sum(t => t.IncludeQty);
            double snQtyTotal = snBarcodeList.Sum(t => t.IncludeQty);
            if (nBarcodeQty != snQtyTotal)
            {
                //throw new UserFriendlyException("标签数量与SRM最小包装总数量不一致");