package com.palmnest.model;

import java.io.Serializable;
import java.math.BigDecimal;
import java.util.Date;

import javax.persistence.CascadeType;
import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.FetchType;
import javax.persistence.GeneratedValue;
import javax.persistence.GenerationType;
import javax.persistence.Id;
import javax.persistence.JoinColumn;
import javax.persistence.ManyToOne;
import javax.persistence.Table;

import org.codehaus.jackson.annotate.JsonIgnore;

import com.palmnest.model.property.TbOrganization;

/**
 * @author longmeizhen
 * 楼层实体类
 */
@Entity
@Table(name = "tb_floor")
public class FloorInfo implements Serializable {

	/**
	 *
	 */
	private static final long serialVersionUID = -5476440953034915682L;


	private Integer id;
	private Long    buildId;	
   
    private BigDecimal floorArea; //楼层面积
	
	private String  name;
	private Date    createTime;
	private Long    creator;
	private Long    modifier;
	private Date    modifyTime;
	private Integer isEnabled;
	private String  partOrgID;
	private Long    organizationId;
	private String  isHaveMeeting;

//	楼宇实体类
//	private TbOrganization organization;


	@Column(name = "isEnabled")
	public Integer getIsEnabled() {
		return isEnabled;
	}

	public void setIsEnabled(Integer isEnabled) {
		this.isEnabled = isEnabled;
	}

	@Id
	@GeneratedValue(strategy = GenerationType.AUTO)
	@Column(name = "ID", unique = true, nullable = false)
	public Integer getId() {
		return id;
	}

	public void setId(Integer id) {
		this.id = id;
	}

	public Long getBuildId() {
		return buildId;
	}

	public void setBuildId(Long buildId) {
		this.buildId = buildId;
	}

	@Column(name = "name")
	public String getName() {
		return name;
	}

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

	@Column(name = "createTime")
	public Date getCreateTime() {
		return createTime;
	}

	public void setCreateTime(Date createTime) {
		this.createTime = createTime;
	}

	@Column(name = "creator")
	public Long getCreator() {
		return creator;
	}

	public void setCreator(Long creator) {
		this.creator = creator;
	}

	@Column(name = "modifier")
	public Long getModifier() {
		return modifier;
	}

	public void setModifier(Long modifier) {
		this.modifier = modifier;
	}

	@Column(name = "modifyTime")
	public Date getModifyTime() {
		return modifyTime;
	}

	public void setModifyTime(Date modifyTime) {
		this.modifyTime = modifyTime;
	}

	@Override
	public String toString() {
		return "FloorInfo [id=" + id + ", organizationId=" + organizationId + ", name=" + name + ", isEnabled="
				+ isEnabled + "]";
	}

	public String getPartOrgID() {
		return partOrgID;
	}

	public void setPartOrgID(String partOrgID) {
		this.partOrgID = partOrgID;
	}

	public Long getOrganizationId() {
		return organizationId;
	}

	public void setOrganizationId(Long organizationId) {
		this.organizationId = organizationId;
	}

	public String getIsHaveMeeting() {
		return isHaveMeeting;
	}

	public void setIsHaveMeeting(String isHaveMeeting) {
		this.isHaveMeeting = isHaveMeeting;
	}

	@Column(name = "floor_area")
	public BigDecimal getFloorArea() {
		return floorArea;
	}

	public void setFloorArea(BigDecimal floorArea) {
		this.floorArea = floorArea;
	}

//	@JsonIgnore
//	@ManyToOne(cascade = CascadeType.REFRESH, fetch = FetchType.EAGER, optional = false)
//	@JoinColumn(name="organizationId")
//	public TbOrganization getOrganization() {
//		return organization;
//	}
//	public void setOrganization(TbOrganization organization) {
//		this.organization = organization;
//	}

	
	

}
