diff --git a/src/main/java/cn/iocoder/dashboard/modules/tool/dal/mysql/codegen/ToolSchemaColumnMapper.java b/src/main/java/cn/iocoder/dashboard/modules/tool/dal/mysql/codegen/ToolSchemaColumnMapper.java index 0ddfe4db2..14a0302da 100644 --- a/src/main/java/cn/iocoder/dashboard/modules/tool/dal/mysql/codegen/ToolSchemaColumnMapper.java +++ b/src/main/java/cn/iocoder/dashboard/modules/tool/dal/mysql/codegen/ToolSchemaColumnMapper.java @@ -10,7 +10,7 @@ import java.util.List; @Mapper public interface ToolSchemaColumnMapper extends BaseMapperX { - default List selectListByTableName(String tableSchema,String tableName) { + default List selectListByTableName(String tableSchema, String tableName) { return selectList(new QueryWrapper().eq("table_name", tableName) .eq("table_schema", tableSchema) .orderByAsc("ordinal_position")); diff --git a/src/main/java/cn/iocoder/dashboard/modules/tool/dal/mysql/codegen/ToolSchemaTableMapper.java b/src/main/java/cn/iocoder/dashboard/modules/tool/dal/mysql/codegen/ToolSchemaTableMapper.java index 89821ae1c..622257c1c 100644 --- a/src/main/java/cn/iocoder/dashboard/modules/tool/dal/mysql/codegen/ToolSchemaTableMapper.java +++ b/src/main/java/cn/iocoder/dashboard/modules/tool/dal/mysql/codegen/ToolSchemaTableMapper.java @@ -22,7 +22,7 @@ public interface ToolSchemaTableMapper extends BaseMapperX { return selectList(new QueryWrapper().eq("table_schema", tableSchema)); } - default ToolSchemaTableDO selectByTableName1(String tableSchema,String tableName) { + default ToolSchemaTableDO selectByTableName1(String tableSchema, String tableName) { return selectOne(new QueryWrapper().eq("table_schema",tableSchema) .eq("table_name", tableName)); } diff --git a/src/main/java/cn/iocoder/dashboard/modules/tool/service/codegen/impl/ToolCodegenServiceImpl.java b/src/main/java/cn/iocoder/dashboard/modules/tool/service/codegen/impl/ToolCodegenServiceImpl.java index cff4931b9..adb9fbfec 100644 --- a/src/main/java/cn/iocoder/dashboard/modules/tool/service/codegen/impl/ToolCodegenServiceImpl.java +++ b/src/main/java/cn/iocoder/dashboard/modules/tool/service/codegen/impl/ToolCodegenServiceImpl.java @@ -104,8 +104,8 @@ public class ToolCodegenServiceImpl implements ToolCodegenService { //获取当前schema String tableSchema = codegenProperties.getDbSchemas().iterator().next(); // 从数据库中,获得数据库表结构 - ToolSchemaTableDO schemaTable = schemaTableMapper.selectByTableName1(tableSchema,tableName); - List schemaColumns = schemaColumnMapper.selectListByTableName(tableSchema,tableName); + ToolSchemaTableDO schemaTable = schemaTableMapper.selectByTableName1(tableSchema, tableName); + List schemaColumns = schemaColumnMapper.selectListByTableName(tableSchema, tableName); // 导入 return this.createCodegen0(ToolCodegenImportTypeEnum.DB, schemaTable, schemaColumns); } @@ -145,7 +145,7 @@ public class ToolCodegenServiceImpl implements ToolCodegenService { } String tableSchema = codegenProperties.getDbSchemas().iterator().next(); // 从数据库中,获得数据库表结构 - List schemaColumns = schemaColumnMapper.selectListByTableName(tableSchema,table.getTableName()); + List schemaColumns = schemaColumnMapper.selectListByTableName(tableSchema, table.getTableName()); // 执行同步 this.syncCodegen0(tableId, schemaColumns);