add login link

This commit is contained in:
matsutani 2016-06-01 18:47:12 +09:00
parent 7423438d52
commit add2048432
5 changed files with 28 additions and 2 deletions

View file

@ -121,6 +121,8 @@ public abstract class FessSearchAction extends FessBaseAction {
}
runtime.registerData("langItems", systemHelper.getLanguageItems(locale));
runtime.registerData("username", systemHelper.getUsername());
runtime.registerData("pageLoginLink", systemHelper.getPageLoginLink());
}
// ===================================================================================

View file

@ -288,4 +288,8 @@ public class SystemHelper implements Serializable {
protected String createSearchRole(final String type, final String name) {
return type + name;
}
public String getPageLoginLink() {
return ComponentUtil.getFessConfig().getPageLoginLink();
}
}

View file

@ -289,6 +289,9 @@ paging.page.range.size = 3
# The option 'fillLimit' of page range for paging
paging.page.range.fill.limit = true
# The option 'loginLink' of page link button for search page
page.login.link = true
# fetch page size
page.docboost.max.fetch.size=1000
page.keymatch.max.fetch.size=1000
@ -372,7 +375,7 @@ online.help.name.crawlinginfo=crawlinginfo
online.help.name.backup=backup
online.help.name.upgrade=upgrade
online.help.supported.langs=ja
online.help.supported.langs=
# ----------------------------------------------------------
# Suggest

View file

@ -1,5 +1,6 @@
<%@page pageEncoding="UTF-8" contentType="text/html; charset=UTF-8"%>
<la:form action="/search" method="get" styleId="searchForm" role="search">
<la:form action="/search" method="get" styleId="searchForm"
role="search">
${fe:facetForm()}${fe:geoForm()}
<nav class="navbar navbar-dark bg-inverse navbar-fixed-top">
<la:link styleClass="navbar-brand" href="/">
@ -25,6 +26,14 @@ ${fe:facetForm()}${fe:geoForm()}
</div>
</li>
</c:if>
<c:if test="${ pageLoginLink == 'true'}">
<li class="nav-item username"><la:link href="/login"
styleClass="nav-link" role="button" aria-haspopup="true"
aria-expanded="false">
<i class="fa fa-user"></i>
<la:message key="labels.login" />
</la:link></li>
</c:if>
</ul>
<div
class="search-box navbar-form col-lg-5 col-md-6 col-sm-6 col-xs-8 pull-right"

View file

@ -39,6 +39,14 @@
</div>
</li>
</c:if>
<c:if test="${ pageLoginLink == 'true'}">
<li class="nav-item username"><la:link href="/login"
styleClass="nav-link" role="button" aria-haspopup="true"
aria-expanded="false">
<i class="fa fa-user"></i>
<la:message key="labels.login" />
</la:link></li>
</c:if>
<li class="nav-item"><la:link href="/help"
styleClass="nav-link help-link">
<i class="fa fa-question-circle"></i>