Add configurable support for admin profile.
This commit is contained in:
@@ -16,8 +16,6 @@ database.hibernate.dialect=org.hibernate.dialect.HSQLDialect
|
||||
database.username=sa
|
||||
database.password=
|
||||
|
||||
# Enable/Disable user confirmation by e-mail. If it's enabled, mail must be configured.
|
||||
user.confirm.registration=false
|
||||
|
||||
##################################################################################
|
||||
# Mail configuration. Must be configured to enable user registration confirmation.
|
||||
@@ -34,3 +32,16 @@ mail.user=
|
||||
mail.password=
|
||||
mail.registrationEmail=root@localhost
|
||||
mail.siteEmail=root@localhost
|
||||
|
||||
|
||||
##################################################################################
|
||||
# Site configuration
|
||||
##################################################################################
|
||||
|
||||
# Enable/Disable user registration confirmation by e-mail. If it's enabled, mail must be configured.
|
||||
user.confirm.registration=false
|
||||
|
||||
# Site administration user. This user will have special permissions for operations such as removing users, set password
|
||||
# etc.
|
||||
admin.user = admin@wisemapping.org
|
||||
|
||||
|
35
wise-webapp/src/main/webapp/WEB-INF/jsp-rest/userView.jsp
Normal file
35
wise-webapp/src/main/webapp/WEB-INF/jsp-rest/userView.jsp
Normal file
@@ -0,0 +1,35 @@
|
||||
<%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8" %>
|
||||
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
|
||||
<html>
|
||||
<head>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
|
||||
<title>Mindmap Detail</title>
|
||||
</head>
|
||||
<body>
|
||||
<h1>Details for User with id '${user.id}'</h1>
|
||||
<table border="1" cellspacing="0">
|
||||
<tbody>
|
||||
<tr>
|
||||
<td>Email:</td>
|
||||
<td>${user.email}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>Fist Name:</td>
|
||||
<td>${user.firstname}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>Last Name:</td>
|
||||
<td>${user.lastname}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>Username:</td>
|
||||
<td>${user.username}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>Active:</td>
|
||||
<td>${user.active}</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
</body>
|
||||
</html>
|
@@ -8,6 +8,11 @@
|
||||
http://www.springframework.org/schema/security
|
||||
http://www.springframework.org/schema/security/spring-security-3.1.xsd">
|
||||
|
||||
<bean id="propertyConfigurer" class="org.springframework.beans.factory.config.PropertyPlaceholderConfigurer">
|
||||
<property name="location" value="/WEB-INF/app.properties"/>
|
||||
</bean>
|
||||
|
||||
|
||||
<bean id="encoder"
|
||||
class="com.wisemapping.security.CustomPasswordEncoder"/>
|
||||
|
||||
@@ -50,11 +55,13 @@
|
||||
</sec:authentication-manager>
|
||||
|
||||
<bean id="dbAuthenticationProvider" class="com.wisemapping.security.AuthenticationProvider">
|
||||
<property name="userManager" ref="userManager"/>
|
||||
<property name="userDetailsService" ref="userDetailsService"/>
|
||||
<property name="encoder" ref="encoder"/>
|
||||
</bean>
|
||||
|
||||
<bean id="userDetailsService" class="com.wisemapping.security.UserDetailService">
|
||||
<bean id="userDetailsService" class="com.wisemapping.security.UserDetailsService">
|
||||
<property name="userManager" ref="userManager"/>
|
||||
<property name="adminUser" value="${admin.user}"/>
|
||||
|
||||
</bean>
|
||||
</beans>
|
Reference in New Issue
Block a user