page.list.dto.java.ftl 986 B

123456789101112131415161718192021222324252627282930313233343536
  1. package ${package};
  2. ${isPage?string("import com.xjrsoft.common.page.PageInput;","import com.xjrsoft.common.page.ListInput;")}
  3. import io.swagger.annotations.ApiModelProperty;
  4. import lombok.Data;
  5. import lombok.EqualsAndHashCode;
  6. import org.springframework.format.annotation.DateTimeFormat;
  7. import java.time.LocalTime;
  8. import java.time.LocalDateTime;
  9. import java.math.BigDecimal;
  10. /**
  11. * @title: ${tableComment}
  12. * @Author ${author}
  13. * @Date: ${date}
  14. * @Version 1.0
  15. */
  16. @Data
  17. @EqualsAndHashCode(callSuper = false)
  18. public class ${entityClass}${isPage?string("Page","List")}Dto ${isPage?string("extends PageInput","extends ListInput")} {
  19. <#--属性遍历-->
  20. <#list fields as field>
  21. /**
  22. * ${(field.fieldComment)!''}
  23. */
  24. @ApiModelProperty("${(field.fieldComment)!''}")
  25. <#if field.fieldType == "LocalDateTime" >
  26. @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
  27. </#if>
  28. private ${field.fieldType} ${field.fieldName};
  29. </#list>
  30. }