NIHVIVO-157 manual merge of the changes from branch NIHVIVO-157-file-storage
This commit is contained in:
parent
083aa4e530
commit
fb7d5bbba9
51 changed files with 3535 additions and 1198 deletions
|
@ -103,17 +103,5 @@
|
|||
</td>
|
||||
</tr>
|
||||
|
||||
<tr class="editformcell" id='thumbnailFilenameTr'>
|
||||
<td id="thumbnailTd" valign="bottom" colspan="1">
|
||||
<b>Thumbnail Filename</b> <em>Optional and usually more convenient to upload from previous screen</em><br/>
|
||||
<input type="text" name="ImageThumb" value="<form:value name="ImageThumb"/>" maxlength="255" />
|
||||
<p class="error"><form:error name="ImageThumb"/></p>
|
||||
</td>
|
||||
<td id="optionalImageTd" valign="bottom" colspan="1">
|
||||
<b>Optional Larger Image</b> <em>(filename or full path)</em>
|
||||
<input type="text" name="ImageFile" value="<form:value name="ImageFile"/>" maxlength="255" />
|
||||
<p class="error"><form:error name="ImageFile"/></p>
|
||||
</td>
|
||||
</tr>
|
||||
|
||||
|
||||
|
|
|
@ -90,18 +90,6 @@
|
|||
<input type="text" name="Timekey" value="<form:value name="Timekey"/>" size="19" maxlength="19"><br>
|
||||
<font size="2" color="red"><form:error name="Timekey"/></font>
|
||||
</td>
|
||||
</tr>
|
||||
<tr class="editformcell" id='thumbnailFilenameTr'>
|
||||
<td id="thumbnailTd" valign="bottom" colspan="1">
|
||||
<b>Thumbnail Filename</b> <em>Optional and usually more convenient to upload from previous screen</em>
|
||||
<input type="text" name="ThumbnailFilename" value="<form:value name="ThumbnailFilename"/>" size="60" maxlength="255" />
|
||||
<font size="2" color="red"><form:error name="ThumbnailFilename"/></font>
|
||||
</td>
|
||||
<td id="optionalImageTd" valign="bottom" colspan="1">
|
||||
<b>Optional Larger Image</b> <em>(filename or full path)</em>
|
||||
<input type="text" name="LargerImage" value="<form:value name="LargerImage"/>" size="60" maxlength="255" />
|
||||
<font size="2" color="red"><form:error name="LargerImage"/></font>
|
||||
</td>
|
||||
</tr>
|
||||
<tr class="editformcell" id="portalFlagsTr">
|
||||
<td id="portalFlagsTd" valign="bottom" colspan="3">
|
||||
|
|
|
@ -63,18 +63,8 @@ if (VitroRequestPrep.isSelfEditing(request) || LoginFormBean.loggedIn(request, L
|
|||
<c:set var="showEdits" value="${showSelfEdits || showCuratorEdits}" scope="request"/>
|
||||
<c:set var="editingClass" value="${showEdits ? 'editing' : ''}" scope="request"/>
|
||||
|
||||
<c:set var='imageDir' value='images' />
|
||||
<c:set var="themeDir"><c:out value="${portalBean.themeDir}" /></c:set>
|
||||
<%
|
||||
//here we build up the url for the larger image.
|
||||
String imageUrl = null;
|
||||
if (entity.getImageFile() != null &&
|
||||
entity.getImageFile().indexOf("http:")==0) {
|
||||
imageUrl = entity.getImageFile();
|
||||
} else {
|
||||
imageUrl = response.encodeURL( "/images/" + entity.getImageFile() );
|
||||
}
|
||||
|
||||
//anytime we are at an entity page we shouldn't have an editing config or submission
|
||||
session.removeAttribute("editjson");
|
||||
EditConfiguration.clearAllConfigsInSession(session);
|
||||
|
@ -196,28 +186,26 @@ if (VitroRequestPrep.isSelfEditing(request) || LoginFormBean.loggedIn(request, L
|
|||
</c:if>
|
||||
|
||||
<%-- Thumbnail (with citation) --%>
|
||||
<c:if test="${showEdits || !empty entity.imageThumb}">
|
||||
<c:if test="${showEdits || !empty entity.thumbUrl}">
|
||||
<div id="dprop-vitro-image" class="propsItem ${editingClass}">
|
||||
<c:set var="mayEditThumbnail"><edLnk:editLinks item="<%= VitroVocabulary.IMAGETHUMB %>" icons="false" /></c:set>
|
||||
<c:if test="${showEdits and !empty mayEditThumbnail}">
|
||||
<c:set var="mayEditImage"><edLnk:editLinks item="<%= VitroVocabulary.IND_MAIN_IMAGE %>" icons="false" /></c:set>
|
||||
<c:if test="${showEdits and !empty mayEditImage}">
|
||||
<h3 class="propertyName">image</h3>
|
||||
<edLnk:editLinks item="<%= VitroVocabulary.IMAGETHUMB %>" icons="false" />
|
||||
<edLnk:editLinks item="<%= VitroVocabulary.IND_MAIN_IMAGE %>" icons="false" />
|
||||
</c:if>
|
||||
<c:if test="${!empty entity.imageThumb}">
|
||||
<c:if test="${!empty entity.thumbUrl}">
|
||||
<div class="datatypeProperties">
|
||||
<div class="datatypePropertyValue">
|
||||
<div class="statementWrap thumbnail">
|
||||
<c:set var="imageTitle" value="${entity.name}" />
|
||||
<c:if test="${!empty entity.imageFile}">
|
||||
<c:url var="imageUrl" value="/${imageDir}/${entity.imageFile}" />
|
||||
<a class="image" href="${imageUrl}">
|
||||
<c:if test="${!empty entity.imageUrl}">
|
||||
<a class="image" href="<c:url value='${entity.imageUrl}'/>">
|
||||
<c:set var="imageTitle" value="click to view larger image in new window" />
|
||||
</c:if>
|
||||
<c:url var="imageSrc" value='/${imageDir}/${entity.imageThumb}'/>
|
||||
<img src="<c:out value="${imageSrc}"/>" title="${imageTitle}" alt="" width="150"/>
|
||||
<c:if test="${!empty entity.imageFile}"></a></c:if>
|
||||
<img src="<c:url value='${entity.thumbUrl}'/>" title="${imageTitle}" alt="" width="150"/>
|
||||
<c:if test="${!empty entity.imageUrl}"></a></c:if>
|
||||
<c:if test="${showEdits}">
|
||||
<c:set var="editLinks"><edLnk:editLinks item="<%= VitroVocabulary.IMAGETHUMB %>" data="${entity.imageThumb}" icons="false"/></c:set>
|
||||
<c:set var="editLinks"><edLnk:editLinks item="<%= VitroVocabulary.IND_MAIN_IMAGE %>" data="${entity.thumbUrl}" icons="false"/></c:set>
|
||||
<c:if test="${!empty editLinks}"><span class="editLinks">${editLinks}</span></c:if>
|
||||
</c:if>
|
||||
</div>
|
||||
|
@ -282,7 +270,7 @@ if (VitroRequestPrep.isSelfEditing(request) || LoginFormBean.loggedIn(request, L
|
|||
</c:if>
|
||||
|
||||
<%-- Citation, if no thumbnail --%>
|
||||
<c:if test="${empty entity.imageThumb}">
|
||||
<c:if test="${empty entity.thumbUrl}">
|
||||
<jsp:include page="entityCitation.jsp" />
|
||||
</c:if>
|
||||
|
||||
|
|
|
@ -34,7 +34,6 @@
|
|||
<c:out value="${requestScope.columns}" default="8"/>
|
||||
</c:set>
|
||||
|
||||
<c:set var='IMG_DIR' value='images/' />
|
||||
<c:set var='IMG_WIDTH' value='100'/>
|
||||
|
||||
<table class='tabEntities entityListForGalleryTab'>
|
||||
|
@ -43,15 +42,14 @@
|
|||
<c:forEach var='col' begin="1" end="${columns}" step="1">
|
||||
<c:set var='ent' value='${entities[count]}'/>
|
||||
<c:set var='count' value='${count + 1}'/>
|
||||
<c:if test="${ not empty ent and not empty ent.imageThumb}">
|
||||
<c:if test="${ not empty ent and not empty ent.thumbUrl}">
|
||||
<td>
|
||||
<c:url var="entityHref" value="/entity">
|
||||
<c:param name="home" value="${portal.portalId}"/>
|
||||
<c:param name="uri" value="${ent.URI}"/>
|
||||
</c:url>
|
||||
<a class="image" href="<c:out value="${entityHref}"/>" >
|
||||
<c:url var="imageSrc" value="${IMG_DIR}${ent.imageThumb}"/>
|
||||
<img width="${IMG_WIDTH}" src="<c:out value="${imageSrc}"/>" title="${ent.name}" alt="${ent.name}" />
|
||||
<img width="${IMG_WIDTH}" src="<c:url value='${ent.thumbUrl}'/>" title="${ent.name}" alt="${ent.name}" />
|
||||
</a>
|
||||
</td>
|
||||
</c:if>
|
||||
|
|
|
@ -25,7 +25,6 @@
|
|||
<c:set var="searchViewPrefix" value="/templates/search/"/>
|
||||
<c:set var='entities' value='${requestScope.entities}' /><%/* just moving this into page scope for easy use */ %>
|
||||
<c:set var='portal' value='${requestScope.portal}' />
|
||||
<c:set var='IMG_DIR' value='images/' />
|
||||
<c:set var='IMG_WIDTH' value='75'/>
|
||||
<jsp:include page="/templates/alpha/alphaIndex.jsp"/>
|
||||
<ul class='tabEntities entityListForTab'>
|
||||
|
@ -76,13 +75,12 @@
|
|||
</c:if>
|
||||
<c:forEach items='${ent.linksList}' var="entLink"><span class="tab-extLink"> | <c:url var="entLinkUrl" value="${entLink.url}"/><a class="externalLink" href="<c:out value="${entLinkUrl}"/>">${entLink.anchor}</a></span></c:forEach>
|
||||
<c:choose>
|
||||
<c:when test='${not empty ent.imageThumb }'>
|
||||
<c:when test='${not empty ent.thumbUrl }'>
|
||||
<c:url var="imageHref" value="entity">
|
||||
<c:param name="home" value="${sessionScope.currentPortalId}"/>
|
||||
<c:param name="uri" value="${ent.URI}"/>
|
||||
</c:url>
|
||||
<c:url var="imageSrc" value="${IMG_DIR}${ent.imageThumb}"/>
|
||||
<div class="tab-image"><a class="image" href="<c:out value="${imageHref}"/>"><img width="${IMG_WIDTH}" src="<c:out value="${imageSrc}"/>" title="${ent.name}" alt="" /></a></div>
|
||||
<div class="tab-image"><a class="image" href="<c:out value="${imageHref}"/>"><img width="${IMG_WIDTH}" src="<c:url value='${ent.thumbUrl}'/>" title="${ent.name}" alt="" /></a></div>
|
||||
<c:if test="${not empty ent.blurb}"><div class='blurb'>${ent.blurb}</div></c:if>
|
||||
</c:when>
|
||||
<c:otherwise>
|
||||
|
|
|
@ -1,55 +1,54 @@
|
|||
<%-- $This file is distributed under the terms of the license in /doc/license.txt$ --%>
|
||||
|
||||
<%@ taglib uri="http://java.sun.com/jstl/core" prefix="c" %><%/* this odd thing points to something in web.xml */ %>
|
||||
<%@ page errorPage="/error.jsp"%>
|
||||
<% /***********************************************
|
||||
Display a single search result group
|
||||
|
||||
request.attributes:
|
||||
a List with objects with the named "entities"
|
||||
a ClassGroup object named "classgroup"
|
||||
|
||||
request.parameters:
|
||||
None yet.
|
||||
|
||||
Consider sticking < % = MiscWebUtils.getReqInfo(request) % > in the html output
|
||||
for debugging info.
|
||||
**********************************************/
|
||||
if (request.getAttribute("entities") == null){
|
||||
String e="searchGroup.jsp expects that request attribute 'entities' be set to the Entity object to display.";
|
||||
throw new JspException(e);
|
||||
}
|
||||
if (request.getAttribute("classgroup") == null){
|
||||
String e="searchGroup.jsp expects that request attribute 'classgroup' be set to the Entity object to display.";
|
||||
throw new JspException(e);
|
||||
}
|
||||
%>
|
||||
<c:set var='imageDir' value='images' />
|
||||
<c:set var='entities' value='${requestScope.entities}'/><%/* just moving this into page scope for easy use */ %>
|
||||
<c:set var='classgroup' value='${requestScope.classgroup}'/>
|
||||
|
||||
<c:set var='portal' value='${requestScope.portal}'/>
|
||||
<c:set var='portalBean' value='${requestScope.portalBean}'/>
|
||||
|
||||
<div class='contents entity entity${entity.id}'>
|
||||
<h1><c:out value="${entity.name}"/></h1>
|
||||
<c:out value="${entity.moniker}" default="moniker?"/>
|
||||
<c:if test="${!empty entity.anchor}">
|
||||
<a href='<c:url value="${entity.url}"/>'>${entity.anchor}</a>
|
||||
</c:if>
|
||||
<c:forEach items="${entity.linksList}" var='link'>
|
||||
| <a href='<c:url value="${link.url}"/>'${link.anchor}</a>
|
||||
</c:forEach>
|
||||
<c:if test="${!empty entity.imageThumb}">
|
||||
<div class="thumbnail">
|
||||
<c:if test="${!empty entity.imageFile}"><a target="_new" href="<c:url value='${imageDir}/${entity.imageFile}'/>"></c:if>
|
||||
<img src="<c:url value='${imageDir}/${entity.imageThumb}'/>" title="click to view larger image in new window" width="150">
|
||||
<c:if test="${!empty entity.imageFile}"></a></c:if>
|
||||
</div>
|
||||
</c:if>
|
||||
<c:import url="${entityPropsListJsp}" /><%/* here we import the properties for the entity */ %>
|
||||
<div class='description'>
|
||||
<c:out value="${entity.description}" escapeXml ='false'/>
|
||||
</div>
|
||||
<jsp:include page="entityAdmin.jsp"/>
|
||||
</div>
|
||||
<%@ taglib uri="http://java.sun.com/jstl/core" prefix="c" %><%/* this odd thing points to something in web.xml */ %>
|
||||
<%@ page errorPage="/error.jsp"%>
|
||||
<% /***********************************************
|
||||
Display a single search result group
|
||||
|
||||
request.attributes:
|
||||
a List with objects with the named "entities"
|
||||
a ClassGroup object named "classgroup"
|
||||
|
||||
request.parameters:
|
||||
None yet.
|
||||
|
||||
Consider sticking < % = MiscWebUtils.getReqInfo(request) % > in the html output
|
||||
for debugging info.
|
||||
**********************************************/
|
||||
if (request.getAttribute("entities") == null){
|
||||
String e="searchGroup.jsp expects that request attribute 'entities' be set to the Entity object to display.";
|
||||
throw new JspException(e);
|
||||
}
|
||||
if (request.getAttribute("classgroup") == null){
|
||||
String e="searchGroup.jsp expects that request attribute 'classgroup' be set to the Entity object to display.";
|
||||
throw new JspException(e);
|
||||
}
|
||||
%>
|
||||
<c:set var='entities' value='${requestScope.entities}'/><%/* just moving this into page scope for easy use */ %>
|
||||
<c:set var='classgroup' value='${requestScope.classgroup}'/>
|
||||
|
||||
<c:set var='portal' value='${requestScope.portal}'/>
|
||||
<c:set var='portalBean' value='${requestScope.portalBean}'/>
|
||||
|
||||
<div class='contents entity entity${entity.id}'>
|
||||
<h1><c:out value="${entity.name}"/></h1>
|
||||
<c:out value="${entity.moniker}" default="moniker?"/>
|
||||
<c:if test="${!empty entity.anchor}">
|
||||
<a href='<c:url value="${entity.url}"/>'>${entity.anchor}</a>
|
||||
</c:if>
|
||||
<c:forEach items="${entity.linksList}" var='link'>
|
||||
| <a href='<c:url value="${link.url}"/>'${link.anchor}</a>
|
||||
</c:forEach>
|
||||
<c:if test="${!empty entity.thumbUrl}">
|
||||
<div class="thumbnail">
|
||||
<c:if test="${!empty entity.imageUrl}"><a target="_new" href="<c:url value='${entity.imageUrl}'/>"></c:if>
|
||||
<img src="<c:url value='${entity.thumbUrl}'/>" title="click to view larger image in new window" width="150">
|
||||
<c:if test="${!empty entity.imageUrl}"></a></c:if>
|
||||
</div>
|
||||
</c:if>
|
||||
<c:import url="${entityPropsListJsp}" /><%/* here we import the properties for the entity */ %>
|
||||
<div class='description'>
|
||||
<c:out value="${entity.description}" escapeXml ='false'/>
|
||||
</div>
|
||||
<jsp:include page="entityAdmin.jsp"/>
|
||||
</div>
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue