package com.jeesite.modules.admin.wenjuan.entity;

import javax.validation.constraints.NotNull;
import javax.validation.constraints.Size;

import com.jeesite.common.entity.DataEntity;
import com.jeesite.common.mybatis.annotation.Column;
import com.jeesite.common.mybatis.annotation.Table;
import com.jeesite.common.mybatis.mapper.query.QueryType;

/**
 * 问卷调查项表Entity
 * @author wlc
 * @version 2022-06-20
 */
@Table(name="admin_question_option", alias="a", label="问卷调查项表信息", columns={
		@Column(name="questionoption_id", attrName="questionoptionId", label="主键ID", isPK=true),
		@Column(name="questionitem_id", attrName="questionitemId.questionitemId", label="问卷调查项ID"),
		@Column(name="title", attrName="title", label="标题"),
		@Column(name="content", attrName="content", label="内容"),
		@Column(name="is_input", attrName="isInput", label="是否为输入框"),
		@Column(name="max_selected", attrName="maxSelected", label="最多可选几项", comment="最多可选几项(0多选 1单选)", isUpdateForce=true),
		@Column(name="is_essay", attrName="isEssay", label="是否问答题", comment="是否问答题(0 true 1false)"),
		@Column(name="count", attrName="count", label="得票数", isUpdateForce=true),
		@Column(name="seq", attrName="seq", label="排序", isUpdateForce=true),
		@Column(name="create_by", attrName="createBy", label="创建者", isUpdate=false, isQuery=false),
		@Column(name="create_date", attrName="createDate", label="创建时间", isUpdate=false, isQuery=false, isUpdateForce=true),
		@Column(name="update_by", attrName="updateBy", label="更新者", isQuery=false),
		@Column(name="update_date", attrName="updateDate", label="更新时间", isQuery=false, isUpdateForce=true),
		@Column(name="remarks", attrName="remarks", label="备注"),
	}, orderBy="a.create_date DESC"
)
public class AdminQuestionOption extends DataEntity<AdminQuestionOption> {
	
	private static final long serialVersionUID = 1L;
	private String questionoptionId;		// 主键ID
	private AdminQuestionItem questionitemId;		// 问卷调查项ID 父类
	private String title;		// 标题
	private String content;		// 内容
	private String isInput;		// 是否为输入框
	private Long maxSelected;		// 最多可选几项(0多选 1单选)
	private String isEssay;		// 是否问答题(0 true 1false)
	private Long count;		// 得票数
	private Long seq;		// 排序
	private String itemTitle;


	public String getItemTitle() {
		return itemTitle;
	}

	public void setItemTitle(String itemTitle) {
		this.itemTitle = itemTitle;
	}

	public AdminQuestionOption() {
		this(null);
	}

	public AdminQuestionOption(AdminQuestionItem questionitemId){
		this.questionitemId = questionitemId;
	}

	public String getQuestionoptionId() {
		return questionoptionId;
	}

	public void setQuestionoptionId(String questionoptionId) {
		this.questionoptionId = questionoptionId;
	}

	public AdminQuestionItem getQuestionitemId() {
		return questionitemId;
	}

	public void setQuestionitemId(AdminQuestionItem questionitemId) {
		this.questionitemId = questionitemId;
	}

	@Size(min=0, max=255, message="标题长度不能超过 255 个字符")
	public String getTitle() {
		return title;
	}

	public void setTitle(String title) {
		this.title = title;
	}

	public String getContent() {
		return content;
	}

	public void setContent(String content) {
		this.content = content;
	}

	@Size(min=0, max=255, message="是否为输入框长度不能超过 255 个字符")
	public String getIsInput() {
		return isInput;
	}

	public void setIsInput(String isInput) {
		this.isInput = isInput;
	}

	public Long getMaxSelected() {
		return maxSelected;
	}

	public void setMaxSelected(Long maxSelected) {
		this.maxSelected = maxSelected;
	}

	@Size(min=0, max=255, message="是否问答题长度不能超过 255 个字符")
	public String getIsEssay() {
		return isEssay;
	}

	public void setIsEssay(String isEssay) {
		this.isEssay = isEssay;
	}

	public Long getCount() {
		return count;
	}

	public void setCount(Long count) {
		this.count = count;
	}

	public Long getSeq() {
		return seq;
	}

	public void setSeq(Long seq) {
		this.seq = seq;
	}
	
}