Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

生成的实体类注释乱码了 #925

Copy link
Copy link
@tslzs

Description

@tslzs
Issue body actions

/**
* CgI2WRIIcXZyVUVkRDEaELAKonyXMCONyYIZqfjOKYswAg==
*/
@column(name = "description")
private String description;
自动生成的实体类字段的注释乱码了,是由于什么原因呢?xml的配置如下:

    <plugin type="tk.mybatis.mapper.generator.MapperPlugin">
        <property name="mappers" value="tk.mybatis.mapper.common.Mapper"/>
        <property name="caseSensitive" value="true"/>
       <property name="forceAnnotation" value="true"/>
        <property name="beginningDelimiter" value="`"/>
        <property name="endingDelimiter" value="`"/>
        <property name="lombok" value="Data"/>
    </plugin>
    <plugin type="org.mybatis.generator.plugins.SerializablePlugin"/>

    <commentGenerator>
        <property name="suppressAllComments" value="true"/>
    </commentGenerator>

    <jdbcConnection driverClass="com.mysql.cj.jdbc.Driver"
                    connectionURL="xxx&amp;useUnicode=true&amp;characterEncoding=UTF-8"
                    userId="xx"
                    password="xxx">
    </jdbcConnection>

    <!--MyBatis 生成器只需要生成 Model-->
    <javaModelGenerator targetPackage="org.example.testspringboot.entity"
                        targetProject="src/main/java"/>
    <sqlMapGenerator targetPackage="mapper"
                     targetProject="src/main/resources">
        <property name="enableSubPackages" value="false"/>
    </sqlMapGenerator>

    <javaClientGenerator type="XMLMAPPER" targetPackage="org.example.testspringboot.mapper"
                         targetProject="src/main/java">
        <property name="enableSubPackages" value="false"/>
    </javaClientGenerator>


    <table schema="s" tableName="ss" domainObjectName="ss">
        <generatedKey column="id" sqlStatement="JDBC" identity="true"/>
    </table>
</context>
Reactions are currently unavailable

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

      Morty Proxy This is a proxified and sanitized view of the page, visit original site.