Commit 7ff46eb0 authored by Matija Obreza's avatar Matija Obreza

Renamed Accession#dublInst to #duplSite, allow JSON [] where multiple

values are allowed in MCPD, use AccessionAlias as back-end for names
parent 6f7328f8
......@@ -69,8 +69,8 @@ public class Accession extends VersionedAuditedModel {
@JoinColumn(name = "orgCtyId", nullable = true)
private Country countryOfOrigin;
@Column(name = "dublInst", length = 8)
private String dublInst;
@Column(name = "duplSite", length = 32)
private String duplSite;
@Column(name = "sampStat", length = 3)
private Integer sampleStatus;
......@@ -168,12 +168,12 @@ public class Accession extends VersionedAuditedModel {
this.countryOfOrigin = countryOfOrigin;
}
public String getDublInst() {
return this.dublInst;
public String getDuplSite() {
return this.duplSite;
}
public void setDublInst(final String dublInst) {
this.dublInst = dublInst;
public void setDuplSite(final String duplSite) {
this.duplSite = duplSite;
}
public Integer getSampleStatus() {
......
......@@ -34,7 +34,7 @@ import org.genesys2.server.model.BusinessModel;
public class AccessionAlias extends BusinessModel {
public static enum AliasType {
GENERIC(0), DONORNAME(1), BREEDERNAME(2), DATABASEID(3), LOCALNAME(4);
ACCENAME(0), DONORNUMB(1), BREEDERNAME(2), DATABASEID(3), LOCALNAME(4), OTHERNUMB(5), COLLNUMB(6);
private int id;
......@@ -75,7 +75,7 @@ public class AccessionAlias extends BusinessModel {
private String instCode;
@Column
private int aliasType = AliasType.GENERIC.id;
private int aliasType = AliasType.ACCENAME.id;
@Column(length = 2)
private String lang;
......
......@@ -167,6 +167,7 @@ accession.crop=Crop
accession.otherNames=Also known as
accession.inTrust=In Trust
accession.mlsStatus=MLS Status
accession.duplSite=Safety duplication
accession.inSvalbard=Svalbardized
accession.inTrust.true=This accession is under Article 15 of the International Treaty on Plant Genetic Resources for Food and Agriculture.
accession.mlsStatus.true=This accession is in the Multilateral System of the ITPGRFA.
......@@ -177,6 +178,7 @@ accession.elevation=Elevation
accession.geolocation=Geolocation (lat, long)
accession.storage=Germplasm storage
accession.storage.=
accession.storage.10=Seed collection
accession.storage.11=Short term
accession.storage.12=Medium term
......@@ -198,6 +200,7 @@ accession.collecting.date=Collecting date
accession.collecting.mission=Collecting mission ID
accession.collecting.source=Collecting source
accession.collectingSource.=
accession.collectingSource.10=Wild habitat
accession.collectingSource.11=Forest or woodland
accession.collectingSource.12=Shrubland
......@@ -253,9 +256,11 @@ accession.sampleStatus.600=GMO
accession.sampleStatus.999=Other
accession.availability=Availability
accession.aliasType.GENERIC=
accession.aliasType.DONORNAME=(Donor accession name)
accession.aliasType.BREEDERNAME=(Used by breeders)
accession.aliasType.ACCENAME=Accession name
accession.aliasType.DONORNUMB=Donor accession identifier
accession.aliasType.BREEDERNAME=Breeder name
accession.aliasType.COLLNUMB=Collecting number
accession.aliasType.OTHERNUMB=Other names
accession.aliasType.DATABASEID=(Database ID)
accession.aliasType.LOCALNAME=(Local name)
......
......@@ -141,6 +141,13 @@
</td>
</tr>
<tr>
<td><spring:message code="accession.duplSite" /></td>
<td><c:forEach items="${accession.duplSite.split('[;,]')}" var="duplSite">
<div><spring:message code="${duplSite}" /></div>
</c:forEach></td>
</tr>
<c:if test="${accessionExchange ne null}">
<tr>
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment