package com.softwarebr.nunu.entity.train;

import com.alibaba.fastjson.annotation.JSONField;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
import lombok.NoArgsConstructor;
import javax.persistence.*;
import java.math.BigDecimal;
import java.time.LocalDateTime;

/**
 * 创新培训活动
 * @date 2020-02-26 11:02:46
 * @author lilin
 */

@Entity
@Data
@NoArgsConstructor
@AllArgsConstructor
@Table(name="train_activity")
@Builder
public class Activity {

	/**
	 * 1未总结
	 */
	public final static Integer SUMMARY_STATUS_NO = 1;
	/**
	 * 2已总结
	 */
	public final static Integer SUMMARY_STATUS_YES = 2;

	/**
	 * 1.创新活动
	 */
	public final static Integer CATEGORY_INNOVATE = 1;
	/**
	 * 2.培训活动
	 */
	public final static Integer CATEGORY_TRAIN = 2;

	@Id
	@GeneratedValue(strategy = GenerationType.IDENTITY)
	@ApiModelProperty(value = "id", required = true, example = "1")
	private Long id;

	@JSONField(format = "yyyy-MM-dd HH:mm:ss")
	@ApiModelProperty(value = "创建时间", required = true, example = "2018-03-12 21:32:33")
	private LocalDateTime createDate;

	@ApiModelProperty(value = "发布者", required = true, example = "1")
	private Long publisher;

	@ApiModelProperty(value = "活动名称", required = true, example = "")
	private String name;

	@JSONField(format = "yyyy-MM-dd HH:mm:ss")
	@ApiModelProperty(value = "报名开始时间", required = true, example = "")
	private LocalDateTime signStartDate;

	@JSONField(format = "yyyy-MM-dd HH:mm:ss")
	@ApiModelProperty(value = "报名结束时间", required = true, example = "")
	private LocalDateTime signEndDate;

	@JSONField(format = "yyyy-MM-dd HH:mm:ss")
	@ApiModelProperty(value = "活动开始时间", required = true, example = "")
	private LocalDateTime startDate;

	@JSONField(format = "yyyy-MM-dd HH:mm:ss")
	@ApiModelProperty(value = "活动结束时间", required = true, example = "")
	private LocalDateTime endDate;

	@ApiModelProperty(value = "活动价格（-1免费)", required = true, example = "")
	private BigDecimal price;

	@ApiModelProperty(value = "省份编号", required = true, example = "")
	private Long provinceId;

	@ApiModelProperty(value = "城市编号", required = true, example = "")
	private Long cityId;

	@ApiModelProperty(value = "区县编号", required = true, example = "")
	private Long areaId;

	@ApiModelProperty(value = "上线人数", required = true, example = "")
	private Integer capacity;

	@ApiModelProperty(value = "已报名人数", required = true, example = "")
	private Integer enrolment;

	@ApiModelProperty(value = "活动类别 1.创新活动 2.培训活动", required = true, example = "")
	private Integer category;

	@ApiModelProperty(value = "活动类型(创新->1.沙龙会2.论坛3.讲座4.项目路演5.创新创业大赛6.私董会7.分享会 培训->1.讲座2.培训班3.研修班)", required = true, example = "")
	private Integer type;

	@ApiModelProperty(value = "封面图", required = true, example = "")
	@Column(length = Integer.MAX_VALUE)
	private String coverUri;

	@ApiModelProperty(value = "活动简介", required = true, example = "")
	@Column(length = Integer.MAX_VALUE)
	private String description;

	@ApiModelProperty(value = "活动信息(text)", required = true, example = "")
	@Column(length = Integer.MAX_VALUE)
	private String information;

	@ApiModelProperty(value = "活动详情(text)", required = true, example = "")
	@Column(length = Integer.MAX_VALUE)
	private String detail;

	@ApiModelProperty(value = "是否推荐至首页(0否 1是)", required = true, example = "")
	private Integer indexType;

	@ApiModelProperty(value = "是否上架(0下架 1上架) ", required = true, example = "")
	private Integer status;

	@ApiModelProperty(value = "审核状态(1待审核 2审核通过 3审核不通过)", required = true, example = "")
	private Integer verify;

	@JSONField(format = "yyyy-MM-dd HH:mm:ss")
	@ApiModelProperty(value = "审核时间", required = true, example = "")
	private LocalDateTime verifyDate;

	@ApiModelProperty(value = "审核备注", required = true, example = "")
	private String verifyRemark;

	@ApiModelProperty(value = "活动总结状态(1未总结 2已总结 )", required = true, example = "")
	private Integer summaryStatus;

	@ApiModelProperty(value = "活动总结(text)", required = true, example = "")
	@Column(length = Integer.MAX_VALUE)
	private String summary;

}