修改
This commit is contained in:
1 parent
523dee5e38
commit
f9bf7be066
12 files changed
+635
-42
No files matched your search
@@ -141,7 +141,7 @@ namespace HHWMS.Web
|
||||
{
|
||||
tasktolocatioin.Status = LocationStatus.满货;
|
||||
}
|
||||
else if (invCount < tasktolocatioin.Length)
|
||||
else if (invCount < tasktolocatioin.Length && invCount != 0)
|
||||
{
|
||||
tasktolocatioin.Status = LocationStatus.有货;
|
||||
}
|
||||
@@ -239,13 +239,21 @@ namespace HHWMS.Web
|
||||
// 创建料盒入库任务
|
||||
// 查找回库的任务起点,
|
||||
var fromLocation = _unitwork.FindSingle<Location>(x => x.Code.Equals(task.ToLocation)).ContiguousCode;
|
||||
newTask.ZoneCode = "L";
|
||||
newTask.TaskNo = _unitwork.GetSerialNumber("in", 4);
|
||||
newTask.ZoneCode = ZoneCodeEnum.盘料库;
|
||||
if (task.TaskNo.Contains("PLoop"))
|
||||
{
|
||||
newTask.TaskNo = _unitwork.GetSerialNumber("PLoopin", 4);
|
||||
}
|
||||
else
|
||||
{
|
||||
newTask.TaskNo = _unitwork.GetSerialNumber("in", 4);
|
||||
}
|
||||
newTask.TaskType = TaskTypeEnum.盘料盒入库;
|
||||
newTask.ContainerCode = containerCode;
|
||||
newTask.FromLocation = fromLocation;
|
||||
newTask.ToLocation = containerCode;
|
||||
newTask.Status = TaskStatusEnum.待下发;
|
||||
newTask.CreateTime = DateTime.Now;
|
||||
_unitwork.Add(newTask);
|
||||
//更新料塔占用
|
||||
station.ContainerCode = "";
|
||||
@@ -282,12 +290,20 @@ namespace HHWMS.Web
|
||||
var fromLocation = _unitwork.FindSingle<Location>(x => x.Code.Equals(task.FromLocation)).ContiguousCode;
|
||||
// 下发盘料盒回库任务,回原位
|
||||
newTask.ZoneCode = ZoneCodeEnum.盘料库;
|
||||
newTask.TaskNo = _unitwork.GetSerialNumber("in", 4);
|
||||
if (task.TaskNo.Contains("PLoop"))
|
||||
{
|
||||
newTask.TaskNo = _unitwork.GetSerialNumber("PLoopin", 4);
|
||||
}
|
||||
else
|
||||
{
|
||||
newTask.TaskNo = _unitwork.GetSerialNumber("in", 4);
|
||||
}
|
||||
newTask.TaskType = TaskTypeEnum.盘料盒入库;
|
||||
newTask.ContainerCode = task.ContainerCode;
|
||||
newTask.FromLocation = fromLocation;
|
||||
newTask.ToLocation = task.ContainerCode;
|
||||
newTask.Status = TaskStatusEnum.待下发;
|
||||
newTask.CreateTime = DateTime.Now;
|
||||
_unitwork.Add(newTask);
|
||||
}
|
||||
break;
|
||||
@@ -302,7 +318,10 @@ namespace HHWMS.Web
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
else
|
||||
{
|
||||
return ApiResultError(msg: $"未找到任务号{taskno}对应的任务!");
|
||||
}
|
||||
return ApiResult();
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user