wankeda
昨天 734f49c3f74e4a46cfb5892ce60dbf1bb86e74ab
WMS/WIDESEA_WMSServer/WIDESEA_BasicService/Service/AssignLocation/LocationInfoService_BC.cs
@@ -132,14 +132,14 @@
                            Dt_LocationInfo undefinedTypeEmptyLocation = undefinedTypeEmptyLocations[i];
                            Dt_LocationInfo? locationInfo = GetUsableLocation_BC(locationInfos, undefinedTypeEmptyLocation, palletType, palletTypeInfo);
                            //判断货位两深及以上是否存在出库锁定货位
                            if (locationInfo?.Depth == 1)
                            {
                                Dt_LocationInfo? IsBebusyLocation = locationInfos.Where(x => x.Row == (locationInfo?.Row == 2 ? locationInfo?.Row - 1 : locationInfo?.Row + 1) && x.Column == locationInfo?.Column && x.Layer == locationInfo?.Layer).FirstOrDefault();
                                if (IsBebusyLocation != null && (IsBebusyLocation.LocationStatus < LocationStatusEnum.InStock.ObjToInt()))
                                {
                                    continue;
                                }
                            }
                            //if (locationInfo?.Depth == 1)
                            //{
                            //    Dt_LocationInfo? IsBebusyLocation = locationInfos.Where(x => x.Row == (locationInfo?.Row == 2 ? locationInfo?.Row - 1 : locationInfo?.Row + 1) && x.Column == locationInfo?.Column && x.Layer == locationInfo?.Layer).FirstOrDefault();
                            //    if (IsBebusyLocation != null && (IsBebusyLocation.LocationStatus < LocationStatusEnum.InStock.ObjToInt()))
                            //    {
                            //        continue;
                            //    }
                            //}
                            if (locationInfo != null)
                            {
                                //UpdateLocationStatus(locationInfo, palletType, LocationStatusEnum.Lock, locationInfo.WarehouseId);
@@ -148,6 +148,13 @@
                            }
                        }
                    }
                    else
                    {
                        Dt_LocationInfo undefinedTypeEmptyLocation = undefinedTypeEmptyLocations.FirstOrDefault();
                        Dt_LocationInfo? locationInfo = GetUsableLocation_BC(locationInfos, undefinedTypeEmptyLocation, palletType, palletTypeInfo);
                        locationCaches_BC.Add(new LocationCache { LocationCode = locationInfo.LocationCode, DateTime = DateTime.Now });
                        return locationInfo;
                    }
                }
                return null;