Plan.java 2.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990
  1. package com.aijiuyi.admin.entity;
  2. import com.baomidou.mybatisplus.annotation.*;
  3. import lombok.Data;
  4. import java.math.BigDecimal;
  5. import java.time.LocalDateTime;
  6. /**
  7. * 方案实体
  8. * 对应数据库 plan 表
  9. */
  10. @Data
  11. @TableName("plan")
  12. public class Plan {
  13. /** 主键ID */
  14. @TableId(type = IdType.AUTO)
  15. private Long id;
  16. /** 方案编码(唯一标识,如 S001) */
  17. private String planCode;
  18. /** 方案名称(最长100字符) */
  19. private String name;
  20. /**
  21. * 模式类型:1=一键艾灸,2=专业模式,3=自定义模式,4=延年圣手
  22. */
  23. private Integer modeType;
  24. /**
  25. * 功效类型:驱寒/祛湿/祛风/化瘀/活血/化痰/养颜/扶阳
  26. */
  27. private String effectType;
  28. /** 适用症状(逗号分隔:怕冷,感冒,咳嗽,...) */
  29. private String symptoms;
  30. /**
  31. * 适用人群:0=不限,1=仅男,2=仅女
  32. */
  33. private Integer applicableGender;
  34. /** 适用年龄最小值(岁) */
  35. private Integer ageMin;
  36. /** 适用年龄最大值(岁) */
  37. private Integer ageMax;
  38. /** 方案描述(最长200字符) */
  39. private String description;
  40. /**
  41. * 创作人类型:1=管理员,2=普通用户,3=专家
  42. */
  43. private Integer authorType;
  44. /** 创作人ID(对应 app_user.id) */
  45. private Long authorId;
  46. /** 创作人名称(冗余存储,加速查询) */
  47. private String authorName;
  48. /**
  49. * 状态:0=草稿,1=已发布,2=已下架
  50. */
  51. private Integer status;
  52. /** 使用人数 */
  53. private Integer useCount;
  54. /** 平均评分 */
  55. private BigDecimal avgRating;
  56. /** 最后使用时间 */
  57. private LocalDateTime lastUseTime;
  58. /** 逻辑删除:0=未删除,1=已删除 */
  59. @TableLogic
  60. private Integer deleted;
  61. /** 创建时间(自动填充) */
  62. @TableField(fill = FieldFill.INSERT)
  63. private LocalDateTime createTime;
  64. /** 更新时间(自动填充) */
  65. @TableField(fill = FieldFill.INSERT_UPDATE)
  66. private LocalDateTime updateTime;
  67. }