From c04b2f6b3f92261f3184a41235f97ff3d03e0995 Mon Sep 17 00:00:00 2001 From: nixj Date: Tue, 9 Jul 2024 16:58:58 +0800 Subject: [PATCH] =?UTF-8?q?=E3=80=90fix=E3=80=91=E4=BF=AE=E5=A4=8Did?= =?UTF-8?q?=E5=AD=97=E6=AE=B5=E5=8F=96=E9=94=99=E9=97=AE=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../service/order_record/LYOrderRecordDomainService.java | 8 ++++---- .../repository/jdbc/JdbcLyOrderCarRecord.java | 2 +- .../repository/jdbc/JdbcLyOrderFlightRecord.java | 2 +- .../repository/jdbc/JdbcLyOrderHotelRecord.java | 2 +- .../repository/jdbc/JdbcLyOrderTrainRecord.java | 2 +- src/test/java/com/chint/ExcelTest.java | 6 +++--- 6 files changed, 11 insertions(+), 11 deletions(-) diff --git a/src/main/java/com/chint/domain/service/order_record/LYOrderRecordDomainService.java b/src/main/java/com/chint/domain/service/order_record/LYOrderRecordDomainService.java index aa0f18f1..02bb7754 100644 --- a/src/main/java/com/chint/domain/service/order_record/LYOrderRecordDomainService.java +++ b/src/main/java/com/chint/domain/service/order_record/LYOrderRecordDomainService.java @@ -88,7 +88,7 @@ public class LYOrderRecordDomainService { .map(it -> lyOrderRecordExtensionFactory.createFlightOrderRecord(it, collect.get(it.getOutApplayOrderNo()))) .toList(); orderDetailDomainService.saveFlightOrderRecordBatch(orderFlightRecordList); - jdbcLyOrderFlightRecord.updateStatusByIds(orderFlightRecordList.stream().map(OrderFlightRecord::getId).toList()); + jdbcLyOrderFlightRecord.updateStatusByIds(lyOrderFlightRecordPageList.stream().map(LyOrderFlightRecord::getId).toList()); count++; } while (count < LoopNum); //修改数据,将状态为null的设置为1 @@ -121,7 +121,7 @@ public class LYOrderRecordDomainService { .map(it -> lyOrderRecordExtensionFactory.createHotelOrderRecord(it, collect.get(it.getOutApplayOrderNo()))) .toList(); orderDetailDomainService.saveHotelOrderRecordBatch(orderHotelRecordList); - jdbcLyOrderHotelRecord.updateStatusByIds(orderHotelRecordList.stream().map(OrderHotelRecord::getId).toList()); + jdbcLyOrderHotelRecord.updateStatusByIds(lyOrderHotelRecordPageList.stream().map(LyOrderHotelRecord::getId).toList()); count++; } while (count < LoopNum); //修改数据,将状态为null的设置为1 @@ -153,7 +153,7 @@ public class LYOrderRecordDomainService { .map(it -> lyOrderRecordExtensionFactory.createTrainOrderRecord(it, collect.get(it.getOutApplayOrderNo()))) .toList(); orderDetailDomainService.saveTrainOrderRecordBatch(orderTrainRecordList); - jdbcLyOrderTrainRecord.updateStatusByIds(orderTrainRecordList.stream().map(OrderTrainRecord::getId).toList()); + jdbcLyOrderTrainRecord.updateStatusByIds(lyOrderTrainRecordPageList.stream().map(LyOrderTrainRecord::getId).toList()); count++; } while (count < LoopNum); //修改数据,将状态为null的设置为1 @@ -187,7 +187,7 @@ public class LYOrderRecordDomainService { .map(it -> lyOrderRecordExtensionFactory.createCarOrderRecord(it, collect.get(it.getOutApplayOrderNo()))) .toList(); orderDetailDomainService.saveCarOrderRecordBatch(orderCarRecordList); - jdbcLyOrderCarRecord.updateStatusByIds(orderCarRecordList.stream().map(OrderCarRecord::getId).toList()); + jdbcLyOrderCarRecord.updateStatusByIds(lyOrderCarRecordPageList.stream().map(LyOrderCarRecord::getId).toList()); count++; } while (count < LoopNum); //修改数据,将状态为null的设置为1 diff --git a/src/main/java/com/chint/infrastructure/repository/jdbc/JdbcLyOrderCarRecord.java b/src/main/java/com/chint/infrastructure/repository/jdbc/JdbcLyOrderCarRecord.java index 9b270e89..c18dedf8 100644 --- a/src/main/java/com/chint/infrastructure/repository/jdbc/JdbcLyOrderCarRecord.java +++ b/src/main/java/com/chint/infrastructure/repository/jdbc/JdbcLyOrderCarRecord.java @@ -26,5 +26,5 @@ public interface JdbcLyOrderCarRecord extends CrudRepository ids); + void updateStatusByIds(@Param("ids") List ids); } diff --git a/src/main/java/com/chint/infrastructure/repository/jdbc/JdbcLyOrderFlightRecord.java b/src/main/java/com/chint/infrastructure/repository/jdbc/JdbcLyOrderFlightRecord.java index bf468bb7..f5e7094f 100644 --- a/src/main/java/com/chint/infrastructure/repository/jdbc/JdbcLyOrderFlightRecord.java +++ b/src/main/java/com/chint/infrastructure/repository/jdbc/JdbcLyOrderFlightRecord.java @@ -26,5 +26,5 @@ public interface JdbcLyOrderFlightRecord extends CrudRepository ids); + void updateStatusByIds(@Param("ids") List ids); } diff --git a/src/main/java/com/chint/infrastructure/repository/jdbc/JdbcLyOrderHotelRecord.java b/src/main/java/com/chint/infrastructure/repository/jdbc/JdbcLyOrderHotelRecord.java index 37099670..688851d1 100644 --- a/src/main/java/com/chint/infrastructure/repository/jdbc/JdbcLyOrderHotelRecord.java +++ b/src/main/java/com/chint/infrastructure/repository/jdbc/JdbcLyOrderHotelRecord.java @@ -27,5 +27,5 @@ public interface JdbcLyOrderHotelRecord extends CrudRepository ids); + void updateStatusByIds(@Param("ids") List ids); } diff --git a/src/main/java/com/chint/infrastructure/repository/jdbc/JdbcLyOrderTrainRecord.java b/src/main/java/com/chint/infrastructure/repository/jdbc/JdbcLyOrderTrainRecord.java index a2c16c53..e3668f6b 100644 --- a/src/main/java/com/chint/infrastructure/repository/jdbc/JdbcLyOrderTrainRecord.java +++ b/src/main/java/com/chint/infrastructure/repository/jdbc/JdbcLyOrderTrainRecord.java @@ -26,5 +26,5 @@ public interface JdbcLyOrderTrainRecord extends CrudRepository ids); + void updateStatusByIds(@Param("ids") List ids); } diff --git a/src/test/java/com/chint/ExcelTest.java b/src/test/java/com/chint/ExcelTest.java index 2d0dd0ab..8cc74af8 100644 --- a/src/test/java/com/chint/ExcelTest.java +++ b/src/test/java/com/chint/ExcelTest.java @@ -100,9 +100,9 @@ public class ExcelTest { @Test public void excelTest() { - List ids=new ArrayList<>(); - ids.add(1L); - ids.add(2L); + List ids=new ArrayList<>(); + ids.add(1); + ids.add(2); jdbcLyOrderFlightRecord.updateStatusByIds(ids); jdbcLyOrderHotelRecord.updateStatusByIds(ids); jdbcLyOrderTrainRecord.updateStatusByIds(ids);