Activity.java 4.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269
  1. package com.goafanti.common.model;
  2. import java.util.Date;
  3. import org.apache.commons.lang3.time.DateFormatUtils;
  4. import com.fasterxml.jackson.annotation.JsonFormat;
  5. import com.fasterxml.jackson.annotation.JsonFormat.Shape;
  6. import com.goafanti.common.constant.AFTConstants;
  7. import com.fasterxml.jackson.annotation.JsonIgnore;
  8. public class Activity {
  9. private Long id;
  10. /**
  11. * 开始时间
  12. */
  13. private Date startTime;
  14. /**
  15. * 结束时间
  16. */
  17. private Date endTime;
  18. /**
  19. * 标题
  20. */
  21. private String name;
  22. /**
  23. * 状态
  24. */
  25. private Integer status;
  26. /**
  27. * 活动地址
  28. */
  29. private String address;
  30. /**
  31. * 主办单位
  32. */
  33. private String host;
  34. /**
  35. * 承办单位
  36. */
  37. private String undertake;
  38. /**
  39. * 协办单位,逗号隔开
  40. */
  41. private String asist;
  42. /**
  43. * 活动类型
  44. */
  45. private Integer type;
  46. /**
  47. * 活动形式
  48. */
  49. private Integer form;
  50. /**
  51. * 活动图片地址
  52. */
  53. private String imgUrls;
  54. /**
  55. * 活动结果描述
  56. */
  57. private String result;
  58. /**
  59. * 创建时间(报名开始时间)
  60. */
  61. private Date createTime;
  62. /**
  63. * 报名截止时间
  64. */
  65. private Date enrollDeadline;
  66. /**
  67. * 题图地址
  68. */
  69. private String titleUrl;
  70. /**
  71. * 描述
  72. */
  73. private String summary;
  74. public Long getId() {
  75. return id;
  76. }
  77. public void setId(Long id) {
  78. this.id = id;
  79. }
  80. public Date getStartTime() {
  81. return startTime;
  82. }
  83. public void setStartTime(Date startTime) {
  84. this.startTime = startTime;
  85. }
  86. public Date getEndTime() {
  87. return endTime;
  88. }
  89. public void setEndTime(Date endTime) {
  90. this.endTime = endTime;
  91. }
  92. public String getName() {
  93. return name;
  94. }
  95. public void setName(String name) {
  96. this.name = name;
  97. }
  98. public Integer getStatus() {
  99. return status;
  100. }
  101. public void setStatus(Integer status) {
  102. this.status = status;
  103. }
  104. public String getAddress() {
  105. return address;
  106. }
  107. public void setAddress(String address) {
  108. this.address = address;
  109. }
  110. public String getHost() {
  111. return host;
  112. }
  113. public void setHost(String host) {
  114. this.host = host;
  115. }
  116. public String getUndertake() {
  117. return undertake;
  118. }
  119. public void setUndertake(String undertake) {
  120. this.undertake = undertake;
  121. }
  122. public String getAsist() {
  123. return asist;
  124. }
  125. public void setAsist(String asist) {
  126. this.asist = asist;
  127. }
  128. @JsonFormat(shape = Shape.STRING)
  129. public Integer getType() {
  130. return type;
  131. }
  132. public void setType(Integer type) {
  133. this.type = type;
  134. }
  135. @JsonFormat(shape = Shape.STRING)
  136. public Integer getForm() {
  137. return form;
  138. }
  139. public void setForm(Integer form) {
  140. this.form = form;
  141. }
  142. public String getImgUrls() {
  143. return imgUrls;
  144. }
  145. public void setImgUrls(String imgUrls) {
  146. this.imgUrls = imgUrls;
  147. }
  148. public String getResult() {
  149. return result;
  150. }
  151. public void setResult(String result) {
  152. this.result = result;
  153. }
  154. @JsonIgnore
  155. public Date getCreateTime() {
  156. return createTime;
  157. }
  158. public void setCreateTime(Date createTime) {
  159. this.createTime = createTime;
  160. }
  161. public Date getEnrollDeadline() {
  162. return enrollDeadline;
  163. }
  164. public void setEnrollDeadline(Date enrollDeadline) {
  165. this.enrollDeadline = enrollDeadline;
  166. }
  167. public String getTitleUrl() {
  168. return titleUrl;
  169. }
  170. public void setTitleUrl(String titleUrl) {
  171. this.titleUrl = titleUrl;
  172. }
  173. public String getSummary() {
  174. return summary;
  175. }
  176. public void setSummary(String summary) {
  177. this.summary = summary;
  178. }
  179. public String getStartTimeFormattedDate() {
  180. if (this.startTime == null) {
  181. return null;
  182. } else {
  183. return DateFormatUtils.format(this.startTime, AFTConstants.YYYYMMDD);
  184. }
  185. }
  186. public void setStartTimeFormattedDate(String startTimeFormattedDate) {
  187. }
  188. public String getEndTimeFormattedDate() {
  189. if (this.endTime == null) {
  190. return null;
  191. } else {
  192. return DateFormatUtils.format(this.endTime, AFTConstants.YYYYMMDD);
  193. }
  194. }
  195. public void setEndTimeFormattedDate(String endTimeFormattedDate) {
  196. }
  197. public String getEnrollDeadlineFormattedDate() {
  198. if (this.enrollDeadline == null) {
  199. return null;
  200. } else {
  201. return DateFormatUtils.format(this.enrollDeadline, AFTConstants.YYYYMMDD);
  202. }
  203. }
  204. public void setEnrollDeadlineFormattedDate(String enrollDeadlineFormattedDate) {
  205. }
  206. }