| | |
| | | using System.Linq; |
| | | using System.Text; |
| | | using System.Threading.Tasks; |
| | | using WIDESEA_BasicService; |
| | | using WIDESEA_Common.CommonEnum; |
| | | using WIDESEA_Common.LocationEnum; |
| | | using WIDESEA_Common.OrderEnum; |
| | |
| | | return WebResponseContent.Instance.Error($"è´§ä½åé
失败,æªæ¾å°å¯åé
è´§ä½"); |
| | | } |
| | | |
| | | |
| | | var newTask = new Dt_Task() |
| | | { |
| | | CurrentAddress = stations.GetValueOrDefault(stationCode) ?? "", |
| | |
| | | TaskStatus = TaskStatusEnum.New.ObjToInt(), |
| | | WarehouseId = stockInfo.WarehouseId, |
| | | PalletType = stockInfo.PalletType, |
| | | OrderNo= stockInfo.Details.FirstOrDefault()?.OrderNo |
| | | OrderNo= stockInfo.Details.FirstOrDefault()?.OrderNo, |
| | | }; |
| | | //空箱 |
| | | if (stockInfo.PalletType == PalletTypeEnum.Empty.ObjToInt()) |
| | | if (stockInfo.PalletType == PalletTypeEnum.Empty.ObjToInt()|| stockInfo.StockStatus == StockStatusEmun.æºä»å
¥æºä»ç»çæå.ObjToInt()) |
| | | { |
| | | _unitOfWorkManage.BeginTran(); |
| | | newTask.TaskType = TaskTypeEnum.InEmpty.ObjToInt(); |
| | | int taskId = BaseDal.AddData(newTask); |
| | | newTask.TaskId = taskId; |
| | | |
| | | locationInfo.LocationStatus = LocationStatusEnum.Lock.ObjToInt(); |
| | | _locationInfoService.UpdateData(locationInfo); |
| | | stockInfo.StockStatus = StockStatusEmun.å
¥åºç¡®è®¤.ObjToInt(); |
| | | |
| | | _stockRepository.UpdateData(stockInfo); |
| | | _unitOfWorkManage.CommitTran(); |
| | | } |
| | | //æºä»å
¥æºä» |
| | | if (stockInfo.StockStatus == StockStatusEmun.æºä»å
¥æºä»ç»çæå.ObjToInt()) |
| | | { |
| | | _unitOfWorkManage.BeginTran(); |
| | | newTask.TaskType = TaskTypeEnum.AllocateInWarehouse.ObjToInt(); |
| | | if (stockInfo.StockStatus == StockStatusEmun.æºä»å
¥æºä»ç»çæå.ObjToInt()) |
| | | { |
| | | newTask.TaskType = TaskTypeEnum.AllocateInWarehouse.ObjToInt(); |
| | | } |
| | | int taskId = BaseDal.AddData(newTask); |
| | | newTask.TaskId = taskId; |
| | | |
| | |
| | | inboundOrder = _inboundOrderService.Repository.QueryFirst(x => x.InboundOrderNo == orderNo && x.OrderStatus < InOrderStatusEnum.å
¥åºå®æ.ObjToInt()); |
| | | |
| | | } |
| | | |
| | | |
| | | stockInfo.StockStatus = StockStatusEmun.å
¥åºç¡®è®¤.ObjToInt(); |
| | | |
| | | LocationStatusEnum lastStatus = (LocationStatusEnum)locationInfo.LocationStatus; |