Skip to content

Commit

Permalink
fix: Fix issue If there are enumerations in the query request paramet…
Browse files Browse the repository at this point in the history
…ers, the generated request parameter comments will not include 'See'.
  • Loading branch information
gongyangfan committed Oct 31, 2024
1 parent 2a15d8b commit 49c79fd
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions src/main/java/com/ly/doc/template/IRestDocTemplate.java
Original file line number Diff line number Diff line change
Expand Up @@ -1175,6 +1175,12 @@ else if (javaClass.isEnum()) {
if (Boolean.TRUE.equals(builder.getApiConfig().getInlineEnum())) {
comment.append("<br/>[Enum: ").append(StringUtil.removeQuotes(enumName)).append("]");
}
else {
String enumComments = javaClass.getComment();
if (StringUtil.isNotEmpty(enumComments)) {
comment.append("<br/>(See: ").append(enumComments).append(")");
}
}
ApiParam param = ApiParam.of()
.setField(paramName)
.setId(paramList.size() + 1)
Expand Down

0 comments on commit 49c79fd

Please sign in to comment.