From 01872dfde3f1672e10c059a49e6406a16197fd5e Mon Sep 17 00:00:00 2001
From: tworrall
Date: Sun, 3 Nov 2013 17:13:46 -0500
Subject: [PATCH] VIVO-435
---
webapp/languages/example/i18n/all_es.properties | 2 ++
webapp/web/i18n/all.properties | 4 +++-
.../freemarker/edit/forms/autoCompleteObjectPropForm.ftl | 8 ++++----
.../freemarker/edit/forms/defaultPropertyForm.ftl | 8 +++++---
4 files changed, 14 insertions(+), 8 deletions(-)
diff --git a/webapp/languages/example/i18n/all_es.properties b/webapp/languages/example/i18n/all_es.properties
index 49e8eb110..8c8d081a5 100644
--- a/webapp/languages/example/i18n/all_es.properties
+++ b/webapp/languages/example/i18n/all_es.properties
@@ -857,3 +857,5 @@ processing_icon = tratamiento
selection_in_process = Su selección se está procesando.view_labels_capitalized = Ver etiquetas
view_labels_capitalized = Ver etiquetas
view_labels_for = Ver Etiquetas de
+
+select_an_existing_document = Seleccione un documento existente
diff --git a/webapp/web/i18n/all.properties b/webapp/web/i18n/all.properties
index 38912ca5f..8bc0a1aeb 100644
--- a/webapp/web/i18n/all.properties
+++ b/webapp/web/i18n/all.properties
@@ -868,4 +868,6 @@ manage_labels_intro = In the case where multiple labels exist in the same langua
processing_icon = processing
selection_in_process = Your selection is being processed.
view_labels_capitalized = View Labels
-view_labels_for = View Labels for
\ No newline at end of file
+view_labels_for = View Labels for
+
+select_an_existing_document = Select an existing document
\ No newline at end of file
diff --git a/webapp/web/templates/freemarker/edit/forms/autoCompleteObjectPropForm.ftl b/webapp/web/templates/freemarker/edit/forms/autoCompleteObjectPropForm.ftl
index 58d829fb5..bb2253cae 100644
--- a/webapp/web/templates/freemarker/edit/forms/autoCompleteObjectPropForm.ftl
+++ b/webapp/web/templates/freemarker/edit/forms/autoCompleteObjectPropForm.ftl
@@ -37,11 +37,11 @@
<#assign selectedObjectUri = ""/>
<#assign submitButtonText = "${i18n().create_entry}" />
#if>
-
+<#assign formTitle = editConfiguration.formTitle />
<#if editConfiguration.formTitle?contains("collaborator") >
<#assign formTitle = "${i18n().select_existing_collaborator(editConfiguration.subjectName)}" />
-<#else>
- <#assign formTitle = editConfiguration.formTitle />
+<#elseif editConfiguration.objectPredicateProperty.rangeVClassURI?contains("IAO_0000030")>
+ <#assign formTitle = "${i18n().select_an_existing_document}" + " ${i18n().for} " + editConfiguration.subjectName/>
#if>
<#--In order to fill out the subject-->
<#assign acFilterForIndividuals = "['" + editConfiguration.subjectUri + "']" />
@@ -82,7 +82,7 @@
<#else>
- ${i18n().there_are_no_entries_for_selection}
+ ${i18n().there_are_no_entries_for_selection}
#if>
#if>
diff --git a/webapp/web/templates/freemarker/edit/forms/defaultPropertyForm.ftl b/webapp/web/templates/freemarker/edit/forms/defaultPropertyForm.ftl
index dd4f0978e..99ac5704b 100644
--- a/webapp/web/templates/freemarker/edit/forms/defaultPropertyForm.ftl
+++ b/webapp/web/templates/freemarker/edit/forms/defaultPropertyForm.ftl
@@ -6,8 +6,11 @@
<#if (rangeOptions?keys?size > 0)>
<#assign rangeOptionsExist = true/>
#if>
-
-${editConfiguration.formTitle}
+<#assign formTitle = editConfiguration.formTitle />
+<#if editConfiguration.objectPredicateProperty.rangeVClassURI?contains("IAO_0000030")>
+ <#assign formTitle = "${i18n().select_an_existing_document}" + " ${i18n().for} " + editConfiguration.subjectName/>
+#if>
+${formTitle}
<#if editConfiguration.propertySelectFromExisting = true>
<#if rangeOptionsExist = true >
@@ -47,4 +50,3 @@
<#if editConfiguration.includeDeletionForm = true>
<#include "defaultDeletePropertyForm.ftl">
#if>
-