From b6dcc7c1c6778cf8804db3cf9633c22f66271ac2 Mon Sep 17 00:00:00 2001 From: yulichang <570810310@qq.com> Date: Mon, 27 Mar 2023 10:59:46 +0800 Subject: [PATCH] =?UTF-8?q?=E6=B3=9B=E5=9E=8B=E4=BC=98=E5=8C=96?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../yulichang/interceptor/MPJInterceptor.java | 19 +++++---- .../yulichang/toolkit/JoinWrappers.java | 8 ++-- .../github/yulichang/toolkit/LambdaUtils.java | 3 +- .../yulichang/toolkit/MPJReflectionKit.java | 42 +++++++++---------- .../yulichang/toolkit/VersionUtils.java | 6 +++ .../yulichang/toolkit/support/FieldCache.java | 19 +++++++++ .../yulichang/wrapper/interfaces/Query.java | 4 +- .../wrapper/interfaces/QueryLabel.java | 26 ++++++------ .../wrapper/resultmap/MybatisLabel.java | 30 ++++++------- .../wrapper/resultmap/MybatisLabelFree.java | 26 ++++++------ .../wrapper/segments/SelectLabel.java | 10 +---- .../yulichang/test/join/entity/AddressDO.java | 21 +--------- .../test/join/entity/AddressGeneric.java | 24 +++++++++++ .../test/join/LambdaWrapperTest.java | 22 +++++++--- 14 files changed, 147 insertions(+), 113 deletions(-) create mode 100644 mybatis-plus-join-core/src/main/java/com/github/yulichang/toolkit/support/FieldCache.java create mode 100644 mybatis-plus-join-test/test-join/src/main/java/com/github/yulichang/test/join/entity/AddressGeneric.java diff --git a/mybatis-plus-join-core/src/main/java/com/github/yulichang/interceptor/MPJInterceptor.java b/mybatis-plus-join-core/src/main/java/com/github/yulichang/interceptor/MPJInterceptor.java index fa5e29b..f2d2788 100644 --- a/mybatis-plus-join-core/src/main/java/com/github/yulichang/interceptor/MPJInterceptor.java +++ b/mybatis-plus-join-core/src/main/java/com/github/yulichang/interceptor/MPJInterceptor.java @@ -9,6 +9,7 @@ import com.github.yulichang.query.MPJQueryWrapper; import com.github.yulichang.toolkit.Constant; import com.github.yulichang.toolkit.MPJReflectionKit; import com.github.yulichang.toolkit.TableHelper; +import com.github.yulichang.toolkit.support.FieldCache; import com.github.yulichang.wrapper.MPJLambdaWrapper; import com.github.yulichang.wrapper.resultmap.Label; import com.github.yulichang.wrapper.resultmap.Result; @@ -168,7 +169,7 @@ public class MPJInterceptor implements Interceptor { return result; } MPJLambdaWrapper wrapper = (MPJLambdaWrapper) obj; - Map fieldMap = MPJReflectionKit.getFieldMap(resultType); + Map fieldMap = MPJReflectionKit.getFieldMap(resultType); List