|
@@ -89,7 +89,9 @@ public class DefaultSqlParamBuilder {
|
|
|
protected Map<String, Object> createConfig(String resultMapId) {
|
|
|
ResultMap resultMaps = ResultMapsUtils.getResultMap(resultMapId);
|
|
|
Map<String, Object> fieldConfig = new HashMap<>();
|
|
|
- resultMaps.getResultMappings().forEach(resultMapping -> {
|
|
|
+ List<ResultMapping> resultMappings=new ArrayList<>(resultMaps.getResultMappings());
|
|
|
+ resultMappings.addAll(resultMaps.getIdResultMappings());
|
|
|
+ resultMappings.forEach(resultMapping -> {
|
|
|
if (resultMapping.getNestedQueryId() == null) {
|
|
|
Map<String, Object> config = new HashMap<>();
|
|
|
config.put("jdbcType", resultMapping.getJdbcType());
|
|
@@ -98,13 +100,6 @@ public class DefaultSqlParamBuilder {
|
|
|
fieldConfig.put(resultMapping.getColumn(), config);
|
|
|
}
|
|
|
});
|
|
|
- resultMaps.getIdResultMappings().forEach(resultMapping -> {
|
|
|
- Map<String, Object> config = new HashMap<>();
|
|
|
- config.put("jdbcType", resultMapping.getJdbcType());
|
|
|
- config.put("javaType", getJavaType(resultMapping.getJavaType()));
|
|
|
- config.put("property", resultMapping.getProperty());
|
|
|
- fieldConfig.put(resultMapping.getColumn(), config);
|
|
|
- });
|
|
|
return fieldConfig;
|
|
|
}
|
|
|
|