Mercurial > hg > ismi-richfaces
diff src/main/java/de/mpiwg/itgroup/ismi/util/guiComponents/TargetMisattribution.java @ 1:2e911857a759
(none)
author | jurzua |
---|---|
date | Wed, 29 Oct 2014 14:00:28 +0000 |
parents | |
children |
line wrap: on
line diff
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/src/main/java/de/mpiwg/itgroup/ismi/util/guiComponents/TargetMisattribution.java Wed Oct 29 14:00:28 2014 +0000 @@ -0,0 +1,52 @@ +package de.mpiwg.itgroup.ismi.util.guiComponents; + +import org.mpi.openmind.repository.bo.Entity; +import org.mpiwg.itgroup.escidoc.bo.ESciDocItem; + +import de.mpiwg.itgroup.ismi.entry.beans.ApplicationBean; + +public class TargetMisattribution{ + private Entity person; + //private Publication pub; + private ESciDocItem item; + + public TargetMisattribution(Entity person, String refId, String notes, ApplicationBean appBean){ + this.person = person; + + this.item = appBean.getRefCache().getItem(refId); + if(this.item == null){ + this.item = new ESciDocItem(refId); + this.item.setErrorLoading(ESciDocItem.ESCIDOC_ERROR_ID_NO_FOUND); + } + this.item.getPublication().setAdditionalInformation(notes); + + /* + try{ + this.pub = ESciDocHandler.getPublicationById(refId); + }catch (Exception e) { + System.err.println("The references could not be loaded. The server did not respond."); + } + + if(this.pub == null){ + this.pub = new Publication(refId); + this.pub.setErrorLoading(Publication.ESCIDOC_ERROR_ID_NO_FOUND); + } + this.pub.setAdditionalInformation(notes); + */ + } + + public Entity getPerson() { + return person; + } + public void setPerson(Entity person) { + this.person = person; + } + + public ESciDocItem getItem() { + return item; + } + + public void setItem(ESciDocItem item) { + this.item = item; + } +} \ No newline at end of file