From 020863d1ef8cdeadbdf8846ef87898f7fd7d3d96 Mon Sep 17 00:00:00 2001
From: Joshi <3040996759@qq.com>
Date: Sat, 30 May 2026 11:04:02 +0800
Subject: [PATCH 01/29] =?UTF-8?q?feat(qc):=20=E6=B7=BB=E5=8A=A0=E5=8C=96?=
=?UTF-8?q?=E5=AD=A6=E6=88=90=E5=88=86=E5=92=8C=E7=89=A9=E7=90=86=E6=80=A7?=
=?UTF-8?q?=E8=83=BD=E6=A3=80=E6=B5=8B=E5=AD=97=E6=AE=B5?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
- 在QcChemicalItem实体类中新增铝、钛、铬、镍、铜、氮、铁、硼等化学成分字段
- 在QcChemicalItemBo业务对象中同步添加对应的化学成分属性
- 更新QcChemicalItemMapper.xml映射文件以支持新字段的数据映射
- 在QcChemicalItemServiceImpl服务实现中添加新字段的查询条件支持
- 在QcChemicalItemVo视图对象中添加化学成分字段并配置Excel导出
- 在QcPhysicalItem实体类中新增规定塑性延伸强度、镀层表面结构、镀层重量等物理性能字段
- 在QcPhysicalItemBo业务对象中添加对应的物理性能属性
- 更新QcPhysicalItemMapper.xml映射文件以支持新的物理性能字段映射
- 在QcPhysicalItemServiceImpl服务实现中添加新物理性能字段的查询条件支持
- 在QcPhysicalItemVo视图对象中添加物理性能字段并配置Excel导出功能
---
.../com/klp/mes/qc/domain/QcChemicalItem.java | 32 +++++++++++++
.../com/klp/mes/qc/domain/QcPhysicalItem.java | 12 +++++
.../mes/qc/domain/bo/QcChemicalItemBo.java | 40 ++++++++++++++++
.../mes/qc/domain/bo/QcPhysicalItemBo.java | 15 ++++++
.../mes/qc/domain/vo/QcChemicalItemVo.java | 48 +++++++++++++++++++
.../mes/qc/domain/vo/QcPhysicalItemVo.java | 18 +++++++
.../impl/QcChemicalItemServiceImpl.java | 8 ++++
.../impl/QcPhysicalItemServiceImpl.java | 3 ++
.../mapper/qc/QcChemicalItemMapper.xml | 8 ++++
.../mapper/qc/QcPhysicalItemMapper.xml | 3 ++
10 files changed, 187 insertions(+)
diff --git a/klp-mes/src/main/java/com/klp/mes/qc/domain/QcChemicalItem.java b/klp-mes/src/main/java/com/klp/mes/qc/domain/QcChemicalItem.java
index f47e50f2..760e45ad 100644
--- a/klp-mes/src/main/java/com/klp/mes/qc/domain/QcChemicalItem.java
+++ b/klp-mes/src/main/java/com/klp/mes/qc/domain/QcChemicalItem.java
@@ -65,6 +65,38 @@ public class QcChemicalItem extends BaseEntity {
* 酸溶铝(%)
*/
private BigDecimal als;
+ /**
+ * 铝(%)
+ */
+ private BigDecimal al;
+ /**
+ * 钛(%)
+ */
+ private BigDecimal ti;
+ /**
+ * 铬(%)
+ */
+ private BigDecimal cr;
+ /**
+ * 镍(%)
+ */
+ private BigDecimal ni;
+ /**
+ * 铜(%)
+ */
+ private BigDecimal cu;
+ /**
+ * 氮(%)
+ */
+ private BigDecimal n;
+ /**
+ * 铁(%)
+ */
+ private BigDecimal fe;
+ /**
+ * 硼(%)
+ */
+ private BigDecimal b;
/**
* 备注
*/
diff --git a/klp-mes/src/main/java/com/klp/mes/qc/domain/QcPhysicalItem.java b/klp-mes/src/main/java/com/klp/mes/qc/domain/QcPhysicalItem.java
index 8cb93679..e44a5b51 100644
--- a/klp-mes/src/main/java/com/klp/mes/qc/domain/QcPhysicalItem.java
+++ b/klp-mes/src/main/java/com/klp/mes/qc/domain/QcPhysicalItem.java
@@ -41,6 +41,10 @@ public class QcPhysicalItem extends BaseEntity {
* 拉伸试验-屈服强度(MPa)
*/
private BigDecimal yieldStrength;
+ /**
+ * 规定塑性延伸强度(MPa)
+ */
+ private BigDecimal plasticExtensionStrength;
/**
* 拉伸试验-抗拉强度(MPa)
*/
@@ -65,6 +69,14 @@ public class QcPhysicalItem extends BaseEntity {
* 表面结构
*/
private String surfaceStructure;
+ /**
+ * 镀层表面结构
+ */
+ private String coatingSurfaceStructure;
+ /**
+ * 镀层重量 COATING MASS(g/m²)
+ */
+ private BigDecimal coatingMass;
/**
* 边缘状态
*/
diff --git a/klp-mes/src/main/java/com/klp/mes/qc/domain/bo/QcChemicalItemBo.java b/klp-mes/src/main/java/com/klp/mes/qc/domain/bo/QcChemicalItemBo.java
index 48a310da..33ddcb25 100644
--- a/klp-mes/src/main/java/com/klp/mes/qc/domain/bo/QcChemicalItemBo.java
+++ b/klp-mes/src/main/java/com/klp/mes/qc/domain/bo/QcChemicalItemBo.java
@@ -73,6 +73,46 @@ public class QcChemicalItemBo extends BaseEntity {
*/
private BigDecimal als;
+ /**
+ * 铝(%)
+ */
+ private BigDecimal al;
+
+ /**
+ * 钛(%)
+ */
+ private BigDecimal ti;
+
+ /**
+ * 铬(%)
+ */
+ private BigDecimal cr;
+
+ /**
+ * 镍(%)
+ */
+ private BigDecimal ni;
+
+ /**
+ * 铜(%)
+ */
+ private BigDecimal cu;
+
+ /**
+ * 氮(%)
+ */
+ private BigDecimal n;
+
+ /**
+ * 铁(%)
+ */
+ private BigDecimal fe;
+
+ /**
+ * 硼(%)
+ */
+ private BigDecimal b;
+
/**
* 备注
*/
diff --git a/klp-mes/src/main/java/com/klp/mes/qc/domain/bo/QcPhysicalItemBo.java b/klp-mes/src/main/java/com/klp/mes/qc/domain/bo/QcPhysicalItemBo.java
index e0e2e945..2e12e995 100644
--- a/klp-mes/src/main/java/com/klp/mes/qc/domain/bo/QcPhysicalItemBo.java
+++ b/klp-mes/src/main/java/com/klp/mes/qc/domain/bo/QcPhysicalItemBo.java
@@ -43,6 +43,11 @@ public class QcPhysicalItemBo extends BaseEntity {
*/
private BigDecimal yieldStrength;
+ /**
+ * 规定塑性延伸强度(MPa)
+ */
+ private BigDecimal plasticExtensionStrength;
+
/**
* 拉伸试验-抗拉强度(MPa)
*/
@@ -73,6 +78,16 @@ public class QcPhysicalItemBo extends BaseEntity {
*/
private String surfaceStructure;
+ /**
+ * 镀层表面结构
+ */
+ private String coatingSurfaceStructure;
+
+ /**
+ * 镀层重量 COATING MASS(g/m²)
+ */
+ private BigDecimal coatingMass;
+
/**
* 边缘状态
*/
diff --git a/klp-mes/src/main/java/com/klp/mes/qc/domain/vo/QcChemicalItemVo.java b/klp-mes/src/main/java/com/klp/mes/qc/domain/vo/QcChemicalItemVo.java
index db3ef9cb..378414eb 100644
--- a/klp-mes/src/main/java/com/klp/mes/qc/domain/vo/QcChemicalItemVo.java
+++ b/klp-mes/src/main/java/com/klp/mes/qc/domain/vo/QcChemicalItemVo.java
@@ -86,6 +86,54 @@ public class QcChemicalItemVo {
@ExcelProperty(value = "酸溶铝(%)")
private BigDecimal als;
+ /**
+ * 铝(%)
+ */
+ @ExcelProperty(value = "铝(%)")
+ private BigDecimal al;
+
+ /**
+ * 钛(%)
+ */
+ @ExcelProperty(value = "钛(%)")
+ private BigDecimal ti;
+
+ /**
+ * 铬(%)
+ */
+ @ExcelProperty(value = "铬(%)")
+ private BigDecimal cr;
+
+ /**
+ * 镍(%)
+ */
+ @ExcelProperty(value = "镍(%)")
+ private BigDecimal ni;
+
+ /**
+ * 铜(%)
+ */
+ @ExcelProperty(value = "铜(%)")
+ private BigDecimal cu;
+
+ /**
+ * 氮(%)
+ */
+ @ExcelProperty(value = "氮(%)")
+ private BigDecimal n;
+
+ /**
+ * 铁(%)
+ */
+ @ExcelProperty(value = "铁(%)")
+ private BigDecimal fe;
+
+ /**
+ * 硼(%)
+ */
+ @ExcelProperty(value = "硼(%)")
+ private BigDecimal b;
+
/**
* 备注
*/
diff --git a/klp-mes/src/main/java/com/klp/mes/qc/domain/vo/QcPhysicalItemVo.java b/klp-mes/src/main/java/com/klp/mes/qc/domain/vo/QcPhysicalItemVo.java
index 29853843..d79d5264 100644
--- a/klp-mes/src/main/java/com/klp/mes/qc/domain/vo/QcPhysicalItemVo.java
+++ b/klp-mes/src/main/java/com/klp/mes/qc/domain/vo/QcPhysicalItemVo.java
@@ -51,6 +51,12 @@ public class QcPhysicalItemVo {
@ExcelProperty(value = "拉伸试验-屈服强度(MPa)")
private BigDecimal yieldStrength;
+ /**
+ * 规定塑性延伸强度(MPa)
+ */
+ @ExcelProperty(value = "规定塑性延伸强度(MPa)")
+ private BigDecimal plasticExtensionStrength;
+
/**
* 拉伸试验-抗拉强度(MPa)
*/
@@ -87,6 +93,18 @@ public class QcPhysicalItemVo {
@ExcelProperty(value = "表面结构")
private String surfaceStructure;
+ /**
+ * 镀层表面结构
+ */
+ @ExcelProperty(value = "镀层表面结构")
+ private String coatingSurfaceStructure;
+
+ /**
+ * 镀层重量 COATING MASS(g/m²)
+ */
+ @ExcelProperty(value = "镀层重量 COATING MASS(g/m²)")
+ private BigDecimal coatingMass;
+
/**
* 边缘状态
*/
diff --git a/klp-mes/src/main/java/com/klp/mes/qc/service/impl/QcChemicalItemServiceImpl.java b/klp-mes/src/main/java/com/klp/mes/qc/service/impl/QcChemicalItemServiceImpl.java
index fbb2e8a3..fb48378f 100644
--- a/klp-mes/src/main/java/com/klp/mes/qc/service/impl/QcChemicalItemServiceImpl.java
+++ b/klp-mes/src/main/java/com/klp/mes/qc/service/impl/QcChemicalItemServiceImpl.java
@@ -79,6 +79,14 @@ public class QcChemicalItemServiceImpl implements IQcChemicalItemService {
lqw.eq(bo.getP() != null, QcChemicalItem::getP, bo.getP());
lqw.eq(bo.getS() != null, QcChemicalItem::getS, bo.getS());
lqw.eq(bo.getAls() != null, QcChemicalItem::getAls, bo.getAls());
+ lqw.eq(bo.getAl() != null, QcChemicalItem::getAl, bo.getAl());
+ lqw.eq(bo.getTi() != null, QcChemicalItem::getTi, bo.getTi());
+ lqw.eq(bo.getCr() != null, QcChemicalItem::getCr, bo.getCr());
+ lqw.eq(bo.getNi() != null, QcChemicalItem::getNi, bo.getNi());
+ lqw.eq(bo.getCu() != null, QcChemicalItem::getCu, bo.getCu());
+ lqw.eq(bo.getN() != null, QcChemicalItem::getN, bo.getN());
+ lqw.eq(bo.getFe() != null, QcChemicalItem::getFe, bo.getFe());
+ lqw.eq(bo.getB() != null, QcChemicalItem::getB, bo.getB());
// 根据创建时间倒叙
lqw.orderByDesc(QcChemicalItem::getCreateTime);
return lqw;
diff --git a/klp-mes/src/main/java/com/klp/mes/qc/service/impl/QcPhysicalItemServiceImpl.java b/klp-mes/src/main/java/com/klp/mes/qc/service/impl/QcPhysicalItemServiceImpl.java
index 44f12e69..c18ee318 100644
--- a/klp-mes/src/main/java/com/klp/mes/qc/service/impl/QcPhysicalItemServiceImpl.java
+++ b/klp-mes/src/main/java/com/klp/mes/qc/service/impl/QcPhysicalItemServiceImpl.java
@@ -73,12 +73,15 @@ public class QcPhysicalItemServiceImpl implements IQcPhysicalItemService {
lqw.eq(bo.getCoilId() != null, QcPhysicalItem::getCoilId, bo.getCoilId());
lqw.eq(StringUtils.isNotBlank(bo.getCoilNo()), QcPhysicalItem::getCoilNo, bo.getCoilNo());
lqw.eq(bo.getYieldStrength() != null, QcPhysicalItem::getYieldStrength, bo.getYieldStrength());
+ lqw.eq(bo.getPlasticExtensionStrength() != null, QcPhysicalItem::getPlasticExtensionStrength, bo.getPlasticExtensionStrength());
lqw.eq(bo.getTensileStrength() != null, QcPhysicalItem::getTensileStrength, bo.getTensileStrength());
lqw.eq(bo.getElongation() != null, QcPhysicalItem::getElongation, bo.getElongation());
lqw.eq(bo.getHardness() != null, QcPhysicalItem::getHardness, bo.getHardness());
lqw.eq(StringUtils.isNotBlank(bo.getBendingTest()), QcPhysicalItem::getBendingTest, bo.getBendingTest());
lqw.eq(StringUtils.isNotBlank(bo.getSurfaceQuality()), QcPhysicalItem::getSurfaceQuality, bo.getSurfaceQuality());
lqw.eq(StringUtils.isNotBlank(bo.getSurfaceStructure()), QcPhysicalItem::getSurfaceStructure, bo.getSurfaceStructure());
+ lqw.eq(StringUtils.isNotBlank(bo.getCoatingSurfaceStructure()), QcPhysicalItem::getCoatingSurfaceStructure, bo.getCoatingSurfaceStructure());
+ lqw.eq(bo.getCoatingMass() != null, QcPhysicalItem::getCoatingMass, bo.getCoatingMass());
lqw.eq(StringUtils.isNotBlank(bo.getEdgeStatus()), QcPhysicalItem::getEdgeStatus, bo.getEdgeStatus());
// 根据创建时间倒叙
lqw.orderByDesc(QcPhysicalItem::getCreateTime);
diff --git a/klp-mes/src/main/resources/mapper/qc/QcChemicalItemMapper.xml b/klp-mes/src/main/resources/mapper/qc/QcChemicalItemMapper.xml
index efed952b..283985aa 100644
--- a/klp-mes/src/main/resources/mapper/qc/QcChemicalItemMapper.xml
+++ b/klp-mes/src/main/resources/mapper/qc/QcChemicalItemMapper.xml
@@ -16,6 +16,14 @@
+
+
+
+
+
+
+
+
diff --git a/klp-mes/src/main/resources/mapper/qc/QcPhysicalItemMapper.xml b/klp-mes/src/main/resources/mapper/qc/QcPhysicalItemMapper.xml
index 5f6b932e..6122459b 100644
--- a/klp-mes/src/main/resources/mapper/qc/QcPhysicalItemMapper.xml
+++ b/klp-mes/src/main/resources/mapper/qc/QcPhysicalItemMapper.xml
@@ -10,12 +10,15 @@
+
+
+
From 91d1236c37e420b2573beb6faa8f368362405fb4 Mon Sep 17 00:00:00 2001
From: Joshi <3040996759@qq.com>
Date: Sat, 30 May 2026 13:44:31 +0800
Subject: [PATCH 02/29] =?UTF-8?q?feat(cost):=20=E4=B8=BA=E6=88=90=E6=9C=AC?=
=?UTF-8?q?=E9=A1=B9=E6=96=B0=E5=A2=9E=E6=9F=A5=E8=AF=A2=E6=9D=A1=E4=BB=B6?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
- 在CostItem实体类、Bo业务对象和Vo视图对象中新增queryCondition字段,用于存储JSON格式的查询条件
- 更新CostItemMapper.xml映射文件以支持新字段的数据映射
- 在CostItemServiceImpl服务实现中添加新字段的查询条件支持,实现按查询条件过滤成本项的功能
---
klp-cost/src/main/java/com/klp/cost/domain/CostItem.java | 4 ++++
.../src/main/java/com/klp/cost/domain/bo/CostItemBo.java | 5 +++++
.../src/main/java/com/klp/cost/domain/vo/CostItemVo.java | 6 ++++++
.../java/com/klp/cost/service/impl/CostItemServiceImpl.java | 1 +
klp-cost/src/main/resources/mapper/cost/CostItemMapper.xml | 1 +
5 files changed, 17 insertions(+)
diff --git a/klp-cost/src/main/java/com/klp/cost/domain/CostItem.java b/klp-cost/src/main/java/com/klp/cost/domain/CostItem.java
index c8f8bb3e..fcbc32c0 100644
--- a/klp-cost/src/main/java/com/klp/cost/domain/CostItem.java
+++ b/klp-cost/src/main/java/com/klp/cost/domain/CostItem.java
@@ -44,6 +44,10 @@ public class CostItem extends BaseEntity {
* 备注
*/
private String remark;
+ /**
+ * 查询条件(JSON格式)
+ */
+ private String queryCondition;
/**
* 删除标识 0=正常 2=删除
*/
diff --git a/klp-cost/src/main/java/com/klp/cost/domain/bo/CostItemBo.java b/klp-cost/src/main/java/com/klp/cost/domain/bo/CostItemBo.java
index f1cc05dc..25d1cf3b 100644
--- a/klp-cost/src/main/java/com/klp/cost/domain/bo/CostItemBo.java
+++ b/klp-cost/src/main/java/com/klp/cost/domain/bo/CostItemBo.java
@@ -47,5 +47,10 @@ public class CostItemBo extends BaseEntity {
*/
private String remark;
+ /**
+ * 查询条件(JSON格式)
+ */
+ private String queryCondition;
+
}
diff --git a/klp-cost/src/main/java/com/klp/cost/domain/vo/CostItemVo.java b/klp-cost/src/main/java/com/klp/cost/domain/vo/CostItemVo.java
index c2f29d4c..d7aa837e 100644
--- a/klp-cost/src/main/java/com/klp/cost/domain/vo/CostItemVo.java
+++ b/klp-cost/src/main/java/com/klp/cost/domain/vo/CostItemVo.java
@@ -55,5 +55,11 @@ public class CostItemVo {
@ExcelProperty(value = "备注")
private String remark;
+ /**
+ * 查询条件(JSON格式)
+ */
+ @ExcelProperty(value = "查询条件(JSON格式)")
+ private String queryCondition;
+
}
diff --git a/klp-cost/src/main/java/com/klp/cost/service/impl/CostItemServiceImpl.java b/klp-cost/src/main/java/com/klp/cost/service/impl/CostItemServiceImpl.java
index 437ff716..ff2bb8d4 100644
--- a/klp-cost/src/main/java/com/klp/cost/service/impl/CostItemServiceImpl.java
+++ b/klp-cost/src/main/java/com/klp/cost/service/impl/CostItemServiceImpl.java
@@ -65,6 +65,7 @@ public class CostItemServiceImpl implements ICostItemService {
lqw.like(StringUtils.isNotBlank(bo.getItemName()), CostItem::getItemName, bo.getItemName());
lqw.eq(StringUtils.isNotBlank(bo.getCategory()), CostItem::getCategory, bo.getCategory());
lqw.eq(StringUtils.isNotBlank(bo.getUnit()), CostItem::getUnit, bo.getUnit());
+ lqw.eq(StringUtils.isNotBlank(bo.getQueryCondition()), CostItem::getQueryCondition, bo.getQueryCondition());
return lqw;
}
diff --git a/klp-cost/src/main/resources/mapper/cost/CostItemMapper.xml b/klp-cost/src/main/resources/mapper/cost/CostItemMapper.xml
index fe2965c4..c2b63d28 100644
--- a/klp-cost/src/main/resources/mapper/cost/CostItemMapper.xml
+++ b/klp-cost/src/main/resources/mapper/cost/CostItemMapper.xml
@@ -11,6 +11,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
+
From 6044413384009fa763894246c4d9075280b0cd7b Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?=E7=A0=82=E7=B3=96?= <2178503051@qq.com>
Date: Sat, 30 May 2026 14:31:20 +0800
Subject: [PATCH 03/29] =?UTF-8?q?fix(wms):=20=E7=BB=9F=E4=B8=80=E5=8F=91?=
=?UTF-8?q?=E8=B4=A7=E5=8D=95=E5=AF=BC=E5=87=BA=E9=80=BB=E8=BE=91=E5=B9=B6?=
=?UTF-8?q?=E4=BF=AE=E5=A4=8D=E5=BC=B9=E7=AA=97=E6=8B=A6=E6=88=AA=E9=97=AE?=
=?UTF-8?q?=E9=A2=98?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
1. 替换原有的window.open弹窗导出为a标签下载,解决浏览器拦截弹窗的问题
2. 统一使用Date.now()替代new Date().getTime()优化代码
3. 新增释放URL对象的代码避免内存泄漏
4. 调整线圈页面批量移出发货单按钮的显示条件
---
klp-ui/src/views/wms/coil/panels/base.vue | 2 +-
.../wms/delivery/components/DugeWayBill1.vue | 17 +++++++----------
.../wms/delivery/components/DugeWayBill2.vue | 17 +++++++----------
.../wms/delivery/components/ZincWayBill1.vue | 17 +++++++----------
.../views/wms/delivery/components/wayBill.vue | 17 +++++++----------
.../views/wms/delivery/components/wayBill2.vue | 17 +++++++----------
6 files changed, 36 insertions(+), 51 deletions(-)
diff --git a/klp-ui/src/views/wms/coil/panels/base.vue b/klp-ui/src/views/wms/coil/panels/base.vue
index e5c49d1d..c2c86195 100644
--- a/klp-ui/src/views/wms/coil/panels/base.vue
+++ b/klp-ui/src/views/wms/coil/panels/base.vue
@@ -103,7 +103,7 @@
搜索
重置
导出
- 批量移出发货单
diff --git a/klp-ui/src/views/wms/delivery/components/DugeWayBill1.vue b/klp-ui/src/views/wms/delivery/components/DugeWayBill1.vue
index 3c97c812..ba9217ad 100644
--- a/klp-ui/src/views/wms/delivery/components/DugeWayBill1.vue
+++ b/klp-ui/src/views/wms/delivery/components/DugeWayBill1.vue
@@ -477,16 +477,13 @@ export default {
const blob = new Blob([pdfBytes], { type: 'application/pdf' });
const url = URL.createObjectURL(blob);
- const win = window.open(url, '_blank');
- if (!win) {
- this.$message.error('打印失败,请检查浏览器设置');
- // const a = document.createElement('a');
- // a.href = url;
- // a.download = `发货单_${this.waybill.waybillName || this.waybill.waybillNo || new Date().getTime()}.pdf`;
- // document.body.appendChild(a);
- // a.click();
- // document.body.removeChild(a);
- }
+ const a = document.createElement('a');
+ a.href = url;
+ a.download = `发货单_${this.waybill.waybillName || this.waybill.waybillNo || Date.now()}.pdf`;
+ document.body.appendChild(a);
+ a.click();
+ document.body.removeChild(a);
+ URL.revokeObjectURL(url);
},
async exportExcel() {
try {
diff --git a/klp-ui/src/views/wms/delivery/components/DugeWayBill2.vue b/klp-ui/src/views/wms/delivery/components/DugeWayBill2.vue
index 12281830..ecded388 100644
--- a/klp-ui/src/views/wms/delivery/components/DugeWayBill2.vue
+++ b/klp-ui/src/views/wms/delivery/components/DugeWayBill2.vue
@@ -475,16 +475,13 @@ export default {
const blob = new Blob([pdfBytes], { type: 'application/pdf' });
const url = URL.createObjectURL(blob);
- const win = window.open(url, '_blank');
- if (!win) {
- this.$message.error('打印失败,请检查浏览器设置');
- // const a = document.createElement('a');
- // a.href = url;
- // a.download = `发货单_${this.waybill.waybillName || this.waybill.waybillNo || new Date().getTime()}.pdf`;
- // document.body.appendChild(a);
- // a.click();
- // document.body.removeChild(a);
- }
+ const a = document.createElement('a');
+ a.href = url;
+ a.download = `发货单_${this.waybill.waybillName || this.waybill.waybillNo || Date.now()}.pdf`;
+ document.body.appendChild(a);
+ a.click();
+ document.body.removeChild(a);
+ URL.revokeObjectURL(url);
},
async exportExcel() {
try {
diff --git a/klp-ui/src/views/wms/delivery/components/ZincWayBill1.vue b/klp-ui/src/views/wms/delivery/components/ZincWayBill1.vue
index a29d9d7d..c40e9d26 100644
--- a/klp-ui/src/views/wms/delivery/components/ZincWayBill1.vue
+++ b/klp-ui/src/views/wms/delivery/components/ZincWayBill1.vue
@@ -477,16 +477,13 @@ export default {
const blob = new Blob([pdfBytes], { type: 'application/pdf' });
const url = URL.createObjectURL(blob);
- const win = window.open(url, '_blank');
- if (!win) {
- this.$message.error('打印失败,请检查浏览器设置');
- // const a = document.createElement('a');
- // a.href = url;
- // a.download = `发货单_${this.waybill.waybillName || this.waybill.waybillNo || new Date().getTime()}.pdf`;
- // document.body.appendChild(a);
- // a.click();
- // document.body.removeChild(a);
- }
+ const a = document.createElement('a');
+ a.href = url;
+ a.download = `发货单_${this.waybill.waybillName || this.waybill.waybillNo || Date.now()}.pdf`;
+ document.body.appendChild(a);
+ a.click();
+ document.body.removeChild(a);
+ URL.revokeObjectURL(url);
},
async exportExcel() {
try {
diff --git a/klp-ui/src/views/wms/delivery/components/wayBill.vue b/klp-ui/src/views/wms/delivery/components/wayBill.vue
index 4d61c7ea..80445ca5 100644
--- a/klp-ui/src/views/wms/delivery/components/wayBill.vue
+++ b/klp-ui/src/views/wms/delivery/components/wayBill.vue
@@ -476,16 +476,13 @@ export default {
const blob = new Blob([pdfBytes], { type: 'application/pdf' });
const url = URL.createObjectURL(blob);
- const win = window.open(url, '_blank');
- if (!win) {
- this.$message.error('打印失败,请检查浏览器设置');
- // const a = document.createElement('a');
- // a.href = url;
- // a.download = `发货单_${this.waybill.waybillName || this.waybill.waybillNo || new Date().getTime()}.pdf`;
- // document.body.appendChild(a);
- // a.click();
- // document.body.removeChild(a);
- }
+ const a = document.createElement('a');
+ a.href = url;
+ a.download = `发货单_${this.waybill.waybillName || this.waybill.waybillNo || Date.now()}.pdf`;
+ document.body.appendChild(a);
+ a.click();
+ document.body.removeChild(a);
+ URL.revokeObjectURL(url);
},
async exportExcelByXLSX() {
try {
diff --git a/klp-ui/src/views/wms/delivery/components/wayBill2.vue b/klp-ui/src/views/wms/delivery/components/wayBill2.vue
index d6ba5d21..40d256cd 100644
--- a/klp-ui/src/views/wms/delivery/components/wayBill2.vue
+++ b/klp-ui/src/views/wms/delivery/components/wayBill2.vue
@@ -475,16 +475,13 @@ export default {
const blob = new Blob([pdfBytes], { type: 'application/pdf' });
const url = URL.createObjectURL(blob);
- const win = window.open(url, '_blank');
- if (!win) {
- this.$message.error('打印失败,请检查浏览器设置');
- // const a = document.createElement('a');
- // a.href = url;
- // a.download = `发货单_${this.waybill.waybillName || this.waybill.waybillNo || new Date().getTime()}.pdf`;
- // document.body.appendChild(a);
- // a.click();
- // document.body.removeChild(a);
- }
+ const a = document.createElement('a');
+ a.href = url;
+ a.download = `发货单_${this.waybill.waybillName || this.waybill.waybillNo || Date.now()}.pdf`;
+ document.body.appendChild(a);
+ a.click();
+ document.body.removeChild(a);
+ URL.revokeObjectURL(url);
},
async exportExcelByXLSX() {
try {
From 6a5220ad787442856ae9a57106368ba24e18957c Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?=E7=A0=82=E7=B3=96?= <2178503051@qq.com>
Date: Sat, 30 May 2026 15:05:43 +0800
Subject: [PATCH 04/29] =?UTF-8?q?feat(mes/roll/grind):=20=E5=A2=9E?=
=?UTF-8?q?=E5=8A=A0=E5=8E=82=E5=AE=B6=E6=90=9C=E7=B4=A2=E7=AD=9B=E9=80=89?=
=?UTF-8?q?=E5=92=8CCR=E7=B1=BB=E5=9E=8B=E9=80=89=E9=A1=B9?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
1. 新增厂家搜索输入框和筛选逻辑
2. 新增CR类型的单选筛选按钮
3. 在辊子列表中展示厂家信息
4. 优化有效当前辊径的默认返回逻辑
---
klp-ui/src/views/mes/roll/grind/index.vue | 17 +++++++++++++----
1 file changed, 13 insertions(+), 4 deletions(-)
diff --git a/klp-ui/src/views/mes/roll/grind/index.vue b/klp-ui/src/views/mes/roll/grind/index.vue
index 51d66b9a..179a738b 100644
--- a/klp-ui/src/views/mes/roll/grind/index.vue
+++ b/klp-ui/src/views/mes/roll/grind/index.vue
@@ -27,10 +27,13 @@
+
全部
WR
BR
+ CR
@@ -47,6 +50,7 @@
{{ statusLabel(r.status) }}
φ{{ r.currentDia != null ? r.currentDia : r.initialDia }}
+ {{ r.manufacturer }}
{{ r.lineName }}
暂无数据
@@ -260,6 +264,7 @@ export default {
filteredRolls: [],
filterNo: '',
filterType: '',
+ filterManufacturer: '',
// 右侧选中辊
selectedRollId: null,
@@ -301,9 +306,9 @@ export default {
// 有效当前辊径:优先取 currentDia,无则取最新磨削记录的磨后径
effectiveCurrentDia() {
- if (this.selectedRoll && this.selectedRoll.currentDia != null) {
- return parseFloat(this.selectedRoll.currentDia)
- }
+ // if (this.selectedRoll && this.selectedRoll.currentDia != null) {
+ // return parseFloat(this.selectedRoll.currentDia)
+ // }
if (this.grindList.length > 0) {
const latest = [...this.grindList].sort((a, b) => {
const ta = a.grindTime ? new Date(a.grindTime).getTime() : 0
@@ -311,6 +316,8 @@ export default {
return tb - ta
})[0]
if (latest && latest.diaAfter != null) return parseFloat(latest.diaAfter)
+ } else {
+ return null
}
return null
},
@@ -363,7 +370,8 @@ export default {
this.filteredRolls = this.allRolls.filter(r => {
const matchNo = !this.filterNo || r.rollNo.includes(this.filterNo)
const matchType = !this.filterType || r.rollType === this.filterType
- return matchNo && matchType
+ const matchMfr = !this.filterManufacturer || (r.manufacturer || '').toLowerCase().includes(this.filterManufacturer.toLowerCase())
+ return matchNo && matchType && matchMfr
})
},
selectRoll(r) {
@@ -545,6 +553,7 @@ export default {
.ri-no { font-family: 'Consolas', monospace; font-size: 13px; font-weight: 600; color: #1f2329; }
.ri-meta { display: flex; align-items: center; gap: 6px; margin-top: 3px; }
.ri-dia { font-size: 11px; color: #9aa0a6; }
+.ri-manufacturer { font-size: 10px; color: #909399; margin-top: 2px; }
.ri-line { font-size: 10px; color: #b0b3bb; margin-top: 2px; }
.ri-status { font-size: 11px; }
.roll-empty { text-align: center; color: #c0c4cc; padding: 20px 0; font-size: 12px; }
From 62da44382a4f17fc426fff00ab5ddb3fb49bc8ad Mon Sep 17 00:00:00 2001
From: Joshi <3040996759@qq.com>
Date: Sat, 30 May 2026 17:38:13 +0800
Subject: [PATCH 05/29] =?UTF-8?q?fix(wms/attendance):=20=E4=BC=98=E5=8C=96?=
=?UTF-8?q?=E5=8D=88=E4=BC=91=E6=89=93=E5=8D=A1=E6=A8=A1=E5=BC=8F=E8=AF=86?=
=?UTF-8?q?=E5=88=AB=E9=80=BB=E8=BE=91?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
1. 重构打卡记录分割逻辑,将原简单中值法改为基于时间区间和间隔检测的智能分割
2. 新增午休打卡模式检测:支持区间内长间隔、提前下班+午饭回来、午休晚归三种场景识别
3. 当检测到午休打卡模式时,按实际打卡间隔进行合理分割;未检测到时回退使用原中值法
4. 提升考勤统计的准确性,避免因午休打卡时间分布不均导致的上下班时段误判
---
.../impl/WmsAttendanceCheckServiceImpl.java | 91 +++++++++++++++++--
1 file changed, 82 insertions(+), 9 deletions(-)
diff --git a/klp-wms/src/main/java/com/klp/service/impl/WmsAttendanceCheckServiceImpl.java b/klp-wms/src/main/java/com/klp/service/impl/WmsAttendanceCheckServiceImpl.java
index d1c51848..dfd4f3df 100644
--- a/klp-wms/src/main/java/com/klp/service/impl/WmsAttendanceCheckServiceImpl.java
+++ b/klp-wms/src/main/java/com/klp/service/impl/WmsAttendanceCheckServiceImpl.java
@@ -386,18 +386,91 @@ public class WmsAttendanceCheckServiceImpl implements IWmsAttendanceCheckService
if (hasPeriod2) {
LocalTime p1End = toLocalTime(schedule.getShiftEndTime());
LocalTime p2Start = toLocalTime(schedule.getShiftStartTime2());
- LocalTime split = LocalTime.of(
- (p1End.getHour() + p2Start.getHour()) / 2,
- (p1End.getMinute() + p2Start.getMinute()) / 2);
+
+ // 按理论时间范围分割:p1End之前、中间区间、p2Start之后
+ List beforeGap = new ArrayList<>();
+ List inGap = new ArrayList<>();
+ List afterGap = new ArrayList<>();
+ for (AttendanceRecords r : records) {
+ LocalTime t = toLocalDateTime(r.getChecktime()).toLocalTime();
+ if (!t.isAfter(p1End)) {
+ beforeGap.add(r);
+ } else if (!t.isBefore(p2Start)) {
+ afterGap.add(r);
+ } else {
+ inGap.add(r);
+ }
+ }
List p1Records = new ArrayList<>();
List p2Records = new ArrayList<>();
- for (AttendanceRecords r : records) {
- LocalTime t = toLocalDateTime(r.getChecktime()).toLocalTime();
- if (t.isBefore(split)) {
- p1Records.add(r);
- } else {
- p2Records.add(r);
+ boolean lunchPatternFound = false;
+
+ // 检测[p1End, p2Start]区间内是否有午休打卡(取最远两条判断>10分钟,按最大连续间隔切开)
+ if (inGap.size() >= 2) {
+ LocalDateTime firstInGap = toLocalDateTime(inGap.get(0).getChecktime());
+ LocalDateTime lastInGap = toLocalDateTime(inGap.get(inGap.size() - 1).getChecktime());
+ if (Duration.between(firstInGap, lastInGap).getSeconds() > 600) {
+ int splitIdx = 0;
+ long maxGap = 0;
+ for (int i = 0; i < inGap.size() - 1; i++) {
+ LocalDateTime t1 = toLocalDateTime(inGap.get(i).getChecktime());
+ LocalDateTime t2 = toLocalDateTime(inGap.get(i + 1).getChecktime());
+ long gap = Duration.between(t1, t2).getSeconds();
+ if (gap > maxGap) {
+ maxGap = gap;
+ splitIdx = i;
+ }
+ if (gap > 600) {
+ break;
+ }
+ }
+ p1Records = new ArrayList<>(beforeGap);
+ p1Records.addAll(inGap.subList(0, splitIdx + 1));
+ p2Records = new ArrayList<>(inGap.subList(splitIdx + 1, inGap.size()));
+ p2Records.addAll(afterGap);
+ lunchPatternFound = true;
+ }
+ }
+
+ // 检测边界:beforeGap最后一条 与 inGap第一条 间隔>10分钟(提前下班+午饭回来)
+ if (!lunchPatternFound && !beforeGap.isEmpty() && !inGap.isEmpty()) {
+ LocalDateTime lastBefore = toLocalDateTime(beforeGap.get(beforeGap.size() - 1).getChecktime());
+ LocalDateTime firstIn = toLocalDateTime(inGap.get(0).getChecktime());
+ if (Duration.between(lastBefore, firstIn).getSeconds() > 600) {
+ p1Records = new ArrayList<>(beforeGap);
+ p2Records = new ArrayList<>(inGap);
+ p2Records.addAll(afterGap);
+ lunchPatternFound = true;
+ }
+ }
+
+ // 检测边界:inGap最后一条 与 afterGap第一条 间隔>10分钟(午休晚归)
+ if (!lunchPatternFound && !inGap.isEmpty() && !afterGap.isEmpty()) {
+ LocalDateTime lastIn = toLocalDateTime(inGap.get(inGap.size() - 1).getChecktime());
+ LocalDateTime firstAfter = toLocalDateTime(afterGap.get(0).getChecktime());
+ if (Duration.between(lastIn, firstAfter).getSeconds() > 600) {
+ p1Records = new ArrayList<>(beforeGap);
+ p1Records.addAll(inGap);
+ p2Records = new ArrayList<>(afterGap);
+ lunchPatternFound = true;
+ }
+ }
+
+ if (!lunchPatternFound) {
+ // 没有午休打卡模式,回退原中值法
+ LocalTime split = LocalTime.of(
+ (p1End.getHour() + p2Start.getHour()) / 2,
+ (p1End.getMinute() + p2Start.getMinute()) / 2);
+ p1Records = new ArrayList<>();
+ p2Records = new ArrayList<>();
+ for (AttendanceRecords r : records) {
+ LocalTime t = toLocalDateTime(r.getChecktime()).toLocalTime();
+ if (t.isBefore(split)) {
+ p1Records.add(r);
+ } else {
+ p2Records.add(r);
+ }
}
}
From 9af5284ff3a1d7c02ff4f0483d839ad4d0a19e47 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?=E7=A0=82=E7=B3=96?= <2178503051@qq.com>
Date: Sat, 30 May 2026 18:00:01 +0800
Subject: [PATCH 06/29] =?UTF-8?q?feat:=20=E5=A4=9A=E9=A1=B5=E9=9D=A2?=
=?UTF-8?q?=E5=8A=9F=E8=83=BD=E4=BC=98=E5=8C=96=E4=B8=8E=E6=96=B0=E5=A2=9E?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
klp-ui/src/views/cost/item.vue | 48 ++++++++++--
.../views/mes/qc/certificate/chemistry.vue | 74 +++++++++++++++++--
.../src/views/mes/qc/certificate/physics.vue | 42 +++++++++--
klp-ui/src/views/wms/coil/panels/base.vue | 8 +-
.../wms/delivery/components/DugeWayBill1.vue | 3 +-
.../wms/delivery/components/DugeWayBill2.vue | 3 +-
.../wms/delivery/components/ZincWayBill1.vue | 3 +-
.../wms/delivery/components/ZincWayBill2.vue | 21 +++---
.../views/wms/delivery/components/wayBill.vue | 3 +-
.../wms/delivery/components/wayBill2.vue | 3 +-
10 files changed, 172 insertions(+), 36 deletions(-)
diff --git a/klp-ui/src/views/cost/item.vue b/klp-ui/src/views/cost/item.vue
index 6cf80dcc..aacacbad 100644
--- a/klp-ui/src/views/cost/item.vue
+++ b/klp-ui/src/views/cost/item.vue
@@ -17,13 +17,22 @@
@keyup.enter.native="handleQuery"
/>
-
-
+
+ @change="handleQuery"
+ >
+
+
+
+
+
+
+
+
+
+
+
+
搜索
重置
@@ -86,9 +103,10 @@
-
+
+
-
-
+
+
+
+
+
+
+
+
+
+
+
@@ -133,6 +160,9 @@
+
+
+
@@ -264,7 +304,7 @@ import { listChemicalItem, getChemicalItem, delChemicalItem, addChemicalItem, up
import CoilSelector from "@/components/CoilSelector";
import { listMaterialCoil } from "@/api/wms/coil";
-const CHEMI_TEMPLATE_HEADERS = ['入场钢卷号', 'C(%)', 'Si(%)', 'Mn(%)', 'P(%)', 'S(%)', 'Als(%)'];
+const CHEMI_TEMPLATE_HEADERS = ['入场钢卷号', 'C(%)', 'Si(%)', 'Mn(%)', 'P(%)', 'S(%)', 'Als(%)', 'Al(%)', 'Ti(%)', 'Cr(%)', 'Ni(%)', 'Cu(%)', 'N(%)', 'Fe(%)', 'B(%)'];
const CHEMI_HEADER_MAP = {
'入场钢卷号': 'coilNo',
@@ -273,7 +313,15 @@ const CHEMI_HEADER_MAP = {
'Mn(%)': 'mn',
'P(%)': 'p',
'S(%)': 's',
- 'Als(%)': 'als'
+ 'Als(%)': 'als',
+ 'Al(%)': 'al',
+ 'Ti(%)': 'ti',
+ 'Cr(%)': 'cr',
+ 'Ni(%)': 'ni',
+ 'Cu(%)': 'cu',
+ 'N(%)': 'n',
+ 'Fe(%)': 'fe',
+ 'B(%)': 'b'
};
export default {
@@ -316,6 +364,14 @@ export default {
p: undefined,
s: undefined,
als: undefined,
+ al: undefined,
+ ti: undefined,
+ cr: undefined,
+ ni: undefined,
+ cu: undefined,
+ n: undefined,
+ fe: undefined,
+ b: undefined,
},
// 表单参数
form: {},
@@ -372,6 +428,14 @@ export default {
p: undefined,
s: undefined,
als: undefined,
+ al: undefined,
+ ti: undefined,
+ cr: undefined,
+ ni: undefined,
+ cu: undefined,
+ n: undefined,
+ fe: undefined,
+ b: undefined,
remark: undefined,
delFlag: undefined,
createTime: undefined,
@@ -523,7 +587,7 @@ export default {
try {
const payload = rows.map(row => {
const item = { coilId: null, coilNo: row.coilNo };
- ['c','si','mn','p','s','als'].forEach(f => { if (row[f]) item[f] = row[f]; });
+ ['c','si','mn','p','s','als','al','ti','cr','ni','cu','n','fe','b'].forEach(f => { if (row[f]) item[f] = row[f]; });
return item;
});
const addRes = await batchAddChemicalItem(payload);
@@ -553,10 +617,10 @@ export default {
this.$refs.importUpload?.clearFiles();
},
importDownloadTemplate() {
- const data = [CHEMI_TEMPLATE_HEADERS, ['示例卷号', '0.05', '0.02', '0.30', '0.015', '0.008', '0.040']];
+ const data = [CHEMI_TEMPLATE_HEADERS, ['示例卷号', '0.05', '0.02', '0.30', '0.015', '0.008', '0.040', '0.04', '0.05', '0.03', '0.02', '0.03', '0.005', '98', '0.001']];
const wb = XLSX.utils.book_new();
const ws = XLSX.utils.aoa_to_sheet(data);
- ws['!cols'] = [{ wch: 16 }, { wch: 8 }, { wch: 8 }, { wch: 8 }, { wch: 8 }, { wch: 8 }, { wch: 8 }];
+ ws['!cols'] = [{ wch: 16 }, { wch: 8 }, { wch: 8 }, { wch: 8 }, { wch: 8 }, { wch: 8 }, { wch: 8 }, { wch: 8 }, { wch: 8 }, { wch: 8 }, { wch: 8 }, { wch: 8 }, { wch: 8 }, { wch: 8 }, { wch: 8 }];
XLSX.utils.book_append_sheet(wb, ws, '导入模板');
XLSX.writeFile(wb, '化学成分导入模板.xlsx');
},
diff --git a/klp-ui/src/views/mes/qc/certificate/physics.vue b/klp-ui/src/views/mes/qc/certificate/physics.vue
index 4cfd5e18..f8d9479c 100644
--- a/klp-ui/src/views/mes/qc/certificate/physics.vue
+++ b/klp-ui/src/views/mes/qc/certificate/physics.vue
@@ -65,6 +65,14 @@
@keyup.enter.native="handleQuery"
/>
+
+
+
搜索
重置
@@ -135,10 +143,13 @@
+
+
+
@@ -189,9 +200,15 @@
+
+
+
+
+
+
@@ -201,6 +218,9 @@
+
+
+
@@ -269,10 +289,13 @@
+
+
+
@@ -320,8 +343,8 @@ import CoilSelector from "@/components/CoilSelector";
import { listMaterialCoil } from "@/api/wms/coil";
const PHYS_TEMPLATE_HEADERS = [
- '当前钢卷号', '屈服强度(MPa)', '抗拉强度(MPa)', '伸长率(%)', '硬度(HRB)', '弯曲试验',
- '表面质量', '表面结构', '边缘状态'
+ '当前钢卷号', '屈服强度(MPa)', '抗拉强度(MPa)', '伸长率(%)', '规定塑性延伸强度(MPa)', '硬度(HRB)',
+ '镀层重量(g/m²)', '弯曲试验', '表面质量', '表面结构', '镀层表面结构', '边缘状态'
];
const PHYS_HEADER_MAP = {
@@ -329,10 +352,13 @@ const PHYS_HEADER_MAP = {
'屈服强度(MPa)': 'yieldStrength',
'抗拉强度(MPa)': 'tensileStrength',
'伸长率(%)': 'elongation',
+ '规定塑性延伸强度(MPa)': 'plasticExtensionStrength',
'硬度(HRB)': 'hardness',
+ '镀层重量(g/m²)': 'coatingMass',
'弯曲试验': 'bendingTest',
'表面质量': 'surfaceQuality',
'表面结构': 'surfaceStructure',
+ '镀层表面结构': 'coatingSurfaceStructure',
'边缘状态': 'edgeStatus'
};
@@ -372,10 +398,13 @@ export default {
yieldStrength: undefined,
tensileStrength: undefined,
elongation: undefined,
+ plasticExtensionStrength: undefined,
hardness: undefined,
+ coatingMass: undefined,
bendingTest: undefined,
surfaceQuality: undefined,
surfaceStructure: undefined,
+ coatingSurfaceStructure: undefined,
edgeStatus: undefined,
},
// 表单参数
@@ -429,10 +458,13 @@ export default {
yieldStrength: undefined,
tensileStrength: undefined,
elongation: undefined,
+ plasticExtensionStrength: undefined,
hardness: undefined,
+ coatingMass: undefined,
bendingTest: undefined,
surfaceQuality: undefined,
surfaceStructure: undefined,
+ coatingSurfaceStructure: undefined,
edgeStatus: undefined,
remark: undefined,
delFlag: undefined,
@@ -585,7 +617,7 @@ export default {
try {
const payload = rows.map(row => {
const item = { coilId: null, coilNo: row.coilNo };
- ['yieldStrength','tensileStrength','elongation','hardness','bendingTest','surfaceQuality','surfaceStructure','edgeStatus'].forEach(f => { if (row[f]) item[f] = row[f]; });
+ ['yieldStrength','tensileStrength','elongation','plasticExtensionStrength','hardness','coatingMass','bendingTest','surfaceQuality','surfaceStructure','coatingSurfaceStructure','edgeStatus'].forEach(f => { if (row[f]) item[f] = row[f]; });
return item;
});
const addRes = await batchAddPhysicalItem(payload);
@@ -615,10 +647,10 @@ export default {
this.$refs.importUpload?.clearFiles();
},
importDownloadTemplate() {
- const data = [PHYS_TEMPLATE_HEADERS, ['示例卷号', '300', '420', '35', '85', '合格', '良好', '光面', '良好']];
+ const data = [PHYS_TEMPLATE_HEADERS, ['示例卷号', '300', '420', '35', '260', '85', '275', '合格', '良好', '光面', '无锌花', '良好']];
const wb = XLSX.utils.book_new();
const ws = XLSX.utils.aoa_to_sheet(data);
- ws['!cols'] = [{ wch: 16 }, { wch: 16 }, { wch: 16 }, { wch: 10 }, { wch: 10 }, { wch: 10 }, { wch: 10 }, { wch: 10 }, { wch: 10 }];
+ ws['!cols'] = [{ wch: 16 }, { wch: 16 }, { wch: 16 }, { wch: 10 }, { wch: 20 }, { wch: 10 }, { wch: 16 }, { wch: 10 }, { wch: 10 }, { wch: 10 }, { wch: 12 }, { wch: 10 }];
XLSX.utils.book_append_sheet(wb, ws, '导入模板');
XLSX.writeFile(wb, '物理性能导入模板.xlsx');
},
diff --git a/klp-ui/src/views/wms/coil/panels/base.vue b/klp-ui/src/views/wms/coil/panels/base.vue
index c2c86195..c27b546e 100644
--- a/klp-ui/src/views/wms/coil/panels/base.vue
+++ b/klp-ui/src/views/wms/coil/panels/base.vue
@@ -103,8 +103,8 @@
搜索
重置
导出
- 批量移出发货单
+ 批量移出发货单
+
-
-
-
-
@@ -251,14 +344,13 @@ import rollLineMixin from '../rollLineMixin'
export default {
name: 'GrindRoom',
mixins: [rollLineMixin],
+ dicts: ['mes_roll_operator'],
data() {
return {
- // 产线列表
productionLines: [],
filterLineId: null,
- lineTabOrder: [], // 本地记录的点击顺序(最近点过的在前)
+ lineTabOrder: [],
- // 左侧辊列表
rollLoading: false,
allRolls: [],
filteredRolls: [],
@@ -266,32 +358,25 @@ export default {
filterType: '',
filterManufacturer: '',
- // 右侧选中辊
selectedRollId: null,
selectedRoll: null,
- // 磨削记录
grindLoading: false,
grindList: [],
- // 月度汇总
currentYear: new Date().getFullYear(),
monthlyList: [],
- // 行内编辑:editRow 不为 null 时表示当前正在编辑/新增的行数据
- // __isNew: true → 新增行;存在 grindId → 修改行
editRow: null,
grindSaving: false
}
},
computed: {
- // 当前登录用户名(RuoYi Plus 的 store 路径)
currentUserName() {
return this.$store.state.user.name || this.$store.getters.name || ''
},
- // 产线 tab 按本地点击顺序排序
sortedProductionLines() {
const order = this.lineTabOrder
return [...this.productionLines].sort((a, b) => {
@@ -304,11 +389,15 @@ export default {
})
},
- // 有效当前辊径:优先取 currentDia,无则取最新磨削记录的磨后径
+ manufacturerOptions() {
+ const set = new Set()
+ this.allRolls.forEach(r => {
+ if (r.manufacturer) set.add(r.manufacturer)
+ })
+ return [...set].sort()
+ },
+
effectiveCurrentDia() {
- // if (this.selectedRoll && this.selectedRoll.currentDia != null) {
- // return parseFloat(this.selectedRoll.currentDia)
- // }
if (this.grindList.length > 0) {
const latest = [...this.grindList].sort((a, b) => {
const ta = a.grindTime ? new Date(a.grindTime).getTime() : 0
@@ -316,13 +405,10 @@ export default {
return tb - ta
})[0]
if (latest && latest.diaAfter != null) return parseFloat(latest.diaAfter)
- } else {
- return null
}
return null
},
- // 表格数据:新增时在顶部插入一个编辑行占位
tableData() {
if (this.editRow && this.editRow.__isNew) {
return [this.editRow, ...this.grindList]
@@ -331,20 +417,17 @@ export default {
}
},
- created() {},
-
methods: {
onLineResolved() {
this.filterLineId = this.lineId
const uid = this.$store.state.user?.userId || 0
- try { this.lineTabOrder = JSON.parse(localStorage.getItem(`grind_line_order_${uid}`) || '[]') } catch {}
+ try { this.lineTabOrder = JSON.parse(localStorage.getItem(`grind_line_order_${uid}`) || '[]') } catch { /* ignore */ }
listProductionLine({ pageNum: 1, pageSize: 100 }).then(res => {
this.productionLines = res.rows || []
})
this.loadRolls()
},
- // ── 轧辊列表 ──────────────────────────────────────
loadRolls() {
this.rollLoading = true
listRollInfo({ pageNum: 1, pageSize: 500, lineId: this.filterLineId }).then(res => {
@@ -368,9 +451,9 @@ export default {
},
filterRolls() {
this.filteredRolls = this.allRolls.filter(r => {
- const matchNo = !this.filterNo || r.rollNo.includes(this.filterNo)
+ const matchNo = !this.filterNo || r.rollNo.includes(this.filterNo)
const matchType = !this.filterType || r.rollType === this.filterType
- const matchMfr = !this.filterManufacturer || (r.manufacturer || '').toLowerCase().includes(this.filterManufacturer.toLowerCase())
+ const matchMfr = !this.filterManufacturer || r.manufacturer === this.filterManufacturer
return matchNo && matchType && matchMfr
})
},
@@ -385,7 +468,6 @@ export default {
this.loadGrindList(r.rollId)
},
- // ── 磨削记录 ──────────────────────────────────────
loadGrindList(rollId) {
this.grindLoading = true
listRollGrind(rollId).then(res => {
@@ -408,7 +490,6 @@ export default {
this.loadMonthlyStats()
},
- // ── 行内编辑 ──────────────────────────────────────
isEditing(row) {
if (!this.editRow) return false
if (row.__isNew && this.editRow.__isNew) return true
@@ -421,20 +502,20 @@ export default {
startAdd() {
const now = new Date()
const pad = n => String(n).padStart(2, '0')
- const grindTime = `${now.getFullYear()}-${pad(now.getMonth()+1)}-${pad(now.getDate())} ` +
+ const grindTime = `${now.getFullYear()}-${pad(now.getMonth() + 1)}-${pad(now.getDate())} ` +
`${pad(now.getHours())}:${pad(now.getMinutes())}:${pad(now.getSeconds())}`
this.editRow = {
- __isNew: true,
- rollId: this.selectedRollId,
+ __isNew: true,
+ rollId: this.selectedRollId,
grindTime,
- team: undefined,
- diaBefore: this.effectiveCurrentDia != null ? this.effectiveCurrentDia : undefined,
- diaAfter: undefined,
- rollShape: '平',
+ team: undefined,
+ diaBefore: this.effectiveCurrentDia != null ? this.effectiveCurrentDia : undefined,
+ diaAfter: undefined,
+ rollShape: '平',
flawResult: '合格',
- hardness: undefined,
- operator: this.currentUserName,
- remark: undefined
+ hardness: undefined,
+ operator: this.currentUserName,
+ remark: undefined
}
},
startEdit(row) {
@@ -448,10 +529,7 @@ export default {
const r = this.editRow
if (!r.grindTime) { this.$modal.msgWarning('请填写磨削时间'); return }
if (r.diaBefore == null) { this.$modal.msgWarning('请填写磨前直径'); return }
- if (r.diaAfter == null) { this.$modal.msgWarning('请填写磨后直径'); return }
-
- // 自动带入操作人
- r.operator = this.currentUserName
+ if (r.diaAfter == null) { this.$modal.msgWarning('请填写磨后直径'); return }
this.grindSaving = true
const isNew = !!r.__isNew
@@ -480,7 +558,6 @@ export default {
})
},
- // ── 计算磨削量 ──────────────────────────────────────
grindAmountOf(row) {
const b = parseFloat(row.diaBefore)
const a = parseFloat(row.diaAfter)
@@ -488,7 +565,6 @@ export default {
return '—'
},
- // 辅助
statusLabel(s) {
return { Online: '在线', Standby: '备用', Offline: '离线', Scrapped: '报废' }[s] || s
}
@@ -500,7 +576,7 @@ export default {
.grind-page { background: #f4f5f7; height: 100%; }
.grind-layout { display: flex; gap: 12px; height: 100%; }
-/* 产线 Tab 列 */
+/* ── 左侧产线 Tab ── */
.line-tabs {
width: 64px;
flex-shrink: 0;
@@ -530,31 +606,87 @@ export default {
font-weight: 600;
}
-/* 轧辊列表 */
-.grind-left { width: 220px; flex-shrink: 0; }
-.grind-right { flex: 1; min-width: 0; }
+/* ── 右侧主体 ── */
+.grind-main {
+ flex: 1;
+ min-width: 0;
+ display: flex;
+ flex-direction: column;
+ gap: 10px;
+}
-.grind-card { border: 1px solid #dcdee0; border-radius: 4px; }
-.h-full { height: calc(100vh - 120px); display: flex; flex-direction: column; }
+/* 顶部检索栏 */
+.search-bar {
+ display: flex;
+ align-items: center;
+ gap: 20px;
+ padding: 10px 14px;
+ background: #fff;
+ border: 1px solid #dcdee0;
+ border-radius: 4px;
+ flex-shrink: 0;
+}
+
+/* 下方内容区:左右分栏 */
+.content-area {
+ flex: 1;
+ min-height: 0;
+ display: flex;
+ gap: 10px;
+}
+
+/* 左侧轧辊列表面板 */
+.roll-list-panel {
+ width: 220px;
+ flex-shrink: 0;
+ height: calc(100vh - 140px);
+ overflow-y: auto;
+}
+
+/* 右侧明细面板 */
+.detail-panel {
+ flex: 1;
+ min-width: 0;
+ overflow-y: auto;
+}
+
+/* 明细卡片 */
+.detail-card {
+ border: 1px solid #dcdee0;
+ border-radius: 4px;
+}
+.detail-card ::v-deep .el-card__body {
+ overflow: auto;
+}
+
+/* 通用卡片 */
+.panel-card {
+ border: 1px solid #dcdee0;
+ border-radius: 4px;
+ height: 100%;
+ display: flex;
+ flex-direction: column;
+}
+.panel-card ::v-deep .el-card__body {
+ flex: 1;
+ min-height: 0;
+ overflow-y: auto;
+}
.card-header { display: flex; align-items: center; gap: 8px; }
.card-title { font-size: 13px; font-weight: 600; color: #3d4b5c; }
+.card-count { font-size: 11px; color: #9aa0a6; background: #f0f2f5; padding: 1px 8px; border-radius: 10px; margin-left: auto; }
-/* 辊列表 */
-.roll-filter { padding: 0 0 4px; }
-::v-deep .el-card .el-card__body {
- overflow-y: scroll;
- overflow-x: hidden;
-}
-.roll-list { overflow-y: auto; flex: 1; min-height: 0; padding: 0; }
+/* 轧辊列表 */
+.roll-list { padding: 0; }
.roll-item { padding: 8px 12px; cursor: pointer; border-bottom: 1px solid #f0f2f5; }
.roll-item:hover { background: #f5f7fa; }
.roll-item--active { background: #e8f4ff !important; border-left: 3px solid #409eff; }
-.ri-no { font-family: 'Consolas', monospace; font-size: 13px; font-weight: 600; color: #1f2329; }
-.ri-meta { display: flex; align-items: center; gap: 6px; margin-top: 3px; }
-.ri-dia { font-size: 11px; color: #9aa0a6; }
+.ri-no { font-family: 'Consolas', monospace; font-size: 13px; font-weight: 600; color: #1f2329; }
+.ri-meta { display: flex; align-items: center; gap: 6px; margin-top: 3px; }
+.ri-dia { font-size: 11px; color: #9aa0a6; }
.ri-manufacturer { font-size: 10px; color: #909399; margin-top: 2px; }
-.ri-line { font-size: 10px; color: #b0b3bb; margin-top: 2px; }
+.ri-line { font-size: 10px; color: #b0b3bb; margin-top: 2px; }
.ri-status { font-size: 11px; }
.roll-empty { text-align: center; color: #c0c4cc; padding: 20px 0; font-size: 12px; }
@@ -582,17 +714,18 @@ export default {
/* 行内编辑 */
.computed-val { color: #409eff; font-weight: 600; font-size: 13px; }
-.auto-operator { color: #0a7c42; font-size: 12px; }
.remark-text { font-size: 12px; color: #5f6368; }
-/* 去掉 number input 的默认上下箭头,保持表格整洁 */
.el-table :deep(input[type=number]::-webkit-inner-spin-button),
.el-table :deep(input[type=number]::-webkit-outer-spin-button) { -webkit-appearance: none; }
.el-table :deep(input[type=number]) { -moz-appearance: textfield; }
-
diff --git a/klp-ui/src/views/wms/delivery/waybill/index.vue b/klp-ui/src/views/wms/delivery/waybill/index.vue
index 862c3b84..669b1932 100644
--- a/klp-ui/src/views/wms/delivery/waybill/index.vue
+++ b/klp-ui/src/views/wms/delivery/waybill/index.vue
@@ -56,11 +56,6 @@
-
-
-
-
搜索
重置
From 94840b2153074e0a3e22fda7c09ff6e1ba72a152 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?=E7=A0=82=E7=B3=96?= <2178503051@qq.com>
Date: Mon, 1 Jun 2026 12:58:35 +0800
Subject: [PATCH 08/29] =?UTF-8?q?feat(mes/roll/grind):=20=E5=AE=9E?=
=?UTF-8?q?=E7=8E=B0=E8=BD=A7=E8=BE=8A=E5=A2=9E=E5=88=A0=E6=94=B9=E6=9F=A5?=
=?UTF-8?q?=E5=8A=9F=E8=83=BD?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
1. 新增轧辊列表头部新增按钮和轧辊明细面板的修改、删除按钮
2. 增加轧辊新增/编辑弹窗,包含完整的轧辊信息表单和校验
3. 对接轧辊CRUD后端接口,实现新增、修改、删除逻辑
4. 调整左侧轧辊面板宽度适配新增内容
---
.../com/klp/mes/roll/domain/MesRollInfo.java | 3 +
klp-ui/src/views/mes/roll/grind/index.vue | 196 +++++++++++++++++-
2 files changed, 195 insertions(+), 4 deletions(-)
diff --git a/klp-mes/src/main/java/com/klp/mes/roll/domain/MesRollInfo.java b/klp-mes/src/main/java/com/klp/mes/roll/domain/MesRollInfo.java
index fdae7bfa..fb9a6345 100644
--- a/klp-mes/src/main/java/com/klp/mes/roll/domain/MesRollInfo.java
+++ b/klp-mes/src/main/java/com/klp/mes/roll/domain/MesRollInfo.java
@@ -71,6 +71,9 @@ public class MesRollInfo extends BaseEntity {
/** 厂家 */
private String manufacturer;
+ /** 备注 */
+ private String remark;
+
@TableLogic
private Integer delFlag;
}
diff --git a/klp-ui/src/views/mes/roll/grind/index.vue b/klp-ui/src/views/mes/roll/grind/index.vue
index 3e66b1db..4bc0a821 100644
--- a/klp-ui/src/views/mes/roll/grind/index.vue
+++ b/klp-ui/src/views/mes/roll/grind/index.vue
@@ -49,6 +49,7 @@
-
+
请从左侧选择一个轧辊
@@ -82,6 +83,8 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
@@ -1237,4 +1373,4 @@ export default {
.plan-sheet-section {
margin-top: 16px;
}
-
\ No newline at end of file
+
diff --git a/klp-ui/src/views/wms/coil/typing.vue b/klp-ui/src/views/wms/coil/typing.vue
index 862e4e12..a65086c0 100644
--- a/klp-ui/src/views/wms/coil/typing.vue
+++ b/klp-ui/src/views/wms/coil/typing.vue
@@ -60,14 +60,20 @@
-
-
+
+
-
-
+
+
+ 厂家卷号匹配到多条入场卷号,请为每行选择对应记录
+
+
+
+
+
+
+
+
+
+
+
+
@@ -343,12 +374,13 @@ import CoilSelector from "@/components/CoilSelector";
import { listMaterialCoil } from "@/api/wms/coil";
const PHYS_TEMPLATE_HEADERS = [
- '当前钢卷号', '屈服强度(MPa)', '抗拉强度(MPa)', '伸长率(%)', '规定塑性延伸强度(MPa)', '硬度(HRB)',
+ '当前钢卷号', '厂家卷号', '屈服强度(MPa)', '抗拉强度(MPa)', '伸长率(%)', '规定塑性延伸强度(MPa)', '硬度(HRB)',
'镀层重量(g/m²)', '弯曲试验', '表面质量', '表面结构', '镀层表面结构', '边缘状态'
];
const PHYS_HEADER_MAP = {
'当前钢卷号': 'coilNo',
+ '厂家卷号': 'supplierCoilNo',
'屈服强度(MPa)': 'yieldStrength',
'抗拉强度(MPa)': 'tensileStrength',
'伸长率(%)': 'elongation',
@@ -429,6 +461,10 @@ export default {
importLoading: false,
coilNoOptions: [],
coilNoLoading: false,
+ tempSupplierCoilNo: '',
+ supplierCoilNoLoading: false,
+ ambiguousVisible: false,
+ ambiguousRows: [],
};
},
created() {
@@ -520,6 +556,34 @@ export default {
this.coilNoLoading = false;
});
},
+ querySupplierCoilNo(queryString, cb) {
+ if (!queryString || queryString.length < 2) {
+ cb([]);
+ return;
+ }
+ this.supplierCoilNoLoading = true;
+ listMaterialCoil({
+ supplierCoilNo: queryString,
+ pageNum: 1,
+ pageSize: 20
+ }).then(response => {
+ const options = (response.rows || []).map(item => ({
+ value: item.supplierCoilNo,
+ label: item.supplierCoilNo,
+ enterCoilNo: item.enterCoilNo
+ }));
+ cb(options);
+ }).finally(() => {
+ this.supplierCoilNoLoading = false;
+ });
+ },
+ handleSelectSupplierCoilNo(item) {
+ if (item.enterCoilNo) {
+ this.form.coilNo = item.enterCoilNo;
+ this.$refs["form"].validateField('coilNo');
+ }
+ this.tempSupplierCoilNo = '';
+ },
handleBatchAdd(rows) {
this.loading = true;
this.buttonLoading = true;
@@ -589,12 +653,89 @@ export default {
if (!this.importFile || !this.importRawData.length) { this.$message.warning('暂无数据可校验'); return; }
this.importValidateLoading = true;
this.importErrorList = [];
- for (let i = 0; i < this.importRawData.length; i++) {
+ this.ambiguousRows = [];
+ const dataRows = this.importRawData;
+ for (let i = 0; i < dataRows.length; i++) {
const rowNum = i + 2;
- let coilNo = '';
- PHYS_TEMPLATE_HEADERS.forEach((h, j) => { if (PHYS_HEADER_MAP[h] === 'coilNo') coilNo = this.importRawData[i][j]; });
- if (!coilNo || !String(coilNo).trim()) this.importErrorList.push({ rowNum, errorMsg: '当前钢卷号不能为空' });
+ let coilNo = '', supplierCoilNo = '';
+ PHYS_TEMPLATE_HEADERS.forEach((h, j) => {
+ if (PHYS_HEADER_MAP[h] === 'coilNo') coilNo = dataRows[i][j];
+ if (PHYS_HEADER_MAP[h] === 'supplierCoilNo') supplierCoilNo = dataRows[i][j];
+ });
+ coilNo = String(coilNo || '').trim();
+ supplierCoilNo = String(supplierCoilNo || '').trim();
+ if (!coilNo && !supplierCoilNo) {
+ this.importErrorList.push({ rowNum, errorMsg: '当前钢卷号和厂家卷号不能同时为空' });
+ }
}
+ // 处理仅填写厂家卷号的行
+ if (this.importErrorList.length === 0) {
+ this.importTableData.forEach((row, idx) => {
+ const cn = (row.coilNo || '').trim();
+ const sn = (row.supplierCoilNo || '').trim();
+ row._sno = sn;
+ row._idx = idx;
+ row._fillCoilNo = cn;
+ if (sn && !cn) row._needMatch = true;
+ });
+ const needMatchRows = this.importTableData.filter(r => r._needMatch);
+ if (needMatchRows.length > 0) {
+ const uniqueSnos = [...new Set(needMatchRows.map(r => r._sno))];
+ const multiMap = {};
+ try {
+ const results = await Promise.all(
+ uniqueSnos.map(sno => listMaterialCoil({ supplierCoilNo: sno, pageNum: 1, pageSize: 50 }))
+ );
+ uniqueSnos.forEach((sno, idx) => {
+ const rows = (results[idx] && results[idx].rows) || [];
+ const enterNos = [...new Set(rows.map(r => r.enterCoilNo).filter(Boolean))];
+ multiMap[sno] = enterNos;
+ });
+ } catch (err) {
+ this.importValidateLoading = false;
+ this.importHandleError('厂家卷号匹配失败:' + err.message);
+ return;
+ }
+ const ambiguousList = [];
+ needMatchRows.forEach(row => {
+ const candidates = multiMap[row._sno] || [];
+ if (candidates.length === 0) {
+ this.importErrorList.push({ rowNum: (row.rowNum || (row._idx + 2)), errorMsg: `厂家卷号"${row._sno}"未匹配到入场卷号` });
+ } else if (candidates.length === 1) {
+ row.coilNo = candidates[0];
+ } else {
+ ambiguousList.push({
+ _idx: row._idx,
+ supplierCoilNo: row._sno,
+ options: candidates,
+ selected: null
+ });
+ }
+ });
+ if (ambiguousList.length > 0) {
+ this.ambiguousRows = ambiguousList;
+ this.importValidateLoading = false;
+ this.ambiguousVisible = true;
+ return;
+ }
+ }
+ }
+ this.finishValidation();
+ },
+ confirmAmbiguous() {
+ const unselected = this.ambiguousRows.filter(r => !r.selected);
+ if (unselected.length > 0) {
+ this.$message.warning('请为所有行选择入场卷号');
+ return;
+ }
+ this.ambiguousRows.forEach(item => {
+ this.importTableData[item._idx].coilNo = item.selected;
+ });
+ this.ambiguousVisible = false;
+ this.importValidateLoading = true;
+ this.finishValidation();
+ },
+ finishValidation() {
if (this.importErrorList.length > 0) {
this.$message.error(`数据校验失败,共发现${this.importErrorList.length}条错误`);
} else {
@@ -647,10 +788,10 @@ export default {
this.$refs.importUpload?.clearFiles();
},
importDownloadTemplate() {
- const data = [PHYS_TEMPLATE_HEADERS, ['示例卷号', '300', '420', '35', '260', '85', '275', '合格', '良好', '光面', '无锌花', '良好']];
+ const data = [PHYS_TEMPLATE_HEADERS, ['示例卷号', '示例厂家卷号', '300', '420', '35', '260', '85', '275', '合格', '良好', '光面', '无锌花', '良好']];
const wb = XLSX.utils.book_new();
const ws = XLSX.utils.aoa_to_sheet(data);
- ws['!cols'] = [{ wch: 16 }, { wch: 16 }, { wch: 16 }, { wch: 10 }, { wch: 20 }, { wch: 10 }, { wch: 16 }, { wch: 10 }, { wch: 10 }, { wch: 10 }, { wch: 12 }, { wch: 10 }];
+ ws['!cols'] = [{ wch: 16 }, { wch: 16 }, { wch: 16 }, { wch: 16 }, { wch: 10 }, { wch: 20 }, { wch: 10 }, { wch: 16 }, { wch: 10 }, { wch: 10 }, { wch: 10 }, { wch: 12 }, { wch: 10 }];
XLSX.utils.book_append_sheet(wb, ws, '导入模板');
XLSX.writeFile(wb, '物理性能导入模板.xlsx');
},
diff --git a/klp-ui/src/views/mes/qc/inspection/task.vue b/klp-ui/src/views/mes/qc/inspection/task.vue
index b2c67be5..4c15fa84 100644
--- a/klp-ui/src/views/mes/qc/inspection/task.vue
+++ b/klp-ui/src/views/mes/qc/inspection/task.vue
@@ -75,6 +75,7 @@
+
@@ -258,27 +259,57 @@
-
-
-
- {{ coilNo }}
-
+
+
+
+
+ 可输入入场卷号或厂家卷号,两者互通匹配
+
+
+
+
+ {{ coilNo }}
+
+
+
+
+
+ {{ coilNo }}
+
+
+
+
-
-
+
@@ -488,6 +519,9 @@ export default {
enterCoilNoLoading: false,
selectedEnterCoilNos: [],
tempEnterCoilNo: '',
+ selectedSupplierCoilNos: [],
+ tempSupplierCoilNo: '',
+ supplierCoilNoLoading: false,
attachmentOpen: false,
attachmentTitle: '',
attachmentLoading: false,
@@ -558,6 +592,8 @@ export default {
this.resetTaskForm();
this.selectedEnterCoilNos = [];
this.tempEnterCoilNo = '';
+ this.selectedSupplierCoilNos = [];
+ this.tempSupplierCoilNo = '';
this.taskOpen = true;
this.taskTitle = "添加检验任务";
},
@@ -581,6 +617,13 @@ export default {
this.selectedEnterCoilNos = [];
}
this.tempEnterCoilNo = '';
+ // 初始化已选择的厂家卷号
+ if (response.data.supplierCoilNos) {
+ this.selectedSupplierCoilNos = response.data.supplierCoilNos.split(',').filter(item => item.trim());
+ } else {
+ this.selectedSupplierCoilNos = [];
+ }
+ this.tempSupplierCoilNo = '';
this.taskLoading = false;
this.taskOpen = true;
this.taskTitle = "修改检验任务";
@@ -636,7 +679,7 @@ export default {
handleQuickCreate() {
this.schemeVisible = true;
},
- handleSchemeConfirm({ template, taskCode, taskType, belongCompany, coilIds, enterCoilNos }) {
+ handleSchemeConfirm({ template, taskCode, taskType, belongCompany, coilIds, enterCoilNos, supplierCoilNos }) {
this.taskLoading = true;
addInspectionTaskWithItems({
taskCode: taskCode,
@@ -645,7 +688,8 @@ export default {
belongCompany: belongCompany,
taskType: taskType,
coilIds: coilIds || undefined,
- enterCoilNos: enterCoilNos || undefined
+ enterCoilNos: enterCoilNos || undefined,
+ supplierCoilNos: supplierCoilNos || undefined
}).then(() => {
this.$modal.msgSuccess("快捷创建成功");
this.getTaskList();
@@ -757,6 +801,43 @@ export default {
this.selectedEnterCoilNos.splice(index, 1);
this.taskForm.enterCoilNos = this.selectedEnterCoilNos.join(',');
},
+ querySupplierCoilNo(queryString, cb) {
+ if (!queryString || queryString.length < 2) {
+ cb([]);
+ return;
+ }
+ this.supplierCoilNoLoading = true;
+ listMaterialCoil({
+ supplierCoilNo: queryString,
+ pageNum: 1,
+ pageSize: 20
+ }).then(response => {
+ const options = (response.rows || []).map(item => ({
+ value: item.supplierCoilNo,
+ label: item.supplierCoilNo,
+ enterCoilNo: item.enterCoilNo
+ })).filter(opt => !this.selectedSupplierCoilNos.includes(opt.value));
+ cb(options);
+ }).finally(() => {
+ this.supplierCoilNoLoading = false;
+ });
+ },
+ handleSelectSupplierCoilNo(item) {
+ if (!this.selectedSupplierCoilNos.includes(item.value)) {
+ this.selectedSupplierCoilNos.push(item.value);
+ }
+ this.taskForm.supplierCoilNos = this.selectedSupplierCoilNos.join(',');
+ if (item.enterCoilNo && !this.selectedEnterCoilNos.includes(item.enterCoilNo)) {
+ this.selectedEnterCoilNos.push(item.enterCoilNo);
+ this.taskForm.enterCoilNos = this.selectedEnterCoilNos.join(',');
+ this.$refs["taskForm"].validateField('enterCoilNos');
+ }
+ this.tempSupplierCoilNo = '';
+ },
+ removeSupplierCoilNo(index) {
+ this.selectedSupplierCoilNos.splice(index, 1);
+ this.taskForm.supplierCoilNos = this.selectedSupplierCoilNos.join(',');
+ },
cancelTask() {
this.taskOpen = false;
this.resetTaskForm();
@@ -787,6 +868,8 @@ export default {
this.taskCoilList = [];
this.selectedEnterCoilNos = [];
this.tempEnterCoilNo = '';
+ this.selectedSupplierCoilNos = [];
+ this.tempSupplierCoilNo = '';
this.resetForm("taskForm");
},
From b134539e539688e5d4199cb73cd339972719fac3 Mon Sep 17 00:00:00 2001
From: wangyu <823267011@qq.com>
Date: Mon, 1 Jun 2026 17:11:36 +0800
Subject: [PATCH 18/29] =?UTF-8?q?=E6=8F=90=E4=BA=A43d=E9=92=A2=E5=8D=B7?=
=?UTF-8?q?=E5=88=9D=E7=89=88?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
klp-ui/package.json | 1 +
.../wms/warehouse/components/Warehouse3D.vue | 647 ++++++++++++++++++
klp-ui/src/views/wms/warehouse/overview.vue | 55 +-
3 files changed, 691 insertions(+), 12 deletions(-)
create mode 100644 klp-ui/src/views/wms/warehouse/components/Warehouse3D.vue
diff --git a/klp-ui/package.json b/klp-ui/package.json
index 2a2d5e7b..1aaa8d73 100644
--- a/klp-ui/package.json
+++ b/klp-ui/package.json
@@ -73,6 +73,7 @@
"quill": "1.3.7",
"screenfull": "5.0.2",
"sortablejs": "1.10.2",
+ "three": "^0.160.1",
"vditor": "^3.11.1",
"video.js": "^8.23.3",
"vue": "2.6.12",
diff --git a/klp-ui/src/views/wms/warehouse/components/Warehouse3D.vue b/klp-ui/src/views/wms/warehouse/components/Warehouse3D.vue
new file mode 100644
index 00000000..5b2a7680
--- /dev/null
+++ b/klp-ui/src/views/wms/warehouse/components/Warehouse3D.vue
@@ -0,0 +1,647 @@
+
+
+
+
+
+
+
+ 等轴
+ 俯视
+ 正视
+ 侧视
+
+
+
左键旋转 · 滚轮缩放 · 右键平移 · 点击钢卷查看 · [R] 复位 · [Esc] 关闭
+
+
+
钢卷 {{ detail && detail.id }}
+
库位{{ detail && detail.posKey }} 第{{ detail && detail.layer }}层
+
钢卷号{{ detail && detail.id }}
+
钢种{{ detail && detail.grade }}
+
宽度×外径{{ detail && (detail.width + ' × Ø' + detail.od) }}
+
重量(t){{ detail && detail.weight }}
+
扫码状态{{ detail && scanText(detail.scan) }}
+
+
+
+
库区统计
+
+
钢卷明细
+
+
+ | 库位 | 钢卷号 | 规格 | 状态 |
+
+
+ | {{ c.posKey }} L{{ c.layer }} |
+ {{ c.id }} |
+ {{ c.width }}ר{{ c.od }} |
+ {{ scanShort(c.scan) }} |
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/klp-ui/src/views/wms/warehouse/overview.vue b/klp-ui/src/views/wms/warehouse/overview.vue
index 17dd2e9c..eeae019b 100644
--- a/klp-ui/src/views/wms/warehouse/overview.vue
+++ b/klp-ui/src/views/wms/warehouse/overview.vue
@@ -10,18 +10,23 @@
-
+
-
-
-
+
+
+
+
+
+
+
+
@@ -66,12 +71,13 @@
From 29328d70e9d454d5c5f18c57ca48d14a980395b1 Mon Sep 17 00:00:00 2001
From: wangyu <823267011@qq.com>
Date: Tue, 2 Jun 2026 10:08:47 +0800
Subject: [PATCH 24/29] =?UTF-8?q?=E6=8F=90=E4=BA=A43d=E9=92=A2=E5=8D=B7?=
=?UTF-8?q?=EF=BC=8C=E8=BF=BD=E6=BA=AF=E5=92=8C=E6=84=8F=E5=BA=93=E5=86=85?=
=?UTF-8?q?=E5=AE=B9?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
.../wms/warehouse/components/Warehouse3D.vue | 288 ++++++++++++++----
klp-ui/src/views/wms/warehouse/overview.vue | 2 +-
2 files changed, 228 insertions(+), 62 deletions(-)
diff --git a/klp-ui/src/views/wms/warehouse/components/Warehouse3D.vue b/klp-ui/src/views/wms/warehouse/components/Warehouse3D.vue
index 1c1107d3..79b46aa6 100644
--- a/klp-ui/src/views/wms/warehouse/components/Warehouse3D.vue
+++ b/klp-ui/src/views/wms/warehouse/components/Warehouse3D.vue
@@ -28,15 +28,48 @@
Z 轴 · 排 (R)
-
+
-
钢卷 {{ detail && detail.id }}
-
库位{{ detail && detail.posKey }} · 第 {{ detail && detail.layer }} 层
-
钢卷号{{ detail && detail.id }}
-
钢种{{ detail && detail.grade }}
-
宽度×外径{{ detail && (detail.width + ' × Ø' + detail.od) }}
-
重量(t){{ detail && detail.weight }}
-
扫码状态{{ detail && scanText(detail.scan) }}
+
钢卷 {{ detail && detail.coilNo }}
+
库位{{ detail && (detail.warehouseName || detail.posKey) }} · 第 {{ detail && detail.layer }} 层
+
钢卷号{{ detail && detail.coilNo }}
+
入库钢卷号{{ detail && (detail.enterCoilNo || '-') }}
+
材质{{ detail && detail.material }}
+
规格{{ detail && detail.specification }}
+
毛重(kg){{ detail && fmtNum(detail.grossWeight) }}
+
净重(kg){{ detail && fmtNum(detail.netWeight) }}
+
质量状态{{ detail && detail.qualityStatus }}
+
+
移库信息
+
+ | 时间 | 库位 | 操作 | 出入库 |
+
+
+ | {{ m.time }} |
+ {{ m.warehouse }} |
+ {{ m.operationType }} |
+ {{ m.inOutType }} |
+
+
+
+
暂无移库记录
+
+
生产追溯
+
+
+
+ {{ step.action }}
+ {{ step.time }}
+
+
操作员:{{ step.operation }}
+
+
+ {{ c.currentCoilNo }}
+
+
+
+
+
暂无追溯数据
@@ -55,15 +88,15 @@
钢卷明细
- | 库位 | 钢卷号 | 规格 | 状态 |
+ | 库位 | 钢卷号 | 规格 | 重量 |
| {{ c.posKey }} L{{ c.layer }} |
- {{ c.id }} |
- {{ c.width }}ר{{ c.od }} |
- {{ scanShort(c.scan) }} |
+ {{ c.coilNo }} |
+ {{ c.specification }} |
+ {{ fmtNum(c.grossWeight) }} |
@@ -75,6 +108,19 @@
+
+
diff --git a/klp-ui/src/views/mes/qc/certificate/components/templates/ColdHardTemplate.vue b/klp-ui/src/views/mes/qc/certificate/components/templates/ColdHardTemplate.vue
new file mode 100644
index 00000000..1173b5d6
--- /dev/null
+++ b/klp-ui/src/views/mes/qc/certificate/components/templates/ColdHardTemplate.vue
@@ -0,0 +1,356 @@
+
+
+
+
+
+
+
+ | 执行标准(SPECIFICATION): |
+ {{ certificate.standard || '/' }} |
+ 证明书号(CERTIFICATE NO.): |
+ {{ certificate.certificateNo || '' }} |
+
+
+ | 收货单位(CONSIGNEE): |
+ {{ certificate.consignee || '-' }} |
+ 合同号(CONTRACT NO.): |
+ {{ certificate.contractNo || '' }} |
+
+
+ | 产品名称(PRODUCT): |
+ {{ certificate.productName || '' }} |
+ 签发日期(DATE OF ISSUE): |
+ {{ formatDate(certificate.issueDate) || '' }} |
+
+
+
+
+
+
+ | 序号 |
+ 钢卷号 Coil No. |
+ 炉号 Heat No. |
+ 材质 Type |
+ 规格 Size (mm) |
+ 件数 Pieces |
+ 重量 Weight(t) |
+ 化学成分(%) Chemical Composition |
+ 拉伸试验 Tensile Test (G.L=80mm) |
+ 硬度试验 Hardness Test |
+ 弯曲试验 180° B.T D=0a |
+ 表面质量 |
+ 表面结构 |
+ 边缘状态 |
+
+
+ | C |
+ Si |
+ Mn |
+ P |
+ S |
+ Als |
+ 屈服 RP0.2 Y.S(MPa) |
+ 抗拉 T.S (MPa) |
+ 伸长率 EL (%) |
+
+
+
+
+ | {{ index + 1 }} |
+ {{ item.coilNo || '' }} |
+ {{ item.heatNo || '' }} |
+ {{ item.materialType || '' }} |
+ {{ item.size || '' }} |
+ {{ item.pieces || '' }} |
+ {{ item.weight || '' }} |
+ {{ item.c || '/' }} |
+ {{ item.si || '/' }} |
+ {{ item.mn || '/' }} |
+ {{ item.p || '/' }} |
+ {{ item.s || '/' }} |
+ {{ item.als || '/' }} |
+ {{ item.yieldStrength || '/' }} |
+ {{ item.tensileStrength || '/' }} |
+ {{ item.elongation || '/' }} |
+ {{ item.hardness || '/' }} |
+ {{ item.bendingTest || '/' }} |
+ {{ item.surfaceQuality || '/' }} |
+ {{ item.surfaceStructure || '/' }} |
+ {{ item.edgeStatus || '/' }} |
+
+
+ | 暂无数据 |
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/klp-ui/src/views/mes/qc/certificate/components/templates/GalvanizingTemplate.vue b/klp-ui/src/views/mes/qc/certificate/components/templates/GalvanizingTemplate.vue
new file mode 100644
index 00000000..84ca61b8
--- /dev/null
+++ b/klp-ui/src/views/mes/qc/certificate/components/templates/GalvanizingTemplate.vue
@@ -0,0 +1,360 @@
+
+
+
+
+
+
+
+ | 执行标准(SPECIFICATION): |
+ {{ certificate.standard || '/' }} |
+ 证明书号(CERTIFICATE NO.): |
+ {{ certificate.certificateNo || '' }} |
+
+
+ | 收货单位(CONSIGNEE): |
+ {{ certificate.consignee || '-' }} |
+ 合同号(CONTRACT NO.): |
+ {{ certificate.contractNo || '' }} |
+
+
+ | 产品名称(PRODUCT): |
+ {{ certificate.productName || '' }} |
+ 签发日期(DATE OF ISSUE): |
+ {{ formatDate(certificate.issueDate) || '' }} |
+
+
+
+
+
+
+ | 序号 |
+ 钢卷号 Coil No. |
+ 原料号 Material No. |
+ 材质 Type |
+ 规格 Size (mm) |
+ 件数 Pieces |
+ 重量 Weight(t) |
+ 化学成分(%) Chemical Composition |
+ 拉伸试验 Tensile Test (G.L=80mm) |
+ 镀层弯曲 B.T D=0a |
+ 表面质量 |
+ 表面结构 |
+ 镀层 表面结构 |
+ 表面处理 |
+ 镀层重量COATINGMASS 锌层重量双面三点平均值 (g/m²) |
+
+
+ | C |
+ Si |
+ Mn |
+ P |
+ S |
+ Als |
+ 屈服 Y.S |
+ 抗拉 T.S |
+ 伸长率 EL |
+
+
+
+
+ | {{ index + 1 }} |
+ {{ item.coilNo || '' }} |
+ {{ item.rawCoilNo || '' }} |
+ {{ item.materialType || '' }} |
+ {{ item.size || '' }} |
+ {{ item.pieces || '' }} |
+ {{ item.weight || '' }} |
+ {{ item.c || '/' }} |
+ {{ item.si || '/' }} |
+ {{ item.mn || '/' }} |
+ {{ item.p || '/' }} |
+ {{ item.s || '/' }} |
+ {{ item.als || '/' }} |
+ {{ item.yieldStrength || '/' }} |
+ {{ item.tensileStrength || '/' }} |
+ {{ item.elongation || '/' }} |
+ {{ item.bendingTest || '/' }} |
+ {{ item.surfaceQuality || '/' }} |
+ {{ item.surfaceStructure || '/' }} |
+ {{ item.coatingSurfaceStructure || '/' }} |
+ {{ item.surfaceTreatment || '/' }} |
+
+ {{ item.coatingMass || '/' }}
+ |
+
+
+ | 暂无数据 |
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/klp-ui/src/views/mes/qc/certificate/components/templates/RawMaterialTemplate.vue b/klp-ui/src/views/mes/qc/certificate/components/templates/RawMaterialTemplate.vue
new file mode 100644
index 00000000..1bcdd7e2
--- /dev/null
+++ b/klp-ui/src/views/mes/qc/certificate/components/templates/RawMaterialTemplate.vue
@@ -0,0 +1,378 @@
+
+
+
+
+
+
+
+ | 执行标准(SPECIFICATION): |
+ {{ certificate.standard || '/' }} |
+ 证明书号(CERTIFICATE NO.): |
+ {{ certificate.certificateNo || '' }} |
+
+
+ | 收货单位(CONSIGNEE): |
+ {{ certificate.consignee || '-' }} |
+ 合同号(CONTRACT NO.): |
+ {{ certificate.contractNo || '' }} |
+
+
+ | 产品名称(PRODUCT): |
+ {{ certificate.productName || '' }} |
+ 签发日期(DATE OF ISSUE): |
+ {{ formatDate(certificate.issueDate) || '' }} |
+
+
+
+
+
+
+ | 序号 |
+ 钢卷号 Coil No. |
+ 炉号 Heat No. |
+ 材质 Type |
+ 规格 Size (mm) |
+ 件数 Pieces |
+ 重量 Weight(t) |
+ 化学成分(%) Chemical Composition |
+ 拉伸试验 Tensile Test (G.L=80mm) |
+ 硬度试验 Hardness Test |
+ 弯曲试验 180° B.T D=0a |
+ 表面质量 |
+ 表面结构 |
+ 边缘状态 |
+ 规定塑性延伸强度 (MPa) |
+ 镀层表面结构 |
+ 镀层重量 (g/m²) |
+
+
+ | C |
+ Si |
+ Mn |
+ P |
+ S |
+ Als |
+ Al |
+ Ti |
+ Cr |
+ Ni |
+ Cu |
+ N |
+ Fe |
+ B |
+ 屈服 RP0.2 Y.S(MPa) |
+ 抗拉 T.S (MPa) |
+ 伸长率 EL (%) |
+
+
+
+
+ | {{ index + 1 }} |
+ {{ item.coilNo || '' }} |
+ {{ item.heatNo || '' }} |
+ {{ item.materialType || '' }} |
+ {{ item.size || '' }} |
+ {{ item.pieces || '' }} |
+ {{ item.weight || '' }} |
+ {{ item.c || '/' }} |
+ {{ item.si || '/' }} |
+ {{ item.mn || '/' }} |
+ {{ item.p || '/' }} |
+ {{ item.s || '/' }} |
+ {{ item.als || '/' }} |
+ {{ item.al || '/' }} |
+ {{ item.ti || '/' }} |
+ {{ item.cr || '/' }} |
+ {{ item.ni || '/' }} |
+ {{ item.cu || '/' }} |
+ {{ item.n || '/' }} |
+ {{ item.fe || '/' }} |
+ {{ item.b || '/' }} |
+ {{ item.yieldStrength || '/' }} |
+ {{ item.tensileStrength || '/' }} |
+ {{ item.elongation || '/' }} |
+ {{ item.hardness || '/' }} |
+ {{ item.bendingTest || '/' }} |
+ {{ item.surfaceQuality || '/' }} |
+ {{ item.surfaceStructure || '/' }} |
+ {{ item.edgeStatus || '/' }} |
+ {{ item.plasticExtensionStrength || '/' }} |
+ {{ item.coatingSurfaceStructure || '/' }} |
+ {{ item.coatingMass || '/' }} |
+
+
+ | 暂无数据 |
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/klp-ui/src/views/mes/qc/certificate/components/templates/index.js b/klp-ui/src/views/mes/qc/certificate/components/templates/index.js
new file mode 100644
index 00000000..bf0c37f9
--- /dev/null
+++ b/klp-ui/src/views/mes/qc/certificate/components/templates/index.js
@@ -0,0 +1,20 @@
+import ChromiumTemplate from './ChromiumTemplate.vue';
+import GalvanizingTemplate from './GalvanizingTemplate.vue';
+import ColdHardTemplate from './ColdHardTemplate.vue';
+import RawMaterialTemplate from './RawMaterialTemplate.vue';
+
+export const templateMap = {
+ chromium: ChromiumTemplate,
+ galvanizing: GalvanizingTemplate,
+ coldHard: ColdHardTemplate,
+ rawMaterial: RawMaterialTemplate
+};
+
+export const templateOptions = [
+ { value: 'chromium', label: '镀铬质保书模版' },
+ { value: 'galvanizing', label: '镀锌质保书模版' },
+ { value: 'coldHard', label: '冷硬质保书模版' },
+ { value: 'rawMaterial', label: '原料质保书模版' }
+];
+
+export default templateMap;
diff --git a/klp-ui/src/views/mes/qc/certificate/item.vue b/klp-ui/src/views/mes/qc/certificate/item.vue
index 02a728b9..369a3093 100644
--- a/klp-ui/src/views/mes/qc/certificate/item.vue
+++ b/klp-ui/src/views/mes/qc/certificate/item.vue
@@ -106,6 +106,11 @@
+
+
+
+
+
@@ -162,6 +167,46 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
@@ -188,6 +233,11 @@
+
@@ -204,6 +254,36 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ :items="printItemsData" :template-type="selectedTemplateType" />
+
+
+
+
+
+
+
+
+ {{ option.label }}
+
+
+
+
+
+
@@ -347,6 +445,7 @@ import { listChemicalItem } from "@/api/mes/qc/chemicalItem";
import { listPhysicalItem } from "@/api/mes/qc/physicalItem";
import CoilSelector from "@/components/CoilSelector/index.vue";
import CertificatePrintPreview from "./components/CertificatePrintPreview.vue";
+import { templateOptions } from "./components/templates";
import { print as printPdf } from "./lib/printUtils";
export default {
@@ -362,6 +461,7 @@ export default {
},
data() {
return {
+ templateOptions,
buttonLoading: false,
loading: false,
certificateLoading: false,
@@ -380,6 +480,9 @@ export default {
printComponentVisible: false,
printCertificateData: {},
printItemsData: [],
+ templateDialogVisible: false,
+ selectedTemplateType: 'chromium',
+ templateDialogResolve: null,
certificateForm: {
certificateNo: '',
contractNo: '',
@@ -527,13 +630,15 @@ export default {
]);
const chem = chemRes.rows && chemRes.rows[0] || {};
const phys = physRes.rows && physRes.rows[0] || {};
- const { c, si, mn, p, s, als, yieldStrength, tensileStrength, elongation, hardness, bendingTest, surfaceQuality, surfaceStructure, edgeStatus } = { ...chem, ...phys };
- return { c, si, mn, p, s, als, yieldStrength, tensileStrength, elongation, hardness, bendingTest, surfaceQuality, surfaceStructure, edgeStatus };
+ const { c, si, mn, p, s, als, al, ti, cr, ni, cu, n, fe, b } = chem;
+ const { yieldStrength, tensileStrength, elongation, hardness, bendingTest, surfaceQuality, surfaceStructure, edgeStatus, plasticExtensionStrength, coatingSurfaceStructure, coatingMass, coating, surfaceTreatment, zincCoatingWeight } = phys;
+ return { c, si, mn, p, s, als, al, ti, cr, ni, cu, n, fe, b, yieldStrength, tensileStrength, elongation, hardness, bendingTest, surfaceQuality, surfaceStructure, edgeStatus, plasticExtensionStrength, coatingSurfaceStructure, coatingMass, coating, surfaceTreatment, zincCoatingWeight };
},
async handleCoilSelect(row) {
if (this.currentEditRow) {
const editRow = this.currentEditRow;
editRow.coilNo = row.currentCoilNo;
+ editRow.materialNo = row.enterCoilNo;
editRow.materialType = row.material;
editRow.size = row.specification;
editRow.weight = row.netWeight;
@@ -718,6 +823,9 @@ export default {
});
},
async handlePrint() {
+ const confirmed = await this.showTemplateDialog();
+ if (!confirmed) return;
+
this.printCertificateData = this.currentCertificateInfo;
this.printItemsData = this.certificateItemList || [];
this.$nextTick(() => {
@@ -725,6 +833,19 @@ export default {
console.log(el);
printPdf(el);
});
+ },
+ showTemplateDialog() {
+ return new Promise((resolve) => {
+ this.templateDialogResolve = resolve;
+ this.templateDialogVisible = true;
+ });
+ },
+ confirmTemplate() {
+ this.templateDialogVisible = false;
+ if (this.templateDialogResolve) {
+ this.templateDialogResolve(true);
+ this.templateDialogResolve = null;
+ }
}
}
};
@@ -899,4 +1020,46 @@ export default {
::v-deep .el-table .cell {
padding: 0;
}
+
+.template-selection {
+ padding: 20px;
+}
+
+.template-radio-group {
+ display: flex;
+ flex-direction: column;
+ gap: 15px;
+}
+
+.template-radio {
+ display: flex;
+ align-items: center;
+ margin: 0;
+ padding: 15px;
+ border: 1px solid #e4e7ed;
+ border-radius: 8px;
+ transition: all 0.3s ease;
+}
+
+.template-radio:hover {
+ border-color: #409eff;
+ background-color: #ecf5ff;
+}
+
+.template-radio.is-checked {
+ border-color: #409eff;
+ background-color: #ecf5ff;
+}
+
+.template-option {
+ display: flex;
+ align-items: center;
+ gap: 10px;
+ font-size: 14px;
+}
+
+.template-option i {
+ font-size: 20px;
+ color: #409eff;
+}
diff --git a/klp-ui/src/views/wms/coil/components/CoilInfo.vue b/klp-ui/src/views/wms/coil/components/CoilInfo.vue
index f5f6dc7d..b0bf216b 100644
--- a/klp-ui/src/views/wms/coil/components/CoilInfo.vue
+++ b/klp-ui/src/views/wms/coil/components/CoilInfo.vue
@@ -1,20 +1,16 @@
-
+
-
-
+
+
+
+ {{ child.label }}: {{ child.value || '-' }}
+
+
+
{{ item.value || '-' }}
@@ -37,7 +33,7 @@ export default {
type: Boolean,
default: false
},
- // 只显示有值的字段
+ // 只显示有值的字段
showOnlyValue: {
type: Boolean,
default: false
@@ -66,9 +62,22 @@ export default {
{ label: '切边要求', key: 'trimmingRequirement' },
{ label: '原料材质', key: 'packingStatus' },
{ label: '包装要求', key: 'packagingRequirement' },
- { label: '实测厚度[mm]', key: 'actualThickness' },
+ // 设置对照属性,两个数量显示在一个格子里
+ {
+ label: '长度[m]',
+ children: [
+ { label: '实测', key: 'actualLength' },
+ { label: '理论', key: 'theoreticalLength' }
+ ]
+ },
+ {
+ label: '厚度[mm]',
+ children: [
+ { label: '实测', key: 'actualThickness' },
+ { label: '理论', key: 'theoreticalThickness' }
+ ]
+ },
{ label: '实测宽度[mm]', key: 'actualWidth' },
- { label: '长度[m]', key: 'length' },
{ label: '毛重[t]', key: 'grossWeight' },
{ label: '净重[t]', key: 'netWeight' },
{ label: '生产开始', key: 'productionStartTime' },
@@ -80,13 +89,29 @@ export default {
]
},
filteredFields() {
- let fields = this.fields.map(item => ({
- ...item,
- value: this.coilInfo[item.key]
- }))
+ let fields = this.fields.map(item => {
+ if (item.children) {
+ return {
+ ...item,
+ children: item.children.map(child => ({
+ ...child,
+ value: this.coilInfo[child.key]
+ }))
+ }
+ }
+ return {
+ ...item,
+ value: this.coilInfo[item.key]
+ }
+ })
if (this.showOnlyValue) {
- fields = fields.filter(item => item.value !== undefined && item.value !== null && item.value !== '')
+ fields = fields.filter(item => {
+ if (item.children) {
+ return item.children.some(child => child.value !== undefined && child.value !== null && child.value !== '')
+ }
+ return item.value !== undefined && item.value !== null && item.value !== ''
+ })
}
return fields
diff --git a/klp-ui/src/views/wms/coil/panels/LabelRender/DuGeTag.vue b/klp-ui/src/views/wms/coil/panels/LabelRender/DuGeTag.vue
index 6bad8327..7243025c 100644
--- a/klp-ui/src/views/wms/coil/panels/LabelRender/DuGeTag.vue
+++ b/klp-ui/src/views/wms/coil/panels/LabelRender/DuGeTag.vue
@@ -295,6 +295,7 @@ export default {