From 108164812630b79dc15859417e390930ffbe9305 Mon Sep 17 00:00:00 2001 From: rjy7 Date: Fri, 19 Mar 2010 15:50:43 +0000 Subject: [PATCH] NIHVIVO-200 Redid previous commit so span tag is not in the custom tag itself, since it messes up other front end links. Just test the value in the JSP before outputting the span tag. --- .../webapp/web/jsptags/PropertyEditLinks.java | 5 +-- webapp/web/templates/entity/entityBasic.jsp | 34 ++++++++++++------- 2 files changed, 23 insertions(+), 16 deletions(-) diff --git a/webapp/src/edu/cornell/mannlib/vitro/webapp/web/jsptags/PropertyEditLinks.java b/webapp/src/edu/cornell/mannlib/vitro/webapp/web/jsptags/PropertyEditLinks.java index 199fd6753..32c2179cd 100644 --- a/webapp/src/edu/cornell/mannlib/vitro/webapp/web/jsptags/PropertyEditLinks.java +++ b/webapp/src/edu/cornell/mannlib/vitro/webapp/web/jsptags/PropertyEditLinks.java @@ -146,15 +146,12 @@ public class PropertyEditLinks extends TagSupport{ } else { try{ JspWriter out = pageContext.getOut(); - if( links != null && links.length > 0){ - // Include the wrapping span here, rather than in the JSP, so if there are no links we don't get the span. - out.print(""); + if( links != null){ for( LinkStruct ln : links ){ if( ln != null ){ out.print( makeElement( ln ) + '\n' ); } } - out.print(""); } } catch(IOException ioe){ log.error( ioe ); diff --git a/webapp/web/templates/entity/entityBasic.jsp b/webapp/web/templates/entity/entityBasic.jsp index 1f42cb822..a665f16c8 100644 --- a/webapp/web/templates/entity/entityBasic.jsp +++ b/webapp/web/templates/entity/entityBasic.jsp @@ -114,8 +114,8 @@ RY Description not working - FIX

${entity.name}

- <%-- --%> - + + ${editLinks}
@@ -125,7 +125,8 @@ RY Description not working - FIX
${entity.moniker} - + + ${editLinks}
@@ -153,7 +154,8 @@ RY Description not working - FIX <%-- - + + ${editLinks} --%> @@ -185,9 +187,11 @@ RY Description not working - FIX
${entity.citation}
+ <%-- - - + + ${editLinks} + --%>
@@ -197,9 +201,11 @@ RY Description not working - FIX
${entity.blurb}
+ <%-- - - + + ${editLinks} + --%>
@@ -207,9 +213,11 @@ RY Description not working - FIX
${entity.description}
+ <%-- - - + + ${editLinks} + --%>
@@ -236,9 +244,11 @@ RY Description not working - FIX
${entity.citation}
+ <%-- - - + + ${editLinks} + --%>