取消任务回调 取消任务 更新货架信息
This commit is contained in:
@ -68,7 +68,8 @@ namespace WCS.BLL.Manager
|
||||
{
|
||||
var shelf = DbHelp.db.Queryable<ShelfInfo>()
|
||||
.Where(t => t.ShelfCode == tasks[i].ShelfCode)
|
||||
.Where(t => t.CurrentLocationId == tasks[i].StratLocationId && t.DestinationLocationId == tasks[i].EndLocationId)
|
||||
.Where(t => t.CurrentTaskCode == tasks[i].TaskCode)
|
||||
.Where(t => t.DestinationLocationId == tasks[i].EndLocationId)
|
||||
.First();
|
||||
if (shelf != null)
|
||||
{
|
||||
|
@ -89,6 +89,20 @@ namespace WCS.WebApi.Controllers
|
||||
DbHelp.db.Updateable(shelf).ExecuteCommand();
|
||||
}
|
||||
|
||||
if (shelf != null && request.method == "cancel" && shelf.TransStatus == TransStatusEnum.运输中)
|
||||
{
|
||||
|
||||
//shelf.CurrentLocationId = 0;
|
||||
//shelf.CurrentLocaiotnCode = string.Empty;
|
||||
|
||||
shelf.DestinationLocationId = 0;
|
||||
shelf.DestinationLocaiotnCode = string.Empty;
|
||||
shelf.TransStatus = TransStatusEnum.静止;
|
||||
shelf.CurrentTaskCode = string.Empty;
|
||||
|
||||
DbHelp.db.Updateable(shelf).ExecuteCommand();
|
||||
}
|
||||
|
||||
if (shelf != null && request.method == "end" && shelf.TransStatus == TransStatusEnum.运输中)
|
||||
{
|
||||
task.TaskStatus = TaskStatusEnum.已结束;
|
||||
|
Reference in New Issue
Block a user