|
|
|
|
@ -346,10 +346,33 @@ namespace Application
|
|
|
|
|
PadResponse padResponse = new PadResponse();
|
|
|
|
|
try
|
|
|
|
|
{
|
|
|
|
|
List<WmsBaseLocation> list = sqlSugarClient.Queryable<WmsBaseLocation>().Where(x => !string.IsNullOrEmpty(x.AgvPositionCode)).ToList();
|
|
|
|
|
List<WmsBaseLocation> Locationlist = sqlSugarClient.Queryable<WmsBaseLocation>().Where(x => !string.IsNullOrEmpty(x.AgvPositionCode)).ToList();
|
|
|
|
|
List<LocationInfo> locationInfos = new List<LocationInfo>();
|
|
|
|
|
foreach (WmsBaseLocation location in Locationlist)
|
|
|
|
|
{
|
|
|
|
|
if (location != null)
|
|
|
|
|
{
|
|
|
|
|
WmsPalletInfo wmsPalletInfo = sqlSugarClient.Queryable<WmsPalletInfo>().Where(t => t.PalletInfoCode == location.ContainerCode).First();
|
|
|
|
|
LocationInfo locationInfo = new LocationInfo();
|
|
|
|
|
locationInfo.LocationCode = location.AgvPositionCode;
|
|
|
|
|
locationInfo.PalletInfoCode = wmsPalletInfo.PalletInfoCode;
|
|
|
|
|
locationInfo.Amount = wmsPalletInfo.Amount;
|
|
|
|
|
locationInfo.LocationStatus = location.LocationStatus;
|
|
|
|
|
locationInfos.Add(locationInfo);
|
|
|
|
|
}
|
|
|
|
|
else
|
|
|
|
|
{
|
|
|
|
|
LocationInfo locationInfo = new LocationInfo();
|
|
|
|
|
locationInfo.LocationCode = "";
|
|
|
|
|
locationInfo.PalletInfoCode = "";
|
|
|
|
|
locationInfo.Amount = 0;
|
|
|
|
|
locationInfo.LocationStatus = 0;
|
|
|
|
|
locationInfos.Add(locationInfo);
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
padResponse.code = "200";
|
|
|
|
|
padResponse.message = "成功";
|
|
|
|
|
padResponse.data = list;
|
|
|
|
|
padResponse.data = locationInfos;
|
|
|
|
|
}
|
|
|
|
|
catch (Exception ex)
|
|
|
|
|
{
|
|
|
|
|
|