package com.rjconsultores.ventaboletos.entidad;

import java.io.Serializable;
import java.util.Date;
import javax.persistence.Basic;
import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.GenerationType;
import javax.persistence.Id;
import javax.persistence.JoinColumn;
import javax.persistence.ManyToOne;
import javax.persistence.SequenceGenerator;
import javax.persistence.Table;
import javax.persistence.Temporal;
import javax.persistence.TemporalType;


@Entity
@SequenceGenerator(name = "GP_PRICING_DIA_SEQ", sequenceName = "GP_PRICING_DIA_SEQ", allocationSize = 1)
@Table(name = "GP_PRICING_DIA")
public class GP_PricingDia implements Serializable, Cloneable {

	private static final long serialVersionUID = 1L;
	@Id
	@Basic(optional = false)
	@GeneratedValue(strategy = GenerationType.AUTO, generator = "GP_PRICING_DIA_SEQ")
	@Column(name = "PRICINGDIA_ID")
	private Integer pricingdiaId;
	
	@Column(name = "INDLUNES")
	private Boolean indlunes;
	
	@Column(name = "INDMARTES")
	private Boolean indmartes;
	
	@Column(name = "INDMIERCOLES")	
	private Boolean indmiercoles;
	
	@Column(name = "INDJUEVES")
	private Boolean indjueves;
	
	@Column(name = "INDVIERNES")
	private Boolean indviernes;
	
	@Column(name = "INDSABADO")
	private Boolean indsabado;
	
	@Column(name = "INDDOMINGO")
	private Boolean inddomingo;
	
	@Column(name = "HORARIOINICIO")
	@Temporal(TemporalType.TIMESTAMP)
	// Fue cambido de TIME para TIMESTAMP porque cuando está time el ao que se salva el 1900 y no 1970.
	private Date horarioinicio;
	
	@Column(name = "HORARIOFIN")
	@Temporal(TemporalType.TIMESTAMP)
	// Fue cambido de TIME para TIMESTAMP porque cuando está time el ao que se salva el 1900 y no 1970.
	private Date horariofin;
	
	@Column(name = "FECMODIF")
	@Temporal(TemporalType.TIMESTAMP)
	private Date fecmodif;
	
	@Column(name = "ACTIVO")
	private Integer activo;
	
	@Column(name = "USUARIO_ID")
	private Integer usuarioId;
	
	@Column(name = "INDFECVIAJE")
	private Boolean indfecviaje;
	
	@Column(name = "INDFECVENTA")
	private Boolean indfecventa;
	
	@JoinColumn(name = "PRICING_ID", referencedColumnName = "PRICING_ID")
	@ManyToOne
	private GP_Pricing pricing;

	public GP_PricingDia() {
	}

	public GP_PricingDia(Integer pricingdiaId) {
		this.pricingdiaId = pricingdiaId;
	}

	public Integer getPricingdiaId() {
		return pricingdiaId;
	}

	public void setPricingdiaId(Integer pricingdiaId) {
		this.pricingdiaId = pricingdiaId;
	}

	public Boolean getInddomingo() {
		return inddomingo;
	}

	public void setInddomingo(Boolean inddomingo) {
		this.inddomingo = inddomingo;
	}

	public Boolean getIndjueves() {
		return indjueves;
	}

	public void setIndjueves(Boolean indjueves) {
		this.indjueves = indjueves;
	}

	public Boolean getIndlunes() {
		return indlunes;
	}

	public void setIndlunes(Boolean indlunes) {
		this.indlunes = indlunes;
	}

	public Boolean getIndmartes() {
		return indmartes;
	}

	public void setIndmartes(Boolean indmartes) {
		this.indmartes = indmartes;
	}

	public Boolean getIndmiercoles() {
		return indmiercoles;
	}

	public void setIndmiercoles(Boolean indmiercoles) {
		this.indmiercoles = indmiercoles;
	}

	public Boolean getIndsabado() {
		return indsabado;
	}

	public void setIndsabado(Boolean indsabado) {
		this.indsabado = indsabado;
	}

	public Boolean getIndviernes() {
		return indviernes;
	}

	public void setIndviernes(Boolean indviernes) {
		this.indviernes = indviernes;
	}

	public Date getHorarioinicio() {
		return horarioinicio;
	}

	public void setHorarioinicio(Date horarioinicio) {
		this.horarioinicio = horarioinicio;
	}

	public Date getHorariofin() {
		return horariofin;
	}

	public void setHorariofin(Date horariofin) {
		this.horariofin = horariofin;
	}

	public Date getFecmodif() {
		return fecmodif;
	}

	public void setFecmodif(Date fecmodif) {
		this.fecmodif = fecmodif;
	}

	public Integer getActivo() {
		return activo;
	}

	public void setActivo(Integer activo) {
		this.activo = activo;
	}

	public Integer getUsuarioId() {
		return usuarioId;
	}

	public void setUsuarioId(Integer usuarioId) {
		this.usuarioId = usuarioId;
	}

	public Boolean getIndfecviaje() {
		return indfecviaje;
	}

	public void setIndfecviaje(Boolean indfecviaje) {
		this.indfecviaje = indfecviaje;
	}

	public Boolean getIndfecventa() {
		return indfecventa;
	}

	public void setIndfecventa(Boolean indfecventa) {
		this.indfecventa = indfecventa;
	}

	public GP_Pricing getPricing() {
		return pricing;
	}

	public void setPricing(GP_Pricing pricing) {
		this.pricing = pricing;
	}

	@Override
	public int hashCode() {
		int hash = 0;
		hash += (pricingdiaId != null ? pricingdiaId.hashCode() : 0);
		return hash;
	}

	@Override
	public boolean equals(Object object) {
		if (!(object instanceof GP_PricingDia)) {
			return false;
		}
		GP_PricingDia other = (GP_PricingDia) object;
		if ((this.pricingdiaId == null && other.pricingdiaId != null) || (this.pricingdiaId != null && !this.pricingdiaId.equals(other.pricingdiaId))) {
			return false;
		}
		return true;
	}

	@Override
	public String toString() {
		return "[id=" + pricingdiaId + "]";
	}

	@Override
	protected Object clone() throws CloneNotSupportedException {
		return super.clone();
	}
}
