优化接口
This commit is contained in:
@@ -2045,6 +2045,13 @@
|
|||||||
<param name="boxBillNo"></param>
|
<param name="boxBillNo"></param>
|
||||||
<returns></returns>
|
<returns></returns>
|
||||||
</member>
|
</member>
|
||||||
|
<member name="M:WMS.Web.Domain.Infrastructure.IBoxInventoryRepositories.IsExist(System.Int32)">
|
||||||
|
<summary>
|
||||||
|
箱库存是否存在
|
||||||
|
</summary>
|
||||||
|
<param name="boxId"></param>
|
||||||
|
<returns></returns>
|
||||||
|
</member>
|
||||||
<member name="M:WMS.Web.Domain.Infrastructure.IBoxInventoryRepositories.GetList(System.Collections.Generic.List{System.Int32})">
|
<member name="M:WMS.Web.Domain.Infrastructure.IBoxInventoryRepositories.GetList(System.Collections.Generic.List{System.Int32})">
|
||||||
<summary>
|
<summary>
|
||||||
列表-根据箱ids
|
列表-根据箱ids
|
||||||
|
|||||||
@@ -28,6 +28,13 @@ namespace WMS.Web.Domain.Infrastructure
|
|||||||
/// <returns></returns>
|
/// <returns></returns>
|
||||||
Task<BoxInventoryResponse> GetInfoBy(string boxBillNo);
|
Task<BoxInventoryResponse> GetInfoBy(string boxBillNo);
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 箱库存是否存在
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="boxId"></param>
|
||||||
|
/// <returns></returns>
|
||||||
|
Task<bool> IsExist(int boxId);
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// 列表-根据箱ids
|
/// 列表-根据箱ids
|
||||||
/// </summary>
|
/// </summary>
|
||||||
|
|||||||
@@ -199,10 +199,10 @@ namespace WMS.Web.Domain.Services
|
|||||||
if (tast_box == null)
|
if (tast_box == null)
|
||||||
return Result<BoxInStockTaskDto>.ReFailure(ResultCodes.Box_NoBind_Task_Data);
|
return Result<BoxInStockTaskDto>.ReFailure(ResultCodes.Box_NoBind_Task_Data);
|
||||||
|
|
||||||
////2.1判断箱是否上架过了---不要这个判断
|
//2.1判断箱是否上架过了
|
||||||
//var isExist = await _inStockRepositories.IsExistBy(box.Id);
|
var isExist = await _boxInventoryRepositories.IsExist(box.Id);
|
||||||
//if (isExist)
|
if (isExist)
|
||||||
// return Result<BoxInStockTaskDto>.ReFailure(ResultCodes.BoxIsTrueShelf);
|
return Result<BoxInStockTaskDto>.ReFailure(ResultCodes.BoxIsTrueShelf);
|
||||||
|
|
||||||
//1.2找到任务单
|
//1.2找到任务单
|
||||||
var tast = await _inStockTaskRepositories.Get(tast_box.TaskId);
|
var tast = await _inStockTaskRepositories.Get(tast_box.TaskId);
|
||||||
|
|||||||
@@ -172,6 +172,12 @@ namespace WMS.Web.Repositories
|
|||||||
return await _context.BoxInventory.Include(x => x.Details).Where(x => ids.Contains(x.BoxId)).ToListAsync();
|
return await _context.BoxInventory.Include(x => x.Details).Where(x => ids.Contains(x.BoxId)).ToListAsync();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public async Task<bool> IsExist(int boxId)
|
||||||
|
{
|
||||||
|
return await _context.BoxInventory.Where(x => x.BoxId == boxId).AnyAsync();
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// 实体-根据箱id
|
/// 实体-根据箱id
|
||||||
/// </summary>
|
/// </summary>
|
||||||
|
|||||||
Reference in New Issue
Block a user