From 85eb2837e3b3bf5411b332aa2cc38d2755e0d3bf Mon Sep 17 00:00:00 2001
From: yeg <1347747024@qq.com>
Date: 星期六, 05 九月 2026 01:27:19 +0800
Subject: [PATCH] 完成电池组当前字段与测试绑定

---
 ruoyi-system/src/main/java/com/ruoyi/system/domain/TTestCollectorChannel.java |    4 ++++
 1 files changed, 4 insertions(+), 0 deletions(-)

diff --git a/ruoyi-system/src/main/java/com/ruoyi/system/domain/TTestCollectorChannel.java b/ruoyi-system/src/main/java/com/ruoyi/system/domain/TTestCollectorChannel.java
index f5af607..4b91336 100644
--- a/ruoyi-system/src/main/java/com/ruoyi/system/domain/TTestCollectorChannel.java
+++ b/ruoyi-system/src/main/java/com/ruoyi/system/domain/TTestCollectorChannel.java
@@ -11,6 +11,8 @@
     private Long mappingId;
     private Long testId;
     private Long batteryRelationId;
+    /** 最终数据库列名对应的测试电池主键。 */
+    private Long testBatteryId;
     private Long collectorId;
     @NotBlank(message = "采集器测量项编码不能为空")
     private String measurementCode;
@@ -25,6 +27,8 @@
     public void setTestId(Long value) { testId = value; }
     public Long getBatteryRelationId() { return batteryRelationId; }
     public void setBatteryRelationId(Long value) { batteryRelationId = value; }
+    public Long getTestBatteryId() { return testBatteryId != null ? testBatteryId : batteryRelationId; }
+    public void setTestBatteryId(Long value) { testBatteryId = value; batteryRelationId = value; }
     public Long getCollectorId() { return collectorId; }
     public void setCollectorId(Long value) { collectorId = value; }
     public String getMeasurementCode() { return measurementCode; }

--
Gitblit v1.7.1