NIHVIVO-1717 Suppress add link on vitro:primaryLink if there's already a primary link for the individual
This commit is contained in:
parent
4e0b942d91
commit
8c1020bf31
1 changed files with 10 additions and 1 deletions
|
@ -96,6 +96,10 @@ name will be used as the label. -->
|
|||
</#if>
|
||||
</#macro>
|
||||
|
||||
<#macro propertyLabel property label="${property.name?capitalize}">
|
||||
<h2 id="${property.localName}">${label}</h2>
|
||||
</#macro>
|
||||
|
||||
<#macro propertyListItem property statement editable>
|
||||
<li role="listitem">
|
||||
<#nested>
|
||||
|
@ -142,11 +146,16 @@ name will be used as the label. -->
|
|||
|
||||
<#if (primaryLink?has_content || additionalLinks?has_content)> <#-- true when the property is in the list, even if not populated (when editing) -->
|
||||
<nav role="navigation">
|
||||
<@addLinkWithLabel primaryLink editable "Primary Web Page" />
|
||||
<#local primaryLinkLabel = "Primary Web Page">
|
||||
<@propertyLabel primaryLink primaryLinkLabel />
|
||||
<#if primaryLink.statements?has_content> <#-- if there are any statements -->
|
||||
<ul class="${linkListClass}" id="links-primary" role="list">
|
||||
<@objectPropertyList primaryLink editable />
|
||||
</ul>
|
||||
<#else>
|
||||
<#-- Show add link only if there isn't a primaryLink already (displayLimitAnnnot not
|
||||
supported for object properties). -->
|
||||
<@addLinkWithLabel primaryLink editable primaryLinkLabel />
|
||||
</#if>
|
||||
<@addLinkWithLabel additionalLinks editable "Additional Web Pages" />
|
||||
<#if additionalLinks.statements?has_content> <#-- if there are any statements -->
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue