package com.qxueyou.scc.school.model;
|
|
import java.io.Serializable;
|
import java.math.BigDecimal;
|
//import java.util.ArrayList;
|
import java.util.Date;
|
import java.util.List;
|
|
//import javax.persistence.CascadeType;
|
import javax.persistence.Column;
|
import javax.persistence.Entity;
|
import javax.persistence.FetchType;
|
import javax.persistence.GeneratedValue;
|
import javax.persistence.Id;
|
import javax.persistence.NamedQuery;
|
import javax.persistence.OneToMany;
|
import javax.persistence.Table;
|
import javax.persistence.Transient;
|
|
//import org.hibernate.annotations.Fetch;
|
//import org.hibernate.annotations.FetchMode;
|
import org.hibernate.annotations.GenericGenerator;
|
import org.springframework.format.annotation.DateTimeFormat;
|
|
import com.fasterxml.jackson.annotation.JsonIgnore;
|
import com.qxueyou.scc.base.model.ITrace;
|
|
/**
|
* 班级课程
|
*
|
* @author ody.yuan
|
*
|
*/
|
@Entity
|
@Table(name = "SCH_CLASS_SUBJECT")
|
@NamedQuery(name = "SchClassSubject.findAll", query = "SELECT s FROM SchClassSubject s")
|
public class SchClassSubject implements Serializable, ITrace {
|
|
private static final long serialVersionUID = 1L;
|
/** 1 必修 2 选修 **/
|
public static final short SUBJECT_TYPE_REQUIRED = 1;
|
public static final short SUBJECT_TYPE_ELECTIVE = 2;
|
|
/** 1 考试 2 考查 **/
|
public static final short SUBJECT_EXAMINATION_REQUIRED = 1;
|
public static final short SUBJECT_EXAMINATION_EXAMINE = 2;
|
@Id
|
@GeneratedValue(generator = "hibernate-uuid")
|
@GenericGenerator(name = "hibernate-uuid", strategy = "uuid")
|
@Column(name = "CLASS_SUBJECT_ID", unique = true, nullable = false, length = 32)
|
private String classSubjectId;
|
|
/** 名称 */
|
@Column(name = "NAME", length = 150)
|
private String name;
|
|
/** 全称 */
|
@Column(name = "FULL_NAME", length = 255)
|
private String fullName;
|
|
/** 编码 */
|
@Column(name = "CODE", length = 64)
|
private String code;
|
|
/** 排序顺序号 */
|
@Column(name = "ORDER_NUM")
|
private int orderNum;
|
|
|
/** 内容简介 */
|
@Column(name = "CONTENT", length = 255)
|
private String content;
|
|
/** 学分 */
|
@Column(name = "CREDIT", precision = 4, scale = 2)
|
private BigDecimal credit;
|
|
/** 课程类别(必修、选修) */
|
@Column(name = "TYPE")
|
private short type;
|
|
/** 考试形式(考试、考查) */
|
@Column(name = "EXAMINATION_FORM")
|
private short examinationForm;
|
|
/** 机构拷贝专业ID,非高校拷贝科目ID */
|
@Column(name = "COURSE_ID", length = 32)
|
private String courseId;
|
|
/** 班级ID */
|
@Column(name = "CLASS_ID", length = 32)
|
private String classId;
|
|
/** 原始公共课程ID */
|
@Column(name = "ORIG_SUBJECT_ID", length = 32)
|
private String origSubjectId;
|
|
/** 班级复制:复制课程保存原始班级的课程ID */
|
@Column(name = "ORIG_CLASS_SUBJECT_ID", length = 32)
|
private String origClassSubjectId;
|
|
@Column(name = "CREATE_ID")
|
@JsonIgnore
|
private String createId;
|
|
@Column(name = "CREATE_TIME")
|
@DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
@JsonIgnore
|
private Date createTime;
|
|
@Column(name = "CREATOR")
|
@JsonIgnore
|
private String creator;
|
|
@Column(name = "DELETE_FLAG")
|
@JsonIgnore
|
private boolean deleteFlag;
|
|
@Column(name = "UPDATE_ID")
|
@JsonIgnore
|
private String updateId;
|
|
@Column(name = "UPDATE_TIME")
|
@DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
@JsonIgnore
|
private Date updateTime;
|
|
@Column(name = "UPDATOR")
|
@JsonIgnore
|
private String updator;
|
|
/** 学生课表 */
|
@OneToMany(fetch = FetchType.LAZY, mappedBy = "subject")
|
@JsonIgnore
|
public List<SchStudentSchedule> studentSchedules;
|
|
/** 班级课表 */
|
@OneToMany(fetch = FetchType.LAZY, mappedBy = "subject")
|
@JsonIgnore
|
public List<SchClassSchedule> classSchedules;
|
|
@Transient
|
public List<SchClassSchedule> lstClassSchedules;
|
|
/** 签到类型 */
|
@Transient
|
private Short signType;
|
|
@Transient
|
private int videoCount;
|
|
@Transient
|
private int handoutCount;
|
|
@Transient
|
private int articleCount;
|
|
public int getVideoCount() {
|
return videoCount;
|
}
|
|
public void setVideoCount(int videoCount) {
|
this.videoCount = videoCount;
|
}
|
|
public int getHandoutCount() {
|
return handoutCount;
|
}
|
|
public void setHandoutCount(int handoutCount) {
|
this.handoutCount = handoutCount;
|
}
|
|
public int getArticleCount() {
|
return articleCount;
|
}
|
|
public void setArticleCount(int articleCount) {
|
this.articleCount = articleCount;
|
}
|
|
public Short getSignType() {
|
return signType;
|
}
|
|
public void setSignType(Short signType) {
|
this.signType = signType;
|
}
|
|
public List<SchClassSchedule> getLstClassSchedules() {
|
return lstClassSchedules;
|
}
|
|
public void setLstClassSchedules(List<SchClassSchedule> lstClassSchedules) {
|
this.lstClassSchedules = lstClassSchedules;
|
}
|
|
public List<SchStudentSchedule> getStudentSchedules() {
|
return studentSchedules;
|
}
|
|
public void setStudentSchedules(List<SchStudentSchedule> studentSchedules) {
|
this.studentSchedules = studentSchedules;
|
}
|
|
public List<SchClassSchedule> getClassSchedules() {
|
return classSchedules;
|
}
|
|
public void setClassSchedules(List<SchClassSchedule> classSchedules) {
|
this.classSchedules = classSchedules;
|
}
|
|
public String getName() {
|
return name;
|
}
|
|
public void setName(String name) {
|
this.name = name;
|
}
|
|
public String getFullName() {
|
return fullName;
|
}
|
|
public void setFullName(String fullName) {
|
this.fullName = fullName;
|
}
|
|
public String getCode() {
|
return code;
|
}
|
|
public void setCode(String code) {
|
this.code = code;
|
}
|
|
public String getContent() {
|
return content;
|
}
|
|
public void setContent(String content) {
|
this.content = content;
|
}
|
|
public BigDecimal getCredit() {
|
return credit;
|
}
|
|
public void setCredit(BigDecimal credit) {
|
this.credit = credit;
|
}
|
|
public short getType() {
|
return type;
|
}
|
|
public void setType(short type) {
|
this.type = type;
|
}
|
|
public short getExaminationForm() {
|
return examinationForm;
|
}
|
|
public void setExaminationForm(short examinationForm) {
|
this.examinationForm = examinationForm;
|
}
|
|
public String getCourseId() {
|
return courseId;
|
}
|
|
public void setCourseId(String courseId) {
|
this.courseId = courseId;
|
}
|
|
public String getCreateId() {
|
return createId;
|
}
|
|
public void setCreateId(String createId) {
|
this.createId = createId;
|
}
|
|
public Date getCreateTime() {
|
return createTime;
|
}
|
|
public void setCreateTime(Date createTime) {
|
this.createTime = createTime;
|
}
|
|
public String getCreator() {
|
return creator;
|
}
|
|
public void setCreator(String creator) {
|
this.creator = creator;
|
}
|
|
public boolean getDeleteFlag() {
|
return deleteFlag;
|
}
|
|
public void setDeleteFlag(boolean deleteFlag) {
|
this.deleteFlag = deleteFlag;
|
}
|
|
public String getUpdateId() {
|
return updateId;
|
}
|
|
public void setUpdateId(String updateId) {
|
this.updateId = updateId;
|
}
|
|
public Date getUpdateTime() {
|
return updateTime;
|
}
|
|
public void setUpdateTime(Date updateTime) {
|
this.updateTime = updateTime;
|
}
|
|
public String getUpdator() {
|
return updator;
|
}
|
|
public void setUpdator(String updator) {
|
this.updator = updator;
|
}
|
|
public String getClassSubjectId() {
|
return classSubjectId;
|
}
|
|
public void setClassSubjectId(String classSubjectId) {
|
this.classSubjectId = classSubjectId;
|
}
|
|
public String getClassId() {
|
return classId;
|
}
|
|
public void setClassId(String classId) {
|
this.classId = classId;
|
}
|
|
public String getOrigSubjectId() {
|
return origSubjectId;
|
}
|
|
public void setOrigSubjectId(String origSubjectId) {
|
this.origSubjectId = origSubjectId;
|
}
|
|
public String getOrigClassSubjectId() {
|
return origClassSubjectId;
|
}
|
|
public void setOrigClassSubjectId(String origClassSubjectId) {
|
this.origClassSubjectId = origClassSubjectId;
|
}
|
|
public int getOrderNum() {
|
return orderNum;
|
}
|
|
public void setOrderNum(int orderNum) {
|
this.orderNum = orderNum;
|
}
|
|
|
|
|
}
|