2012-06-20 18:28:45 +02:00
|
|
|
<%@page pageEncoding="UTF-8" %>
|
2012-06-30 07:26:21 +02:00
|
|
|
|
|
|
|
<%@ page import="com.wisemapping.model.User" %>
|
|
|
|
<%@ page import="com.wisemapping.security.Utils" %>
|
2009-06-07 20:59:43 +02:00
|
|
|
<%@ taglib prefix="c" uri="http://java.sun.com/jstl/core_rt" %>
|
|
|
|
<%@ taglib prefix="spring" uri="http://www.springframework.org/tags" %>
|
|
|
|
<%@ taglib prefix="form" uri="http://www.springframework.org/tags/form" %>
|
|
|
|
|
2012-06-30 07:26:21 +02:00
|
|
|
<%
|
|
|
|
User user = Utils.getUser(false);
|
|
|
|
if (user != null) {
|
|
|
|
request.setAttribute("principal", user);
|
|
|
|
}
|
|
|
|
%>
|
|
|
|
|
2012-06-20 18:28:45 +02:00
|
|
|
<div id="settings-dialog-modal" class="modal fade">
|
2014-02-09 06:19:59 +01:00
|
|
|
<div class="modal-dialog">
|
|
|
|
<div class="modal-content">
|
|
|
|
<div class="modal-header">
|
|
|
|
<button class="close" data-dismiss="modal">x</button>
|
|
|
|
<h3><spring:message code="ACCOUNT"/></h3>
|
|
|
|
</div>
|
|
|
|
<div class="modal-body">
|
2012-06-20 18:28:45 +02:00
|
|
|
|
2014-02-09 06:19:59 +01:00
|
|
|
</div>
|
|
|
|
<div class="modal-footer">
|
|
|
|
<button class="btn btn-cancel"><spring:message code="CLOSE"/></button>
|
|
|
|
</div>
|
2012-06-20 18:28:45 +02:00
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
</div>
|
2009-06-07 20:59:43 +02:00
|
|
|
<div id="header">
|
|
|
|
<div id="headerToolbar">
|
|
|
|
<c:choose>
|
|
|
|
<c:when test="${principal != null}">
|
2014-03-15 03:59:16 +01:00
|
|
|
<div id="headerActions">
|
2012-05-19 07:18:22 +02:00
|
|
|
<spring:message code="WELCOME"/>, ${principal.firstname}
|
2014-03-15 03:59:16 +01:00
|
|
|
| <span><a href="c/maps/"><spring:message
|
|
|
|
code="MY_WISEMAPS"/></a></span>
|
|
|
|
| <span><a id="userSettingsBtn" href="#"
|
|
|
|
title="<spring:message code="ACCOUNT_DETAIL"/>"><spring:message
|
|
|
|
code="ACCOUNT"/></a></span>
|
|
|
|
| <span><a href="c/logout"
|
|
|
|
title="<spring:message code="LOGOUT"/>"><spring:message code="LOGOUT"/></a></span>
|
2009-06-07 20:59:43 +02:00
|
|
|
</div>
|
|
|
|
</c:when>
|
2012-09-13 04:29:57 +02:00
|
|
|
<c:when test="${!param.removeSignin && !requestScope.removeSignin}">
|
2012-05-19 07:18:22 +02:00
|
|
|
<div id="headerActions">
|
2009-06-07 20:59:43 +02:00
|
|
|
<spring:message code="ALREADY_A_MEMBER"/>
|
2012-07-02 03:42:18 +02:00
|
|
|
<span><a href="c/login" title="<spring:message code="SIGN_IN"/>">
|
2009-06-07 20:59:43 +02:00
|
|
|
<spring:message code="SIGN_IN"/>
|
2012-05-19 07:18:22 +02:00
|
|
|
</a></span>
|
2012-06-20 18:28:45 +02:00
|
|
|
</div>
|
2009-06-07 20:59:43 +02:00
|
|
|
</c:when>
|
|
|
|
</c:choose>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<c:if test="${param.onlyActionHeader!=true}">
|
|
|
|
<div id="headerContent">
|
2012-09-01 19:30:32 +02:00
|
|
|
<a href="${requestScope['site.homepage']}" title="Homepage">
|
2009-06-07 20:59:43 +02:00
|
|
|
<div id="headerLogo"> </div>
|
|
|
|
</a>
|
|
|
|
|
|
|
|
<div id="headerSlogan">
|
|
|
|
<spring:message code="SITE.SLOGAN"/>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
</c:if>
|
2012-04-06 22:05:42 +02:00
|
|
|
|
2012-06-20 18:28:45 +02:00
|
|
|
|
|
|
|
<script type="text/javascript">
|
2014-03-15 03:59:16 +01:00
|
|
|
var userSettingsLink = $('#userSettingsBtn');
|
|
|
|
if (userSettingsLink) {
|
|
|
|
userSettingsLink.click(
|
|
|
|
function (event) {
|
|
|
|
$('#settings-dialog-modal .modal-body').load("c/account/settings",
|
|
|
|
function () {
|
|
|
|
$('#settings-dialog-modal .btn-cancel').unbind('click').click(function () {
|
|
|
|
$('#settings-dialog-modal').modal("hide");
|
|
|
|
window.location.reload();
|
|
|
|
});
|
|
|
|
}
|
|
|
|
);
|
|
|
|
$('#settings-dialog-modal').modal();
|
|
|
|
event.preventDefault();
|
|
|
|
|
|
|
|
});
|
2012-09-27 00:42:24 +02:00
|
|
|
}
|
2012-06-20 18:28:45 +02:00
|
|
|
|
|
|
|
</script>
|
|
|
|
|