From 6a17bde61e85c7dbe0dc441ad3faf057ff44d66f Mon Sep 17 00:00:00 2001
From: dengjunjie <dengjunjie@hnkhzn.com>
Date: 星期二, 14 一月 2025 14:58:42 +0800
Subject: [PATCH] 1
---
代码管理/WMS/WIDESEA_WMSServer/WIDESEA_InboundService/InboundOrderService.cs | 35 +++++++++++++++++++++++++++++++++++
代码管理/WMS/WIDESEA_WMSServer/WIDESEA_OutboundService/OutboundOrderService.cs | 5 ++++-
代码管理/淮安PDA/pages/stash/pickingMat.vue | 1 -
代码管理/WMS/WIDESEA_WMSServer/WIDESEA_TaskInfoService/TaskService.cs | 2 +-
代码管理/WMS/WIDESEA_WMSServer/WIDESEA_TaskInfoService/TaskService_Inbound.cs | 6 +++---
5 files changed, 43 insertions(+), 6 deletions(-)
diff --git "a/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSServer/WIDESEA_InboundService/InboundOrderService.cs" "b/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSServer/WIDESEA_InboundService/InboundOrderService.cs"
index 56030ff..8a57f20 100644
--- "a/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSServer/WIDESEA_InboundService/InboundOrderService.cs"
+++ "b/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSServer/WIDESEA_InboundService/InboundOrderService.cs"
@@ -407,6 +407,41 @@
_inboundRepository.InboundOrderRepository.UpdateData(inboundOrder);
_recordService.StockQuantityChangeRecordService.AddStockChangeRecord(stockInfo, stockInfoDetails, beforeQuantity, totalQuantity, StockChangeTypeEnum.Inbound);
_unitOfWorkManage.CommitTran();
+
+ #region 涓婃姤ERP鍏ュ簱瀹屾垚
+ List<ERPInboundDetailModel> detailModels = new List<ERPInboundDetailModel>();
+ foreach (var item in stockInfo.Details)
+ {
+ ERPInboundDetailModel detailModel = new ERPInboundDetailModel()
+ {
+ ExpiryDate = item.EffectiveDate ?? "",
+ LocationCode = warehouse.WarehouseCode,
+ MaterialsCode = item.MaterielCode,
+ MfgDate = item.ProductionDate ?? "",
+ QtyCustoms = "0",
+ Quantity = item.StockQuantity.ToString(),
+ Rack = stockInfo.LocationCode,
+ ReceiptCode = inboundOrder.UpperOrderNo,
+ ReceiptSerNo = item.InboundOrderRowNo.ToString()
+ };
+ detailModels.Add(detailModel);
+ }
+ ERPInboundModel eRPInboundModel = new ERPInboundModel()
+ {
+ Code = inboundOrder.InboundOrderNo,
+ CreatorCode = inboundOrder.Creater,
+ EntDate = inboundOrder.CreateDate.ToString("yyyy-MM-dd HH:mm:ss"),
+ StockDate = DateTime.Now.ToString("yyyy-MM-dd HH:mm:ss"),
+ SuppliersId = inboundOrder.SupplierId,
+ Type = "S",
+ UniqueTag = inboundOrder.Id.ToString(),
+ WarehouseCode = warehouse.WarehouseCode,
+ Way = 1,
+ Details = detailModels
+ };
+ //鎺ㄩ�丒RP 娴嬭瘯娉ㄩ噴
+ _invokeERPService.InvokeInboundOrderApi(eRPInboundModel);
+ #endregion
content.OK();
}
catch (Exception ex)
diff --git "a/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSServer/WIDESEA_OutboundService/OutboundOrderService.cs" "b/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSServer/WIDESEA_OutboundService/OutboundOrderService.cs"
index 24712a8..e3deb6c 100644
--- "a/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSServer/WIDESEA_OutboundService/OutboundOrderService.cs"
+++ "b/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSServer/WIDESEA_OutboundService/OutboundOrderService.cs"
@@ -247,6 +247,9 @@
Pickcode = outboundOrder.UpperOrderNo,
PickList = eRPPickModels
};
+ string Createuser = "";
+ if (!string.IsNullOrEmpty(App.User.UserName)) Createuser = App.User.UserName;
+ else Createuser = stockLockInfos.FirstOrDefault().Creater;
issueModel = new ERPIssueModel()
{
UniqueTag = outboundOrder.Id.ToString(),
@@ -256,7 +259,7 @@
Deptno = outboundOrder.DepartmentCode,
Deptname = outboundOrder.DepartmentName,
Createtime = DateTime.Now.ToString("yyyy-MM-dd HH:mm:ss"),
- Createuser = App.User.UserName ?? stockLockInfos.FirstOrDefault().Creater ?? "admin",
+ Createuser = string.IsNullOrEmpty(Createuser) ? Createuser : "admin",
Issitem = new List<ERPIssueItemModel>() { issueItemModel },
};
}
diff --git "a/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSServer/WIDESEA_TaskInfoService/TaskService.cs" "b/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSServer/WIDESEA_TaskInfoService/TaskService.cs"
index 9a33c4e..b3a551d 100644
--- "a/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSServer/WIDESEA_TaskInfoService/TaskService.cs"
+++ "b/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSServer/WIDESEA_TaskInfoService/TaskService.cs"
@@ -140,7 +140,7 @@
{
return WebResponseContent.Instance.Error($"鏈壘鍒癢CSAApi鍦板潃,璇锋鏌ラ厤缃枃浠�");
}
- string response = HttpHelper.Post($"{url}/api/CTU_AGV/PutFinish?code" + code);
+ string response = HttpHelper.Post($"{url}/api/CTU_AGV/PutFinish?code=" + code);
return JsonConvert.DeserializeObject<WebResponseContent>(response) ?? WebResponseContent.Instance.Error("杩斿洖閿欒");
}
diff --git "a/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSServer/WIDESEA_TaskInfoService/TaskService_Inbound.cs" "b/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSServer/WIDESEA_TaskInfoService/TaskService_Inbound.cs"
index 02afab2..018d5ce 100644
--- "a/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSServer/WIDESEA_TaskInfoService/TaskService_Inbound.cs"
+++ "b/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSServer/WIDESEA_TaskInfoService/TaskService_Inbound.cs"
@@ -42,7 +42,7 @@
return WebResponseContent.Instance.Error($"璇ユ墭鐩樺凡鐢熸垚浠诲姟");
}
- if (Repository.QueryFirst(x => x.SourceAddress == stationCode && x.TaskStatus == TaskStatusEnum.New.ObjToInt()) != null)
+ if (Repository.QueryFirst(x => x.SourceAddress == stationCode && x.TaskStatus == TaskStatusEnum.New.ObjToInt()) != null && warehouse.WarehouseCode != WarehouseEnum.HA60.ToString())
{
return WebResponseContent.Instance.Error($"璇ョ珯鐐瑰凡鏈夋湭鎵ц鐨勪换鍔�");
}
@@ -299,7 +299,7 @@
else if (stockInfo.StockStatus == StockStatusEmun.鎷i�夊畬鎴�.ObjToInt())
{
stockInfo.StockStatus = StockStatusEmun.鎷i�夊畬鎴�.ObjToInt();
- newTask.TaskType=TaskTypeEnum.InPick.ObjToInt();
+ newTask.TaskType = TaskTypeEnum.InPick.ObjToInt();
}
else
{
@@ -390,7 +390,7 @@
{
stockInfo.StockStatus = StockStatusEmun.鍏ュ簱纭.ObjToInt();
}
-
+
_unitOfWorkManage.BeginTran();
int taskId = BaseDal.AddData(newTask);
newTask.TaskId = taskId;
diff --git "a/\344\273\243\347\240\201\347\256\241\347\220\206/\346\267\256\345\256\211PDA/pages/stash/pickingMat.vue" "b/\344\273\243\347\240\201\347\256\241\347\220\206/\346\267\256\345\256\211PDA/pages/stash/pickingMat.vue"
index 9d8df60..cb7cf9c 100644
--- "a/\344\273\243\347\240\201\347\256\241\347\220\206/\346\267\256\345\256\211PDA/pages/stash/pickingMat.vue"
+++ "b/\344\273\243\347\240\201\347\256\241\347\220\206/\346\267\256\345\256\211PDA/pages/stash/pickingMat.vue"
@@ -182,7 +182,6 @@
if (res.status) {
uni.$showMsg(res.message);
this.inboundBarcode = "";
- this.address = "";
setTimeout(() => {
this.addressFocus = false;
}, 200);
--
Gitblit v1.9.3