NIHVIVO-1333 Added some sample markup to the ontology property display template.

This commit is contained in:
rjy7 2010-12-06 22:18:26 +00:00
parent 55eb8bece4
commit 96b10bed71

View file

@ -6,30 +6,46 @@
<#list propertyGroups as group> <#list propertyGroups as group>
<#-- Display the group heading --> <#-- Get the group name -->
<#-- If there are no groups, a dummy group has been created with a null name. --> <#if group.name??>
<#if ! group.name??> <#if group.name?has_content>
<#-- Here you might just do nothing and proceed to list the properties as in the grouped case, <#assign groupName = group.name>
or you might choose different markup for the groupless case. -->
<#-- This is the group for properties not assigned to any group. It has an empty name. -->
<#elseif group.name?length == 0>
<h3>other</h3>
<#else> <#else>
<h3>${group.name}</h3> <#-- This is the group for properties not assigned to any group. It has an empty name. -->
<#assign groupName = "other">
</#if>
<#else>
<#-- If there are no groups, a dummy group has been created with a null name. -->
<#assign groupName = "">
</#if>
<div class="property-group" id="group-${groupName}">
<#-- Display the group heading -->
<#if groupName?has_content>
<h3>${groupName}</h3>
</#if> </#if>
<#-- Now list the properties in the group --> <#-- Now list the properties in the group -->
<div class="properties">
<#list group.properties as property> <#list group.properties as property>
<div class="property" id="prop-${property.name}">
<#-- Property display name -->
<h4>${property.name}</h4> <h4>${property.name}</h4>
<#-- List the statements for each property --> <#-- List the statements for each property -->
<#if property.type == "data"> <#-- data property -->
<#list property.statements as statement> <#list property.statements as statement>
<#if statement.value??> <#-- data property -->
<div class="dataprop-value"> <div class="dataprop-value">
${statement.value} ${statement.value}
</div> </div> <!-- end dataprop-value -->
</#if>
</#list>
</#list> </#list>
<#else> <#-- object property -->
</#if>
</div> <!-- end property -->
</#list>
</div> <!-- end properties -->
</div> <!-- end property-group -->
</#list> </#list>