Show More
1 | NO CONTENT: modified file, binary diff hidden |
|
NO CONTENT: modified file, binary diff hidden |
@@ -158,6 +158,14 b' msgstr[0] "%(count)s \xd0\xb0\xd0\xba\xd1\x82\xd0\xb8\xd0\xb2\xd0\xbd\xd0\xb0\xd1\x8f \xd1\x82\xd0\xb5\xd0\xbc\xd0\xb0"' | |||||
158 | msgstr[1] "%(count)s активные темы" |
|
158 | msgstr[1] "%(count)s активные темы" | |
159 | msgstr[2] "%(count)s активных тем" |
|
159 | msgstr[2] "%(count)s активных тем" | |
160 |
|
160 | |||
|
161 | #: templates/boards/all_threads.html:76 | |||
|
162 | #, python-format | |||
|
163 | msgid "%(count)s thread in bumplimit" | |||
|
164 | msgid_plural "%(count)s threads in bumplimit" | |||
|
165 | msgstr[0] "%(count)s тема в бамплимите" | |||
|
166 | msgstr[1] "%(count)s темы в бамплимите" | |||
|
167 | msgstr[2] "%(count)s тем в бамплимите" | |||
|
168 | ||||
161 | #: templates/boards/all_threads.html:77 |
|
169 | #: templates/boards/all_threads.html:77 | |
162 | #, python-format |
|
170 | #, python-format | |
163 | msgid "%(count)s archived thread" |
|
171 | msgid "%(count)s archived thread" |
@@ -61,14 +61,19 b' class Tag(models.Model, Viewable):' | |||||
61 |
|
61 | |||
62 | return self.get_thread_count() == 0 |
|
62 | return self.get_thread_count() == 0 | |
63 |
|
63 | |||
64 | def get_thread_count(self, archived=None) -> int: |
|
64 | def get_thread_count(self, archived=None, bumpable=None) -> int: | |
65 | threads = self.get_threads() |
|
65 | threads = self.get_threads() | |
66 | if archived is not None: |
|
66 | if archived is not None: | |
67 | threads = threads.filter(archived=archived) |
|
67 | threads = threads.filter(archived=archived) | |
|
68 | if bumpable is not None: | |||
|
69 | threads = threads.filter(bumpable=bumpable) | |||
68 | return threads.count() |
|
70 | return threads.count() | |
69 |
|
71 | |||
70 | def get_active_thread_count(self) -> int: |
|
72 | def get_active_thread_count(self) -> int: | |
71 | return self.get_thread_count(archived=False) |
|
73 | return self.get_thread_count(archived=False, bumpable=True) | |
|
74 | ||||
|
75 | def get_bumplimit_thread_count(self) -> int: | |||
|
76 | return self.get_thread_count(archived=False, bumpable=False) | |||
72 |
|
77 | |||
73 | def get_archived_thread_count(self) -> int: |
|
78 | def get_archived_thread_count(self) -> int: | |
74 | return self.get_thread_count(archived=True) |
|
79 | return self.get_thread_count(archived=True) |
@@ -74,6 +74,7 b'' | |||||
74 | {% endif %} |
|
74 | {% endif %} | |
75 | <p> |
|
75 | <p> | |
76 | {% blocktrans count count=tag.get_active_thread_count %}{{ count }} active thread{% plural %}active threads{% endblocktrans %}, |
|
76 | {% blocktrans count count=tag.get_active_thread_count %}{{ count }} active thread{% plural %}active threads{% endblocktrans %}, | |
|
77 | {% blocktrans count count=tag.get_bumplimit_thread_count %}{{ count }} thread in bumplimit{% plural %} threads in bumplimit{% endblocktrans %}, | |||
77 | {% blocktrans count count=tag.get_archived_thread_count %}{{ count }} archived thread{% plural %}archived threads{% endblocktrans %}, |
|
78 | {% blocktrans count count=tag.get_archived_thread_count %}{{ count }} archived thread{% plural %}archived threads{% endblocktrans %}, | |
78 | {% blocktrans count count=tag.get_post_count %}{{ count }} message{% plural %}messages{% endblocktrans %}. |
|
79 | {% blocktrans count count=tag.get_post_count %}{{ count }} message{% plural %}messages{% endblocktrans %}. | |
79 | </p> |
|
80 | </p> |
General Comments 0
You need to be logged in to leave comments.
Login now