PiStatusHistory.java 3.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174
  1. package com.punchsettle.server.atomic.entity;
  2. import java.io.Serial;
  3. import java.io.Serializable;
  4. import java.math.BigDecimal;
  5. import java.time.LocalDate;
  6. import java.util.Date;
  7. import com.punchsettle.server.common.pojo.BaseEntity;
  8. import com.punchsettle.server.constant.ConsecutiveStatusEnum;
  9. import jakarta.persistence.Column;
  10. import jakarta.persistence.Table;
  11. import lombok.Data;
  12. import lombok.EqualsAndHashCode;
  13. /**
  14. * @author tyuio
  15. * @version 1.0.0
  16. * @description 打卡任务状态记录表
  17. * @date 2025/04/08 09:49
  18. */
  19. @Data
  20. @EqualsAndHashCode(callSuper = true)
  21. @Table(name = "pi_status_history")
  22. public class PiStatusHistory extends BaseEntity implements Serializable {
  23. @Serial
  24. private static final long serialVersionUID = 4985644914965499020L;
  25. /**
  26. * 用户ID
  27. */
  28. @Column(name = "user_id")
  29. private Long userId;
  30. /**
  31. * 打卡多任务唯一ID
  32. */
  33. @Column(name = "multi_task_unique_id")
  34. private Long multiTaskUniqueId;
  35. /**
  36. * 打卡任务唯一ID
  37. */
  38. @Column(name = "task_unique_id")
  39. private Long taskUniqueId;
  40. /**
  41. * 记录状态的时间
  42. */
  43. @Column(name = "status_date")
  44. private String statusDate;
  45. /**
  46. * 任务连续打卡状态(连续打卡-CONTINUE、中断-INTERRUPTED)
  47. * @see ConsecutiveStatusEnum
  48. */
  49. @Column(name = "task_continue_status")
  50. private ConsecutiveStatusEnum taskContinueStatus;
  51. /**
  52. * 任务连续天数,第一天开始就等于1
  53. */
  54. @Column(name = "task_continue_day")
  55. private Integer taskContinueDay;
  56. /**
  57. * 连续阶段(宽限期-GRACE_STAGE,正常打卡期-NORMAL_STAGE,惩罚期-PENALTY_STAGE)
  58. */
  59. @Column(name = "continue_stage")
  60. private String continueStage;
  61. /**
  62. * 阶段开始日期
  63. */
  64. @Column(name = "stage_start_date")
  65. private LocalDate stageStartDate;
  66. /**
  67. * 结束日期
  68. */
  69. @Column(name = "stage_end_date")
  70. private LocalDate stageEndDate;
  71. /**
  72. * 连续中断次数
  73. */
  74. @Column(name = "连续中断次数")
  75. private Integer continueInterruptedCount;
  76. /**
  77. * 统计时间(格式:yyyy-W周数)
  78. */
  79. @Column(name = "stats_time_in_week")
  80. private String statTimeInWeek;
  81. /**
  82. * 本周需打卡数
  83. */
  84. @Column(name = "punch_in_total_count_in_week")
  85. private Integer punchInTotalCountInWeek;
  86. /**
  87. * 本周已打卡数
  88. */
  89. @Column(name = "punch_in_count_in_week")
  90. private Integer punchInCountInWeek;
  91. /**
  92. * 本周完成打卡数
  93. */
  94. @Column(name = "punch_in_done_count_in_week")
  95. private Integer punchInDoneCountInWeek;
  96. /**
  97. * 本周打卡率
  98. */
  99. @Column(name = "punch_in_rate_in_week")
  100. private BigDecimal punchInRateInWeek;
  101. /**
  102. * 本周打卡完成率
  103. */
  104. @Column(name = "punch_in_done_rate_in_week")
  105. private BigDecimal punchInDoneRateInWeek;
  106. /**
  107. * 本周获取积分数
  108. */
  109. @Column(name = "points_in_week")
  110. private Integer pointsInWeek;
  111. /**
  112. * 统计时间(格式:yyyy-W周数)
  113. */
  114. @Column(name = "stats_time_in_month")
  115. private String statTimeInMonth;
  116. /**
  117. * 本周需打卡数
  118. */
  119. @Column(name = "punch_in_total_count_in_month")
  120. private Integer punchInTotalCountInMonth;
  121. /**
  122. * 本周已打卡数
  123. */
  124. @Column(name = "punch_in_count_in_month")
  125. private Integer punchInCountInMonth;
  126. /**
  127. * 本周完成打卡数
  128. */
  129. @Column(name = "punch_in_done_count_in_month")
  130. private Integer punchInDoneCountInMonth;
  131. /**
  132. * 本周打卡率
  133. */
  134. @Column(name = "punch_in_rate_in_month")
  135. private BigDecimal punchInRateInMonth;
  136. /**
  137. * 本周打卡完成率
  138. */
  139. @Column(name = "punch_in_done_rate_in_month")
  140. private BigDecimal punchInDoneRateInMonth;
  141. /**
  142. * 本周获取积分数
  143. */
  144. @Column(name = "points_in_month")
  145. private Integer pointsInMonth;
  146. }