Browse Source

修复Beetl模板引擎无法生成注释

https://github.com/baomidou/mybatis-plus/issues/5054
lanjerry 1 year ago
parent
commit
9847055990

+ 1 - 1
mybatis-plus-generator/src/main/resources/templates/entity.java.btl

@@ -36,7 +36,7 @@ import lombok.experimental.Accessors;
 @TableName("${schemaName}${table.name}")
 <% } %>
 <% if(springdoc){ %>
-@Schema(name = "${entity}", description = "$!{table.comment}")
+@Schema(name = "${entity}", description = "${table.comment!''}")
 <% }else if(swagger){ %>
 @ApiModel(value = "${entity}对象", description = "${table.comment!''}")
 <% } %>