Commit ff324b13 authored by Matija Obreza's avatar Matija Obreza
Browse files

Organization blurp

parent 5badbae1
......@@ -49,6 +49,10 @@ public class Organization extends BusinessModel {
@Field(name = "body", store = Store.NO)
private String title;
@Lob
@Field(name = "text", store = Store.NO)
private String description;
@ManyToMany(cascade = CascadeType.ALL, fetch = FetchType.EAGER, targetEntity = FaoInstitute.class)
@JoinTable(name = "organizationinstitute", joinColumns = @JoinColumn(name = "organizationId"), inverseJoinColumns = @JoinColumn(name = "instituteId"))
private List<FaoInstitute> members = new ArrayList<FaoInstitute>();
......@@ -69,6 +73,14 @@ public class Organization extends BusinessModel {
this.title = title;
}
public String getDescription() {
return description;
}
public void setDescription(String description) {
this.description = description;
}
public List<FaoInstitute> getMembers() {
return members;
}
......
......@@ -12,10 +12,15 @@
<small><c:out value="${organization.slug}" /></small>
</h1>
<div class="free-text">
<c:out value="${organization.description}" escapeXml="false" />
</div>
<div class="page-header">
<a href="<c:url value="/org/${organization.slug}/data" />"><spring:message code="view.accessions" /></a>
</div>
<ul class="funny-list">
<c:forEach items="${organization.members}" var="faoInstitute" varStatus="status">
<li class="clearfix ${status.count % 2 == 0 ? 'even' : 'odd'}"><a class="show pull-left" href="<c:url value="/wiews/${faoInstitute.code.toLowerCase()}" />"><b><c:out value="${faoInstitute.code}" /></b> <c:out value="${faoInstitute.fullName}" /></a>
......
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