1
dengjunjie
2025-01-10 5ee4d66f4fef38f9d7ba38d8c3cfae7f7fc082d3
代码管理/WMS/WIDESEA_WMSServer/WIDESEA_TaskInfoService/TaskService.cs
@@ -112,7 +112,12 @@
                {
                    x.AGVArea = agvDescription;
                });
                string response = HttpHelper.Post("http://127.0.0.1:9291/api/Task/ReceiveTask", taskDTOs.Serialize());
                string address = AppSettings.Get("WCSApiAddress");
                if (string.IsNullOrEmpty(address))
                {
                    return WebResponseContent.Instance.Error($"鏈壘鍒癢CSApi鍦板潃");
                }
                string response = HttpHelper.Post($"{address}/api/Task/ReceiveTask", taskDTOs.Serialize());
                return JsonConvert.DeserializeObject<WebResponseContent>(response) ?? WebResponseContent.Instance.Error("杩斿洖閿欒");
            }
@@ -130,7 +135,12 @@
        {
            try
            {
                string response = HttpHelper.Post("http://127.0.0.1:9281/api/CTU_AGV/PutFinish", code);
                string address = AppSettings.Get("WCSApiAddress");
                if (string.IsNullOrEmpty(address))
                {
                    return WebResponseContent.Instance.Error($"鏈壘鍒癢CSApi鍦板潃");
                }
                string response = HttpHelper.Post($"{address}/api/CTU_AGV/PutFinish", code);
                return JsonConvert.DeserializeObject<WebResponseContent>(response) ?? WebResponseContent.Instance.Error("杩斿洖閿欒");
            }
@@ -261,7 +271,7 @@
                {
                    foreach (var model in stockInfo.Details)
                    {
                        TestSynStock(new TestToolSynInfo() { ToolCode = model.BatchNo, MaterialName = model.MaterielName, Life = int.TryParse(model.Remark, out int val) ? val : 1000 });
                        TestSynStock(new TestToolSynInfo() { ToolCode = model.BatchNo, /*MaterialName = model.MaterielName,*/ Life = int.TryParse(model.Remark, out int val) ? val : 1000 });
                    }
                }
@@ -405,12 +415,11 @@
                if (warehouse.WarehouseCode != WarehouseEnum.HA64.ToString() && task.TaskType == TaskTypeEnum.Outbound.ObjToInt())
                {
                    _outboundService.OutboundOrderService.TestOutUpload(outboundOrderDetails.FirstOrDefault().Id, outStockLockInfos);
                    _outboundService.OutboundOrderService.TestOutUpload(outboundOrderDetails.FirstOrDefault().OrderId, outStockLockInfos);
                }
                if (task.TaskType == TaskTypeEnum.MesOutbound.ObjToInt())
                {
                    MesMaterialLotaAceptModel model = GetMesMaterialLotaAceptModel(stockInfo, stockInfo.Details.FirstOrDefault(), mesOutboundOrders.FirstOrDefault().TaskNo, warehouse.WarehouseCode, mesOutboundOrders.FirstOrDefault().OrderQuantity);
                    UploadMesMaterialLotaAcept(model);
                }
                return WebResponseContent.Instance.OK();