From: Jan Szejko Date: Fri, 28 Sep 2018 09:27:53 +0000 (+0200) Subject: add mailing list choice X-Git-Url: https://git.mdrn.pl/wolnelektury.git/commitdiff_plain/e81500796eb5163e07ac6b02109666747fb0c206?ds=inline add mailing list choice --- diff --git a/src/contact/mailing.py b/src/contact/mailing.py index bfd42093a..2034766cd 100644 --- a/src/contact/mailing.py +++ b/src/contact/mailing.py @@ -2,18 +2,10 @@ from hashlib import md5 -import requests from django.conf import settings from mailchimp3 import MailChimp from mailchimp3.mailchimpclient import MailChimpError -INTERESTS = {settings.MAILCHIMP_GROUP_ID: True} - - -def get_client(): - headers = requests.utils.default_headers() - headers['User-Agent'] = '%s (%s)' % settings.MANAGERS[0] - def subscriber_hash(email): return md5(email).hexdigest() @@ -32,7 +24,7 @@ def remove_from_groups(email, client): data={'interests': interests}) -def subscribe(email): +def subscribe(email, mailing_lists=None): client = MailChimp(mc_api=settings.MAILCHIMP_API_KEY, timeout=10.0) try: member = client.lists.members.get(settings.MAILCHIMP_LIST_ID, subscriber_hash(email)) @@ -41,12 +33,18 @@ def subscribe(email): else: if member['status'] != 'subscribed': remove_from_groups(email, client) + mailing_lists = mailing_lists or [settings.MAILCHIMP_DEFAULT_GROUP] + interests = { + settings.MAILCHIMP_GROUP_IDS[mailing_list]: True + for mailing_list in mailing_lists + if mailing_list in settings.MAILCHIMP_GROUP_IDS + } client.lists.members.create_or_update( settings.MAILCHIMP_LIST_ID, subscriber_hash(email), data={ 'email_address': email, 'status_if_new': 'subscribed', 'status': 'subscribed', - 'interests': INTERESTS, + 'interests': interests, } ) diff --git a/src/newsletter/forms.py b/src/newsletter/forms.py index eb7afa5a8..8cb19ee19 100644 --- a/src/newsletter/forms.py +++ b/src/newsletter/forms.py @@ -1,8 +1,9 @@ # -*- coding: utf-8 -*- from django.core.exceptions import ValidationError from django.core.validators import validate_email -from django.forms import Form, BooleanField +from django.forms import Form, BooleanField, MultipleChoiceField from django.forms.fields import EmailField +from django.forms.widgets import CheckboxSelectMultiple from django.template.loader import render_to_string from django.utils.safestring import mark_safe from django.utils.translation import ugettext_lazy as _, ugettext @@ -16,6 +17,8 @@ class NewsletterForm(Form): email_field = 'email' agree_newsletter = BooleanField( required=False, initial=False, label=_(u'I want to receive Wolne Lektury\'s newsletter.')) + mailing = False + mailing_field = 'agree_newsletter' data_processing_part1 = u'''\ Administratorem danych osobowych jest Fundacja Nowoczesna Polska (ul. Marszałkowska 84/92 lok. 125, 00-514 Warszawa). @@ -35,7 +38,7 @@ Więcej informacji w polityce prywatności.''' super(NewsletterForm, self).save(*args, **kwargs) except AttributeError: pass - if not self.cleaned_data.get('agree_newsletter'): + if not (self.mailing or self.cleaned_data.get(self.mailing_field)): return email = self.cleaned_data[self.email_field] try: @@ -47,15 +50,21 @@ Więcej informacji w polityce prywatności.''' # send_noreply_mail( # ugettext(u'Confirm your subscription to Wolne Lektury newsletter'), # render_to_string('newsletter/subscribe_email.html', {'subscription': subscription}), [email]) - mailing.subscribe(email) + mailing.subscribe(email, mailing_lists=self.cleaned_data.get('mailing_lists')) class SubscribeForm(NewsletterForm): + mailing = True + agree_newsletter = None + email = EmailField(label=_('email address')) + mailing_lists = MultipleChoiceField( + widget=CheckboxSelectMultiple, + choices=(('general', _(u'general newsletter')), ('contest', _(u'about the contest'))), + label=_(u'mailing list')) def __init__(self, *args, **kwargs): super(SubscribeForm, self).__init__(*args, **kwargs) - self.fields['agree_newsletter'].required = True class UnsubscribeForm(Form): diff --git a/src/newsletter/locale/de/LC_MESSAGES/django.mo b/src/newsletter/locale/de/LC_MESSAGES/django.mo index 06f3fb728..71cbdf3e9 100644 Binary files a/src/newsletter/locale/de/LC_MESSAGES/django.mo and b/src/newsletter/locale/de/LC_MESSAGES/django.mo differ diff --git a/src/newsletter/locale/de/LC_MESSAGES/django.po b/src/newsletter/locale/de/LC_MESSAGES/django.po index 482fe19d0..9b804bf0f 100644 --- a/src/newsletter/locale/de/LC_MESSAGES/django.po +++ b/src/newsletter/locale/de/LC_MESSAGES/django.po @@ -8,7 +8,7 @@ msgid "" msgstr "" "Project-Id-Version: PACKAGE VERSION\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2018-04-04 17:12+0200\n" +"POT-Creation-Date: 2018-09-28 11:23+0200\n" "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" "Last-Translator: FULL NAME \n" "Language-Team: LANGUAGE \n" @@ -18,19 +18,31 @@ msgstr "" "Content-Transfer-Encoding: 8bit\n" "Plural-Forms: nplurals=2; plural=(n != 1);\n" -#: forms.py:17 +#: forms.py:19 msgid "I want to receive Wolne Lektury's newsletter." msgstr "" -#: forms.py:46 forms.py:54 models.py:10 +#: forms.py:60 forms.py:71 models.py:10 msgid "email address" msgstr "" -#: forms.py:61 +#: forms.py:63 +msgid "general newsletter" +msgstr "" + +#: forms.py:63 +msgid "about the contest" +msgstr "" + +#: forms.py:64 +msgid "mailing list" +msgstr "" + +#: forms.py:78 msgid "Email address not found." msgstr "" -#: forms.py:72 +#: forms.py:89 msgid "Unsubscribe from Wolne Lektury's newsletter." msgstr "" @@ -54,7 +66,7 @@ msgstr "" msgid "Your subscription to Wolne Lektury newsletter is confirmed. Thank you!" msgstr "" -#: templates/newsletter/subscribe_form.html:15 +#: templates/newsletter/subscribe_form.html:16 msgid "Subscribe" msgstr "" diff --git a/src/newsletter/locale/en/LC_MESSAGES/django.mo b/src/newsletter/locale/en/LC_MESSAGES/django.mo index f364c6015..6c5906d1c 100644 Binary files a/src/newsletter/locale/en/LC_MESSAGES/django.mo and b/src/newsletter/locale/en/LC_MESSAGES/django.mo differ diff --git a/src/newsletter/locale/en/LC_MESSAGES/django.po b/src/newsletter/locale/en/LC_MESSAGES/django.po index d9a4b2deb..8d23cffa5 100644 --- a/src/newsletter/locale/en/LC_MESSAGES/django.po +++ b/src/newsletter/locale/en/LC_MESSAGES/django.po @@ -8,7 +8,7 @@ msgid "" msgstr "" "Project-Id-Version: PACKAGE VERSION\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2018-04-04 17:12+0200\n" +"POT-Creation-Date: 2018-09-28 11:23+0200\n" "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" "Last-Translator: FULL NAME \n" "Language-Team: LANGUAGE \n" @@ -17,19 +17,31 @@ msgstr "" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -#: forms.py:17 +#: forms.py:19 msgid "I want to receive Wolne Lektury's newsletter." msgstr "" -#: forms.py:46 forms.py:54 models.py:10 +#: forms.py:60 forms.py:71 models.py:10 msgid "email address" msgstr "" -#: forms.py:61 +#: forms.py:63 +msgid "general newsletter" +msgstr "" + +#: forms.py:63 +msgid "about the contest" +msgstr "" + +#: forms.py:64 +msgid "mailing list" +msgstr "" + +#: forms.py:78 msgid "Email address not found." msgstr "" -#: forms.py:72 +#: forms.py:89 msgid "Unsubscribe from Wolne Lektury's newsletter." msgstr "" @@ -53,7 +65,7 @@ msgstr "" msgid "Your subscription to Wolne Lektury newsletter is confirmed. Thank you!" msgstr "" -#: templates/newsletter/subscribe_form.html:15 +#: templates/newsletter/subscribe_form.html:16 msgid "Subscribe" msgstr "" diff --git a/src/newsletter/locale/es/LC_MESSAGES/django.mo b/src/newsletter/locale/es/LC_MESSAGES/django.mo index 06f3fb728..71cbdf3e9 100644 Binary files a/src/newsletter/locale/es/LC_MESSAGES/django.mo and b/src/newsletter/locale/es/LC_MESSAGES/django.mo differ diff --git a/src/newsletter/locale/es/LC_MESSAGES/django.po b/src/newsletter/locale/es/LC_MESSAGES/django.po index 482fe19d0..9b804bf0f 100644 --- a/src/newsletter/locale/es/LC_MESSAGES/django.po +++ b/src/newsletter/locale/es/LC_MESSAGES/django.po @@ -8,7 +8,7 @@ msgid "" msgstr "" "Project-Id-Version: PACKAGE VERSION\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2018-04-04 17:12+0200\n" +"POT-Creation-Date: 2018-09-28 11:23+0200\n" "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" "Last-Translator: FULL NAME \n" "Language-Team: LANGUAGE \n" @@ -18,19 +18,31 @@ msgstr "" "Content-Transfer-Encoding: 8bit\n" "Plural-Forms: nplurals=2; plural=(n != 1);\n" -#: forms.py:17 +#: forms.py:19 msgid "I want to receive Wolne Lektury's newsletter." msgstr "" -#: forms.py:46 forms.py:54 models.py:10 +#: forms.py:60 forms.py:71 models.py:10 msgid "email address" msgstr "" -#: forms.py:61 +#: forms.py:63 +msgid "general newsletter" +msgstr "" + +#: forms.py:63 +msgid "about the contest" +msgstr "" + +#: forms.py:64 +msgid "mailing list" +msgstr "" + +#: forms.py:78 msgid "Email address not found." msgstr "" -#: forms.py:72 +#: forms.py:89 msgid "Unsubscribe from Wolne Lektury's newsletter." msgstr "" @@ -54,7 +66,7 @@ msgstr "" msgid "Your subscription to Wolne Lektury newsletter is confirmed. Thank you!" msgstr "" -#: templates/newsletter/subscribe_form.html:15 +#: templates/newsletter/subscribe_form.html:16 msgid "Subscribe" msgstr "" diff --git a/src/newsletter/locale/fr/LC_MESSAGES/django.mo b/src/newsletter/locale/fr/LC_MESSAGES/django.mo index 1090d01b5..2c90dd0c8 100644 Binary files a/src/newsletter/locale/fr/LC_MESSAGES/django.mo and b/src/newsletter/locale/fr/LC_MESSAGES/django.mo differ diff --git a/src/newsletter/locale/fr/LC_MESSAGES/django.po b/src/newsletter/locale/fr/LC_MESSAGES/django.po index 271e7a997..26887f349 100644 --- a/src/newsletter/locale/fr/LC_MESSAGES/django.po +++ b/src/newsletter/locale/fr/LC_MESSAGES/django.po @@ -8,7 +8,7 @@ msgid "" msgstr "" "Project-Id-Version: PACKAGE VERSION\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2018-04-04 17:12+0200\n" +"POT-Creation-Date: 2018-09-28 11:23+0200\n" "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" "Last-Translator: FULL NAME \n" "Language-Team: LANGUAGE \n" @@ -18,19 +18,31 @@ msgstr "" "Content-Transfer-Encoding: 8bit\n" "Plural-Forms: nplurals=2; plural=(n > 1);\n" -#: forms.py:17 +#: forms.py:19 msgid "I want to receive Wolne Lektury's newsletter." msgstr "" -#: forms.py:46 forms.py:54 models.py:10 +#: forms.py:60 forms.py:71 models.py:10 msgid "email address" msgstr "" -#: forms.py:61 +#: forms.py:63 +msgid "general newsletter" +msgstr "" + +#: forms.py:63 +msgid "about the contest" +msgstr "" + +#: forms.py:64 +msgid "mailing list" +msgstr "" + +#: forms.py:78 msgid "Email address not found." msgstr "" -#: forms.py:72 +#: forms.py:89 msgid "Unsubscribe from Wolne Lektury's newsletter." msgstr "" @@ -54,7 +66,7 @@ msgstr "" msgid "Your subscription to Wolne Lektury newsletter is confirmed. Thank you!" msgstr "" -#: templates/newsletter/subscribe_form.html:15 +#: templates/newsletter/subscribe_form.html:16 msgid "Subscribe" msgstr "" diff --git a/src/newsletter/locale/it/LC_MESSAGES/django.mo b/src/newsletter/locale/it/LC_MESSAGES/django.mo index 06f3fb728..71cbdf3e9 100644 Binary files a/src/newsletter/locale/it/LC_MESSAGES/django.mo and b/src/newsletter/locale/it/LC_MESSAGES/django.mo differ diff --git a/src/newsletter/locale/it/LC_MESSAGES/django.po b/src/newsletter/locale/it/LC_MESSAGES/django.po index 482fe19d0..9b804bf0f 100644 --- a/src/newsletter/locale/it/LC_MESSAGES/django.po +++ b/src/newsletter/locale/it/LC_MESSAGES/django.po @@ -8,7 +8,7 @@ msgid "" msgstr "" "Project-Id-Version: PACKAGE VERSION\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2018-04-04 17:12+0200\n" +"POT-Creation-Date: 2018-09-28 11:23+0200\n" "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" "Last-Translator: FULL NAME \n" "Language-Team: LANGUAGE \n" @@ -18,19 +18,31 @@ msgstr "" "Content-Transfer-Encoding: 8bit\n" "Plural-Forms: nplurals=2; plural=(n != 1);\n" -#: forms.py:17 +#: forms.py:19 msgid "I want to receive Wolne Lektury's newsletter." msgstr "" -#: forms.py:46 forms.py:54 models.py:10 +#: forms.py:60 forms.py:71 models.py:10 msgid "email address" msgstr "" -#: forms.py:61 +#: forms.py:63 +msgid "general newsletter" +msgstr "" + +#: forms.py:63 +msgid "about the contest" +msgstr "" + +#: forms.py:64 +msgid "mailing list" +msgstr "" + +#: forms.py:78 msgid "Email address not found." msgstr "" -#: forms.py:72 +#: forms.py:89 msgid "Unsubscribe from Wolne Lektury's newsletter." msgstr "" @@ -54,7 +66,7 @@ msgstr "" msgid "Your subscription to Wolne Lektury newsletter is confirmed. Thank you!" msgstr "" -#: templates/newsletter/subscribe_form.html:15 +#: templates/newsletter/subscribe_form.html:16 msgid "Subscribe" msgstr "" diff --git a/src/newsletter/locale/lt/LC_MESSAGES/django.mo b/src/newsletter/locale/lt/LC_MESSAGES/django.mo index 914b4b583..50c618427 100644 Binary files a/src/newsletter/locale/lt/LC_MESSAGES/django.mo and b/src/newsletter/locale/lt/LC_MESSAGES/django.mo differ diff --git a/src/newsletter/locale/lt/LC_MESSAGES/django.po b/src/newsletter/locale/lt/LC_MESSAGES/django.po index 478defff8..b34be27f6 100644 --- a/src/newsletter/locale/lt/LC_MESSAGES/django.po +++ b/src/newsletter/locale/lt/LC_MESSAGES/django.po @@ -8,7 +8,7 @@ msgid "" msgstr "" "Project-Id-Version: PACKAGE VERSION\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2018-04-04 17:12+0200\n" +"POT-Creation-Date: 2018-09-28 11:23+0200\n" "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" "Last-Translator: FULL NAME \n" "Language-Team: LANGUAGE \n" @@ -19,19 +19,31 @@ msgstr "" "Plural-Forms: nplurals=3; plural=(n%10==1 && n%100!=11 ? 0 : n%10>=2 && (n" "%100<10 || n%100>=20) ? 1 : 2);\n" -#: forms.py:17 +#: forms.py:19 msgid "I want to receive Wolne Lektury's newsletter." msgstr "" -#: forms.py:46 forms.py:54 models.py:10 +#: forms.py:60 forms.py:71 models.py:10 msgid "email address" msgstr "" -#: forms.py:61 +#: forms.py:63 +msgid "general newsletter" +msgstr "" + +#: forms.py:63 +msgid "about the contest" +msgstr "" + +#: forms.py:64 +msgid "mailing list" +msgstr "" + +#: forms.py:78 msgid "Email address not found." msgstr "" -#: forms.py:72 +#: forms.py:89 msgid "Unsubscribe from Wolne Lektury's newsletter." msgstr "" @@ -55,7 +67,7 @@ msgstr "" msgid "Your subscription to Wolne Lektury newsletter is confirmed. Thank you!" msgstr "" -#: templates/newsletter/subscribe_form.html:15 +#: templates/newsletter/subscribe_form.html:16 msgid "Subscribe" msgstr "" diff --git a/src/newsletter/locale/pl/LC_MESSAGES/django.mo b/src/newsletter/locale/pl/LC_MESSAGES/django.mo index c5f0322bd..0abba0a19 100644 Binary files a/src/newsletter/locale/pl/LC_MESSAGES/django.mo and b/src/newsletter/locale/pl/LC_MESSAGES/django.mo differ diff --git a/src/newsletter/locale/pl/LC_MESSAGES/django.po b/src/newsletter/locale/pl/LC_MESSAGES/django.po index 95ea219b7..87bf45bd6 100644 --- a/src/newsletter/locale/pl/LC_MESSAGES/django.po +++ b/src/newsletter/locale/pl/LC_MESSAGES/django.po @@ -7,7 +7,7 @@ msgid "" msgstr "" "Project-Id-Version: PACKAGE VERSION\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2018-04-04 17:12+0200\n" +"POT-Creation-Date: 2018-09-28 11:23+0200\n" "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" "Last-Translator: Jan Szejko \n" "Language-Team: LANGUAGE \n" @@ -18,19 +18,31 @@ msgstr "" "Plural-Forms: nplurals=3; plural=(n==1 ? 0 : n%10>=2 && n%10<=4 && (n%100<10 " "|| n%100>=20) ? 1 : 2);\n" -#: forms.py:17 +#: forms.py:19 msgid "I want to receive Wolne Lektury's newsletter." msgstr "Chcę otrzymywać newsletter Wolnych Lektur" -#: forms.py:46 forms.py:54 models.py:10 +#: forms.py:60 forms.py:71 models.py:10 msgid "email address" msgstr "adres email" -#: forms.py:61 +#: forms.py:63 +msgid "general newsletter" +msgstr "ogólny newsletter" + +#: forms.py:63 +msgid "about the contest" +msgstr "informacje o konkursie" + +#: forms.py:64 +msgid "mailing list" +msgstr "lista mailowa" + +#: forms.py:78 msgid "Email address not found." msgstr "Nie znaleziono adresu email." -#: forms.py:72 +#: forms.py:89 msgid "Unsubscribe from Wolne Lektury's newsletter." msgstr "Wypisuję się z newslettera Wolnych Lektur" @@ -54,7 +66,7 @@ msgstr "Ekstrakt" msgid "Your subscription to Wolne Lektury newsletter is confirmed. Thank you!" msgstr "Potwierdzono subskrypcję newslettera Wolnych Lektur. Dziękujemy!" -#: templates/newsletter/subscribe_form.html:15 +#: templates/newsletter/subscribe_form.html:16 msgid "Subscribe" msgstr "Zapisz się" @@ -79,7 +91,6 @@ msgid "Subscribe To Newsletter" msgstr "Zapisz się na newsletter" #: views.py:28 -#| msgid "Subscribe" msgid "Subscribed" msgstr "Zapisano do newslettera" diff --git a/src/newsletter/locale/ru/LC_MESSAGES/django.mo b/src/newsletter/locale/ru/LC_MESSAGES/django.mo index a609786d6..d2d31a4fd 100644 Binary files a/src/newsletter/locale/ru/LC_MESSAGES/django.mo and b/src/newsletter/locale/ru/LC_MESSAGES/django.mo differ diff --git a/src/newsletter/locale/ru/LC_MESSAGES/django.po b/src/newsletter/locale/ru/LC_MESSAGES/django.po index bbd427fc2..8c408ebe1 100644 --- a/src/newsletter/locale/ru/LC_MESSAGES/django.po +++ b/src/newsletter/locale/ru/LC_MESSAGES/django.po @@ -8,7 +8,7 @@ msgid "" msgstr "" "Project-Id-Version: PACKAGE VERSION\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2018-04-04 17:12+0200\n" +"POT-Creation-Date: 2018-09-28 11:23+0200\n" "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" "Last-Translator: FULL NAME \n" "Language-Team: LANGUAGE \n" @@ -19,19 +19,31 @@ msgstr "" "Plural-Forms: nplurals=3; plural=(n%10==1 && n%100!=11 ? 0 : n%10>=2 && n" "%10<=4 && (n%100<10 || n%100>=20) ? 1 : 2);\n" -#: forms.py:17 +#: forms.py:19 msgid "I want to receive Wolne Lektury's newsletter." msgstr "" -#: forms.py:46 forms.py:54 models.py:10 +#: forms.py:60 forms.py:71 models.py:10 msgid "email address" msgstr "" -#: forms.py:61 +#: forms.py:63 +msgid "general newsletter" +msgstr "" + +#: forms.py:63 +msgid "about the contest" +msgstr "" + +#: forms.py:64 +msgid "mailing list" +msgstr "" + +#: forms.py:78 msgid "Email address not found." msgstr "" -#: forms.py:72 +#: forms.py:89 msgid "Unsubscribe from Wolne Lektury's newsletter." msgstr "" @@ -55,7 +67,7 @@ msgstr "" msgid "Your subscription to Wolne Lektury newsletter is confirmed. Thank you!" msgstr "" -#: templates/newsletter/subscribe_form.html:15 +#: templates/newsletter/subscribe_form.html:16 msgid "Subscribe" msgstr "" diff --git a/src/newsletter/locale/uk/LC_MESSAGES/django.mo b/src/newsletter/locale/uk/LC_MESSAGES/django.mo index a609786d6..d2d31a4fd 100644 Binary files a/src/newsletter/locale/uk/LC_MESSAGES/django.mo and b/src/newsletter/locale/uk/LC_MESSAGES/django.mo differ diff --git a/src/newsletter/locale/uk/LC_MESSAGES/django.po b/src/newsletter/locale/uk/LC_MESSAGES/django.po index bbd427fc2..8c408ebe1 100644 --- a/src/newsletter/locale/uk/LC_MESSAGES/django.po +++ b/src/newsletter/locale/uk/LC_MESSAGES/django.po @@ -8,7 +8,7 @@ msgid "" msgstr "" "Project-Id-Version: PACKAGE VERSION\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2018-04-04 17:12+0200\n" +"POT-Creation-Date: 2018-09-28 11:23+0200\n" "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" "Last-Translator: FULL NAME \n" "Language-Team: LANGUAGE \n" @@ -19,19 +19,31 @@ msgstr "" "Plural-Forms: nplurals=3; plural=(n%10==1 && n%100!=11 ? 0 : n%10>=2 && n" "%10<=4 && (n%100<10 || n%100>=20) ? 1 : 2);\n" -#: forms.py:17 +#: forms.py:19 msgid "I want to receive Wolne Lektury's newsletter." msgstr "" -#: forms.py:46 forms.py:54 models.py:10 +#: forms.py:60 forms.py:71 models.py:10 msgid "email address" msgstr "" -#: forms.py:61 +#: forms.py:63 +msgid "general newsletter" +msgstr "" + +#: forms.py:63 +msgid "about the contest" +msgstr "" + +#: forms.py:64 +msgid "mailing list" +msgstr "" + +#: forms.py:78 msgid "Email address not found." msgstr "" -#: forms.py:72 +#: forms.py:89 msgid "Unsubscribe from Wolne Lektury's newsletter." msgstr "" @@ -55,7 +67,7 @@ msgstr "" msgid "Your subscription to Wolne Lektury newsletter is confirmed. Thank you!" msgstr "" -#: templates/newsletter/subscribe_form.html:15 +#: templates/newsletter/subscribe_form.html:16 msgid "Subscribe" msgstr "" diff --git a/src/newsletter/templates/newsletter/subscribe_form.html b/src/newsletter/templates/newsletter/subscribe_form.html index 203e54c04..c0379f014 100644 --- a/src/newsletter/templates/newsletter/subscribe_form.html +++ b/src/newsletter/templates/newsletter/subscribe_form.html @@ -11,7 +11,7 @@ {% render_honeypot_field %}
  1. {{ form.email|pretty_field }}
  2. -
  3. {{ form.agree_newsletter|pretty_checkbox }}
  4. +
  5. {{ form.mailing_lists|pretty_field }}
  6. {{ form.data_processing }}