Skip to content

Commit

Permalink
Merge pull request IQSS#4086 from IQSS/4030-nav-dataverse-links
Browse files Browse the repository at this point in the history
4030 nav dataverse links
  • Loading branch information
kcondon authored Aug 23, 2017
2 parents 79dfdc3 + 98bf8fb commit 0cde5dd
Show file tree
Hide file tree
Showing 6 changed files with 27 additions and 25 deletions.
10 changes: 6 additions & 4 deletions src/main/webapp/dataverse.xhtml
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
xmlns:h="http://java.sun.com/jsf/html"
xmlns:f="http://java.sun.com/jsf/core"
xmlns:ui="http://java.sun.com/jsf/facelets"
xmlns:c="http://java.sun.com/jsp/jstl/core"
xmlns:p="http://primefaces.org/ui"
xmlns:o="http://omnifaces.org/ui"
xmlns:jsf="http://xmlns.jcp.org/jsf">
Expand Down Expand Up @@ -529,22 +530,23 @@
<ui:repeat value="#{DataversePage.carouselFeaturedDataverses}" var="dv" varStatus="status">
<div class="item">
<div style="vertical-align:middle;">
<c:set var="dvFeatUrl" value="/dataverse.xhtml?alias=#{dv.alias}"/>
<ui:fragment rendered="#{empty dv.dataverseTheme.logo}">
<a href="/dataverse/#{widgetWrapper.wrapURL(dv.alias)}" title="#{dv.name}">
<a href="#{widgetWrapper.wrapURL(dvFeatUrl)}" title="#{dv.name}">
<i class="icon-dataverse"></i>
</a>
</ui:fragment>
<ui:fragment rendered="#{!empty dv.dataverseTheme.logo and dv.dataverseTheme.logoFormat == 'SQUARE'}">
<a href="/dataverse/#{widgetWrapper.wrapURL(dv.alias)}" title="#{dv.name}">
<a href="#{widgetWrapper.wrapURL(dvFeatUrl)}" title="#{dv.name}">
<img src="/logos/#{dv.logoOwnerId}/#{dv.dataverseTheme.logo}" alt="#{dv.name}"/>
</a>
</ui:fragment>
<ui:fragment rendered="#{!empty dv.dataverseTheme.logo and dv.dataverseTheme.logoFormat == 'RECTANGLE'}">
<a href="/dataverse/#{widgetWrapper.wrapURL(dv.alias)}" title="#{dv.name}">
<a href="#{widgetWrapper.wrapURL(dvFeatUrl)}" title="#{dv.name}">
<img src="/logos/#{dv.logoOwnerId}/#{dv.dataverseTheme.logo}" alt="#{dv.name}"/>
</a>
</ui:fragment>
<a href="/dataverse/#{widgetWrapper.wrapURL(dv.alias)}" title="#{dv.name}">
<a href="#{widgetWrapper.wrapURL(dvFeatUrl)}" title="#{dv.name}">
<h:outputText value="#{dv.name}"/>
</a>
</div>
Expand Down
14 changes: 7 additions & 7 deletions src/main/webapp/dataverse_header.xhtml
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@
<label class="sr-only" for="navbarsearch">#{bundle.search}</label>
<input id="navbarsearch" type="text" class="search-input ui-inputfield ui-inputtext ui-widget ui-state-default ui-corner-all" size="28" value="" placeholder="#{bundle['header.search.title']}"/>
</div>
<button type="submit" class="btn btn-default" onclick="window.location = '/dataverse/#{dataverseServiceBean.findRootDataverse().alias}?q=' + document.getElementById('navbarsearch').value;
<button type="submit" class="btn btn-default" onclick="window.location = '/dataverse.xhtml?alias=#{dataverseServiceBean.findRootDataverse().alias}&#38;q=' + document.getElementById('navbarsearch').value;
return false;">
<span class="glyphicon glyphicon-search"/> #{bundle.find}
</button>
Expand Down Expand Up @@ -158,7 +158,7 @@
style="background:##{!empty dataverse.dataverseTheme.backgroundColor ? dataverse.dataverseTheme.backgroundColor : 'F5F5F5'};"
jsf:rendered="#{showDataverseHeader and !widgetWrapper.widgetView}">
<o:importFunctions type="org.apache.commons.lang.StringEscapeUtils"/>
<div class="dataverseHeaderLogo" style="text-align:#{!empty dataverse.dataverseTheme.logoAlignment ? dataverse.dataverseTheme.logoAlignment : 'center'};; background:##{!empty dataverse.dataverseTheme.logoBackgroundColor ? dataverse.dataverseTheme.logoBackgroundColor : 'F5F5F5'};"
<div class="dataverseHeaderLogo" style="text-align:#{!empty dataverse.dataverseTheme.logoAlignment ? dataverse.dataverseTheme.logoAlignment : 'center'};background:##{!empty dataverse.dataverseTheme.logoBackgroundColor ? dataverse.dataverseTheme.logoBackgroundColor : 'F5F5F5'};"
jsf:rendered="#{!empty dataverse.dataverseTheme.logo and dataverse.dataverseTheme.logoFormat == 'RECTANGLE'}">
<img src="/logos/#{dataverse.logoOwnerId}/#{dataverse.dataverseTheme.logo}" alt="#{dataverse.name}"/>
</div>
Expand All @@ -167,7 +167,7 @@
<img src="/logos/#{dataverse.logoOwnerId}/#{dataverse.dataverseTheme.logo}" alt="#{dataverse.name}"/>
</div>
<div class="dataverseHeaderCell dataverseHeaderName" jsf:rendered="#{!empty dataverse.name}">
<a href="/dataverse/#{dataverse.alias}" class="dataverseHeaderDataverseName" style="color:##{!empty dataverse.dataverseTheme.linkColor ? dataverse.dataverseTheme.linkColor : '428bca'};">#{dataverse.name}</a>
<a href="/dataverse.xhtml?alias=#{dataverse.alias}" class="dataverseHeaderDataverseName" style="color:##{!empty dataverse.dataverseTheme.linkColor ? dataverse.dataverseTheme.linkColor : '428bca'};">#{dataverse.name}</a>
<h:outputText style="color:##{!empty dataverse.dataverseTheme.textColor ? dataverse.dataverseTheme.textColor : '888888'};" value=" (#{dataverse.affiliation})" rendered="#{!empty dataverse.affiliation}"/>
<h:outputText value="#{bundle.unpublished}" styleClass="label label-warning label-unpublished" rendered="#{!dataverse.released}"/>
</div>
Expand Down Expand Up @@ -199,7 +199,7 @@
</a>
</ui:fragment>
<ui:fragment rendered="#{breadcrumb.dvObject.instanceofDataverse}">
<c:set var="dvUrl" value="/dataverse/#{breadcrumb.dvObject.alias}"/>
<c:set var="dvUrl" value="/dataverse.xhtml?alias=#{breadcrumb.dvObject.alias}"/>
<a id="breadcrumbLnk#{status.index}" href="#{widgetWrapper.isWidgetTarget(breadcrumb.dvObject) ? widgetWrapper.wrapURL(dvUrl) : dvUrl}" target="#{!widgetWrapper.widgetView or widgetWrapper.isWidgetTarget(breadcrumb.dvObject) ? '' : '_blank'}">
<h:outputText value="#{breadcrumb.breadcrumbText}"/>
</a>
Expand Down Expand Up @@ -227,13 +227,13 @@
<div class="dropdown #{dataverseHeaderFragment.hasVisibleChildren(dv) ? 'dropdown-toggle keep-on' : ''}" data-delay="#{dataverseHeaderFragment.hasVisibleChildren(dv) ? '800' : ''}" data-hover="#{dataverseHeaderFragment.hasVisibleChildren(dv) ? 'dropdown' : ''}" data-target="#{dataverseHeaderFragment.hasVisibleChildren(dv) ? '#' : ''}" data-close-others="#{dataverseHeaderFragment.hasVisibleChildren(dv) ? 'true' : ''}">
<h:outputText value="#{dv.name}" styleClass="#{dataverse.id == dv.id ? 'breadcrumbActive' : ''}" rendered="#{dataverse.id == dv.id and dataset == null}"/>
<ui:fragment rendered="#{dataverse.id != dv.id or dataset != null}" >
<a id="breadcrumbLnk#{status.index}" href="/dataverse/#{dv.alias}">
<a id="breadcrumbLnk#{status.index}" href="/dataverse.xhtml?alias=#{dv.alias}">
<h:outputText value="#{dv.name}"/>
</a>
</ui:fragment>

<ui:fragment rendered="#{dataverseHeaderFragment.hasVisibleChildren(dv)}">
<a id="taverse" styleClass="#{dataverse.id == dv.id ? 'breadcrumbActive' : ''}" role="button">
<a id="dataverse" styleClass="#{dataverse.id == dv.id ? 'breadcrumbActive' : ''}" role="button">
<span class="glyphicon glyphicon-chevron-down"></span>
</a>
</ui:fragment>
Expand All @@ -242,7 +242,7 @@
<p:tree value="#{dataverseHeaderFragment.getDataverseTree(dv)}" var="node" cache="true" id="tree">
<p:treeNode>
<h:outputText value="#{node.name}" styleClass="breadcrumbActive" rendered="#{dataverse.id == node.id and dataset == null}"/>
<h:outputLink value="/dataverse/#{node.alias}" rendered="#{dataverse.id != node.id or dataset != null}">
<h:outputLink value="/dataverse.xhtml?alias=#{node.alias}" rendered="#{dataverse.id != node.id or dataset != null}">
<h:outputText value="#{node.name}"/>
</h:outputLink>
</p:treeNode>
Expand Down
16 changes: 8 additions & 8 deletions src/main/webapp/dataverseuser.xhtml
Original file line number Diff line number Diff line change
Expand Up @@ -100,10 +100,10 @@
<i class="icon-dataverse text-icon-inline text-muted"></i>
<h:outputFormat value="#{bundle['notification.createDataverse']}" escape="false">
<o:param>
<a href="/dataverse/#{item.theObject.getAlias()}" title="#{item.theObject.getDisplayName()}">#{item.theObject.getDisplayName()}</a>
<a href="/dataverse.xhtml?alias=#{item.theObject.getAlias()}" title="#{item.theObject.getDisplayName()}">#{item.theObject.getDisplayName()}</a>
</o:param>
<o:param>
<a href="/dataverse/#{item.theObject.getOwner().getAlias()}" title="#{item.theObject.getOwner().getDisplayName()}">#{item.theObject.getOwner().getDisplayName()}</a>
<a href="/dataverse.xhtml?alias=#{item.theObject.getOwner().getAlias()}" title="#{item.theObject.getOwner().getDisplayName()}">#{item.theObject.getOwner().getDisplayName()}</a>
</o:param>
<o:param>
<a href="#{systemConfig.guidesBaseUrl}/#{systemConfig.guidesVersion}/user/dataverse-management.html" title="#{bundle['notification.dataverse.management.title']}" target="_blank">#{bundle['header.guides.user']}</a>
Expand All @@ -117,7 +117,7 @@
<a href="/dataset.xhtml?persistentId=#{item.theObject.getDataset().getGlobalId()}" title="#{item.theObject.getDataset().getDisplayName()}">#{item.theObject.getDataset().getDisplayName()}</a>
</o:param>
<o:param>
<a href="/dataverse/#{item.theObject.getDataset().getOwner().getAlias()}" title="#{item.theObject.getDataset().getOwner().getDisplayName()}">#{item.theObject.getDataset().getOwner().getDisplayName()}</a>
<a href="/dataverse.xhtml?alias=#{item.theObject.getDataset().getOwner().getAlias()}" title="#{item.theObject.getDataset().getOwner().getDisplayName()}">#{item.theObject.getDataset().getOwner().getDisplayName()}</a>
</o:param>
<o:param>
<a href="#{systemConfig.guidesBaseUrl}/#{systemConfig.guidesVersion}/user/dataset-management.html" title="#{bundle['notification.dataset.management.title']}" target="_blank">#{bundle['header.guides.user']}</a>
Expand All @@ -131,7 +131,7 @@
<a href="/dataset.xhtml?persistentId=#{item.theObject.getDataset().getGlobalId()}&amp;version=DRAFT&amp;faces-redirect=true" title="#{item.theObject.getDataset().getDisplayName()}">#{item.theObject.getDataset().getDisplayName()}</a>
</o:param>
<o:param>
<a href="/dataverse/#{item.theObject.getDataset().getOwner().getAlias()}" title="#{item.theObject.getDataset().getOwner().getDisplayName()}">#{item.theObject.getDataset().getOwner().getDisplayName()}</a>
<a href="/dataverse.xhtml?alias=#{item.theObject.getDataset().getOwner().getAlias()}" title="#{item.theObject.getDataset().getOwner().getDisplayName()}">#{item.theObject.getDataset().getOwner().getDisplayName()}</a>
</o:param>
<o:param>
#{DataverseUserPage.getReasonForReturn(item.theObject)}
Expand All @@ -145,7 +145,7 @@
<a href="/dataset.xhtml?persistentId=#{item.theObject.getDataset().getGlobalId()}&amp;version=DRAFT&amp;faces-redirect=true" title="#{item.theObject.getDataset().getDisplayName()}">#{item.theObject.getDataset().getDisplayName()}</a>
</o:param>
<o:param>
<a href="/dataverse/#{item.theObject.getDataset().getOwner().getAlias()}" title="#{item.theObject.getDataset().getOwner().getDisplayName()}">#{item.theObject.getDataset().getOwner().getDisplayName()}</a>
<a href="/dataverse.xhtml?alias=#{item.theObject.getDataset().getOwner().getAlias()}" title="#{item.theObject.getDataset().getOwner().getDisplayName()}">#{item.theObject.getDataset().getOwner().getDisplayName()}</a>
</o:param>
<!-- Reason for Return - This needs some work in the DataverseUserPage method to get it to work -->
<ui:remove>
Expand All @@ -162,7 +162,7 @@
<a href="/dataset.xhtml?persistentId=#{item.theObject.getDataset().getGlobalId()}&amp;version=DRAFT&amp;faces-redirect=true" title="#{item.theObject.getDataset().getDisplayName()}">#{item.theObject.getDataset().getDisplayName()}</a>
</o:param>
<o:param>
<a href="/dataverse/#{item.theObject.getDataset().getOwner().getAlias()}" title="#{item.theObject.getDataset().getOwner().getDisplayName()}">#{item.theObject.getDataset().getOwner().getDisplayName()}</a>
<a href="/dataverse.xhtml?alias=#{item.theObject.getDataset().getOwner().getAlias()}" title="#{item.theObject.getDataset().getOwner().getDisplayName()}">#{item.theObject.getDataset().getOwner().getDisplayName()}</a>
</o:param>
</h:outputFormat>
</ui:fragment>
Expand Down Expand Up @@ -213,7 +213,7 @@
<h:outputFormat value="#{bundle['notification.access.granted.dataverse']}" escape="false">
<o:param value="#{item.roleString}"/>
<o:param>
<a href="/dataverse/#{item.theObject.getAlias()}" title="#{item.theObject.getDisplayName()}">#{item.theObject.getDisplayName()}</a>
<a href="/dataverse.xhtml?alias=#{item.theObject.getAlias()}" title="#{item.theObject.getDisplayName()}">#{item.theObject.getDisplayName()}</a>
</o:param>
</h:outputFormat>
<ui:fragment rendered="#{item.roleString == 'File Downloader'}">
Expand Down Expand Up @@ -254,7 +254,7 @@
<i class="icon-dataset text-icon-inline text-muted"></i>
<h:outputFormat value="#{bundle['notification.access.revoked.dataverse']}" escape="false">
<o:param>
<a href="/dataverse/#{item.theObject.getAlias()}" title="#{item.theObject.getDisplayName()}">#{item.theObject.getDisplayName()}</a>
<a href="/dataverse.xhtml?alias=#{item.theObject.getAlias()}" title="#{item.theObject.getDisplayName()}">#{item.theObject.getDisplayName()}</a>
</o:param>
</h:outputFormat>
</ui:fragment>
Expand Down
2 changes: 1 addition & 1 deletion src/main/webapp/harvestclients.xhtml
Original file line number Diff line number Diff line change
Expand Up @@ -101,7 +101,7 @@
<div class="text-muted small"><h:outputText value="#{harvestClient.harvestingUrl}"/></div>
</p:column>
<p:column width="17%" headerText="Dataverse">
<h:outputLink value="/dataverse/#{harvestClient.dataverse.alias}" title="#{harvestClient.dataverse.displayName}">
<h:outputLink value="/dataverse.xhtml?alias=#{harvestClient.dataverse.alias}" title="#{harvestClient.dataverse.displayName}">
<h:outputText value="#{harvestClient.dataverse.displayName}" />
</h:outputLink>
</p:column>
Expand Down
2 changes: 1 addition & 1 deletion src/main/webapp/resources/css/structure.css
Original file line number Diff line number Diff line change
Expand Up @@ -344,9 +344,9 @@ div.ui-state-focus span.ui-chkbox-icon {outline: -webkit-focus-ring-color auto 5
.button-block {margin-top:1em;}
.form-group > .button-block,
.panel-body > .button-block,
th.col-file-action.text-right {text-align: right;}
td.col-file-action > .button-block, .col-manage-action > .button-block,
div.ui-datatable-header > .button-block, .button-block.tab-header, #topDatasetBlock > #actionButtonBlock > .button-block {margin-top:0;}
th.col-file-action.text-right {text-align: right;}
form.btn-form {display:inline-block;}
.button-block button, .button-block a.btn, .button-block input.btn, .button-block div.btn-group, .button-block span.btn.ui-state-disabled, .button-block .button-container {margin-right:1em;}

Expand Down
Loading

0 comments on commit 0cde5dd

Please sign in to comment.