diff --git a/wise-webapp/pom.xml b/wise-webapp/pom.xml index d3b0dd8a..648f452f 100644 --- a/wise-webapp/pom.xml +++ b/wise-webapp/pom.xml @@ -307,7 +307,7 @@ org.hsqldb.jdbc.JDBCDriver - jdbc:hsqldb:file:${basedir}/target/db/wisemapping + jdbc:hsqldb:file:${project.basedir}/target/db/wisemapping sa diff --git a/wise-webapp/src/main/java/com/wisemapping/model/User.java b/wise-webapp/src/main/java/com/wisemapping/model/User.java index c0b82b98..9c98da21 100644 --- a/wise-webapp/src/main/java/com/wisemapping/model/User.java +++ b/wise-webapp/src/main/java/com/wisemapping/model/User.java @@ -18,7 +18,7 @@ package com.wisemapping.model; -import org.jetbrains.annotations.NotNull; +import org.jetbrains.annotations.Nullable; import java.io.Serializable; import java.util.*; @@ -141,11 +141,12 @@ public class User this.username = username; } + @Nullable public String getLocale() { return locale; } - public void setLocale(@NotNull String locale) { + public void setLocale(@Nullable String locale) { this.locale = locale; } } diff --git a/wise-webapp/src/main/java/com/wisemapping/rest/AdminController.java b/wise-webapp/src/main/java/com/wisemapping/rest/AdminController.java index d0806806..6a24d920 100644 --- a/wise-webapp/src/main/java/com/wisemapping/rest/AdminController.java +++ b/wise-webapp/src/main/java/com/wisemapping/rest/AdminController.java @@ -122,7 +122,7 @@ public class AdminController extends BaseController { userService.changePassword(user); } - @RequestMapping(method = RequestMethod.DELETE) + @RequestMapping(method = RequestMethod.DELETE,value = "admin/users/{id}") @ResponseStatus(value = HttpStatus.NO_CONTENT) public void getUserByEmail(@PathVariable long id) throws IOException, WiseMappingException { final User user = userService.getUserBy(id); diff --git a/wise-webapp/src/main/java/com/wisemapping/rest/model/RestUser.java b/wise-webapp/src/main/java/com/wisemapping/rest/model/RestUser.java index 986fb60e..ff59a707 100644 --- a/wise-webapp/src/main/java/com/wisemapping/rest/model/RestUser.java +++ b/wise-webapp/src/main/java/com/wisemapping/rest/model/RestUser.java @@ -78,7 +78,7 @@ public class RestUser { return user.getId(); } - public void setId(int id) { + public void setId(long id) { user.setId(id); } diff --git a/wise-webapp/src/main/webapp/WEB-INF/app.properties b/wise-webapp/src/main/webapp/WEB-INF/app.properties index 00b81362..ebb670c8 100755 --- a/wise-webapp/src/main/webapp/WEB-INF/app.properties +++ b/wise-webapp/src/main/webapp/WEB-INF/app.properties @@ -1,93 +1,93 @@ -################################################################################## -# Database Configuration -################################################################################## - -# MySQL 5.X configuration properties -#database.url=jdbc:mysql://localhost/wisemapping -#database.driver=com.mysql.jdbc.Driver -#database.hibernate.dialect=org.hibernate.dialect.MySQL5Dialect -#database.username=wisemapping -#database.password=password - -# HSQL Configuration properties -database.url=jdbc:hsqldb:file:target/db/wisemapping -database.driver=org.hsqldb.jdbc.JDBCDriver -database.hibernate.dialect=org.hibernate.dialect.HSQLDialect -database.username=sa -database.password= - - -################################################################################## -# Mail configuration. Must be configured to enable user registration confirmation. -################################################################################## - -#------------------------ -# Plain SMTP Server Configuration -#------------------------ -mail.smtp.port=465 -mail.smtp.host=localhost -mail.username=root -mail.password= -mail.smtp.auth=false -mail.smtp.starttls.enable=false -mail.smtp.quitwait=false - -#------------------------ -# SSL SMTP Server Configuration -#------------------------ - -#------------------------ -# GMAIL SMTP Configuration -#------------------------ -#mail.smtp.port=587 -#mail.smtp.host=smtp.gmail.com -#mail.username= -#mail.password= -#mail.smtp.auth=true -#mail.smtp.starttls.enable=true -#mail.smtp.quitwait=false - -#------------------------ -# Emails configuration -#------------------------ - -# Required: "from" email account that will appear in the emails sent from the sender. -mail.serverSendEmail=root@localhost - -# Optional: Support account that the users could use to contact you. This address will appear in emails and in some places in the site. -mail.supportEmail=root@localhost - -# Optional: Unexpected error will be reported to this address. -mail.errorReporterEmail= - -################################################################################## -# Users Registration Configuration -################################################################################## - -# Enable/Disable user registration confirmation by e-mail. If it's enabled, mail must be configured. -registration.email.enabled = false - -# Enable captcha confirmation -google.recaptcha.enabled = true - -# ReCaptcha is the default captcha. Public and private keys are required. -# More Info: http://www.google.com/recaptcha . -google.recaptcha.privateKey = 6LeQ4tISAAAAAMfHMPRKyHupTfA-KE4QeTCnLXhK -google.recaptcha.publicKey = 6LeQ4tISAAAAALzCGKNgRv8UqsDx7Cb0vq4wbJBr - -################################################################################## -# Site configuration -################################################################################## - -# Site administration user. This user will have special permissions for operations such as removing users, set password -# etc. -admin.user = admin@wisemapping.org - -# Site URL. This url will be used during sharing emails and public views. -site.baseurl = http://localhost:8080 - -################################################################################## -# Google Analytics Settings -################################################################################## -google.analytics.enabled=false + +################################################################################## +# Database Configuration +################################################################################## + +# MySQL 5.X configuration properties +#database.url=jdbc:mysql://localhost/wisemapping +#database.driver=com.mysql.jdbc.Driver +#database.hibernate.dialect=org.hibernate.dialect.MySQL5Dialect +#database.username=wisemapping +#database.password=password + +# HSQL Configuration properties +database.url=jdbc:hsqldb:file:target/db/wisemapping +database.driver=org.hsqldb.jdbc.JDBCDriver +database.hibernate.dialect=org.hibernate.dialect.HSQLDialect +database.username=sa +database.password= + +################################################################################## +# Mail configuration. Must be configured to enable user registration confirmation. +################################################################################## + +#------------------------ +# Plain SMTP Server Configuration +#------------------------ +mail.smtp.port=465 +mail.smtp.host=localhost +mail.username=root +mail.password= +mail.smtp.auth=false +mail.smtp.starttls.enable=false +mail.smtp.quitwait=false + +#------------------------ +# SSL SMTP Server Configuration +#------------------------ + +#------------------------ +# GMAIL SMTP Configuration +#------------------------ +#mail.smtp.port=587 +#mail.smtp.host=smtp.gmail.com +#mail.username= +#mail.password= +#mail.smtp.auth=true +#mail.smtp.starttls.enable=true +#mail.smtp.quitwait=false + +#------------------------ +# Emails configuration +#------------------------ + +# Required: "from" email account that will appear in the emails sent from the sender. +mail.serverSendEmail=root@localhost + +# Optional: Support account that the users could use to contact you. This address will appear in emails and in some places in the site. +mail.supportEmail=root@localhost + +# Optional: Unexpected errors will be reported to this address. +mail.errorReporterEmail= + +################################################################################## +# Users Registration Configuration +################################################################################## + +# Enable/Disable user registration confirmation by e-mail. If it's enabled, mail must be configured. +registration.email.enabled = false + +# Enable captcha confirmation +google.recaptcha.enabled = true + +# ReCaptcha is the default captcha. Public and private keys are required. +# More Info: http://www.google.com/recaptcha . +google.recaptcha.privateKey = 6LeQ4tISAAAAAMfHMPRKyHupTfA-KE4QeTCnLXhK +google.recaptcha.publicKey = 6LeQ4tISAAAAALzCGKNgRv8UqsDx7Cb0vq4wbJBr + +################################################################################## +# Site configuration +################################################################################## + +# Site administration user. This user will have special permissions for operations such as removing users, set password +# etc. +admin.user = admin@wisemapping.org + +# Site URL. This url will be used during sharing emails and public views. +site.baseurl = http://localhost:8080 + +################################################################################## +# Google Analytics Settings +################################################################################## +google.analytics.enabled=false google.analytics.account=UA-XXXX \ No newline at end of file