package com.ssj.bean.weixin.zyb.domain;

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.JoinColumn;
import javax.persistence.OneToMany;
import javax.persistence.OrderBy;
import javax.persistence.Table;
import javax.persistence.Transient;

import com.alibaba.fastjson.annotation.JSONField;
import com.ssj.bean.common.framework.core.domain.BaseEntity;
import org.hibernate.annotations.Fetch;
import org.hibernate.annotations.FetchMode;

/** 
 * @author  ZhangCaibao 
 * @version 2017年11月1日 下午2:26:21 
 * 类说明 
 */
@Entity
@Table(name = "zyb_student_work_how_details")
public class ZuoybStudentWorkHowDetails extends BaseEntity{

	/**
	 * 
	 */
	private static final long serialVersionUID = -529998138900770248L;
	
	/**
	 * 打分ID
	 */
	private String  studentWorkId;
	
	/**
	 * 大纲ID
	 */
	private String workHowId;
	/**
	 * 课程ID
	 */
	private String howDetailsId;
	/**
	 * 课程内容
	 */
	
	private String name;
	/**
	 * 手动增加课程内容
	 */
	private String manualName;
	/**
	 * 排序
	 */
	private Integer num;
	
	private Date    createTime;
	
	private String yicuo;
	
	private Integer memorize; //识记
	
	private Integer understanding;//理解
	
	private Integer apply; //应用
	
	private String duration; //时长
	
	/**
	 * 模块（新）
	 */
	private String module;
	
	private Integer type;//1是全部，2是错题
	
	/**
	 * 大纲对应的错题
	 */
	private List<ZuoybStudentWorkImg>  imgList = new ArrayList<ZuoybStudentWorkImg>();

	public String getStudentWorkId() {
		return studentWorkId;
	}

	public void setStudentWorkId(String studentWorkId) {
		this.studentWorkId = studentWorkId;
	}

	public String getWorkHowId() {
		return workHowId;
	}

	public void setWorkHowId(String workHowId) {
		this.workHowId = workHowId;
	}

	public String getName() {
		return name;
	}

	public void setName(String name) {
		this.name = name;
	}

	public Integer getNum() {
		return num;
	}

	public void setNum(Integer num) {
		this.num = num;
	}
	@Column(updatable =false)
	@JSONField(serialize=false)
	public Date getCreateTime() {
		return createTime;
	}

	public void setCreateTime(Date createTime) {
		this.createTime = createTime;
	}
	
	@OneToMany(cascade = { CascadeType.REFRESH}, fetch=FetchType.EAGER)
	@JoinColumn(name="howDetailsId",updatable =false,insertable =false)
	@OrderBy(" num asc")
	@Fetch(FetchMode.SELECT)
	public List<ZuoybStudentWorkImg> getImgList() {
		return imgList;
	}

	public void setImgList(List<ZuoybStudentWorkImg> imgList) {
		this.imgList = imgList;
	}

	public String getManualName() {
		return manualName;
	}

	public void setManualName(String manualName) {
		this.manualName = manualName;
	}

	public String getHowDetailsId() {
		return howDetailsId;
	}

	public void setHowDetailsId(String howDetailsId) {
		this.howDetailsId = howDetailsId;
	}
    @Transient
	public String getYicuo() {
		return yicuo;
	}

	public void setYicuo(String yicuo) {
		this.yicuo = yicuo;
	}

	public Integer getMemorize() {
		return memorize;
	}

	public void setMemorize(Integer memorize) {
		this.memorize = memorize;
	}

	public Integer getUnderstanding() {
		return understanding;
	}

	public void setUnderstanding(Integer understanding) {
		this.understanding = understanding;
	}

	public Integer getApply() {
		return apply;
	}

	public void setApply(Integer apply) {
		this.apply = apply;
	}

	public String getDuration() {
		return duration;
	}

	public void setDuration(String duration) {
		this.duration = duration;
	}

	public String getModule() {
		return module;
	}

	public void setModule(String module) {
		this.module = module;
	}

	public Integer getType() {
		return type;
	}

	public void setType(Integer type) {
		this.type = type;
	}
	
  
}
