130 lines
5.9 KiB
XML
130 lines
5.9 KiB
XML
|
<?xml version="1.0" encoding="UTF-8"?>
|
|||
|
<!DOCTYPE generatorConfiguration
|
|||
|
PUBLIC "-//mybatis.org//DTD MyBatis Generator Configuration 1.0//EN"
|
|||
|
"http://mybatis.org/dtd/mybatis-generator-config_1_0.dtd">
|
|||
|
<generatorConfiguration>
|
|||
|
<!--数据库驱动 -->
|
|||
|
<classPathEntry location="mysql-connector-java-5.1.38.jar"/>
|
|||
|
<context id="DB2Tables" targetRuntime="MyBatis3">
|
|||
|
<!-- 生成的Java文件的编码 -->
|
|||
|
<property name="javaFileEncoding" value="UTF-8"/>
|
|||
|
<!-- 格式化java代码 -->
|
|||
|
<property name="javaFormatter" value="org.mybatis.generator.api.dom.DefaultJavaFormatter"/>
|
|||
|
<!-- 格式化XML代码 -->
|
|||
|
<property name="xmlFormatter" value="org.mybatis.generator.api.dom.DefaultXmlFormatter"/>
|
|||
|
<!-- JavaBean 实现 序列化 接口 -->
|
|||
|
<plugin type="org.mybatis.generator.plugins.SerializablePlugin"/>
|
|||
|
<!-- 以上为插件配置信息 -->
|
|||
|
<!-- 是否去除自动生成的注释 true:是;false:否 -->
|
|||
|
<commentGenerator>
|
|||
|
<!--生成的注释包含时间戳-->
|
|||
|
<property name="suppressDate" value="true"/>
|
|||
|
<property name="suppressAllComments" value="true"/>
|
|||
|
</commentGenerator>
|
|||
|
<!--数据库连接的信息:驱动类、连接地址、用户名、密码 -->
|
|||
|
<jdbcConnection
|
|||
|
driverClass="com.mysql.jdbc.Driver"
|
|||
|
connectionURL="jdbc:Mysql://47.103.14.6:3306/zilean-bms?characterEncoding=utf8"
|
|||
|
userId="root"
|
|||
|
password="$oDboy*#sDa22#11">
|
|||
|
<property name="useInformationSchema" value="true"/>
|
|||
|
</jdbcConnection>
|
|||
|
<!-- 默认false,把JDBC DECIMAL 和 NUMERIC 类型解析为 Integer,为 true时把JDBC DECIMAL 和 NUMERIC 类型解析为java.math.BigDecimal -->
|
|||
|
<javaTypeResolver>
|
|||
|
<property name="forceBigDecimals" value="false"/>
|
|||
|
</javaTypeResolver>
|
|||
|
<!--生成Model类存放位置 -->
|
|||
|
<!-- targetProject:生成PO类的位置 -->
|
|||
|
<javaModelGenerator targetPackage="cn.odboy.zilean.core.entity" targetProject="src/main/java">
|
|||
|
<!-- enableSubPackages:是否让schema作为包的后缀 -->
|
|||
|
<property name="enableSubPackages" value="true"/>
|
|||
|
<!-- 从数据库返回的值被清理前后的空格 -->
|
|||
|
<property name="trimStrings" value="true"/>
|
|||
|
</javaModelGenerator>
|
|||
|
<!--生成映射文件存放位置 -->
|
|||
|
<sqlMapGenerator targetPackage="cn.odboy.zilean.dao" targetProject="src/main/java">
|
|||
|
<!-- enableSubPackages:是否让schema作为包的后缀 -->
|
|||
|
<property name="enableSubPackages" value="true"/>
|
|||
|
</sqlMapGenerator>
|
|||
|
<!--生成Dao类存放位置 -->
|
|||
|
<!--
|
|||
|
ANNOTATEDMAPPER: 生成java类文件,基于注解的Mapper接口,不会有对应的XML映射文件
|
|||
|
MIXEDMAPPER:XML和注解的混合形式
|
|||
|
XMLMAPPER:所有的方法都在XML中,接口调用依赖XML文件
|
|||
|
-->
|
|||
|
<javaClientGenerator type="XMLMAPPER" targetPackage="cn.odboy.zilean.dao" targetProject="src/main/java">
|
|||
|
<property name="enableSubPackages" value="true"/>
|
|||
|
</javaClientGenerator>
|
|||
|
<!-- tableName:用于自动生成代码的数据库表;domainObjectName:对应于数据库表的javaBean类名 -->
|
|||
|
<table
|
|||
|
schema=""
|
|||
|
tableName="t_dict_data"
|
|||
|
domainObjectName="DictData"
|
|||
|
enableCountByExample="false"
|
|||
|
enableUpdateByExample="false"
|
|||
|
enableDeleteByExample="false"
|
|||
|
enableSelectByExample="false"
|
|||
|
selectByExampleQueryId="false">
|
|||
|
</table>
|
|||
|
<table
|
|||
|
schema=""
|
|||
|
tableName="t_dict_Type"
|
|||
|
domainObjectName="DictType"
|
|||
|
enableCountByExample="false"
|
|||
|
enableUpdateByExample="false"
|
|||
|
enableDeleteByExample="false"
|
|||
|
enableSelectByExample="false"
|
|||
|
selectByExampleQueryId="false">
|
|||
|
</table>
|
|||
|
<table
|
|||
|
schema=""
|
|||
|
tableName="t_operation_log"
|
|||
|
domainObjectName="OperationLog"
|
|||
|
enableCountByExample="false"
|
|||
|
enableUpdateByExample="false"
|
|||
|
enableDeleteByExample="false"
|
|||
|
enableSelectByExample="false"
|
|||
|
selectByExampleQueryId="false">
|
|||
|
</table>
|
|||
|
<table
|
|||
|
schema=""
|
|||
|
tableName="t_permission"
|
|||
|
domainObjectName="Permission"
|
|||
|
enableCountByExample="false"
|
|||
|
enableUpdateByExample="false"
|
|||
|
enableDeleteByExample="false"
|
|||
|
enableSelectByExample="false"
|
|||
|
selectByExampleQueryId="false">
|
|||
|
</table>
|
|||
|
<table
|
|||
|
schema=""
|
|||
|
tableName="t_role"
|
|||
|
domainObjectName="Role"
|
|||
|
enableCountByExample="false"
|
|||
|
enableUpdateByExample="false"
|
|||
|
enableDeleteByExample="false"
|
|||
|
enableSelectByExample="false"
|
|||
|
selectByExampleQueryId="false">
|
|||
|
</table>
|
|||
|
<table
|
|||
|
schema=""
|
|||
|
tableName="t_role_permission"
|
|||
|
domainObjectName="RolePermission"
|
|||
|
enableCountByExample="false"
|
|||
|
enableUpdateByExample="false"
|
|||
|
enableDeleteByExample="false"
|
|||
|
enableSelectByExample="false"
|
|||
|
selectByExampleQueryId="false">
|
|||
|
</table>
|
|||
|
<table
|
|||
|
schema=""
|
|||
|
tableName="t_user"
|
|||
|
domainObjectName="User"
|
|||
|
enableCountByExample="false"
|
|||
|
enableUpdateByExample="false"
|
|||
|
enableDeleteByExample="false"
|
|||
|
enableSelectByExample="false"
|
|||
|
selectByExampleQueryId="false">
|
|||
|
</table>
|
|||
|
</context>
|
|||
|
</generatorConfiguration>
|