#-- $This file is distributed under the terms of the license in /doc/license.txt$ -->
<#-- Macros used to build the statistical information on the home page -->
<#-- Get the classgroups so they can be used to qualify searches -->
<#macro allClassGroupNames classGroups>
<#list classGroups as group>
<#-- Only display populated class groups -->
<#if (group.individualCount > 0)>
${group.displayName?capitalize}
#if>
#list>
#macro>
<#-- Renders the html for the faculty member section on the home page. -->
<#-- Works in conjunction with the homePageUtils.js file, which contains the ajax call. -->
<#macro facultyMbrHtml>
${i18n().faculty_capitalized}
${i18n().loading_faculty}
#macro>
<#-- We need the faculty count in order to randomly select 4 faculty using a search query -->
<#macro facultyMemberCount classGroups>
<#assign foundClassGroup = false />
<#list classGroups as group>
<#if (group.individualCount > 0) && group.uri?contains("people") >
<#list group.classes as class>
<#if (class.uri?contains("FacultyMember")) >
<#assign foundClassGroup = true />
<#if (class.individualCount > 0) >
<#else>
#if>
#if>
#list>
#if>
#list>
<#if !foundClassGroup>
#if>
#macro>
<#-- builds the "stats" section of the home page, i.e., class group counts -->
<#macro allClassGroups classGroups>
<#-- Loop through classGroups first so we can account for situations when all class groups are empty -->
<#assign selected = 'class="selected" ' />
<#assign classGroupList>
#assign>
<#-- Display the class group browse only if we have at least one populated class group -->
<#if firstPopulatedClassGroup??>
${classGroupList}
<#else>
${i18n().no_content_create_groups_classes}
<#if user.loggedIn>
<#if user.hasSiteAdminAccess>
${i18n().you_can} ${i18n().add_content_manage_site} ${i18n().from_site_admin_page}
#if>
<#else>
${i18n().please} ${i18n().log_in} ${i18n().to_manage_content}
#if>
#if>
#macro>
<#-- Renders the html for the research section on the home page. -->
<#-- Works in conjunction with the homePageUtils.js file -->
<#macro researchClasses classGroups=vClassGroups>
<#assign foundClassGroup = false />
${i18n().research_capitalized}
<#list classGroups as group>
<#if (group.individualCount > 0) && group.uri?contains("publications") >
<#assign foundClassGroup = true />
<#list group.classes as class>
<#if (class.individualCount > 0) && (class.uri?contains("AcademicArticle") || class.uri?contains("Book") || class.uri?contains("Chapter") ||class.uri?contains("ConferencePaper") || class.uri?contains("Grant") || class.uri?contains("Report")) >
-
${class.individualCount!}
<#if class.name?substring(class.name?length-1) == "s">
${class.name}
<#else>
${class.name}s
#if>
#if>
#list>
- ${i18n().view_all}
#if>
#list>
<#if !foundClassGroup>
- ${i18n().no_research_content_found}
#if>
#macro>
<#-- Renders the html for the academic departments section on the home page. -->
<#-- Works in conjunction with the homePageUtils.js file -->
<#macro academicDeptsHtml>
#macro>
<#-- builds the "academic departments" box on the home page -->
<#macro listAcademicDepartments>
#macro>
<#-- renders the "geographic focus" section on the home page. works in -->
<#-- conjunction with the homePageMaps.js and latLongJson.js files, as well -->
<#-- as the leaflet javascript library. -->
<#macro geographicFocusHtml>
${i18n().geographic_focus}
<#-- map controls allow toggling between multiple map types: e.g., global, country, state/province. -->
<#-- VIVO default is for only a global display, though the javascript exists to support the other -->
<#-- types. See map documentation for additional information on how to implement additional types. -->
<#--
-->
${i18n().loading_map_information}
<#--
-->
#macro>