]> git.ipfire.org Git - ipfire.org.git/commitdiff
people: Remove subscription confirmation page
authorMichael Tremer <michael.tremer@ipfire.org>
Fri, 22 Nov 2019 10:57:32 +0000 (10:57 +0000)
committerMichael Tremer <michael.tremer@ipfire.org>
Fri, 22 Nov 2019 10:57:32 +0000 (10:57 +0000)
This is unnecessary because it is two clicks for the same thing

Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
Makefile.am
src/templates/people/index.html
src/templates/people/subscribe.html [deleted file]
src/web/people.py

index 2705ad26ba64d8ddcee5f034edd02ead6339a0d5..bed8f9d6cfc2b1699a2768372497b5f788658881 100644 (file)
@@ -276,7 +276,6 @@ templates_people_DATA = \
        src/templates/people/search.html \
        src/templates/people/sip.html \
        src/templates/people/stats.html \
-       src/templates/people/subscribe.html \
        src/templates/people/subscribed.html \
        src/templates/people/unsubscribe.html \
        src/templates/people/unsubscribed.html \
index 1fb58b56a516365daae434371a81f6d055146787..ad461e156f2dd8acf756bcb4f08d1ea0ac03831c 100644 (file)
                            </div>
 
                            <div class="col-12 col-lg-4">
-                               <a class="btn btn-success btn-block" href="/subscribe">
-                                   {{ _("Subscribe Now") }}
-                               </a>
+                                                       <form action="/subscribe" method="POST">
+                                                               {% raw xsrf_form_html() %}
+
+                                                               <button type="submit" class="btn btn-success btn-block">
+                                                                       {{ _("Subscribe Now") }}
+                                                               </button>
+                                                       </form>
                            </div>
                        </div>
                                </div>
diff --git a/src/templates/people/subscribe.html b/src/templates/people/subscribe.html
deleted file mode 100644 (file)
index 864930d..0000000
+++ /dev/null
@@ -1,27 +0,0 @@
-{% extends "../base.html" %}
-
-{% block title %}{{ _("Subscribe") }}{% end block %}
-
-{% block content %}
-       <div class="row justify-content-center my-5">
-               <div class="col col-md-8 col-lg-6">
-                       <div class="card border-success">
-                               <div class="card-body">
-                                       <h5>{{ _("Subscribe to Receive Import Updates from the IPFire Project") }}</h5>
-
-                                       <p>
-                                               {{ _("Subscribe to receive updates after releases and other important news from the IPFire Project.") }}
-                                       </p>
-
-                                       <form action="" method="POST">
-                                               {% raw xsrf_form_html() %}
-
-                                               <button type="submit" class="btn btn-success btn-block">
-                                                       {{ _("Subscribe") }}
-                                               </button>
-                                       </form>
-                               </div>
-                       </div>
-               </div>
-       </div>
-{% end block %}
index 13d0617fbc6b7daaff212623a590d185bdb19806..8f6a858bcb5119b30bd7a81e495573d80be7f4e5 100644 (file)
@@ -232,13 +232,6 @@ class StatsHandler(auth.CacheMixin, base.BaseHandler):
 
 
 class SubscribeHandler(auth.CacheMixin, base.BaseHandler):
-       @tornado.web.authenticated
-       def get(self):
-               if self.current_user.consents_to_promotional_emails:
-                       return self.render("people/subscribed.html")
-
-               self.render("people/subscribe.html")
-
        @tornado.web.authenticated
        def post(self):
                # Give consent