From fe4104023f6aead05173fb557ff1da41f0fbb798 Mon Sep 17 00:00:00 2001 From: cappadona Date: Thu, 21 Jul 2011 12:29:08 +0000 Subject: [PATCH] NIHVIVO 2836 Merged r8772 from maint-rel-vivo-1.3 branch. --- .../body/individualList-checkForData.ftl | 28 ++++++++ .../freemarker/body/individualList.ftl | 64 ++++++++++--------- 2 files changed, 63 insertions(+), 29 deletions(-) create mode 100644 webapp/web/templates/freemarker/body/individualList-checkForData.ftl diff --git a/webapp/web/templates/freemarker/body/individualList-checkForData.ftl b/webapp/web/templates/freemarker/body/individualList-checkForData.ftl new file mode 100644 index 000000000..6f3528681 --- /dev/null +++ b/webapp/web/templates/freemarker/body/individualList-checkForData.ftl @@ -0,0 +1,28 @@ +<#-- $This file is distributed under the terms of the license in /doc/license.txt$ --> + +<#if (individuals?size == 0)> + <#assign noData = true /> +<#else> + <#assign noData = false /> + + +<#assign noDataNotification> + <#if user.loggedIn> + <#if user.authorizedToRebuildSearchIndex> + +

Expecting content?

+

Try rebuilding the search index.

+
+ + <#else> + +

Please log in to manage content.

+
+ + +

There is currently no ${title} content in the system

+ + <#if user.loggedIn && user.hasSiteAdminAccess> +

You can add content and manage this site from the Site Administration page.

+ + \ No newline at end of file diff --git a/webapp/web/templates/freemarker/body/individualList.ftl b/webapp/web/templates/freemarker/body/individualList.ftl index 8484ba94b..bfa0300aa 100644 --- a/webapp/web/templates/freemarker/body/individualList.ftl +++ b/webapp/web/templates/freemarker/body/individualList.ftl @@ -4,6 +4,8 @@ <#import "lib-list.ftl" as l> +<#include "individualList-checkForData.ftl"> + ${stylesheets.add('')}
@@ -16,35 +18,39 @@ ${stylesheets.add(' + <#list pages as page> + <#if page.selected> +
  • ${page.text}
  • + <#else> + <#-- RY Ideally the urls would be generated by the controller; see search-pagedResults.ftl --> +
  • ${page.text}
  • + + + + + + + ${pagination} + + + + ${pagination} + <#else> - <#assign pagination> - <#if (pages?has_content && pages?size > 1)> - pages: - - - - - ${pagination} - - - - ${pagination} + ${noDataNotification}
    \ No newline at end of file