Show More
@@ -85,6 +85,7 b' MIMETYPE_EXTENSIONS = {' | |||||
85 | } |
|
85 | } | |
86 |
|
86 | |||
87 | DOWN_MODE_DOWNLOAD = 'DOWNLOAD' |
|
87 | DOWN_MODE_DOWNLOAD = 'DOWNLOAD' | |
|
88 | DOWN_MODE_DOWNLOAD_UNIQUE = 'DOWNLOAD_UNIQUE' | |||
88 | DOWN_MODE_URL = 'URL' |
|
89 | DOWN_MODE_URL = 'URL' | |
89 | DOWN_MODE_TRY = 'TRY' |
|
90 | DOWN_MODE_TRY = 'TRY' | |
90 |
|
91 | |||
@@ -187,12 +188,13 b' class PostForm(NeboardForm):' | |||||
187 | required=False, label=LABEL_TEXT) |
|
188 | required=False, label=LABEL_TEXT) | |
188 | download_mode = forms.ChoiceField( |
|
189 | download_mode = forms.ChoiceField( | |
189 | choices=( |
|
190 | choices=( | |
190 |
(DOWN_MODE_TRY, _('Download or |
|
191 | (DOWN_MODE_TRY, _('Download or insert as URLs')), | |
191 |
(DOWN_MODE_DOWNLOAD, _('Download |
|
192 | (DOWN_MODE_DOWNLOAD, _('Download')), | |
|
193 | (DOWN_MODE_DOWNLOAD_UNIQUE, _('Download and check for uniqueness')), | |||
192 | (DOWN_MODE_URL, _('Insert as URLs')), |
|
194 | (DOWN_MODE_URL, _('Insert as URLs')), | |
193 | ), |
|
195 | ), | |
194 | initial=DOWN_MODE_TRY, |
|
196 | initial=DOWN_MODE_TRY, | |
195 |
label=_(' |
|
197 | label=_('File process mode')) | |
196 | file = UrlFileField(required=False, label=LABEL_FILE) |
|
198 | file = UrlFileField(required=False, label=LABEL_FILE) | |
197 |
|
199 | |||
198 | # This field is for spam prevention only |
|
200 | # This field is for spam prevention only | |
@@ -200,7 +202,6 b' class PostForm(NeboardForm):' | |||||
200 | widget=forms.TextInput(attrs={ |
|
202 | widget=forms.TextInput(attrs={ | |
201 | 'class': 'form-email'})) |
|
203 | 'class': 'form-email'})) | |
202 | subscribe = forms.BooleanField(required=False, label=_('Subscribe to thread')) |
|
204 | subscribe = forms.BooleanField(required=False, label=_('Subscribe to thread')) | |
203 | check_duplicates = forms.BooleanField(required=False, label=LABEL_DUPLICATES) |
|
|||
204 |
|
205 | |||
205 | guess = forms.CharField(widget=forms.HiddenInput(), required=False) |
|
206 | guess = forms.CharField(widget=forms.HiddenInput(), required=False) | |
206 | timestamp = forms.CharField(widget=forms.HiddenInput(), required=False) |
|
207 | timestamp = forms.CharField(widget=forms.HiddenInput(), required=False) | |
@@ -257,7 +258,7 b' class PostForm(NeboardForm):' | |||||
257 | # Time-based |
|
258 | # Time-based | |
258 | self._validate_posting_speed() |
|
259 | self._validate_posting_speed() | |
259 | settings_manager.set_setting('confirmed_user', True) |
|
260 | settings_manager.set_setting('confirmed_user', True) | |
260 | if self.cleaned_data['check_duplicates']: |
|
261 | if self.cleaned_data['download_mode'] == DOWN_MODE_DOWNLOAD_UNIQUE: | |
261 | self._check_file_duplicates(self.get_files()) |
|
262 | self._check_file_duplicates(self.get_files()) | |
262 |
|
263 | |||
263 | return cleaned_data |
|
264 | return cleaned_data |
1 | NO CONTENT: modified file, binary diff hidden |
|
NO CONTENT: modified file, binary diff hidden |
@@ -587,17 +587,20 b' msgstr "\xd0\x92\xd1\x8b \xd1\x83\xd0\xb2\xd0\xb5\xd1\x80\xd0\xb5\xd0\xbd\xd1\x8b?"' | |||||
587 | msgid "Ban" |
|
587 | msgid "Ban" | |
588 | msgstr "Забанить" |
|
588 | msgstr "Забанить" | |
589 |
|
589 | |||
590 |
msgid " |
|
590 | msgid "File process mode" | |
591 |
msgstr "Режим |
|
591 | msgstr "Режим обработки файлов" | |
|
592 | ||||
|
593 | msgid "Download or insert as URLs" | |||
|
594 | msgstr "Загрузить или вставить как ссылки" | |||
592 |
|
595 | |||
593 |
msgid "Download |
|
596 | msgid "Download" | |
594 |
msgstr "Загрузить |
|
597 | msgstr "Загрузить" | |
595 |
|
598 | |||
596 |
msgid "Download |
|
599 | msgid "Download and check for uniqueness" | |
597 |
msgstr "Загрузить и |
|
600 | msgstr "Загрузить и проверить на уникальность" | |
598 |
|
601 | |||
599 | msgid "Insert as URLs" |
|
602 | msgid "Insert as URLs" | |
600 |
msgstr "Встав |
|
603 | msgstr "Вставить как ссылки" | |
601 |
|
604 | |||
602 | msgid "Help" |
|
605 | msgid "Help" | |
603 | msgstr "Справка" |
|
606 | msgstr "Справка" |
1 | NO CONTENT: modified file, binary diff hidden |
|
NO CONTENT: modified file, binary diff hidden |
@@ -587,17 +587,20 b' msgstr "\xd0\xa7\xd0\xb8 \xd0\xb2\xd0\xb8 \xd0\xbf\xd0\xb5\xd0\xb2\xd0\xbd\xd1\x96?"' | |||||
587 | msgid "Ban" |
|
587 | msgid "Ban" | |
588 | msgstr "Заблокувати" |
|
588 | msgstr "Заблокувати" | |
589 |
|
589 | |||
590 |
msgid " |
|
590 | msgid "File process mode" | |
591 | msgstr "Режим завантаження посилань" |
|
591 | msgstr "Режим обробки файлів" | |
|
592 | ||||
|
593 | msgid "Download or insert as URLs" | |||
|
594 | msgstr "Завантажити або вставити як посилання" | |||
592 |
|
595 | |||
593 |
msgid "Download |
|
596 | msgid "Download" | |
594 |
msgstr "Завантажити |
|
597 | msgstr "Завантажити" | |
595 |
|
598 | |||
596 |
msgid "Download |
|
599 | msgid "Download and check for uniqueness" | |
597 |
msgstr "Завантажити |
|
600 | msgstr "Завантажити та перевірити на унікальність" | |
598 |
|
601 | |||
599 | msgid "Insert as URLs" |
|
602 | msgid "Insert as URLs" | |
600 |
msgstr "Встав |
|
603 | msgstr "Вставити як посилання" | |
601 |
|
604 | |||
602 | msgid "Help" |
|
605 | msgid "Help" | |
603 | msgstr "Справка" |
|
606 | msgstr "Справка" |
General Comments 0
You need to be logged in to leave comments.
Login now