using AngleSharp.Dom;
|
using Mapster;
|
using Masuit.Tools;
|
using SqlSugar;
|
using System.Collections.Generic;
|
using System.Drawing.Printing;
|
using System.Linq.Expressions;
|
using WIDESEA_Core;
|
using WIDESEA_IStorageBasicService;
|
using WIDESEA_StorageBasicRepository;
|
|
namespace WIDESEA_StorageBasicService;
|
|
public class Dt_PalletStockInfoDetailService : ServiceBase<Dt_PalletStockInfoDetail, IDt_PalletStockInfoDetailRepository>, IDt_PalletStockInfoDetailService
|
{
|
|
private readonly IDt_PalletStockInfoRepository _palletStockInfoRepository;
|
public Dt_PalletStockInfoDetailService(IDt_PalletStockInfoDetailRepository BaseDal, IDt_PalletStockInfoRepository palletStockInfoRepository) : base(BaseDal)
|
{
|
_palletStockInfoRepository = palletStockInfoRepository;
|
}
|
|
/// <summary>
|
/// 查询组盘信息
|
/// </summary>
|
/// <param name="palletCode"></param>
|
/// <returns></returns>
|
public object GetBarcodeDetial(string palletCode)
|
{
|
List<Dt_PalletStockInfoDetail> list = null;
|
try
|
{
|
var headId = _palletStockInfoRepository.QueryFirst(x => x.PalletCode == palletCode);
|
if (headId != null)
|
{
|
list = BaseDal.QueryData(x => x.StockId == headId.Id);
|
return new
|
{
|
status = 1,
|
count = list.Count(),
|
data = list
|
};
|
}
|
return new
|
{
|
status = 0,
|
data = new List<Dt_PalletStockInfoDetail>()
|
};
|
|
}
|
catch (Exception)
|
{
|
return new
|
{
|
status = 0,
|
data = new List<Dt_PalletStockInfoDetail>()
|
};
|
};
|
}
|
}
|