From e5047fedea61ed7dda909155518c43b7f5cb5a9e Mon Sep 17 00:00:00 2001 From: shenzhouyu Date: Tue, 2 Dec 2025 23:58:16 +0800 Subject: [PATCH] =?UTF-8?q?=E9=80=80=E6=96=99=E4=BF=AE=E6=94=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../productionReturnPDAIssueList.vue | 217 ++++++++++------- .../productionReturnPickingDetail.vue | 223 +++++++++++------- 2 files changed, 266 insertions(+), 174 deletions(-) diff --git a/src/views/modules/production-return/productionReturnPDAIssueList.vue b/src/views/modules/production-return/productionReturnPDAIssueList.vue index a1bebbe..624c978 100644 --- a/src/views/modules/production-return/productionReturnPDAIssueList.vue +++ b/src/views/modules/production-return/productionReturnPDAIssueList.vue @@ -11,113 +11,132 @@
- +
- + {{ "移除" }} {{ "添加" }}
+ +
- -
-
-
- {{ - orderInfo.type === "workOrder" ? "工单号" : "退料申请单号" - }}:{{ orderInfo.orderNo }}     批次号:{{ batchNo }} -
- - -
- {{ orderInfo.type === "workOrder" ? "关联单号" : "关联工单" }}:{{ - orderInfo.transactionId - }}  申请单退量:{{unissureQty}} -
-
- {{ orderInfo.partNo }} -
-
- {{ orderInfo.description }} -
+ +
+ +
+
+
+ {{ + orderInfo.type === "workOrder" ? "工单号" : "退料申请单号" + }}:{{ orderInfo.orderNo }}     批次号:{{ batchNo }} +
-
-
-
已退数量
-
{{ qtyReversed }}
+ +
+ {{ orderInfo.type === "workOrder" ? "关联单号" : "关联工单" }}:{{ + orderInfo.transactionId + }}  申请单退量:{{unissureQty}}
-
-
领料数量
-
{{ orderInfo.quantity }}
+
+ {{ orderInfo.partNo }}
-
-
本次
-
{{ totalScannedQty }}
+
+ {{ orderInfo.description }} +
+ +
+
+
已退数量
+
{{ qtyReversed }}
+
+
+
领料数量
+
{{ orderInfo.quantity }}
+
+
+
本次
+
{{ totalScannedQty }}
+
-
- -
-
- - 退料信息确认 + +
+
+ + 退料信息确认 +
+
- -
- -
-
-
NO.
-
物料标签
- -
库位
-
高度
-
退料数量
-
+ +
+
+
NO.
+
物料标签
+ +
库位
+
高度
+
退料数量
+
-
-
{{ index+1 }}
-
{{ label.labelCode }}
- -
{{ label.locationId }}
-
{{ label.height }}
-
- {{ label.quantity }} - +
+
{{ index+1 }}
+
{{ label.labelCode }}
+ +
{{ label.locationId }}
+
{{ label.height }}
+
+ {{ label.quantity }} + +
-
- -
-

暂无扫描标签

+ +
+

暂无扫描标签

+
-
- - + + +
@@ -409,6 +428,7 @@ export default { lineItemNo:'', releaseNo:'', sequenceNo:'', + enablePrint: true, // 是否打印标签,默认勾选 } }, computed: { @@ -655,6 +675,13 @@ export default { this.$message.warning('扫描数量不能大于总领料数量和已退数量的差!') return } + const hasNewPrint = this.labelList.some(item => { + return typeof item !== null && item.newPrint === 'NEW'; + }); + if(hasNewPrint && !this.enablePrint){ + this.$message.warning('存在新标签,需勾选打印标签选项!') + return + } const returnParams = { site: localStorage.getItem('site'), @@ -690,7 +717,7 @@ export default { if (data.code === 0 && data) { this.$message.success('生产退料成功') const unitIds = data.unitIds || []; - if (unitIds.length > 0) { + if (this.enablePrint && unitIds.length > 0) { this.printViaServer(unitIds); } this.$router.back() @@ -1015,6 +1042,13 @@ export default { background: #f5f5f5; } +/* 中间内容滚动区域:订单卡片 + 标题 + 标签列表 */ +.scrollable-content { + flex: 1; + overflow-y: auto; + min-height: 0; +} + /* 头部栏 */ .header-bar { display: flex; @@ -1053,6 +1087,7 @@ export default { display: flex; align-items: center; gap: 12px; + flex-wrap: wrap; } .search-container .el-input { @@ -1072,6 +1107,14 @@ export default { margin-left: auto; } +/* 打印勾选 */ +.print-checkbox { + font-size: 12px; + color: #606266; + width: 100%; + margin-top: 4px; +} + .new-label-btn:hover { background: #13998c; border-color: #13998c; @@ -1326,8 +1369,6 @@ export default { margin: 0 10px 12px; border-radius: 0 0 8px 8px; overflow: hidden; - max-height: 300px; - overflow-y: auto; } .list-header { diff --git a/src/views/modules/production-return/productionReturnPickingDetail.vue b/src/views/modules/production-return/productionReturnPickingDetail.vue index 2635d3e..b104e1a 100644 --- a/src/views/modules/production-return/productionReturnPickingDetail.vue +++ b/src/views/modules/production-return/productionReturnPickingDetail.vue @@ -11,15 +11,31 @@
- +
- + {{ "移除" }} {{ "添加" }}
- 新标签 +
@@ -66,24 +82,37 @@
- -
-
-
NO.
-
标签条码
-
物料编码
-
高度
-
标签数量
-
- -
-
{{ index+1 }}
-
{{ label.labelCode }}
-
{{ label.partNo }}
-
{{ label.height }}
-
- {{ label.quantity }} - + +
+
+
+ +
+
+
+ 标签号: + {{ label.labelCode }} +
+
+ 物料号: + {{ label.partNo || '-' }} +
+
+ 库位号: + {{ label.locationId || '-' }} +
+
+ 高度: + {{ label.height || '-' }} +
+
+ 退料数量: + {{ label.quantity || 0 }} +
@@ -319,6 +348,7 @@ export default { sequenceNo: '', wdrNo: '', engChgLevel: '', + enablePrint: true, // 是否打印标签,默认勾选 } }, computed: { @@ -644,6 +674,13 @@ export default { this.$message.warning('扫描数量不能大于总领料数量和已退数量的差!') return } + const hasNewPrint = this.labelList.some(item => { + return typeof item !== null && item.newPrint === 'NEW'; + }); + if(hasNewPrint && !this.enablePrint){ + this.$message.warning('存在新标签,需勾选打印标签选项!') + return + } const returnParams = { site: localStorage.getItem('site'), @@ -681,7 +718,8 @@ export default { if (data.code === 0 && data) { this.$message.success('生产退料成功') const unitIds = data.unitIds || []; - if (unitIds.length > 0) { + // 根据勾选框决定是否打印 + if (this.enablePrint && unitIds.length > 0) { this.printViaServer(unitIds); } this.$router.back() @@ -919,6 +957,7 @@ export default { display: flex; align-items: center; gap: 12px; + flex-wrap: wrap; } .search-container .el-input { @@ -946,6 +985,14 @@ export default { transform: scale(0.98); } +/* 打印勾选 */ +.print-checkbox { + font-size: 12px; + color: #606266; + width: 100%; + margin-top: 4px; +} + .manual-btn { border: 1px solid #1abc4a; @@ -1210,96 +1257,100 @@ export default { color: #0d8f7f; } -/* 标签列表 */ -.label-list { - background: white; - margin: 0 10px 12px; - border-radius: 0 0 8px 8px; - overflow: hidden; - display: flex; - flex-direction: column; +/* 标签列表 - 卡片容器(参考客户发料) */ +.label-card-container { + padding: 0 8px 8px; + background: #f5f5f5; } -.list-header { - display: flex; - background: #f8f9fa; - padding: 12px 8px; - border-bottom: 1px solid #e0e0e0; - font-size: 12px; - color: #666; - font-weight: 500; - position: sticky; - top: 0; - z-index: 1; +/* 标签卡片 - 更紧凑样式 */ +.label-card { + background: white; + border-radius: 4px; + margin-bottom: 6px; + padding: 6px 8px; + box-shadow: 0 1px 2px rgba(0, 0, 0, 0.08); + border: 1px solid #e0e0e0; + cursor: pointer; + transition: all 0.2s ease; + position: relative; } -.list-item { - display: flex; - padding: 12px 8px; - border-bottom: 1px solid #f0f0f0; - font-size: 12px; - color: #333; - align-items: flex-start; - min-height: 40px; +.label-card:hover { + box-shadow: 0 2px 4px rgba(0, 0, 0, 0.12); + border-color: #17b3a3; } -.list-item:last-child { - border-bottom: none; +.label-card:active { + transform: scale(0.98); } -.col-no { +/* 编辑图标 - 右上角 */ +.card-edit-icon { + position: absolute; + top: 6px; + right: 6px; width: 20px; - text-align: center; + height: 20px; + display: flex; + align-items: center; + justify-content: center; + background: #f0f0f0; + border-radius: 3px; + cursor: pointer; + transition: all 0.2s ease; + z-index: 10; } -.col-label { - flex: 1.5; - text-align: center; - word-break: break-all; - white-space: normal; - line-height: 1.2; +.card-edit-icon:hover { + background: #17b3a3; + color: white; } -.col-part { - flex: 1.5; - text-align: center; +.card-edit-icon i { + font-size: 12px; + color: #17b3a3; } -.col-batch { - flex: 1.5; - text-align: center; +.card-edit-icon:hover i { + color: white; } -.col-qty { - width: 80px; - text-align: center; - cursor: pointer; - position: relative; +/* 卡片内容 */ +.card-content { + padding-right: 28px; +} + +.card-row { display: flex; align-items: center; - justify-content: center; - gap: 4px; + font-size: 11px; + line-height: 1.5; + margin-bottom: 3px; } -.quantity-display { - font-size: 12px; - color: #333; +.card-row:last-child { + margin-bottom: 0; } -.edit-icon { - font-size: 12px; - color: #17b3a3; - opacity: 0.7; - transition: opacity 0.2s ease; +.card-label { + color: #666; + min-width: 65px; + flex-shrink: 0; + font-size: 11px; } -.col-qty:hover .edit-icon { - opacity: 1; +.card-value { + color: #333; + flex: 1; + word-break: break-all; + font-size: 11px; } -.col-qty:hover { - background-color: #f0fffe; - border-radius: 4px; +.card-value.highlight { + color: #17b3a3; + font-weight: bold; + font-size: 12px; } .empty-labels {