н¨Îļþ¼Ð/WIDESEA_WMSServer/ClassLibrary2/InventoryInfoService.cs
@@ -21,6 +21,7 @@
        public InventoryInfoService(IRepository<Dt_InventoryInfo> BaseDal) : base(BaseDal)
        {
        }
        public IRepository<Dt_InventoryInfo> Repository => BaseDal;
        /// <summary>
        /// wcs回传给我调用我的方法
@@ -60,7 +61,7 @@
                        entity = new Dt_InventoryInfo
                        {
                            PalletCode = detail.orderDetails?.FirstOrDefault()?.palletCode ?? "",
                            WarehouseId = 001,  // é»˜è®¤åº“房编号,可根据业务改
                            WarehouseCode = 001.ToString(),  // é»˜è®¤åº“房编号,可根据业务改
                            LocationCode = "", // æš‚无可空
                            StockStatus = 1,   // ç«‹åº“固定为 1
                            MaterielCode = detail.productCode ?? detail.productName,
@@ -82,14 +83,14 @@
                    switch (request.orderType)
                    {
                        case "1": // å…¥åº“
                            entity.StockQuantity += (float)orderQty;
                            entity.StockQuantity += orderQty;
                            entity.InDate = DateTime.Now;
                            entity.Remark = "入库单回传";
                            break;
                        case "2": // å‡ºåº“
                            entity.OutboundQuantity += (float)orderQty;
                            entity.StockQuantity -= (float)orderQty;
                            entity.OutboundQuantity += orderQty;
                            entity.StockQuantity -= orderQty;
                            if (entity.StockQuantity < 0) entity.StockQuantity = 0;
                            entity.Remark = "出库单回传";
                            break;
@@ -102,11 +103,11 @@
                                    decimal diff = Convert.ToDecimal(stock.differenceQuantity);
                                    if (stock.IsProfit == "1") // ç›˜ç›ˆ
                                    {
                                        entity.SupplyQuantity += (float)Math.Abs(diff);
                                        entity.SupplyQuantity += Math.Abs(diff);
                                    }
                                    else // ç›˜äº
                                    {
                                        entity.SupplyQuantity -= (float)Math.Abs(diff);
                                        entity.SupplyQuantity -= Math.Abs(diff);
                                        if (entity.SupplyQuantity < 0) entity.SupplyQuantity = 0;
                                    }
                                    entity.PalletCode = stock.palletCode;