Corrected Conference : merge gone bad :P
This commit is contained in:
@@ -1,6 +1,7 @@
|
||||
package org.yacos.core.conferences;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.Collection;
|
||||
import java.util.Date;
|
||||
import java.util.List;
|
||||
import javax.persistence.Entity;
|
||||
@@ -17,37 +18,37 @@ import javax.persistence.TemporalType;
|
||||
import org.yacos.core.article.Article;
|
||||
import org.yacos.core.users.User;
|
||||
|
||||
//@Entity
|
||||
@Entity
|
||||
public class Conference {
|
||||
//@Id
|
||||
//@GeneratedValue(strategy=GenerationType.AUTO)
|
||||
private Integer id;
|
||||
@Id
|
||||
@GeneratedValue(strategy=GenerationType.AUTO)
|
||||
private String id;
|
||||
private String titre;
|
||||
private String description;
|
||||
private String otherInformations;
|
||||
//@Temporal(TemporalType.DATE)
|
||||
@Temporal(TemporalType.DATE)
|
||||
private Date dateAbstract;
|
||||
//@Temporal(TemporalType.DATE)
|
||||
@Temporal(TemporalType.DATE)
|
||||
private Date dateArticle;
|
||||
//@Temporal(TemporalType.DATE)
|
||||
@Temporal(TemporalType.DATE)
|
||||
private Date dateEvaluation;
|
||||
//@Temporal(TemporalType.DATE)
|
||||
@Temporal(TemporalType.DATE)
|
||||
private Date dateStart;
|
||||
//@Temporal(TemporalType.DATE)
|
||||
@Temporal(TemporalType.DATE)
|
||||
private Date dateEnd;
|
||||
|
||||
//@OneToOne(targetEntity=User.class,optional=false)
|
||||
//@JoinColumn(name="chairman_id",nullable=false)
|
||||
@OneToOne(targetEntity=User.class,optional=false)
|
||||
@JoinColumn(name="chairman_id",nullable=false)
|
||||
private User chairman;
|
||||
|
||||
//@OneToMany(targetEntity=Article.class,mappedBy="articles")
|
||||
private ArrayList<Article> articles;
|
||||
@OneToMany(targetEntity=Article.class,mappedBy="conference")
|
||||
private Collection<Article> articles;
|
||||
|
||||
/**
|
||||
* @return the chairman
|
||||
*/
|
||||
//@OneToOne(targetEntity=User.class,optional=false)
|
||||
//@JoinColumn(name="chairman_id",nullable=false)
|
||||
@OneToOne(targetEntity=User.class,optional=false)
|
||||
@JoinColumn(name="chairman_id",nullable=false)
|
||||
public User getChairman() {
|
||||
return chairman;
|
||||
}
|
||||
@@ -55,64 +56,64 @@ public class Conference {
|
||||
/**
|
||||
* @param chairman the chairman to set
|
||||
*/
|
||||
//@OneToOne(targetEntity=User.class,optional=false)
|
||||
//@JoinColumn(name="chairman_id",nullable=false)
|
||||
@OneToOne(targetEntity=User.class,optional=false)
|
||||
@JoinColumn(name="chairman_id",nullable=false)
|
||||
public void setChairman(User chairman) {
|
||||
this.chairman = chairman;
|
||||
}
|
||||
|
||||
//@Temporal(TemporalType.DATE)
|
||||
@Temporal(TemporalType.DATE)
|
||||
public Date getDataAbstract() {
|
||||
return dateAbstract;
|
||||
}
|
||||
|
||||
//@Temporal(TemporalType.DATE)
|
||||
@Temporal(TemporalType.DATE)
|
||||
public void setDataAbstract(Date dataAbstract) {
|
||||
this.dateAbstract = dataAbstract;
|
||||
}
|
||||
//@Temporal(TemporalType.DATE)
|
||||
@Temporal(TemporalType.DATE)
|
||||
public Date getDateArticle() {
|
||||
return dateArticle;
|
||||
}
|
||||
//@Temporal(TemporalType.DATE)
|
||||
@Temporal(TemporalType.DATE)
|
||||
public void setDateArticle(Date dateArticle) {
|
||||
this.dateArticle = dateArticle;
|
||||
}
|
||||
//@Temporal(TemporalType.DATE)
|
||||
@Temporal(TemporalType.DATE)
|
||||
public Date getDateEnd() {
|
||||
return dateEnd;
|
||||
}
|
||||
//@Temporal(TemporalType.DATE)
|
||||
@Temporal(TemporalType.DATE)
|
||||
public void setDateEnd(Date dateEnd) {
|
||||
this.dateEnd = dateEnd;
|
||||
}
|
||||
//@Temporal(TemporalType.DATE)
|
||||
@Temporal(TemporalType.DATE)
|
||||
public Date getDateEvaluation() {
|
||||
return dateEvaluation;
|
||||
}
|
||||
//@Temporal(TemporalType.DATE)
|
||||
@Temporal(TemporalType.DATE)
|
||||
public void setDateEvaluation(Date dateEvaluation) {
|
||||
this.dateEvaluation = dateEvaluation;
|
||||
}
|
||||
//@Temporal(TemporalType.DATE)
|
||||
@Temporal(TemporalType.DATE)
|
||||
public Date getDateStart() {
|
||||
return dateStart;
|
||||
}
|
||||
//@Temporal(TemporalType.DATE)
|
||||
@Temporal(TemporalType.DATE)
|
||||
public void setDateStart(Date dateStart) {
|
||||
this.dateStart = dateStart;
|
||||
}
|
||||
public String getDescirption() {
|
||||
public String getDescription() {
|
||||
return description;
|
||||
}
|
||||
public void setDescirption(String descirption) {
|
||||
public void setDescription(String descirption) {
|
||||
this.description = descirption;
|
||||
}
|
||||
public String getInfoComplementray() {
|
||||
public String getOtherInformations() {
|
||||
return otherInformations;
|
||||
}
|
||||
public void setInfoComplementray(String infoComplementray) {
|
||||
this.otherInformations = infoComplementray;
|
||||
public void setOtherInformations(String otherInformations) {
|
||||
this.otherInformations = otherInformations;
|
||||
}
|
||||
public String getTitre() {
|
||||
return titre;
|
||||
@@ -120,17 +121,17 @@ public class Conference {
|
||||
public void setTitre(String titre) {
|
||||
this.titre = titre;
|
||||
}
|
||||
public Integer getId() {
|
||||
public String getId() {
|
||||
return id;
|
||||
}
|
||||
public void setId(Integer id) {
|
||||
public void setId(String id) {
|
||||
this.id = id;
|
||||
}
|
||||
|
||||
public Conference() {
|
||||
}
|
||||
|
||||
public Conference(Integer id, String titre, String descirption, String infoComplementray, Date dataAbstract, Date dateArticle, Date dateEvaluation, Date dateStart, Date dateEnd) {
|
||||
public Conference(String id, String titre, String descirption, String infoComplementray, Date dataAbstract, Date dateArticle, Date dateEvaluation, Date dateStart, Date dateEnd) {
|
||||
super();
|
||||
this.id = id;
|
||||
this.titre = titre;
|
||||
@@ -143,8 +144,13 @@ public class Conference {
|
||||
this.dateEnd = dateEnd;
|
||||
}
|
||||
|
||||
//@OneToMany(targetEntity=Article.class,mappedBy="articles")
|
||||
public List<Article> getArticles() {
|
||||
@OneToMany(targetEntity=Article.class,mappedBy="articles")
|
||||
public void setArticles(Collection<Article> articles) {
|
||||
this.articles = articles;
|
||||
}
|
||||
|
||||
@OneToMany(targetEntity=Article.class,mappedBy="articles")
|
||||
public Collection<Article> getArticles() {
|
||||
return articles;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user