aboutsummaryrefslogtreecommitdiff
path: root/juick-www
diff options
context:
space:
mode:
Diffstat (limited to 'juick-www')
-rw-r--r--juick-www/src/main/java/com/juick/www/controllers/Settings.java8
-rw-r--r--juick-www/src/main/webapp/WEB-INF/views/settings_main.html9
2 files changed, 4 insertions, 13 deletions
diff --git a/juick-www/src/main/java/com/juick/www/controllers/Settings.java b/juick-www/src/main/java/com/juick/www/controllers/Settings.java
index 64775aec..a2459654 100644
--- a/juick-www/src/main/java/com/juick/www/controllers/Settings.java
+++ b/juick-www/src/main/java/com/juick/www/controllers/Settings.java
@@ -214,11 +214,9 @@ public class Settings {
}
break;
case "email-subscr":
- if (emailService.setSubscriptionHour(visitor.getUid(), request.getParameter("account"),
- request.getParameter("time"))) {
- result = String.format("<p>Saved! Will send to <strong>%s</strong> at <strong>%s:00 GMT</strong>." +
- "</p><p><a href=\"/settings\">Back</a></p>", request.getParameter("account"),
- request.getParameter("time"));
+ if (emailService.setNotificationsEmail(visitor.getUid(), request.getParameter("account"))) {
+ result = String.format("<p>Saved! Will send notifications to <strong>%s</strong>." +
+ "</p><p><a href=\"/settings\">Back</a></p>", request.getParameter("account"));
} else {
result = "<p>Disabled.</p><p><a href=\"/settings\">Back</a></p>";
}
diff --git a/juick-www/src/main/webapp/WEB-INF/views/settings_main.html b/juick-www/src/main/webapp/WEB-INF/views/settings_main.html
index 26539a69..dddf63bb 100644
--- a/juick-www/src/main/webapp/WEB-INF/views/settings_main.html
+++ b/juick-www/src/main/webapp/WEB-INF/views/settings_main.html
@@ -84,7 +84,7 @@
{% if emails is not empty %}
<!--email_off-->
<form action="/settings" method="POST" enctype="multipart/form-data">
- <p>You can receive all your subscriptions by email:<br/>
+ <p>You can receive notifications to email:<br/>
Sent to <select name="account">
<option value="">Disabled</option>
{% for email in emails %}
@@ -92,13 +92,6 @@
{{ email }}
</option>
{% endfor %}
- </select> every day at <select name="time">
- {% for hour in hours %}
- <option value="{{ hour }}" {% if eopts.subscriptionHour == hour %} selected="selected" {%
- endif %}>
- {{ hour }}:00 GMT
- </option>
- {% endfor %}
</select>
<input type="hidden" name="page" value="email-subscr"/>
<input type="submit" value="OK"/></p>