优化
This commit is contained in:
@@ -90,10 +90,10 @@ namespace WMS.Web.Repositories
|
||||
if(!string.IsNullOrEmpty(dto.BoxBillNo))
|
||||
query = query.Where(w => EF.Functions.Like(w.box.BoxBillNo, "%" + dto.BoxBillNo + "%"));
|
||||
|
||||
if (dto.SubStockId.HasValue)
|
||||
query = query.Where(w => w.order.SubStockId == dto.SubStockId.Value);
|
||||
if (!string.IsNullOrEmpty(dto.SubStockCode))
|
||||
query = query.Where(w => w.order.SubStockCode == dto.SubStockCode);
|
||||
|
||||
if(dto.Type.HasValue)
|
||||
if (dto.Type.HasValue)
|
||||
query = query.Where(w => (int)w.order.Type == dto.Type.Value);
|
||||
|
||||
if (ids.Count() > 0)
|
||||
@@ -114,13 +114,13 @@ namespace WMS.Web.Repositories
|
||||
Type = s.order.Type.GetRemark(),
|
||||
Creator = _singleDataService.GetSingleData(SingleAction.Staffs, companyId, s.order.CreatorId),
|
||||
CreateTime =s.order.CreateTime.ToString("yyyy-MM-dd HH:mm:ss"),
|
||||
MaterialName = _erpBasicDataExtendService.GetMaterialName(materials, s.detail.MaterialId),
|
||||
MaterialNumber = _erpBasicDataExtendService.GetMaterialNumber(materials, s.detail.MaterialId),
|
||||
Specifications = _erpBasicDataExtendService.GetMaterialSpecifications(materials, s.detail.MaterialId),
|
||||
MaterialName = _erpBasicDataExtendService.GetMaterialName(materials, s.detail.MaterialNumber),
|
||||
MaterialNumber = s.detail.MaterialNumber,
|
||||
Specifications = _erpBasicDataExtendService.GetMaterialSpecifications(materials, s.detail.MaterialNumber),
|
||||
Qty = s.detail.Qty,
|
||||
Org= _erpBasicDataExtendService.GetOrgName(orgs, s.order.OrgCode),
|
||||
Stock = _singleDataService.GetSingleData(SingleAction.StocksJoinOrgCode, companyId, s.order.StockCode + s.order.OrgCode),
|
||||
SubStock = _singleDataService.GetSingleData(SingleAction.SubStocks, companyId, s.order.SubStockId),
|
||||
SubStock = _singleDataService.GetSingleData(SingleAction.SubStocks, companyId, s.order.SubStockCode),
|
||||
SerialNumbers = (string.Join(",", s.detail.SerialNumbers)).TrimEnd(','),
|
||||
}).OrderByDescending(x => x.Id).Skip((dto.PageNo - 1) * dto.PageSize).Take(dto.PageSize).ToListAsync();
|
||||
|
||||
|
||||
Reference in New Issue
Block a user