From a48dec1aaf88e1ba79cb521ae277c3b3d5ff3d84 Mon Sep 17 00:00:00 2001
From: 647556386 <647556386@qq.com>
Date: 星期五, 23 一月 2026 18:35:30 +0800
Subject: [PATCH] 1
---
项目代码/WMS无仓储版/WIDESEA_WMSServer/WIDESEA_WMSServer/Controllers/Allocate/AllocateOrderController.cs | 1
项目代码/WIDESEA_WMSClient/src/extension/outbound/extend/outOrderDetail.vue | 70 ++++++++++++++++++++---------------
项目代码/WMS无仓储版/WIDESEA_WMSServer/WIDESEA_OutboundService/OutboundService.cs | 14 ++++++
3 files changed, 53 insertions(+), 32 deletions(-)
diff --git "a/\351\241\271\347\233\256\344\273\243\347\240\201/WIDESEA_WMSClient/src/extension/outbound/extend/outOrderDetail.vue" "b/\351\241\271\347\233\256\344\273\243\347\240\201/WIDESEA_WMSClient/src/extension/outbound/extend/outOrderDetail.vue"
index a3771de..59d95f2 100644
--- "a/\351\241\271\347\233\256\344\273\243\347\240\201/WIDESEA_WMSClient/src/extension/outbound/extend/outOrderDetail.vue"
+++ "b/\351\241\271\347\233\256\344\273\243\347\240\201/WIDESEA_WMSClient/src/extension/outbound/extend/outOrderDetail.vue"
@@ -424,38 +424,48 @@
});
},
outbound() {
- if (this.selection.length === 0) {
- return this.$message.error("璇烽�夋嫨鍗曟嵁鏄庣粏");
- }
+ if (this.selection.length === 0) {
+ return this.$message.error("璇烽�夋嫨鍗曟嵁鏄庣粏");
+ }
- const keys = this.selection.map((item) => item.id);
- const requestParams = {
- detailIds: keys,
- outboundQuantity: 1,
- operator: "",
- orderNo: this.row.orderNo,
- isBatch: this.isBatch,
- };
- console.log(requestParams);
- this.$refs.DirectOutbound.open(requestParams);
- },
- outboundbatch() {
- if (this.selection.length === 0) {
- return this.$message.error("璇烽�夋嫨鍗曟嵁鏄庣粏");
- }
+ const keys = this.selection.map((item) => item.id);
+ const requestParams = {
+ detailIds: keys,
+ outboundQuantity: 1,
+ operator: "",
+ orderNo: this.row.orderNo,
+ isBatch: this.isBatch,
+ };
+ console.log(requestParams);
+ this.$refs.DirectOutbound.open(requestParams);
+ },
+
+ outboundbatch() {
+ if (this.selection.length === 0) {
+ return this.$message.error("璇烽�夋嫨鍗曟嵁鏄庣粏");
+ }
- const keys = this.selection.map((item) => item.id);
- const requestParams = {
- detailIds: keys,
- outboundQuantity:
- this.selection[0].orderQuantity - this.selection[0].lockQuantity,
- operator: "",
- orderNo: this.row.orderNo,
- isBatch: this.isBatch,
- };
- console.log(requestParams);
- this.$refs.DirectOutbound.open(requestParams);
- },
+ const keys = this.selection.map((item) => item.id);
+
+ // 璁$畻鎵�鏈夐�変腑鏄庣粏鐨勫彲鍑哄簱鏁伴噺鎬诲拰
+ let totalOutboundQuantity = 0;
+ this.selection.forEach(item => {
+ // 绫诲瀷杞崲+瀹归敊锛岄伩鍏嶉潪鏁板瓧鍊煎鑷磋绠楅敊璇�
+ const orderQty = Number(item.orderQuantity) || 0;
+ const lockQty = Number(item.lockQuantity) || 0;
+ totalOutboundQuantity += (orderQty - lockQty);
+ });
+
+ const requestParams = {
+ detailIds: keys,
+ outboundQuantity: totalOutboundQuantity,
+ operator: "",
+ orderNo: this.row.orderNo,
+ isBatch: this.isBatch,
+ };
+ console.log("鍒嗘壒鍑哄簱鍙傛暟锛�", requestParams);
+ this.$refs.DirectOutbound.open(requestParams);
+ },
setCurrent(row) {
this.$refs.singleTable.setCurrentRow(row);
},
diff --git "a/\351\241\271\347\233\256\344\273\243\347\240\201/WMS\346\227\240\344\273\223\345\202\250\347\211\210/WIDESEA_WMSServer/WIDESEA_OutboundService/OutboundService.cs" "b/\351\241\271\347\233\256\344\273\243\347\240\201/WMS\346\227\240\344\273\223\345\202\250\347\211\210/WIDESEA_WMSServer/WIDESEA_OutboundService/OutboundService.cs"
index be18841..26c2a23 100644
--- "a/\351\241\271\347\233\256\344\273\243\347\240\201/WMS\346\227\240\344\273\223\345\202\250\347\211\210/WIDESEA_WMSServer/WIDESEA_OutboundService/OutboundService.cs"
+++ "b/\351\241\271\347\233\256\344\273\243\347\240\201/WMS\346\227\240\344\273\223\345\202\250\347\211\210/WIDESEA_WMSServer/WIDESEA_OutboundService/OutboundService.cs"
@@ -209,6 +209,11 @@
string responseMsg = totalActualAllocate == totalNeedAllocate
? "鍒嗘嫞浠诲姟鍒嗛厤鎴愬姛"
: $"鍒嗘嫞浠诲姟鍒嗛厤瀹屾垚锛堝疄闄呭垎閰峽totalActualAllocate}锛岄渶姹倇totalNeedAllocate}锛屽簱瀛樹笉瓒抽儴鍒嗘湭鍒嗛厤锛�";
+ if(totalActualAllocate == 0)
+ {
+ UpdateOutboundOrderStatus(request.OrderNo, (int)OutOrderStatusEnum.鏈紑濮�);
+ return WebResponseContent.Instance.Error("鍒嗛厤搴撳瓨鏁伴噺涓�0锛屾棤娉曞嚭搴�");
+ }
response.Success = true;
response.Message = responseMsg;
response.Tasks = tasks;
@@ -1113,7 +1118,14 @@
{
barcodeQuantity = item.LockQuantity - item.OverOutQuantity;
allocatedQuantity -= (item.LockQuantity - item.OverOutQuantity);
- item.CurrentDeliveryQty = item.LockQuantity - item.OverOutQuantity;
+ if(item.ReturnToMESStatus == 0)
+ {
+ item.CurrentDeliveryQty = item.LockQuantity;
+ }
+ else
+ {
+ item.CurrentDeliveryQty = item.LockQuantity - item.OverOutQuantity;
+ }
item.OverOutQuantity = item.LockQuantity;
}
diff --git "a/\351\241\271\347\233\256\344\273\243\347\240\201/WMS\346\227\240\344\273\223\345\202\250\347\211\210/WIDESEA_WMSServer/WIDESEA_WMSServer/Controllers/Allocate/AllocateOrderController.cs" "b/\351\241\271\347\233\256\344\273\243\347\240\201/WMS\346\227\240\344\273\223\345\202\250\347\211\210/WIDESEA_WMSServer/WIDESEA_WMSServer/Controllers/Allocate/AllocateOrderController.cs"
index eda1033..54997b7 100644
--- "a/\351\241\271\347\233\256\344\273\243\347\240\201/WMS\346\227\240\344\273\223\345\202\250\347\211\210/WIDESEA_WMSServer/WIDESEA_WMSServer/Controllers/Allocate/AllocateOrderController.cs"
+++ "b/\351\241\271\347\233\256\344\273\243\347\240\201/WMS\346\227\240\344\273\223\345\202\250\347\211\210/WIDESEA_WMSServer/WIDESEA_WMSServer/Controllers/Allocate/AllocateOrderController.cs"
@@ -119,7 +119,6 @@
}
allocateOrder.Details.Add(orderDetail);
}
- allocateOrder.Details.AddRange(allocateOrder.Details);
}
var content = await Service.ReceiveAllocateOrder(allocateOrder, model.OperationType);
--
Gitblit v1.9.3