package com.qxueyou.scc.school.model; import java.io.Serializable; import java.util.Date; import javax.persistence.Column; import javax.persistence.Entity; import javax.persistence.GeneratedValue; import javax.persistence.Id; import javax.persistence.NamedQuery; import javax.persistence.Table; import org.hibernate.annotations.Formula; import org.hibernate.annotations.GenericGenerator; import org.springframework.format.annotation.DateTimeFormat; import com.qxueyou.scc.base.model.ITrace; import com.fasterxml.jackson.annotation.JsonIgnore; /** * The persistent class for the sch_interact database table. * */ @Entity @Table(name="sch_interact") @NamedQuery(name="SchInteract.findAll", query="SELECT s FROM SchInteract s") public class SchInteract implements Serializable,ITrace { private static final long serialVersionUID = 1L; @Id @GeneratedValue(generator = "hibernate-uuid") @GenericGenerator(name = "hibernate-uuid", strategy = "uuid") @Column(name="INTERACT_ID", unique=true, nullable=false, length=32) private String interactId; @Column(name="CLASS_ID", length=32) private String classId; @Column(name="CREATE_ID", nullable=false, length=32) @JsonIgnore private String createId; @Column(name="CREATE_TIME", nullable=false) @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss") @JsonIgnore private Date createTime; @Column(name="CREATOR", nullable=false, length=100) @JsonIgnore private String creator; @Column(name="DELETE_FLAG", nullable=false) @JsonIgnore private boolean deleteFlag; @Column(name="EXERCISE_GROUP_ID", length=32) private String exerciseGroupId; /** 班级课表ID */ @Column(name="CLASS_SCHEDULE_ID", length=32) private String classScheduleId; @Column(name="STATUS") private short status; public final static short STATUS_LOCK = 1; public final static short STATUS_INTERACTING = 2; public final static short STATUS_END = 3; @Column(name="UPDATE_ID", length=32) @JsonIgnore private String updateId; @Column(name="UPDATE_TIME", nullable=false) @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss") @JsonIgnore private Date updateTime; @Column(name="UPDATOR", length=100) @JsonIgnore private String updator; @Formula(value="(select cur.name from EXERCISE_GROUP cur where cur.GROUP_ID= EXERCISE_GROUP_ID)") private String name; /** 图片路径 */ @Column(name="IMG_PATH", length=255) private String imgPath; @Column(name="START_TIME") @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss") private Date startTime; @Column(name="STOP_TIME") @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss") private Date stopTime; public Date getStartTime() { return startTime; } public void setStartTime(Date startTime) { this.startTime = startTime; } public Date getStopTime() { return stopTime; } public void setStopTime(Date stopTime) { this.stopTime = stopTime; } public String getName() { return name; } public void setName(String name) { this.name = name; } public SchInteract() { } public String getInteractId() { return this.interactId; } public void setInteractId(String interactId) { this.interactId = interactId; } public String getClassId() { return this.classId; } public void setClassId(String classId) { this.classId = classId; } public String getCreateId() { return this.createId; } public void setCreateId(String createId) { this.createId = createId; } public Date getCreateTime() { return this.createTime; } public void setCreateTime(Date createTime) { this.createTime = createTime; } public String getCreator() { return this.creator; } public void setCreator(String creator) { this.creator = creator; } public boolean getDeleteFlag() { return this.deleteFlag; } public void setDeleteFlag(boolean deleteFlag) { this.deleteFlag = deleteFlag; } public String getExerciseGroupId() { return this.exerciseGroupId; } public void setExerciseGroupId(String exerciseGroupId) { this.exerciseGroupId = exerciseGroupId; } public short getStatus() { return this.status; } public void setStatus(short status) { this.status = status; } public String getUpdateId() { return this.updateId; } public void setUpdateId(String updateId) { this.updateId = updateId; } public Date getUpdateTime() { return this.updateTime; } public void setUpdateTime(Date updateTime) { this.updateTime = updateTime; } public String getUpdator() { return this.updator; } public void setUpdator(String updator) { this.updator = updator; } public String getImgPath() { return imgPath; } public void setImgPath(String imgPath) { this.imgPath = imgPath; } public String getClassScheduleId() { return classScheduleId; } public void setClassScheduleId(String classScheduleId) { this.classScheduleId = classScheduleId; } }