From 7874e546c45a503095dbe9ddce5d1e0cea0973af Mon Sep 17 00:00:00 2001 From: Joshi <3040996759@qq.com> Date: Wed, 28 Jan 2026 14:48:13 +0800 Subject: [PATCH 1/7] =?UTF-8?q?feat(WmsMaterialCoil):=20=E6=B7=BB=E5=8A=A0?= =?UTF-8?q?=E9=92=A2=E5=8D=B7=E5=88=97=E8=A1=A8=E6=8E=92=E5=BA=8F=E5=8A=9F?= =?UTF-8?q?=E8=83=BD?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - 新增 orderBy 字段用于接收前端排序参数 - 实现按实际库位绑定状态排序逻辑 - 支持已绑定库位的钢卷优先展示 - 保持原有创建时间倒序作为默认排序方式 - 添加实际库位ID升序排列支持 --- .../java/com/klp/domain/bo/WmsMaterialCoilBo.java | 4 ++++ .../service/impl/WmsMaterialCoilServiceImpl.java | 14 ++++++++++++-- 2 files changed, 16 insertions(+), 2 deletions(-) diff --git a/klp-wms/src/main/java/com/klp/domain/bo/WmsMaterialCoilBo.java b/klp-wms/src/main/java/com/klp/domain/bo/WmsMaterialCoilBo.java index a1e43560..496923a9 100644 --- a/klp-wms/src/main/java/com/klp/domain/bo/WmsMaterialCoilBo.java +++ b/klp-wms/src/main/java/com/klp/domain/bo/WmsMaterialCoilBo.java @@ -237,5 +237,9 @@ public class WmsMaterialCoilBo extends BaseEntity { * 独占状态(0=未独占,1=特殊分卷中) */ private Integer exclusiveStatus; + + // 接收前端传来是否排序的字段 OrderBy + @TableField(exist = false) + private String orderBy; } diff --git a/klp-wms/src/main/java/com/klp/service/impl/WmsMaterialCoilServiceImpl.java b/klp-wms/src/main/java/com/klp/service/impl/WmsMaterialCoilServiceImpl.java index 96725f70..b0ce3187 100644 --- a/klp-wms/src/main/java/com/klp/service/impl/WmsMaterialCoilServiceImpl.java +++ b/klp-wms/src/main/java/com/klp/service/impl/WmsMaterialCoilServiceImpl.java @@ -611,8 +611,18 @@ public class WmsMaterialCoilServiceImpl implements IWmsMaterialCoilService { if (bo.getMinAbnormalCount() != null) { qw.apply("COALESCE(ca.abnormal_count, 0) >= {0}", bo.getMinAbnormalCount()); } - //根据创建时间倒叙 - qw.orderByDesc("mc.create_time"); + // 排序: + // - 当前端需要绑定信息(includeBindInfo=true)时:优先展示“已绑定实际库位”的钢卷(actual_warehouse_id 非空在前) + // 再按实际库位ID升序(库位ID为自增,升序即可满足“先生成的库位在前”) + // - 否则:保持原有创建时间倒序 + if (Boolean.TRUE.equals(bo.getOrderBy())) { + // MySQL: false(0) < true(1),因此 "IS NULL" 升序可实现非空在前、空值在后 + qw.orderByAsc("mc.actual_warehouse_id IS NULL"); + qw.orderByAsc("mc.actual_warehouse_id"); + } else { + //根据创建时间倒叙 + qw.orderByDesc("mc.create_time"); + } return qw; } From 747fde261659eb0d91ecdb6ca0d4ad04c3f9cf1c Mon Sep 17 00:00:00 2001 From: Joshi <3040996759@qq.com> Date: Wed, 28 Jan 2026 14:48:49 +0800 Subject: [PATCH 2/7] =?UTF-8?q?fix(domain):=20=E4=BF=AE=E6=AD=A3WmsMateria?= =?UTF-8?q?lCoilBo=E4=B8=ADorderBy=E5=AD=97=E6=AE=B5=E6=95=B0=E6=8D=AE?= =?UTF-8?q?=E7=B1=BB=E5=9E=8B?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - 将orderBy字段从String类型修改为Boolean类型 - 保持TableField注解配置不变 --- klp-wms/src/main/java/com/klp/domain/bo/WmsMaterialCoilBo.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/klp-wms/src/main/java/com/klp/domain/bo/WmsMaterialCoilBo.java b/klp-wms/src/main/java/com/klp/domain/bo/WmsMaterialCoilBo.java index 496923a9..ef26f94a 100644 --- a/klp-wms/src/main/java/com/klp/domain/bo/WmsMaterialCoilBo.java +++ b/klp-wms/src/main/java/com/klp/domain/bo/WmsMaterialCoilBo.java @@ -240,6 +240,6 @@ public class WmsMaterialCoilBo extends BaseEntity { // 接收前端传来是否排序的字段 OrderBy @TableField(exist = false) - private String orderBy; + private Boolean orderBy; } From 1614358bbe0615b6bcd972369e9faf81f29b3c83 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E7=A0=82=E7=B3=96?= Date: Wed, 28 Jan 2026 15:16:37 +0800 Subject: [PATCH 3/7] =?UTF-8?q?feat(=E9=92=A2=E5=8D=B7=E9=80=89=E6=8B=A9?= =?UTF-8?q?=E5=99=A8):=20=E5=A2=9E=E5=8A=A0=E6=8C=89=E5=AE=9E=E9=99=85?= =?UTF-8?q?=E5=BA=93=E5=8C=BA=E7=AD=9B=E9=80=89=E9=92=A2=E5=8D=B7=E5=8A=9F?= =?UTF-8?q?=E8=83=BD?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 在钢卷选择器中添加实际库区筛选功能,并调整对话框宽度以适应新增控件。修改了detailTable.vue中的调用参数以启用该功能。 --- klp-ui/src/components/CoilSelector/index.vue | 15 +++++++++++++-- .../views/wms/delivery/components/detailTable.vue | 4 +++- 2 files changed, 16 insertions(+), 3 deletions(-) diff --git a/klp-ui/src/components/CoilSelector/index.vue b/klp-ui/src/components/CoilSelector/index.vue index 5acd7105..34fb5399 100644 --- a/klp-ui/src/components/CoilSelector/index.vue +++ b/klp-ui/src/components/CoilSelector/index.vue @@ -39,6 +39,9 @@ + + + 搜索 @@ -86,12 +89,14 @@ import { listMaterialCoil } from '@/api/wms/coil'; import MemoInput from '@/components/MemoInput/index.vue'; import MutiSelect from '@/components/MutiSelect/index.vue'; import { defaultColumns } from './data'; +import ActualWarehouseSelect from '@/components/KLPService/ActualWarehouseSelect/index.vue'; export default { name: 'CoilSelector', components: { MemoInput, - MutiSelect + MutiSelect, + ActualWarehouseSelect }, dicts: ['coil_itemname', 'coil_material', 'coil_manufacturer'], props: { @@ -102,7 +107,7 @@ export default { }, dialogWidth: { type: String, - default: '900px' + default: '1000px' }, // 过滤条件(可以预设一些查询条件) filters: { @@ -146,6 +151,11 @@ export default { type: Boolean, default: false }, + // 是否根据实际库区查询钢卷 + orderBy: { + type: Boolean, + default: false + }, }, data() { return { @@ -161,6 +171,7 @@ export default { pageSize: 10, currentCoilNo: null, grade: null, + actualWarehouseId: null, selectType: 'product', status: 0, // 不包含已发货的钢卷 dataType: 1 // 只查询当前数据,不查询历史数据 diff --git a/klp-ui/src/views/wms/delivery/components/detailTable.vue b/klp-ui/src/views/wms/delivery/components/detailTable.vue index ae0bd304..14ba0d00 100644 --- a/klp-ui/src/views/wms/delivery/components/detailTable.vue +++ b/klp-ui/src/views/wms/delivery/components/detailTable.vue @@ -48,7 +48,9 @@
- +
From d15a629300fd9b32796c4863d5f82eb421d2284c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E7=A0=82=E7=B3=96?= Date: Wed, 28 Jan 2026 15:26:50 +0800 Subject: [PATCH 4/7] =?UTF-8?q?fix:=20=E4=BF=AE=E5=A4=8DMemoInput=E7=A9=BA?= =?UTF-8?q?=E5=80=BC=E5=A4=84=E7=90=86=E5=92=8CCoilSelector=E6=9F=A5?= =?UTF-8?q?=E8=AF=A2=E5=8F=82=E6=95=B0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 修复MemoInput组件在空值情况下未触发input事件的问题,并更新CoilSelector组件的查询参数命名以保持一致性 --- klp-ui/src/components/CoilSelector/index.vue | 11 ++++++++++- klp-ui/src/components/MemoInput/index.vue | 2 ++ 2 files changed, 12 insertions(+), 1 deletion(-) diff --git a/klp-ui/src/components/CoilSelector/index.vue b/klp-ui/src/components/CoilSelector/index.vue index 34fb5399..915dfd27 100644 --- a/klp-ui/src/components/CoilSelector/index.vue +++ b/klp-ui/src/components/CoilSelector/index.vue @@ -19,6 +19,12 @@ @close="handleClose" append-to-body> + @@ -28,7 +34,7 @@ clearable /> - @@ -171,6 +177,9 @@ export default { pageSize: 10, currentCoilNo: null, grade: null, + itemSpecification: null, + itemMaterial: null, + itemManufacturer: null, actualWarehouseId: null, selectType: 'product', status: 0, // 不包含已发货的钢卷 diff --git a/klp-ui/src/components/MemoInput/index.vue b/klp-ui/src/components/MemoInput/index.vue index f78bf183..7cd958b1 100644 --- a/klp-ui/src/components/MemoInput/index.vue +++ b/klp-ui/src/components/MemoInput/index.vue @@ -136,6 +136,8 @@ export default { this.cacheInputValue(value.trim()); // 触发自定义事件,通知父组件输入结果 this.$emit('input', value.trim()); + } else { + this.$emit('input', ''); } }, From c87b43ae954d917be5e3f984935ec9f3fac2392c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E7=A0=82=E7=B3=96?= Date: Wed, 28 Jan 2026 17:22:32 +0800 Subject: [PATCH 5/7] =?UTF-8?q?feat(wms):=20=E6=9B=B4=E6=96=B0=E9=92=A2?= =?UTF-8?q?=E5=8D=B7=E8=BF=BD=E6=BA=AF=E5=8A=9F=E8=83=BD=E5=B9=B6=E4=BC=98?= =?UTF-8?q?=E5=8C=96=E5=8F=91=E8=B4=A7=E5=8D=95=E7=8A=B6=E6=80=81=E7=AE=A1?= =?UTF-8?q?=E7=90=86?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - 在detailTable.vue中将edgeType字段从edgeRequirement改为trimmingRequirement - 在waybill/index.vue和bills/index.vue中注释掉导出按钮 - 在base.vue中为钢卷追溯添加加载状态 - 在bills/index.vue中启用发货状态选择器并添加状态更新逻辑 - 重构CoilTraceResult.vue,优化钢卷追溯信息展示和交互体验 --- .../views/wms/coil/panels/CoilTraceResult.vue | 784 +++++++++++------- klp-ui/src/views/wms/coil/panels/base.vue | 7 +- klp-ui/src/views/wms/delivery/bills/index.vue | 23 +- .../wms/delivery/components/detailTable.vue | 2 +- .../src/views/wms/delivery/waybill/index.vue | 2 +- 5 files changed, 517 insertions(+), 301 deletions(-) diff --git a/klp-ui/src/views/wms/coil/panels/CoilTraceResult.vue b/klp-ui/src/views/wms/coil/panels/CoilTraceResult.vue index 863c6cfd..ee45f910 100644 --- a/klp-ui/src/views/wms/coil/panels/CoilTraceResult.vue +++ b/klp-ui/src/views/wms/coil/panels/CoilTraceResult.vue @@ -1,175 +1,179 @@ \ No newline at end of file diff --git a/klp-ui/src/views/wms/coil/panels/base.vue b/klp-ui/src/views/wms/coil/panels/base.vue index 243be7ae..3a08d993 100644 --- a/klp-ui/src/views/wms/coil/panels/base.vue +++ b/klp-ui/src/views/wms/coil/panels/base.vue @@ -268,7 +268,7 @@ - + @@ -411,6 +411,8 @@ export default { buttonLoading: false, // 遮罩层 loading: true, + // 追溯加载中 + traceLoading: false, // 选中数组 ids: [], // 非单个禁用 @@ -646,6 +648,7 @@ export default { /** 追溯按钮操作 */ handleTrace(row) { this.traceOpen = true; + this.traceLoading = true; this.traceResult = null; // 清空历史数据 getMaterialCoilTrace({ enterCoilNo: row.enterCoilNo, @@ -655,6 +658,8 @@ export default { }).catch(err => { console.error('溯源查询失败:', err); this.$message.error('溯源查询失败,请重试'); + }).finally(() => { + this.traceLoading = false; }); }, handleGradeChange(row) { diff --git a/klp-ui/src/views/wms/delivery/bills/index.vue b/klp-ui/src/views/wms/delivery/bills/index.vue index 43b49b97..6cb36dde 100644 --- a/klp-ui/src/views/wms/delivery/bills/index.vue +++ b/klp-ui/src/views/wms/delivery/bills/index.vue @@ -15,7 +15,7 @@ 刷新 - 导出 + @@ -33,12 +33,12 @@ @@ -62,7 +62,7 @@