From: Radek Czajka Date: Thu, 10 Jun 2021 12:08:11 +0000 (+0200) Subject: Collection link on main and slight funding wording change. X-Git-Url: https://git.mdrn.pl/wolnelektury.git/commitdiff_plain/b39c329ecd604d815de1f772ed9c2e9598db4c46?hp=689dab7f9aab019f0419133043bf02efcf469c93 Collection link on main and slight funding wording change. --- diff --git a/src/funding/forms.py b/src/funding/forms.py index c3661d5e9..ef797740f 100644 --- a/src/funding/forms.py +++ b/src/funding/forms.py @@ -21,8 +21,8 @@ class FundingForm(NewsletterForm): email = forms.EmailField( label=_("Contact e-mail"), help_text=mark_safe(_( - "We'll use it to contact you about the details needed for your perks,
" - "and to send you updates about your payment and the fundraiser status (which you can always turn off).
" + "We'll use it to " + "send you updates about your payment and the fundraiser status (which you can always turn off).
" "Your e-mail won't be publicised.")), required=False) data_processing_part2 = '''\ diff --git a/src/funding/locale/de/LC_MESSAGES/django.po b/src/funding/locale/de/LC_MESSAGES/django.po index 475cf33c4..81d737d3d 100644 --- a/src/funding/locale/de/LC_MESSAGES/django.po +++ b/src/funding/locale/de/LC_MESSAGES/django.po @@ -51,8 +51,7 @@ msgstr "" #: funding/forms.py:24 msgid "" -"We'll use it to contact you about the details needed for your perks,
and to send you updates about your payment and the fundraiser " +"We'll use it to send you updates about your payment and the fundraiser " "status (which you can always turn off).
Your e-mail won't be publicised." msgstr "" @@ -165,7 +164,7 @@ msgstr "" msgid "email" msgstr "" -#: funding/models.py:273 funding/models.py:352 +#: funding/models.py:273 funding/models.py:355 msgid "amount" msgstr "" @@ -186,19 +185,19 @@ msgstr "" msgid "fundings" msgstr "" -#: funding/models.py:353 +#: funding/models.py:356 msgid "when" msgstr "" -#: funding/models.py:356 +#: funding/models.py:359 msgid "money spent on a book" msgstr "" -#: funding/models.py:357 +#: funding/models.py:360 msgid "money spent on books" msgstr "" -#: funding/models.py:385 funding/templates/funding/thanks.html:6 +#: funding/models.py:388 funding/templates/funding/thanks.html:6 #: funding/templates/funding/thanks.html:13 msgid "Thank you for your support!" msgstr "" diff --git a/src/funding/locale/en/LC_MESSAGES/django.po b/src/funding/locale/en/LC_MESSAGES/django.po index 7ce9bd354..50bea65fb 100644 --- a/src/funding/locale/en/LC_MESSAGES/django.po +++ b/src/funding/locale/en/LC_MESSAGES/django.po @@ -50,8 +50,7 @@ msgstr "" #: funding/forms.py:24 msgid "" -"We'll use it to contact you about the details needed for your perks,
and to send you updates about your payment and the fundraiser " +"We'll use it to send you updates about your payment and the fundraiser " "status (which you can always turn off).
Your e-mail won't be publicised." msgstr "" @@ -164,7 +163,7 @@ msgstr "" msgid "email" msgstr "" -#: funding/models.py:273 funding/models.py:352 +#: funding/models.py:273 funding/models.py:355 msgid "amount" msgstr "" @@ -185,19 +184,19 @@ msgstr "" msgid "fundings" msgstr "" -#: funding/models.py:353 +#: funding/models.py:356 msgid "when" msgstr "" -#: funding/models.py:356 +#: funding/models.py:359 msgid "money spent on a book" msgstr "" -#: funding/models.py:357 +#: funding/models.py:360 msgid "money spent on books" msgstr "" -#: funding/models.py:385 funding/templates/funding/thanks.html:6 +#: funding/models.py:388 funding/templates/funding/thanks.html:6 #: funding/templates/funding/thanks.html:13 msgid "Thank you for your support!" msgstr "" diff --git a/src/funding/locale/es/LC_MESSAGES/django.po b/src/funding/locale/es/LC_MESSAGES/django.po index 475cf33c4..81d737d3d 100644 --- a/src/funding/locale/es/LC_MESSAGES/django.po +++ b/src/funding/locale/es/LC_MESSAGES/django.po @@ -51,8 +51,7 @@ msgstr "" #: funding/forms.py:24 msgid "" -"We'll use it to contact you about the details needed for your perks,
and to send you updates about your payment and the fundraiser " +"We'll use it to send you updates about your payment and the fundraiser " "status (which you can always turn off).
Your e-mail won't be publicised." msgstr "" @@ -165,7 +164,7 @@ msgstr "" msgid "email" msgstr "" -#: funding/models.py:273 funding/models.py:352 +#: funding/models.py:273 funding/models.py:355 msgid "amount" msgstr "" @@ -186,19 +185,19 @@ msgstr "" msgid "fundings" msgstr "" -#: funding/models.py:353 +#: funding/models.py:356 msgid "when" msgstr "" -#: funding/models.py:356 +#: funding/models.py:359 msgid "money spent on a book" msgstr "" -#: funding/models.py:357 +#: funding/models.py:360 msgid "money spent on books" msgstr "" -#: funding/models.py:385 funding/templates/funding/thanks.html:6 +#: funding/models.py:388 funding/templates/funding/thanks.html:6 #: funding/templates/funding/thanks.html:13 msgid "Thank you for your support!" msgstr "" diff --git a/src/funding/locale/fr/LC_MESSAGES/django.po b/src/funding/locale/fr/LC_MESSAGES/django.po index 41a23c7bb..d69574c45 100644 --- a/src/funding/locale/fr/LC_MESSAGES/django.po +++ b/src/funding/locale/fr/LC_MESSAGES/django.po @@ -51,8 +51,7 @@ msgstr "" #: funding/forms.py:24 msgid "" -"We'll use it to contact you about the details needed for your perks,
and to send you updates about your payment and the fundraiser " +"We'll use it to send you updates about your payment and the fundraiser " "status (which you can always turn off).
Your e-mail won't be publicised." msgstr "" @@ -165,7 +164,7 @@ msgstr "" msgid "email" msgstr "" -#: funding/models.py:273 funding/models.py:352 +#: funding/models.py:273 funding/models.py:355 msgid "amount" msgstr "" @@ -186,19 +185,19 @@ msgstr "" msgid "fundings" msgstr "" -#: funding/models.py:353 +#: funding/models.py:356 msgid "when" msgstr "" -#: funding/models.py:356 +#: funding/models.py:359 msgid "money spent on a book" msgstr "" -#: funding/models.py:357 +#: funding/models.py:360 msgid "money spent on books" msgstr "" -#: funding/models.py:385 funding/templates/funding/thanks.html:6 +#: funding/models.py:388 funding/templates/funding/thanks.html:6 #: funding/templates/funding/thanks.html:13 msgid "Thank you for your support!" msgstr "" diff --git a/src/funding/locale/it/LC_MESSAGES/django.po b/src/funding/locale/it/LC_MESSAGES/django.po index 475cf33c4..81d737d3d 100644 --- a/src/funding/locale/it/LC_MESSAGES/django.po +++ b/src/funding/locale/it/LC_MESSAGES/django.po @@ -51,8 +51,7 @@ msgstr "" #: funding/forms.py:24 msgid "" -"We'll use it to contact you about the details needed for your perks,
and to send you updates about your payment and the fundraiser " +"We'll use it to send you updates about your payment and the fundraiser " "status (which you can always turn off).
Your e-mail won't be publicised." msgstr "" @@ -165,7 +164,7 @@ msgstr "" msgid "email" msgstr "" -#: funding/models.py:273 funding/models.py:352 +#: funding/models.py:273 funding/models.py:355 msgid "amount" msgstr "" @@ -186,19 +185,19 @@ msgstr "" msgid "fundings" msgstr "" -#: funding/models.py:353 +#: funding/models.py:356 msgid "when" msgstr "" -#: funding/models.py:356 +#: funding/models.py:359 msgid "money spent on a book" msgstr "" -#: funding/models.py:357 +#: funding/models.py:360 msgid "money spent on books" msgstr "" -#: funding/models.py:385 funding/templates/funding/thanks.html:6 +#: funding/models.py:388 funding/templates/funding/thanks.html:6 #: funding/templates/funding/thanks.html:13 msgid "Thank you for your support!" msgstr "" diff --git a/src/funding/locale/lt/LC_MESSAGES/django.po b/src/funding/locale/lt/LC_MESSAGES/django.po index 10a3d20aa..17e866668 100644 --- a/src/funding/locale/lt/LC_MESSAGES/django.po +++ b/src/funding/locale/lt/LC_MESSAGES/django.po @@ -52,8 +52,7 @@ msgstr "" #: funding/forms.py:24 msgid "" -"We'll use it to contact you about the details needed for your perks,
and to send you updates about your payment and the fundraiser " +"We'll use it to send you updates about your payment and the fundraiser " "status (which you can always turn off).
Your e-mail won't be publicised." msgstr "" @@ -166,7 +165,7 @@ msgstr "" msgid "email" msgstr "" -#: funding/models.py:273 funding/models.py:352 +#: funding/models.py:273 funding/models.py:355 msgid "amount" msgstr "" @@ -187,19 +186,19 @@ msgstr "" msgid "fundings" msgstr "" -#: funding/models.py:353 +#: funding/models.py:356 msgid "when" msgstr "" -#: funding/models.py:356 +#: funding/models.py:359 msgid "money spent on a book" msgstr "" -#: funding/models.py:357 +#: funding/models.py:360 msgid "money spent on books" msgstr "" -#: funding/models.py:385 funding/templates/funding/thanks.html:6 +#: funding/models.py:388 funding/templates/funding/thanks.html:6 #: funding/templates/funding/thanks.html:13 msgid "Thank you for your support!" msgstr "" diff --git a/src/funding/locale/pl/LC_MESSAGES/django.mo b/src/funding/locale/pl/LC_MESSAGES/django.mo index 85a86dceb..99760e1bb 100644 Binary files a/src/funding/locale/pl/LC_MESSAGES/django.mo and b/src/funding/locale/pl/LC_MESSAGES/django.mo differ diff --git a/src/funding/locale/pl/LC_MESSAGES/django.po b/src/funding/locale/pl/LC_MESSAGES/django.po index bf3a62e03..d55735536 100644 --- a/src/funding/locale/pl/LC_MESSAGES/django.po +++ b/src/funding/locale/pl/LC_MESSAGES/django.po @@ -5,18 +5,18 @@ # msgid "" msgstr "" -"Project-Id-Version: PACKAGE VERSION\n" +"Project-Id-Version: \n" "Report-Msgid-Bugs-To: \n" -"PO-Revision-Date: 2015-04-16 13:13+0100\n" +"PO-Revision-Date: 2021-06-10 14:06+0200\n" "Last-Translator: Radek Czajka \n" -"Language-Team: LANGUAGE \n" -"Language: \n" +"Language: pl\n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" "Plural-Forms: nplurals=3; plural=(n==1 ? 0 : n%10>=2 && n%10<=4 && (n%100<10 " "|| n%100>=20) ? 1 : 2);\n" -"X-Generator: Poedit 1.5.4\n" +"X-Generator: Poedit 2.4.1\n" +"Language-Team: \n" #: funding/admin.py:27 msgid "payment complete" @@ -53,14 +53,12 @@ msgstr "E-mail kontaktowy" #: funding/forms.py:24 msgid "" -"We'll use it to contact you about the details needed for your perks,
and to send you updates about your payment and the fundraiser " +"We'll use it to send you updates about your payment and the fundraiser " "status (which you can always turn off).
Your e-mail won't be publicised." msgstr "" -"Użyjemy go do kontaktu w sprawie danych potrzebnych do realizacji " -"prezentów
i do informowania Cię o zmianach statusu płatności i " -"zbiórki (z czego zawsze możesz zrezygnować).
Twój adres e-mail nie " -"będzie upubliczniony." +"Użyjemy go do informowania Cię o zmianach statusu płatności i zbiórki (z " +"czego zawsze możesz zrezygnować).
Twój adres e-mail nie będzie " +"upubliczniony." #: funding/forms.py:43 #, python-format @@ -171,7 +169,7 @@ msgstr "prezent" msgid "email" msgstr "e-mail" -#: funding/models.py:273 funding/models.py:352 +#: funding/models.py:273 funding/models.py:355 msgid "amount" msgstr "kwota" @@ -192,19 +190,19 @@ msgstr "wpłata" msgid "fundings" msgstr "wpłaty" -#: funding/models.py:353 +#: funding/models.py:356 msgid "when" msgstr "kiedy" -#: funding/models.py:356 +#: funding/models.py:359 msgid "money spent on a book" msgstr "pieniądze wydane na książkę" -#: funding/models.py:357 +#: funding/models.py:360 msgid "money spent on books" msgstr "pieniądze wydane na książki" -#: funding/models.py:385 funding/templates/funding/thanks.html:6 +#: funding/models.py:388 funding/templates/funding/thanks.html:6 #: funding/templates/funding/thanks.html:13 msgid "Thank you for your support!" msgstr "Dziękujemy za Twoje wsparcie!" diff --git a/src/funding/locale/ru/LC_MESSAGES/django.po b/src/funding/locale/ru/LC_MESSAGES/django.po index e29fcfb7c..5e529378e 100644 --- a/src/funding/locale/ru/LC_MESSAGES/django.po +++ b/src/funding/locale/ru/LC_MESSAGES/django.po @@ -52,8 +52,7 @@ msgstr "" #: funding/forms.py:24 msgid "" -"We'll use it to contact you about the details needed for your perks,
and to send you updates about your payment and the fundraiser " +"We'll use it to send you updates about your payment and the fundraiser " "status (which you can always turn off).
Your e-mail won't be publicised." msgstr "" @@ -166,7 +165,7 @@ msgstr "" msgid "email" msgstr "" -#: funding/models.py:273 funding/models.py:352 +#: funding/models.py:273 funding/models.py:355 msgid "amount" msgstr "" @@ -187,19 +186,19 @@ msgstr "" msgid "fundings" msgstr "" -#: funding/models.py:353 +#: funding/models.py:356 msgid "when" msgstr "" -#: funding/models.py:356 +#: funding/models.py:359 msgid "money spent on a book" msgstr "" -#: funding/models.py:357 +#: funding/models.py:360 msgid "money spent on books" msgstr "" -#: funding/models.py:385 funding/templates/funding/thanks.html:6 +#: funding/models.py:388 funding/templates/funding/thanks.html:6 #: funding/templates/funding/thanks.html:13 msgid "Thank you for your support!" msgstr "" diff --git a/src/funding/locale/uk/LC_MESSAGES/django.po b/src/funding/locale/uk/LC_MESSAGES/django.po index e29fcfb7c..5e529378e 100644 --- a/src/funding/locale/uk/LC_MESSAGES/django.po +++ b/src/funding/locale/uk/LC_MESSAGES/django.po @@ -52,8 +52,7 @@ msgstr "" #: funding/forms.py:24 msgid "" -"We'll use it to contact you about the details needed for your perks,
and to send you updates about your payment and the fundraiser " +"We'll use it to send you updates about your payment and the fundraiser " "status (which you can always turn off).
Your e-mail won't be publicised." msgstr "" @@ -166,7 +165,7 @@ msgstr "" msgid "email" msgstr "" -#: funding/models.py:273 funding/models.py:352 +#: funding/models.py:273 funding/models.py:355 msgid "amount" msgstr "" @@ -187,19 +186,19 @@ msgstr "" msgid "fundings" msgstr "" -#: funding/models.py:353 +#: funding/models.py:356 msgid "when" msgstr "" -#: funding/models.py:356 +#: funding/models.py:359 msgid "money spent on a book" msgstr "" -#: funding/models.py:357 +#: funding/models.py:360 msgid "money spent on books" msgstr "" -#: funding/models.py:385 funding/templates/funding/thanks.html:6 +#: funding/models.py:388 funding/templates/funding/thanks.html:6 #: funding/templates/funding/thanks.html:13 msgid "Thank you for your support!" msgstr "" diff --git a/src/wolnelektury/templates/main_page.html b/src/wolnelektury/templates/main_page.html index f47e1d227..369d6f603 100644 --- a/src/wolnelektury/templates/main_page.html +++ b/src/wolnelektury/templates/main_page.html @@ -23,7 +23,7 @@ {{ book.mini_box }} {% endfor %} - +
{% trans "and many other books, poems, pictures, audiobooks…" %}
diff --git a/src/wolnelektury/views.py b/src/wolnelektury/views.py index 2cc0fd799..5e56f5906 100644 --- a/src/wolnelektury/views.py +++ b/src/wolnelektury/views.py @@ -51,12 +51,16 @@ def main_page(request): best = [] best_places = 5 + recommended_collection = None for recommended in Collection.objects.filter(listed=True, role='recommend').order_by('?'): + if recommended_collection is None: + recommended_collection = recommended books = list(recommended.get_books().exclude(id__in=[b.id for b in best]).order_by('?')[:best_places]) best.extend(books) best_places -= len(books) if not best_places: break + ctx['recommended_collection'] = recommended_collection if best_places: best.extend( list(