Documentation for ccm-sci-types-institute.ftl

git-svn-id: https://svn.libreccm.org/ccm/trunk@6310 8810af33-2d31-482b-a856-94f89814c4df
master
jensp 2019-11-03 18:03:00 +00:00
parent 5edd620506
commit 7871487205
1 changed files with 46 additions and 0 deletions

View File

@ -7,6 +7,17 @@
<#import ../ccm-cms/content-item.ftl as ContentItem> <#import ../ccm-cms/content-item.ftl as ContentItem>
<#--filedoc
Functions for processing SciInstitute items.
-->
<#--doc
Gets the description of the institute.
@param data The SciInstitute to use.
@return The description of the institute.
-->
<#function getDescription data> <#function getDescription data>
<#if (data["./instituteDesc"]?size > 0)> <#if (data["./instituteDesc"]?size > 0)>
<#return data["./instituteDesc"]> <#return data["./instituteDesc"]>
@ -15,6 +26,13 @@
</#if> </#if>
</#function> </#function>
<#--doc
Gets the short description of the institute.
@param data The SciInstitute to use.
@return The short description of the institute.
-->
<#function getShortDescription data> <#function getShortDescription data>
<#if (data["./instituteShortDescription"])> <#if (data["./instituteShortDescription"])>
<#return data["./instituteShortDescription"])> <#return data["./instituteShortDescription"])>
@ -23,18 +41,46 @@
</#if> </#if>
</#function> </#function>
<#--doc
Gets the departments of an institute.
@param data The SciInstitute to use.
@return A sequence of SciDepartments.
-->
<#function getDepartments data> <#function getDepartments data>
<#return data["./departments"]> <#return data["./departments"]>
</#function> </#function>
<#--doc
Gets the OID of a department.
@param department The SciDepartment to use.
@return The OID of the department.
-->
<#function getDepartmentOid department> <#function getDepartmentOid department>
<#return department["./@oid"]> <#return department["./@oid"]>
</#function> </#function>
<#--doc
Gets the title of a department.
@param department The SciDepartment to use.
@return The title of the department.
-->
<#function getDepartmentTitle department> <#function getDepartmentTitle department>
<#return department["./title"]> <#return department["./title"]>
</#function> </#function>
<#--doc
Gets the link the to department.
@param department The SciDepartment to use.
@return The link to the department.
-->
<#function getDepartmentLink department> <#function getDepartmentLink department>
<#return ContentItem.generateContentItemLink(department)> <#return ContentItem.generateContentItemLink(department)>
</#function> </#function>