| | |
| | | WebResponseContent content = new WebResponseContent(); |
| | | return await _unitOfWorkManage.BeginTranAsync(async () => |
| | | { |
| | | if (task.TaskType == (int)TaskOutboundTypeEnum.OutEmpty) |
| | | { |
| | | location.LocationStatus = LocationStatusEnum.Free.GetHashCode(); |
| | | |
| | | var updateResult = await _locationInfoService.UpdateLocationInfoAsync(location); |
| | | var deleteResult = _stockInfoService.DeleteData(stockInfo).Status; |
| | | if (!updateResult && !deleteResult) |
| | | return content.Error("任务完成失败"); |
| | | |
| | | var completeResult1 = await CompleteTaskAsync(task, "出库完成"); |
| | | return content.OK(); |
| | | |
| | | } |
| | | |
| | | stockInfo.LocationId = 0; |
| | | stockInfo.LocationCode = string.Empty; |
| | | stockInfo.OutboundDate = DateTime.Now; |
| | | stockInfo.StockStatus = (int)StockStatusEmun.出库完成; |
| | | |
| | | location.LocationStatus = LocationStatusEnum.Free.GetHashCode(); |
| | | |
| | |
| | | TaskNum = await BaseDal.GetTaskNo(), |
| | | PalletCode = task.PalletCode, |
| | | PalletType = task.PalletType, |
| | | Roadway = "CW1", |
| | | Roadway = "CWSC1", |
| | | TaskType = TaskInboundTypeEnum.Inbound.GetHashCode(), |
| | | TaskStatus = TaskInStatusEnum.InNew.GetHashCode(), |
| | | SourceAddress = task.TargetAddress, |
| | | SourceAddress = "11042", |
| | | TargetAddress = task.TargetAddress, |
| | | CurrentAddress = task.TargetAddress, |
| | | CurrentAddress = "11042", |
| | | NextAddress = task.TargetAddress, |
| | | WarehouseId = (int)WarehouseEnum.CW1, |
| | | Grade = 1, |
| | |
| | | return ( |
| | | result?.Data?.IsSuccess ?? false, |
| | | Newtonsoft.Json.JsonConvert.SerializeObject(result), |
| | | result?.Data?.Msg ?? result?.ErrorMessage ?? "未知错误" |
| | | result?.Data?.Msg ?? result?.ErrorMessage ?? "未知错误", |
| | | _mesService.BuildConfig(token ?? string.Empty).ToJson() |
| | | ); |
| | | }); |
| | | |