diff options
| author | Adrian Holovaty <adrian@holovaty.com> | 2007-06-07 21:49:06 +0000 |
|---|---|---|
| committer | Adrian Holovaty <adrian@holovaty.com> | 2007-06-07 21:49:06 +0000 |
| commit | d34639b09bf85dfb1b6f9a4b59f8ccbc3117230b (patch) | |
| tree | 619db1e6fde32bbfb0c135bde382d1b1df395e9a | |
| parent | 659d99b7afda730180e80ea4d68a7d505b21ba86 (diff) | |
newforms-admin: Merged to [5439]
git-svn-id: http://code.djangoproject.com/svn/django/branches/newforms-admin@5440 bcc190cf-cafb-0310-a4f2-bffc1f526a37
52 files changed, 2274 insertions, 1833 deletions
@@ -142,6 +142,7 @@ answer newbie questions, and generally made Django that much better: Joseph Kocherhans konrad@gwu.edu lakin.wecker@gmail.com + Nick Lane <nick.lane.au@gmail.com> Stuart Langridge <http://www.kryogenix.org/> Nicola Larosa <nico@teknico.net> Eugene Lazutkin <http://lazutkin.com/blog/> @@ -230,6 +231,7 @@ answer newbie questions, and generally made Django that much better: viestards.lists@gmail.com Milton Waddams wam-djangobug@wamber.net + wangchun <yaohua2000@gmail.com> Dan Watson <http://theidioteque.net/> Chris Wesseling <Chris.Wesseling@cwi.nl> charly.wilhelm@gmail.com diff --git a/django/bin/daily_cleanup.py b/django/bin/daily_cleanup.py index 3b83583d73..c87be1e4c3 100644 --- a/django/bin/daily_cleanup.py +++ b/django/bin/daily_cleanup.py @@ -7,13 +7,13 @@ Can be run as a cronjob to clean out old data from the database (only expired sessions at the moment). """ -from django.db import backend, connection, transaction +import datetime +from django.db import transaction +from django.contrib.sessions.models import Session def clean_up(): - # Clean up old database records - cursor = connection.cursor() - cursor.execute("DELETE FROM %s WHERE %s < NOW()" % \ - (backend.quote_name('django_session'), backend.quote_name('expire_date'))) + """Clean up expired sessions.""" + Session.objects.filter(expire_date__lt=datetime.datetime.now()).delete() transaction.commit_unless_managed() if __name__ == "__main__": diff --git a/django/conf/global_settings.py b/django/conf/global_settings.py index 9abc8d6a6c..2be6a4ef95 100644 --- a/django/conf/global_settings.py +++ b/django/conf/global_settings.py @@ -144,6 +144,7 @@ TEMPLATE_CONTEXT_PROCESSORS = ( 'django.core.context_processors.auth', 'django.core.context_processors.debug', 'django.core.context_processors.i18n', + 'django.core.context_processors.media', # 'django.core.context_processors.request', ) @@ -331,6 +332,13 @@ TEST_RUNNER = 'django.test.simple.run_tests' # If None, a name of 'test_' + DATABASE_NAME will be assumed TEST_DATABASE_NAME = None +# Strings used to set the character set and collation order for the test +# database. These values are passed literally to the server, so they are +# backend-dependent. If None, no special settings are sent (system defaults are +# used). +TEST_DATABASE_CHARSET = None +TEST_DATABASE_COLLATION = None + ############ # FIXTURES # ############ diff --git a/django/conf/locale/ca/LC_MESSAGES/django.mo b/django/conf/locale/ca/LC_MESSAGES/django.mo Binary files differindex ca03991f2b..665d7d41a9 100644 --- a/django/conf/locale/ca/LC_MESSAGES/django.mo +++ b/django/conf/locale/ca/LC_MESSAGES/django.mo diff --git a/django/conf/locale/ca/LC_MESSAGES/django.po b/django/conf/locale/ca/LC_MESSAGES/django.po index ccef4f8e3b..30a8797a91 100644 --- a/django/conf/locale/ca/LC_MESSAGES/django.po +++ b/django/conf/locale/ca/LC_MESSAGES/django.po @@ -6,8 +6,8 @@ msgid "" msgstr "" "Project-Id-Version: django\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2007-05-20 18:25+0200\n" -"PO-Revision-Date: 2007-05-20 18:24+0200\n" +"POT-Creation-Date: 2007-05-25 13:04+0200\n" +"PO-Revision-Date: 2007-05-25 13:04+0200\n" "Last-Translator: Marc Fargas <marc@fargas.com>\n" "Language-Team: <es@li.org>\n" "MIME-Version: 1.0\n" @@ -16,278 +16,302 @@ msgstr "" "X-Generator: VIM 7.0\n" "Plural-Forms: nplurals=2; plural=(n != 1);\n" -#: utils/dateformat.py:40 -msgid "p.m." -msgstr "p.m." +#: template/defaultfilters.py:491 +msgid "yes,no,maybe" +msgstr "si,no,potser" -#: utils/dateformat.py:41 -msgid "a.m." -msgstr "a.m." +#: template/defaultfilters.py:520 +#, python-format +msgid "%(size)d byte" +msgid_plural "%(size)d bytes" +msgstr[0] "%(size)d byte" +msgstr[1] "%(size)d bytes" -#: utils/dateformat.py:46 -msgid "PM" -msgstr "PM" +#: template/defaultfilters.py:522 +#, python-format +msgid "%.1f KB" +msgstr "%.1f KB" -#: utils/dateformat.py:47 -msgid "AM" -msgstr "AM" +#: template/defaultfilters.py:524 +#, python-format +msgid "%.1f MB" +msgstr "%.1f MB" -#: utils/dateformat.py:95 -msgid "midnight" -msgstr "mitja nit" +#: template/defaultfilters.py:525 +#, python-format +msgid "%.1f GB" +msgstr "%.1f GB" -#: utils/dateformat.py:97 -msgid "noon" -msgstr "mig dia" +#: newforms/models.py:173 newforms/fields.py:432 +msgid "Select a valid choice. That choice is not one of the available choices." +msgstr "" +"Esculli una opció vàlida; Aquesta opció no és una de les opcions disponibles." -#: utils/dates.py:6 -msgid "Monday" -msgstr "Dilluns" +#: newforms/models.py:186 newforms/fields.py:87 newforms/fields.py:444 +#: newforms/fields.py:520 newforms/fields.py:531 oldforms/__init__.py:357 +#: db/models/fields/__init__.py:121 db/models/fields/__init__.py:278 +#: db/models/fields/__init__.py:675 db/models/fields/__init__.py:686 +msgid "This field is required." +msgstr "Aquest camp és obligatori." -#: utils/dates.py:6 -msgid "Tuesday" -msgstr "Dimarts" +#: newforms/models.py:190 newforms/fields.py:448 newforms/fields.py:524 +msgid "Enter a list of values." +msgstr "Introdueixi una llista de valors." -#: utils/dates.py:6 -msgid "Wednesday" -msgstr "Dimecres" +#: newforms/models.py:196 newforms/fields.py:457 +#, python-format +msgid "Select a valid choice. %s is not one of the available choices." +msgstr "Esculli una opció vàlida; %s' no és una de les opcions vàlides." -#: utils/dates.py:6 -msgid "Thursday" -msgstr "Dijous" +#: newforms/widgets.py:182 contrib/admin/filterspecs.py:150 +#: oldforms/__init__.py:577 +msgid "Unknown" +msgstr "Desconegut" -#: utils/dates.py:6 -msgid "Friday" -msgstr "Divendres" +#: newforms/widgets.py:182 contrib/admin/filterspecs.py:143 +#: oldforms/__init__.py:577 +msgid "Yes" +msgstr "Si" -#: utils/dates.py:7 -msgid "Saturday" -msgstr "Dissabte" +#: newforms/widgets.py:182 contrib/admin/filterspecs.py:143 +#: oldforms/__init__.py:577 +msgid "No" +msgstr "No" -#: utils/dates.py:7 -msgid "Sunday" -msgstr "Diumenge" +#: newforms/fields.py:110 newforms/fields.py:324 +#, python-format +msgid "Ensure this value has at most %d characters." +msgstr "Asseguris de que el seu texte té com a màxim %d caracters." -#: utils/dates.py:14 -msgid "January" -msgstr "Gener" +#: newforms/fields.py:112 newforms/fields.py:326 +#, python-format +msgid "Ensure this value has at least %d characters." +msgstr "Asseguris de que el seu texte té almenys %d caracters." -#: utils/dates.py:14 -msgid "February" -msgstr "Febrer" +#: newforms/fields.py:135 core/validators.py:121 +msgid "Enter a whole number." +msgstr "Introdueixi un número sencer." -#: utils/dates.py:14 utils/dates.py:27 -msgid "March" -msgstr "Març" +#: newforms/fields.py:137 newforms/fields.py:160 newforms/fields.py:192 +#, python-format +msgid "Ensure this value is less than or equal to %s." +msgstr "Aquest valor ha de ser menor o igual a %s." -#: utils/dates.py:14 utils/dates.py:27 -msgid "April" -msgstr "Abril" +#: newforms/fields.py:139 newforms/fields.py:162 newforms/fields.py:194 +#, python-format +msgid "Ensure this value is greater than or equal to %s." +msgstr "Asseguris de que aquest valor sigui superior o igual a %s." -#: utils/dates.py:14 utils/dates.py:27 -msgid "May" -msgstr "Maig" +#: newforms/fields.py:158 newforms/fields.py:186 +msgid "Enter a number." +msgstr "Introdueixi un número." -#: utils/dates.py:14 utils/dates.py:27 -msgid "June" -msgstr "Juny" +#: newforms/fields.py:196 +#, python-format +msgid "Ensure that there are no more than %s digits in total." +msgstr "Asseguris de que no hi ha més de %s dígits en total." -#: utils/dates.py:15 utils/dates.py:27 -msgid "July" -msgstr "Juliol" +#: newforms/fields.py:198 +#, python-format +msgid "Ensure that there are no more than %s decimal places." +msgstr "Asseguris de que no hi ha més de %s decimals." -#: utils/dates.py:15 -msgid "August" -msgstr "Agost" +#: newforms/fields.py:200 +#, python-format +msgid "Ensure that there are no more than %s digits before the decimal point." +msgstr "Asseguris de que no hia ha més de %s dígits decimals." -#: utils/dates.py:15 -msgid "September" -msgstr "Setembre" +#: newforms/fields.py:233 +msgid "Enter a valid date." +msgstr "Introdueixi una data vàlida." -#: utils/dates.py:15 -msgid "October" -msgstr "Octubre" +#: newforms/fields.py:260 +msgid "Enter a valid time." +msgstr "Introdueixi una hora vàlida." -#: utils/dates.py:15 -msgid "November" -msgstr "Novembre" +#: newforms/fields.py:296 +msgid "Enter a valid date/time." +msgstr "Introdueixi una data/hora vàlides." -#: utils/dates.py:16 -msgid "December" -msgstr "Desembre" +#: newforms/fields.py:310 +msgid "Enter a valid value." +msgstr "Introdueixi un valor vàlid." -#: utils/dates.py:19 -msgid "jan" -msgstr "gen" +#: newforms/fields.py:339 core/validators.py:163 +msgid "Enter a valid e-mail address." +msgstr "Introdueixi una adreça de correu vàlida." -#: utils/dates.py:19 -msgid "feb" -msgstr "feb" +#: newforms/fields.py:357 newforms/fields.py:379 +msgid "Enter a valid URL." +msgstr "Introdueixi una URL vàlida." -#: utils/dates.py:19 -msgid "mar" -msgstr "mar" +#: newforms/fields.py:381 +msgid "This URL appears to be a broken link." +msgstr "Aquesta URL sembla ser un enllaç trencat." -#: utils/dates.py:19 -msgid "apr" -msgstr "abr" +#: conf/global_settings.py:39 +msgid "Arabic" +msgstr "Arabic" -#: utils/dates.py:19 -msgid "may" -msgstr "mai" +#: conf/global_settings.py:40 +msgid "Bengali" +msgstr "Bengalí" -#: utils/dates.py:19 -msgid "jun" -msgstr "jun" +#: conf/global_settings.py:41 +msgid "Bulgarian" +msgstr "Bulgar" -#: utils/dates.py:20 -msgid "jul" -msgstr "jul" +#: conf/global_settings.py:42 +msgid "Catalan" +msgstr "Català" -#: utils/dates.py:20 -msgid "aug" -msgstr "ago" +#: conf/global_settings.py:43 +msgid "Czech" +msgstr "Txec" -#: utils/dates.py:20 -msgid "sep" -msgstr "set" +#: conf/global_settings.py:44 +msgid "Welsh" +msgstr "Galès" -#: utils/dates.py:20 -msgid "oct" -msgstr "oct" +#: conf/global_settings.py:45 +msgid "Danish" +msgstr "Danès" -#: utils/dates.py:20 -msgid "nov" -msgstr "nov" +#: conf/global_settings.py:46 +msgid "German" +msgstr "Alemany" -#: utils/dates.py:20 -msgid "dec" -msgstr "des" +#: conf/global_settings.py:47 +msgid "Greek" +msgstr "Grec" -#: utils/dates.py:27 -msgid "Jan." -msgstr "Gen." +#: conf/global_settings.py:48 +msgid "English" +msgstr "Anglès" -#: utils/dates.py:27 -msgid "Feb." -msgstr "Feb." +#: conf/global_settings.py:49 +msgid "Spanish" +msgstr "Espanyol" -#: utils/dates.py:28 -msgid "Aug." -msgstr "Ago." +#: conf/global_settings.py:50 +msgid "Argentinean Spanish" +msgstr "Castellà Argentí" -#: utils/dates.py:28 -msgid "Sept." -msgstr "Set." +#: conf/global_settings.py:51 +msgid "Finnish" +msgstr "Finlandès" -#: utils/dates.py:28 -msgid "Oct." -msgstr "Oct." +#: conf/global_settings.py:52 +msgid "French" +msgstr "Francès" -#: utils/dates.py:28 -msgid "Nov." -msgstr "Nov." +#: conf/global_settings.py:53 +msgid "Galician" +msgstr "Galleg" -#: utils/dates.py:28 -msgid "Dec." -msgstr "Des." +#: conf/global_settings.py:54 +msgid "Hungarian" +msgstr "Húngar" -#: utils/timesince.py:12 -msgid "year" -msgid_plural "years" -msgstr[0] "any" -msgstr[1] "anys" +#: conf/global_settings.py:55 +msgid "Hebrew" +msgstr "Hebreu" -#: utils/timesince.py:13 -msgid "month" -msgid_plural "months" -msgstr[0] "mes" -msgstr[1] "mesos" +#: conf/global_settings.py:56 +msgid "Icelandic" +msgstr "Islandès" -#: utils/timesince.py:14 -msgid "week" -msgid_plural "weeks" -msgstr[0] "setmana" -msgstr[1] "setmanes" +#: conf/global_settings.py:57 +msgid "Italian" +msgstr "Italià" -#: utils/timesince.py:15 -msgid "day" -msgid_plural "days" -msgstr[0] "dia" -msgstr[1] "dies" +#: conf/global_settings.py:58 +msgid "Japanese" +msgstr "Japonès" -#: utils/timesince.py:16 -msgid "hour" -msgid_plural "hours" -msgstr[0] "hora" -msgstr[1] "hores" +#: conf/global_settings.py:59 +msgid "Korean" +msgstr "Coreà" -#: utils/timesince.py:17 -msgid "minute" -msgid_plural "minutes" -msgstr[0] "minut" -msgstr[1] "minuts" +#: conf/global_settings.py:60 +msgid "Kannada" +msgstr "" -#: utils/timesince.py:40 -#, python-format -msgid "%d milliseconds" -msgstr "%d milisegons" +#: conf/global_settings.py:61 +msgid "Latvian" +msgstr "" -#: utils/timesince.py:41 -#, python-format -msgid "%(number)d %(type)s" -msgstr "%(number)d %(type)s" +#: conf/global_settings.py:62 +msgid "Macedonian" +msgstr "Macedoni" -#: utils/timesince.py:47 -#, python-format -msgid ", %(number)d %(type)s" -msgstr ", %(number)d %(type)s" +#: conf/global_settings.py:63 +msgid "Dutch" +msgstr "Holandès" -#: utils/translation/trans_real.py:358 -msgid "DATE_FORMAT" -msgstr "F j, Y" +#: conf/global_settings.py:64 +msgid "Norwegian" +msgstr "Norueg" -#: utils/translation/trans_real.py:359 -msgid "DATETIME_FORMAT" -msgstr "F j, Y, H:i" +#: conf/global_settings.py:65 +msgid "Polish" +msgstr "Polac" -#: utils/translation/trans_real.py:360 -msgid "TIME_FORMAT" -msgstr "H:i" +#: conf/global_settings.py:66 +msgid "Portugese" +msgstr "Portuguès" -#: utils/translation/trans_real.py:376 -msgid "YEAR_MONTH_FORMAT" -msgstr "j de/d' F del Y" +#: conf/global_settings.py:67 +msgid "Brazilian" +msgstr "Brasileny" -#: utils/translation/trans_real.py:377 -msgid "MONTH_DAY_FORMAT" -msgstr "j de/d' F del Y" +#: conf/global_settings.py:68 +msgid "Romanian" +msgstr "Rumanès" -#: template/defaultfilters.py:491 -msgid "yes,no,maybe" -msgstr "si,no,potser" +#: conf/global_settings.py:69 +msgid "Russian" +msgstr "Rús" -#: template/defaultfilters.py:520 -#, python-format -msgid "%(size)d byte" -msgid_plural "%(size)d bytes" -msgstr[0] "%(size)d byte" -msgstr[1] "%(size)d bytes" +#: conf/global_settings.py:70 +msgid "Slovak" +msgstr "Eslovac" -#: template/defaultfilters.py:522 -#, python-format -msgid "%.1f KB" -msgstr "%.1f KB" +#: conf/global_settings.py:71 +msgid "Slovenian" +msgstr "Esloveni" -#: template/defaultfilters.py:524 -#, python-format -msgid "%.1f MB" -msgstr "%.1f MB" +#: conf/global_settings.py:72 +msgid "Serbian" +msgstr "Serbi" -#: template/defaultfilters.py:525 -#, python-format -msgid "%.1f GB" -msgstr "%.1f GB" +#: conf/global_settings.py:73 +msgid "Swedish" +msgstr "Suec" + +#: conf/global_settings.py:74 +msgid "Tamil" +msgstr "" + +#: conf/global_settings.py:75 +msgid "Telugu" +msgstr "" + +#: conf/global_settings.py:76 +msgid "Turkish" +msgstr "Turc" + +#: conf/global_settings.py:77 +msgid "Ukrainian" +msgstr "Ucranià" + +#: conf/global_settings.py:78 +msgid "Simplified Chinese" +msgstr "Xinés simplificat" + +#: conf/global_settings.py:79 +msgid "Traditional Chinese" +msgstr "Xinés tradicional" #: contrib/comments/models.py:67 contrib/comments/models.py:166 msgid "object ID" @@ -346,7 +370,7 @@ msgstr "data/hora d'enviament" msgid "is public" msgstr "és públic" -#: contrib/comments/models.py:85 contrib/admin/views/doc.py:304 +#: contrib/comments/models.py:85 contrib/admin/views/doc.py:305 msgid "IP address" msgstr "Adreça IP" @@ -471,6 +495,75 @@ msgstr "eliminacions del moderador" msgid "Moderator deletion by %r" msgstr "eliminació del moderador per %r" +#: contrib/comments/templates/comments/freeform.html:4 +msgid "Your name:" +msgstr "El seu nom:" + +#: contrib/comments/templates/comments/freeform.html:5 +#: contrib/comments/templates/comments/form.html:28 +msgid "Comment:" +msgstr "Comentari:" + +#: contrib/comments/templates/comments/freeform.html:10 +#: contrib/comments/templates/comments/form.html:35 +msgid "Preview comment" +msgstr "Previsualitzar comentari" + +#: contrib/comments/templates/comments/form.html:6 +#: contrib/comments/templates/comments/form.html:8 +#: contrib/admin/templates/admin/login.html:17 +msgid "Username:" +msgstr "Usuari:" + +#: contrib/comments/templates/comments/form.html:6 +#: contrib/admin/templates/admin/object_history.html:3 +#: contrib/admin/templates/admin/delete_confirmation.html:3 +#: contrib/admin/templates/admin/change_form.html:10 +#: contrib/admin/templates/admin/change_list.html:5 +#: contrib/admin/templates/admin/base.html:25 +#: contrib/admin/templates/admin/auth/user/change_password.html:9 +#: contrib/admin/templates/registration/password_change_form.html:3 +#: contrib/admin/templates/registration/password_change_done.html:3 +#: contrib/admin/templates/admin_doc/bookmarklets.html:4 +#: contrib/admin/templates/admin_doc/template_tag_index.html:5 +#: contrib/admin/templates/admin_doc/view_detail.html:4 +#: contrib/admin/templates/admin_doc/missing_docutils.html:4 +#: contrib/admin/templates/admin_doc/model_index.html:5 +#: contrib/admin/templates/admin_doc/index.html:4 +#: contrib/admin/templates/admin_doc/template_filter_index.html:5 +#: contrib/admin/templates/admin_doc/model_detail.html:3 +#: contrib/admin/templates/admin_doc/template_detail.html:4 +#: contrib/admin/templates/admin_doc/view_index.html:5 +msgid "Log out" +msgstr "Finalitzar sessió" + +#: contrib/comments/templates/comments/form.html:8 +#: contrib/admin/templates/admin/login.html:20 +msgid "Password:" +msgstr "Contrasenya:" + +#: contrib/comments/templates/comments/form.html:8 +msgid "Forgotten your password?" +msgstr "Contrasenya oblidada?" + +#: contrib/comments/templates/comments/form.html:12 +msgid "Ratings" +msgstr "Qualificacions" + +#: contrib/comments/templates/comments/form.html:12 +#: contrib/comments/templates/comments/form.html:23 +msgid "Required" +msgstr "Requerit" + +#: contrib/comments/templates/comments/form.html:12 +#: contrib/comments/templates/comments/form.html:23 +msgid "Optional" +msgstr "Opcional" + +#: contrib/comments/templates/comments/form.html:23 +msgid "Post a photo" +msgstr "Enviar una fotografia" + #: contrib/comments/views/comments.py:27 msgid "" "This rating is required because you've entered at least one other rating." @@ -553,107 +646,6 @@ msgstr "ID del comentari invàlid" msgid "No voting for yourself" msgstr "No pots votar-te a tu mateix" -#: contrib/comments/templates/comments/form.html:6 -#: contrib/comments/templates/comments/form.html:8 -#: contrib/admin/templates/admin/login.html:17 -msgid "Username:" -msgstr "Usuari:" - -#: contrib/comments/templates/comments/form.html:6 -#: contrib/admin/templates/admin/change_form.html:10 -#: contrib/admin/templates/admin/change_list.html:5 -#: contrib/admin/templates/admin/delete_confirmation.html:3 -#: contrib/admin/templates/admin/object_history.html:3 -#: contrib/admin/templates/admin/base.html:25 -#: contrib/admin/templates/admin/auth/user/change_password.html:9 -#: contrib/admin/templates/admin_doc/missing_docutils.html:4 -#: contrib/admin/templates/admin_doc/template_detail.html:4 -#: contrib/admin/templates/admin_doc/view_detail.html:4 -#: contrib/admin/templates/admin_doc/view_index.html:5 -#: contrib/admin/templates/admin_doc/index.html:4 -#: contrib/admin/templates/admin_doc/template_tag_index.html:5 -#: contrib/admin/templates/admin_doc/bookmarklets.html:4 -#: contrib/admin/templates/admin_doc/model_index.html:5 -#: contrib/admin/templates/admin_doc/template_filter_index.html:5 -#: contrib/admin/templates/admin_doc/model_detail.html:3 -#: contrib/admin/templates/registration/password_change_form.html:3 -#: contrib/admin/templates/registration/password_change_done.html:3 -msgid "Log out" -msgstr "Finalitzar sessió" - -#: contrib/comments/templates/comments/form.html:8 -#: contrib/admin/templates/admin/login.html:20 -msgid "Password:" -msgstr "Contrasenya:" - -#: contrib/comments/templates/comments/form.html:8 -msgid "Forgotten your password?" -msgstr "Contrasenya oblidada?" - -#: contrib/comments/templates/comments/form.html:12 -msgid "Ratings" -msgstr "Qualificacions" - -#: contrib/comments/templates/comments/form.html:12 -#: contrib/comments/templates/comments/form.html:23 -msgid "Required" -msgstr "Requerit" - -#: contrib/comments/templates/comments/form.html:12 -#: contrib/comments/templates/comments/form.html:23 -msgid "Optional" -msgstr "Opcional" - -#: contrib/comments/templates/comments/form.html:23 -msgid "Post a photo" -msgstr "Enviar una fotografia" - -#: contrib/comments/templates/comments/form.html:28 -#: contrib/comments/templates/comments/freeform.html:5 -msgid "Comment:" -msgstr "Comentari:" - -#: contrib/comments/templates/comments/form.html:35 -#: contrib/comments/templates/comments/freeform.html:10 -msgid "Preview comment" -msgstr "Previsualitzar comentari" - -#: contrib/comments/templates/comments/freeform.html:4 -msgid "Your name:" -msgstr "El seu nom:" - -#: contrib/redirects/models.py:7 -msgid "redirect from" -msgstr "redreçar des de" - -#: contrib/redirects/models.py:8 -msgid "" -"This should be an absolute path, excluding the domain name. Example: '/" -"events/search/'." -msgstr "" -"Aquesta ruta hauria de ser el camí absolut, excloent-ne el nom del domini. " -"Exemple '/events/search/'." - -#: contrib/redirects/models.py:9 -msgid "redirect to" -msgstr "redreçar a" - -#: contrib/redirects/models.py:10 -msgid "" -"This can be either an absolute path (as above) or a full URL starting with " -"'http://'." -msgstr "" -"Això pot ser bé una ruta absoluta (com abans) o una URL completa que comenci " -"per http:// ." - -#: contrib/redirects/models.py:13 -msgid "redirect" -msgstr "redreçament" - -#: contrib/redirects/models.py:14 -msgid "redirects" -msgstr "redreçaments" - #: contrib/admin/models.py:16 msgid "action time" msgstr "moment de l'acció" @@ -716,384 +708,160 @@ msgstr "Aquest mes" msgid "This year" msgstr "Aquest any" -#: contrib/admin/filterspecs.py:143 newforms/widgets.py:182 -#: oldforms/__init__.py:577 -msgid "Yes" -msgstr "Si" - -#: contrib/admin/filterspecs.py:143 newforms/widgets.py:182 -#: oldforms/__init__.py:577 -msgid "No" -msgstr "No" - -#: contrib/admin/filterspecs.py:150 newforms/widgets.py:182 -#: oldforms/__init__.py:577 -msgid "Unknown" -msgstr "Desconegut" - -#: contrib/admin/templatetags/admin_list.py:247 +#: contrib/admin/templatetags/admin_list.py:249 msgid "All dates" msgstr "Totes les dates" -#: contrib/admin/views/doc.py:46 contrib/admin/views/doc.py:48 -#: contrib/admin/views/doc.py:50 -msgid "tag:" -msgstr "etiqueta:" - -#: contrib/admin/views/doc.py:77 contrib/admin/views/doc.py:79 -#: contrib/admin/views/doc.py:81 -msgid "filter:" -msgstr "filtre:" - -#: contrib/admin/views/doc.py:135 contrib/admin/views/doc.py:137 -#: contrib/admin/views/doc.py:139 -msgid "view:" -msgstr "vista:" - -#: contrib/admin/views/doc.py:164 -#, python-format -msgid "App %r not found" -msgstr "La aplicació %r no s'ha pogut trobar" - -#: contrib/admin/views/doc.py:171 -#, python-format -msgid "Model %(name)r not found in app %(label)r" -msgstr "El model %(name)r no s'ha trobat en la aplicació %(label)r" - -#: contrib/admin/views/doc.py:183 -#, python-format -msgid "the related `%(label)s.%(type)s` object" -msgstr "el objecte relacionat `%(label)s.%(type)s`" - -#: contrib/admin/views/doc.py:183 contrib/admin/views/doc.py:205 -#: contrib/admin/views/doc.py:219 contrib/admin/views/doc.py:224 -msgid "model:" -msgstr "model:" - -#: contrib/admin/views/doc.py:214 -#, python-format -msgid "related `%(label)s.%(name)s` objects" -msgstr "objectes relacionats `%(label)s.%(name)s`" - -#: contrib/admin/views/doc.py:219 -#, python-format -msgid "all %s" -msgstr "tots %s" - -#: contrib/admin/views/doc.py:224 -#, python-format -msgid "number of %s" -msgstr "nombre de %s" - -#: contrib/admin/views/doc.py:229 -#, python-format -msgid "Fields on %s objects" -msgstr "Camps en objectes %s" - -#: contrib/admin/views/doc.py:291 contrib/admin/views/doc.py:301 -#: contrib/admin/views/doc.py:303 contrib/admin/views/doc.py:309 -#: contrib/admin/views/doc.py:310 contrib/admin/views/doc.py:312 -msgid "Integer" -msgstr "Enter" - -#: contrib/admin/views/doc.py:292 -msgid "Boolean (Either True or False)" -msgstr "Booleà (Verdader o Fals)" - -#: contrib/admin/views/doc.py:293 contrib/admin/views/doc.py:311 -#, python-format -msgid "String (up to %(maxlength)s)" -msgstr "Cadena (fins a %(maxlength)s)" - -#: contrib/admin/views/doc.py:294 -msgid "Comma-separated integers" -msgstr "Enters separats per comes" - -#: contrib/admin/views/doc.py:295 -msgid "Date (without time)" -msgstr "Data (sense hora)" - -#: contrib/admin/views/doc.py:296 -msgid "Date (with time)" -msgstr "Data (amb hora)" - -#: contrib/admin/views/doc.py:297 -msgid "E-mail address" -msgstr "Adreça de correu electrònic" - -#: contrib/admin/views/doc.py:298 contrib/admin/views/doc.py:299 -#: contrib/admin/views/doc.py:302 -msgid "File path" -msgstr "Ruta del fitxer" - -#: contrib/admin/views/doc.py:300 -msgid "Decimal number" -msgstr "Número decimal" - -#: contrib/admin/views/doc.py:306 -msgid "Boolean (Either True, False or None)" -msgstr "Booleà (Verdader, Fals o 'None' (cap))" - -#: contrib/admin/views/doc.py:307 -msgid "Relation to parent model" -msgstr "Relació amb el model pare" - -#: contrib/admin/views/doc.py:308 -msgid "Phone number" -msgstr "Número de telèfon" - -#: contrib/admin/views/doc.py:313 -msgid "Text" -msgstr "Texte" - -#: contrib/admin/views/doc.py:314 -msgid "Time" -msgstr "Hora" - -#: contrib/admin/views/doc.py:315 contrib/flatpages/models.py:7 -msgid "URL" -msgstr "URL" - -#: contrib/admin/views/doc.py:316 -msgid "U.S. state (two uppercase letters)" -msgstr "Estat dels E.U.A. (dos lletres majúscules)" - -#: contrib/admin/views/doc.py:317 -msgid "XML text" -msgstr "Texte XML" - -#: contrib/admin/views/doc.py:343 -#, python-format -msgid "%s does not appear to be a urlpattern object" -msgstr "%s no sembla ser un objecte 'urlpattern'" - -#: contrib/admin/views/decorators.py:10 contrib/auth/forms.py:60 -msgid "" -"Please enter a correct username and password. Note that both fields are case-" -"sensitive." -msgstr "" -"Si us plau, introdueixi un nom d'usuari i contrasenya vàlids. Tingui en " -"compte que tots dos camps son sensibles a majúscules i minúscules." - -#: contrib/admin/views/decorators.py:24 -#: contrib/admin/templates/admin/login.html:25 -msgid "Log in" -msgstr "Iniciar sessió" - -#: contrib/admin/views/decorators.py:62 -msgid "" -"Please log in again, because your session has expired. Don't worry: Your " -"submission has been saved." -msgstr "" -"Si us plau, identifiquis de nou doncs la seva sessió ha expirat. No es " -"preocupi, el seu enviament està emmagatzemat." - -#: contrib/admin/views/decorators.py:69 -msgid "" -"Looks like your browser isn't configured to accept cookies. Please enable " -"cookies, reload this page, and try again." -msgstr "" -"Sembla ser que el seu navegador no està configurat per acceptar " -"'cookies' (galetes). Si us plau, habiliti les 'cookies', recarregui aquesta " -"pàgina i provi-ho de nou. " - -#: contrib/admin/views/decorators.py:83 -msgid "Usernames cannot contain the '@' character." -msgstr "Els noms d'usuari no poden contenir el caracter '@'." - -#: contrib/admin/views/decorators.py:85 -#, python-format -msgid "Your e-mail address is not your username. Try '%s' instead." -msgstr "" -"La seva adreça de correu no és el seu nom d'usuari. Provi '%s' en tot cas." - -#: contrib/admin/views/auth.py:19 contrib/admin/views/main.py:257 -#, python-format -msgid "The %(name)s \"%(obj)s\" was added successfully." -msgstr "El/la %(name)s \"%(obj)s\".ha estat agregat/da amb èxit." - -#: contrib/admin/views/auth.py:24 contrib/admin/views/main.py:261 -#: contrib/admin/views/main.py:347 -msgid "You may edit it again below." -msgstr "Pot editar-lo de nou abaix." - -#: contrib/admin/views/auth.py:30 -msgid "Add user" -msgstr "Agregar usuari" - -#: contrib/admin/views/auth.py:57 -msgid "Password changed successfully." -msgstr "Canvi de clau exitós" - -#: contrib/admin/views/auth.py:64 -#, python-format -msgid "Change password: %s" -msgstr "Canviar clau: %s" - -#: contrib/admin/views/main.py:223 -msgid "Site administration" -msgstr "Lloc administratiu" - -#: contrib/admin/views/main.py:271 contrib/admin/views/main.py:356 -#, python-format -msgid "You may add another %s below." -msgstr "Pot agregar un altre %s abaix." - -#: contrib/admin/views/main.py:289 -#, python-format -msgid "Add %s" -msgstr "Agregar %s" - -#: contrib/admin/views/main.py:335 -#, python-format -msgid "Added %s." -msgstr "Agregat %s." - -#: contrib/admin/views/main.py:335 contrib/admin/views/main.py:337 -#: contrib/admin/views/main.py:339 db/models/manipulators.py:308 -msgid "and" -msgstr "i" - -#: contrib/admin/views/main.py:337 -#, python-format -msgid "Changed %s." -msgstr "Modificat %s." - -#: contrib/admin/views/main.py:339 -#, python-format -msgid "Deleted %s." -msgstr "Eliminat %s." - -#: contrib/admin/views/main.py:342 -msgid "No fields changed." -msgstr "Cap camp canviat." - -#: contrib/admin/views/main.py:345 -#, python-format -msgid "The %(name)s \"%(obj)s\" was changed successfully." -msgstr "S'ha modificat amb èxist el/la %(name)s \"%(obj)s." - -#: contrib/admin/views/main.py:353 -#, python-format -msgid "" -"The %(name)s \"%(obj)s\" was added successfully. You may edit it again below." -msgstr "" -"S'ha agregat amb èxit el/la %(name)s \"%(obj)s\". Pot editar-lo de nou abaix." - -#: contrib/admin/views/main.py:391 -#, python-format -msgid "Change %s" -msgstr "Modificar %s" - -#: contrib/admin/views/main.py:476 -#, python-format -msgid "One or more %(fieldname)s in %(name)s: %(obj)s" -msgstr "Un o més %(fieldname)s en %(name)s: %(obj)s" - -#: contrib/admin/views/main.py:481 -#, python-format -msgid "One or more %(fieldname)s in %(name)s:" -msgstr "Un o més %(fieldname)s en %(name)s:" - -#: contrib/admin/views/main.py:514 -#, python-format -msgid "The %(name)s \"%(obj)s\" was deleted successfully." -msgstr "El/la %(name)s \"%(obj)s\".ha estat eliminat amb èxit." - -#: contrib/admin/views/main.py:517 -msgid "Are you sure?" -msgstr "Està segur?" - -#: contrib/admin/views/main.py:539 -#, python-format -msgid "Change history: %s" -msgstr "Modificar històric: %s" - -#: contrib/admin/views/main.py:573 -#, python-format -msgid "Select %s" -msgstr "Seleccioni %s" - -#: contrib/admin/views/main.py:573 -#, python-format -msgid "Select %s to change" -msgstr "Seleccioni %s per modificar" - -#: contrib/admin/views/main.py:768 -msgid "Database error" -msgstr "Error de/en la base de dades" - -#: contrib/admin/templates/admin/filter.html:2 -#, python-format -msgid " By %(filter_title)s " -msgstr "Per %(filter_title)s " - -#: contrib/admin/templates/admin/filters.html:4 -msgid "Filter" -msgstr "Filtre" - +#: contrib/admin/templates/admin/object_history.html:3 +#: contrib/admin/templates/admin/delete_confirmation.html:3 #: contrib/admin/templates/admin/change_form.html:10 #: contrib/admin/templates/admin/change_list.html:5 -#: contrib/admin/templates/admin/delete_confirmation.html:3 -#: contrib/admin/templates/admin/object_history.html:3 #: contrib/admin/templates/admin/base.html:25 #: contrib/admin/templates/admin/auth/user/change_password.html:9 -#: contrib/admin/templates/admin_doc/bookmarklets.html:3 #: contrib/admin/templates/registration/password_change_form.html:3 #: contrib/admin/templates/registration/password_change_done.html:3 +#: contrib/admin/templates/admin_doc/bookmarklets.html:3 msgid "Documentation" msgstr "Documentació" +#: contrib/admin/templates/admin/object_history.html:3 +#: contrib/admin/templates/admin/delete_confirmation.html:3 #: contrib/admin/templates/admin/change_form.html:10 #: contrib/admin/templates/admin/change_list.html:5 -#: contrib/admin/templates/admin/delete_confirmation.html:3 -#: contrib/admin/templates/admin/object_history.html:3 #: contrib/admin/templates/admin/base.html:25 #: contrib/admin/templates/admin/auth/user/change_password.html:9 #: contrib/admin/templates/admin/auth/user/change_password.html:15 #: contrib/admin/templates/admin/auth/user/change_password.html:46 -#: contrib/admin/templates/admin_doc/missing_docutils.html:4 -#: contrib/admin/templates/admin_doc/template_detail.html:4 -#: contrib/admin/templates/admin_doc/view_detail.html:4 -#: contrib/admin/templates/admin_doc/view_index.html:5 -#: contrib/admin/templates/admin_doc/index.html:4 -#: contrib/admin/templates/admin_doc/template_tag_index.html:5 +#: contrib/admin/templates/registration/password_change_form.html:3 +#: contrib/admin/templates/registration/password_change_done.html:3 #: contrib/admin/templates/admin_doc/bookmarklets.html:4 +#: contrib/admin/templates/admin_doc/template_tag_index.html:5 +#: contrib/admin/templates/admin_doc/view_detail.html:4 +#: contrib/admin/templates/admin_doc/missing_docutils.html:4 #: contrib/admin/templates/admin_doc/model_index.html:5 +#: contrib/admin/templates/admin_doc/index.html:4 #: contrib/admin/templates/admin_doc/template_filter_index.html:5 #: contrib/admin/templates/admin_doc/model_detail.html:3 -#: contrib/admin/templates/registration/password_change_form.html:3 -#: contrib/admin/templates/registration/password_change_done.html:3 +#: contrib/admin/templates/admin_doc/template_detail.html:4 +#: contrib/admin/templates/admin_doc/view_index.html:5 msgid "Change password" msgstr "Canviar clau" +#: contrib/admin/templates/admin/object_history.html:5 +#: contrib/admin/templates/admin/invalid_setup.html:4 +#: contrib/admin/templates/admin/delete_confirmation.html:6 #: contrib/admin/templates/admin/change_form.html:13 -#: contrib/admin/templates/admin/change_list.html:6 #: contrib/admin/templates/admin/500.html:4 -#: contrib/admin/templates/admin/delete_confirmation.html:6 -#: contrib/admin/templates/admin/object_history.html:5 +#: contrib/admin/templates/admin/change_list.html:6 #: contrib/admin/templates/admin/base.html:30 -#: contrib/admin/templates/admin/invalid_setup.html:4 #: contrib/admin/templates/admin/auth/user/change_password.html:12 -#: contrib/admin/templates/admin_doc/bookmarklets.html:3 -#: contrib/admin/templates/registration/password_reset_form.html:4 -#: contrib/admin/templates/registration/password_reset_done.html:4 +#: contrib/admin/templates/registration/logged_out.html:4 #: contrib/admin/templates/registration/password_change_form.html:4 +#: contrib/admin/templates/registration/password_reset_done.html:4 #: contrib/admin/templates/registration/password_change_done.html:4 -#: contrib/admin/templates/registration/logged_out.html:4 +#: contrib/admin/templates/registration/password_reset_form.html:4 +#: contrib/admin/templates/admin_doc/bookmarklets.html:3 msgid "Home" msgstr "Inici" +#: contrib/admin/templates/admin/object_history.html:5 +#: contrib/admin/templates/admin/change_form.html:21 +msgid "History" +msgstr "Històric" + +#: contrib/admin/templates/admin/object_history.html:18 +msgid "Date/time" +msgstr "Data/hora" + +#: contrib/admin/templates/admin/object_history.html:19 +msgid "User" +msgstr "Usuari" + +#: contrib/admin/templates/admin/object_history.html:20 +msgid "Action" +msgstr "Acció" + +#: contrib/admin/templates/admin/object_history.html:26 +msgid "DATE_WITH_TIME_FULL" +msgstr "F j, Y, H:i " + +#: contrib/admin/templates/admin/object_history.html:36 +msgid "" +"This object doesn't have a change history. It probably wasn't added via this " +"admin site." +msgstr "" +"Aquest objecte no te historial de canvis. Probablement no va ser afegit " +"utilitzant aquest lloc administratiu." + +#: contrib/admin/templates/admin/invalid_setup.html:8 +msgid "" +"Something's wrong with your database installation. Make sure the appropriate " +"database tables have been created, and make sure the database is readable by " +"the appropriate user." +msgstr "" +"Alguna cosa està malament en la instal·lació de la teva base de dades. " +"Assegurat de que s'han creat les taules, i de que la base de dades és " +"llegible per l'usuari apropiat." + +#: contrib/admin/templates/admin/search_form.html:8 +msgid "Go" +msgstr "Cercar" + +#: contrib/admin/templates/admin/search_form.html:10 +#, python-format +msgid "1 result" +msgid_plural "%(counter)s results" +msgstr[0] "1 resultat" +msgstr[1] "%(counter)s resultats" + +#: contrib/admin/templates/admin/search_form.html:10 +#, python-format +msgid "%(full_result_count)s total" +msgstr "%(full_result_count)s en total" + +#: contrib/admin/templates/admin/delete_confirmation.html:9 +#: contrib/admin/templates/admin/submit_line.html:3 +msgid "Delete" +msgstr "Eliminar" + +#: contrib/admin/templates/admin/delete_confirmation.html:14 +#, python-format +msgid "" +"Deleting the %(object_name)s '%(escaped_object)s' would result in deleting " +"related objects, but your account doesn't have permission to delete the " +"following types of objects:" +msgstr "" +"Eliminar el/la %(object_name)s '%(escaped_object)s' provocaria l'eliminació " +"d'objectes relacionats, però el seu compte no te permisos per a esborrar els " +"tipus d'objecte següents:" + +#: contrib/admin/templates/admin/delete_confirmation.html:21 +#, python-format +msgid "" +"Are you sure you want to delete the %(object_name)s \"%(escaped_object)s\"? " +"All of the following related items will be deleted:" +msgstr "" +"Està segur de voler esborrar els/les %(object_name)s \"%(escaped_object)s\"? " +"S'esborraran els següents elements relacionats:" + +#: contrib/admin/templates/admin/delete_confirmation.html:26 +msgid "Yes, I'm sure" +msgstr "Si, estic segur" + +#: contrib/admin/templates/admin/pagination.html:10 +msgid "Show all" +msgstr "Mostrar tots" + +#: contrib/admin/templates/admin/login.html:25 +#: contrib/admin/views/decorators.py:24 +msgid "Log in" +msgstr "Iniciar sessió" + #: contrib/admin/templates/admin/change_form.html:15 #: contrib/admin/templates/admin/index.html:28 msgid "Add" msgstr "Afegir" -#: contrib/admin/templates/admin/change_form.html:21 -#: contrib/admin/templates/admin/object_history.html:5 -msgid "History" -msgstr "Històric" - #: contrib/admin/templates/admin/change_form.html:22 msgid "View on site" msgstr "Veure en el lloc" @@ -1113,44 +881,35 @@ msgstr "Ordre" msgid "Order:" msgstr "Ordre:" -#: contrib/admin/templates/admin/change_list.html:12 +#: contrib/admin/templates/admin/index.html:17 #, python-format -msgid "Add %(name)s" -msgstr "Afegir %(name)s" - -#: contrib/admin/templates/admin/submit_line.html:3 -#: contrib/admin/templates/admin/delete_confirmation.html:9 -msgid "Delete" -msgstr "Eliminar" - -#: contrib/admin/templates/admin/submit_line.html:4 -msgid "Save as new" -msgstr "Desar com a nou" +msgid "Models available in the %(name)s application." +msgstr "Models disponibles en la aplicació %(name)s." -#: contrib/admin/templates/admin/submit_line.html:5 -msgid "Save and add another" -msgstr "Desar i afegir-ne un de nou" +#: contrib/admin/templates/admin/index.html:18 +#, python-format +msgid "%(name)s" +msgstr "%(name)s" -#: contrib/admin/templates/admin/submit_line.html:6 -msgid "Save and continue editing" -msgstr "Desar i continuar editant" +#: contrib/admin/templates/admin/index.html:34 +msgid "Change" +msgstr "Modificar" -#: contrib/admin/templates/admin/submit_line.html:7 -msgid "Save" -msgstr "Desar" +#: contrib/admin/templates/admin/index.html:44 +msgid "You don't have permission to edit anything." +msgstr "No té permís per editar res." -#: contrib/admin/templates/admin/404.html:4 -#: contrib/admin/templates/admin/404.html:8 -msgid "Page not found" -msgstr "No s'ha pogut trobar la pàgina" +#: contrib/admin/templates/admin/index.html:52 +msgid "Recent Actions" +msgstr "Accions recents" -#: contrib/admin/templates/admin/404.html:10 -msgid "We're sorry, but the requested page could not be found." -msgstr "Ho sentim, però no s'ha pogut trobar la pàgina solicitada" +#: contrib/admin/templates/admin/index.html:53 +msgid "My Actions" +msgstr "Les meves accions" -#: contrib/admin/templates/admin/pagination.html:10 -msgid "Show all" -msgstr "Mostrar tots" +#: contrib/admin/templates/admin/index.html:57 +msgid "None available" +msgstr "Cap disponible" #: contrib/admin/templates/admin/500.html:4 msgid "Server error" @@ -1172,6 +931,15 @@ msgstr "" "Hi ha hagut un error. S'ha informat als administradors del lloc per correu " "electrònic y hauria d'arreglar-se en breu. Gràcies per la seva paciència." +#: contrib/admin/templates/admin/change_list.html:12 +#, python-format +msgid "Add %(name)s" +msgstr "Afegir %(name)s" + +#: contrib/admin/templates/admin/base.html:25 +msgid "Welcome," +msgstr "Benvingut," + #: contrib/admin/templates/admin/base_site.html:4 msgid "Django site admin" msgstr "Lloc administratiu de Django" @@ -1180,145 +948,205 @@ msgstr "Lloc administratiu de Django" msgid "Django administration" msgstr "Adminsitració de Django" -#: contrib/admin/templates/admin/search_form.html:8 -msgid "Go" -msgstr "Cercar" +#: contrib/admin/templates/admin/filters.html:4 +msgid "Filter" +msgstr "Filtre" -#: contrib/admin/templates/admin/search_form.html:10 -#, python-format -msgid "1 result" -msgid_plural "%(counter)s results" -msgstr[0] "1 resultat" -msgstr[1] "%(counter)s resultats" +#: contrib/admin/templates/admin/submit_line.html:4 +msgid "Save as new" +msgstr "Desar com a nou" -#: contrib/admin/templates/admin/search_form.html:10 -#, python-format -msgid "%(full_result_count)s total" -msgstr "%(full_result_count)s en total" +#: contrib/admin/templates/admin/submit_line.html:5 +msgid "Save and add another" +msgstr "Desar i afegir-ne un de nou" -#: contrib/admin/templates/admin/index.html:17 -#, python-format -msgid "Models available in the %(name)s application." -msgstr "Models disponibles en la aplicació %(name)s." +#: contrib/admin/templates/admin/submit_line.html:6 +msgid "Save and continue editing" +msgstr "Desar i continuar editant" -#: contrib/admin/templates/admin/index.html:18 +#: contrib/admin/templates/admin/submit_line.html:7 +msgid "Save" +msgstr "Desar" + +#: contrib/admin/templates/admin/404.html:4 +#: contrib/admin/templates/admin/404.html:8 +msgid "Page not found" +msgstr "No s'ha pogut trobar la pàgina" + +#: contrib/admin/templates/admin/404.html:10 +msgid "We're sorry, but the requested page could not be found." +msgstr "Ho sentim, però no s'ha pogut trobar la pàgina solicitada" + +#: contrib/admin/templates/admin/filter.html:2 #, python-format -msgid "%(name)s" -msgstr "%(name)s" +msgid " By %(filter_title)s " +msgstr "Per %(filter_title)s " -#: contrib/admin/templates/admin/index.html:34 -msgid "Change" -msgstr "Modificar" +#: contrib/admin/templates/admin/auth/user/add_form.html:6 +msgid "" +"First, enter a username and password. Then, you'll be able to edit more user " +"options." +msgstr "" +"Primer, entri un usuari i una contrasenya. Després podrà editar més opcions " +"del usuari." -#: contrib/admin/templates/admin/index.html:44 -msgid "You don't have permission to edit anything." -msgstr "No té permís per editar res." +#: contrib/admin/templates/admin/auth/user/add_form.html:12 +msgid "Username" +msgstr "Usuari" -#: contrib/admin/templates/admin/index.html:52 -msgid "Recent Actions" -msgstr "Accions recents" +#: contrib/admin/templates/admin/auth/user/add_form.html:18 +#: contrib/admin/templates/admin/auth/user/change_password.html:34 +msgid "Password" +msgstr "Contrasenya" -#: contrib/admin/templates/admin/index.html:53 -msgid "My Actions" -msgstr "Les meves accions" +#: contrib/admin/templates/admin/auth/user/add_form.html:23 +#: contrib/admin/templates/admin/auth/user/change_password.html:39 +msgid "Password (again)" +msgstr "Contrasenya (de nou)" -#: contrib/admin/templates/admin/index.html:57 -msgid "None available" -msgstr "Cap disponible" +#: contrib/admin/templates/admin/auth/user/add_form.html:24 +#: contrib/admin/templates/admin/auth/user/change_password.html:40 +msgid "Enter the same password as above, for verification." +msgstr "Introdueixi la mateixa contrasenya que a sobre, per a verificació." -#: contrib/admin/templates/admin/delete_confirmation.html:14 +#: contrib/admin/templates/admin/auth/user/change_password.html:28 #, python-format -msgid "" -"Deleting the %(object_name)s '%(escaped_object)s' would result in deleting " -"related objects, but your account doesn't have permission to delete the " -"following types of objects:" -msgstr "" -"Eliminar el/la %(object_name)s '%(escaped_object)s' provocaria l'eliminació " -"d'objectes relacionats, però el seu compte no te permisos per a esborrar els " -"tipus d'objecte següents:" +msgid "Enter a new password for the user <strong>%(username)s</strong>." +msgstr "Introdueixi una contrasenya per l'usuari <strong>%(username)s</strong>" -#: contrib/admin/templates/admin/delete_confirmation.html:21 -#, python-format +#: contrib/admin/templates/widget/date_time.html:3 +msgid "Date:" +msgstr "Data:" + +#: contrib/admin/templates/widget/date_time.html:4 +msgid "Time:" +msgstr "Hora:" + +#: contrib/admin/templates/widget/file.html:2 +msgid "Currently:" +msgstr "Actualment:" + +#: contrib/admin/templates/widget/file.html:3 +msgid "Change:" +msgstr "Modificar:" + +#: contrib/admin/templates/registration/logged_out.html:8 +msgid "Thanks for spending some quality time with the Web site today." +msgstr "Gràcies per emprar algun temps de cualitat amb el lloc web avui." + +#: contrib/admin/templates/registration/logged_out.html:10 +msgid "Log in again" +msgstr "Iniciar sessió de nou" + +#: contrib/admin/templates/registration/password_change_form.html:4 +#: contrib/admin/templates/registration/password_change_form.html:6 +#: contrib/admin/templates/registration/password_change_form.html:10 +#: contrib/admin/templates/registration/password_change_done.html:4 +msgid "Password change" +msgstr "Canvi de clau" + +#: contrib/admin/templates/registration/password_change_form.html:12 msgid "" -"Are you sure you want to delete the %(object_name)s \"%(escaped_object)s\"? " -"All of the following related items will be deleted:" +"Please enter your old password, for security's sake, and then enter your new " +"password twice so we can verify you typed it in correctly." msgstr "" -"Està segur de voler esborrar els/les %(object_name)s \"%(escaped_object)s\"? " -"S'esborraran els següents elements relacionats:" +"Si us plau, introdueixi la seva contrasenya antiga, per seguretat, i tot " +"seguit introdueixi la seva nova contrasenya dues vegades per verificar que " +"l'ha escrit correctament." -#: contrib/admin/templates/admin/delete_confirmation.html:26 -msgid "Yes, I'm sure" -msgstr "Si, estic segur" +#: contrib/admin/templates/registration/password_change_form.html:17 +msgid "Old password:" +msgstr "Contrasenya antiga:" -#: contrib/admin/templates/admin/object_history.html:18 -msgid "Date/time" -msgstr "Data/hora" +#: contrib/admin/templates/registration/password_change_form.html:19 +msgid "New password:" +msgstr "Contrasenya nova:" -#: contrib/admin/templates/admin/object_history.html:19 -msgid "User" -msgstr "Usuari" +#: contrib/admin/templates/registration/password_change_form.html:21 +msgid "Confirm password:" +msgstr "Confirmar contrasenya:" -#: contrib/admin/templates/admin/object_history.html:20 -msgid "Action" -msgstr "Acció" +#: contrib/admin/templates/registration/password_change_form.html:23 +msgid "Change my password" +msgstr "Canviar la meva clau:" -#: contrib/admin/templates/admin/object_history.html:26 -msgid "DATE_WITH_TIME_FULL" -msgstr "F j, Y, H:i " +#: contrib/admin/templates/registration/password_reset_done.html:4 +#: contrib/admin/templates/registration/password_reset_form.html:4 +#: contrib/admin/templates/registration/password_reset_form.html:6 +#: contrib/admin/templates/registration/password_reset_form.html:10 +msgid "Password reset" +msgstr "Restablir contrasenya" -#: contrib/admin/templates/admin/object_history.html:36 +#: contrib/admin/templates/registration/password_reset_done.html:6 +#: contrib/admin/templates/registration/password_reset_done.html:10 +msgid "Password reset successful" +msgstr "Contrasenya restaber-ta amb èxit" + +#: contrib/admin/templates/registration/password_reset_done.html:12 msgid "" -"This object doesn't have a change history. It probably wasn't added via this " -"admin site." +"We've e-mailed a new password to the e-mail address you submitted. You " +"should be receiving it shortly." msgstr "" -"Aquest objecte no te historial de canvis. Probablement no va ser afegit " -"utilitzant aquest lloc administratiu." +"Li hem enviat una contrasenya nova a l'adreça de correu electrònic que ens " +"ha indicat. L'hauria de rebre en breu." -#: contrib/admin/templates/admin/base.html:25 -msgid "Welcome," -msgstr "Benvingut," +#: contrib/admin/templates/registration/password_change_done.html:6 +#: contrib/admin/templates/registration/password_change_done.html:10 +msgid "Password change successful" +msgstr "Canvi de clau exitò" -#: contrib/admin/templates/admin/invalid_setup.html:8 -msgid "" -"Something's wrong with your database installation. Make sure the appropriate " -"database tables have been created, and make sure the database is readable by " -"the appropriate user." +#: contrib/admin/templates/registration/password_change_done.html:12 +msgid "Your password was changed." +msgstr "La seva clau ha estat canviada." + +#: contrib/admin/templates/registration/password_reset_email.html:2 +msgid "You're receiving this e-mail because you requested a password reset" msgstr "" -"Alguna cosa està malament en la instal·lació de la teva base de dades. " -"Assegurat de que s'han creat les taules, i de que la base de dades és " -"llegible per l'usuari apropiat." +"Està rebent aquest missatge degut a que va solicitar un restabliment de " +"contrasenya." -#: contrib/admin/templates/admin/auth/user/change_password.html:28 +#: contrib/admin/templates/registration/password_reset_email.html:3 #, python-format -msgid "Enter a new password for the user <strong>%(username)s</strong>." -msgstr "Introdueixi una contrasenya per l'usuari <strong>%(username)s</strong>" +msgid "for your user account at %(site_name)s" +msgstr "del seu compte d'usuari a %(site_name)s." -#: contrib/admin/templates/admin/auth/user/change_password.html:34 -#: contrib/admin/templates/admin/auth/user/add_form.html:18 -msgid "Password" -msgstr "Contrasenya" +#: contrib/admin/templates/registration/password_reset_email.html:5 +#, python-format +msgid "Your new password is: %(new_password)s" +msgstr "La seva nova contrasenya és: %(new_password)s" -#: contrib/admin/templates/admin/auth/user/change_password.html:39 -#: contrib/admin/templates/admin/auth/user/add_form.html:23 -msgid "Password (again)" -msgstr "Contrasenya (de nou)" +#: contrib/admin/templates/registration/password_reset_email.html:7 +msgid "Feel free to change this password by going to this page:" +msgstr "Sentis lliure de canviar-la en aquesta pàgina:" -#: contrib/admin/templates/admin/auth/user/change_password.html:40 -#: contrib/admin/templates/admin/auth/user/add_form.html:24 -msgid "Enter the same password as above, for verification." -msgstr "Introdueixi la mateixa contrasenya que a sobre, per a verificació." +#: contrib/admin/templates/registration/password_reset_email.html:11 +msgid "Your username, in case you've forgotten:" +msgstr "El seu nom d'usuari, en cas d'haver-lo oblidat:" -#: contrib/admin/templates/admin/auth/user/add_form.html:6 +#: contrib/admin/templates/registration/password_reset_email.html:13 +msgid "Thanks for using our site!" +msgstr "Gràcies per fer us del nostre lloc!" + +#: contrib/admin/templates/registration/password_reset_email.html:15 +#, python-format +msgid "The %(site_name)s team" +msgstr "L'equip de %(site_name)s" + +#: contrib/admin/templates/registration/password_reset_form.html:12 msgid "" -"First, enter a username and password. Then, you'll be able to edit more user " -"options." +"Forgotten your password? Enter your e-mail address below, and we'll reset " +"your password and e-mail the new one to you." msgstr "" -"Primer, entri un usuari i una contrasenya. Després podrà editar més opcions " -"del usuari." +"Ha oblidat la seva contrasenya? Introdueixi la seva adreça de correu " +"electrònic i crearem una nova que li enviarem per correu." -#: contrib/admin/templates/admin/auth/user/add_form.html:12 -msgid "Username" -msgstr "Usuari" +#: contrib/admin/templates/registration/password_reset_form.html:16 +msgid "E-mail address:" +msgstr "Adreça de correu electrònic:" + +#: contrib/admin/templates/registration/password_reset_form.html:16 +msgid "Reset my password" +msgstr "Restablir la meva contrasenya" #: contrib/admin/templates/admin_doc/bookmarklets.html:3 msgid "Bookmarklets" @@ -1390,610 +1218,292 @@ msgstr "Editar aquest objecte (nova finestra)" msgid "As above, but opens the admin page in a new window." msgstr "Com abans, però obre la pàgina d'administració en una nova finestra." -#: contrib/admin/templates/widget/date_time.html:3 -msgid "Date:" -msgstr "Data:" - -#: contrib/admin/templates/widget/date_time.html:4 -msgid "Time:" -msgstr "Hora:" - -#: contrib/admin/templates/widget/file.html:2 -msgid "Currently:" -msgstr "Actualment:" +#: contrib/admin/views/auth.py:19 contrib/admin/views/main.py:257 +#, python-format +msgid "The %(name)s \"%(obj)s\" was added successfully." +msgstr "El/la %(name)s \"%(obj)s\".ha estat agregat/da amb èxit." -#: contrib/admin/templates/widget/file.html:3 -msgid "Change:" -msgstr "Modificar:" +#: contrib/admin/views/auth.py:24 contrib/admin/views/main.py:261 +#: contrib/admin/views/main.py:347 +msgid "You may edit it again below." +msgstr "Pot editar-lo de nou abaix." -#: contrib/admin/templates/registration/password_reset_email.html:2 -msgid "You're receiving this e-mail because you requested a password reset" -msgstr "" -"Està rebent aquest missatge degut a que va solicitar un restabliment de " -"contrasenya." +#: contrib/admin/views/auth.py:30 +msgid "Add user" +msgstr "Agregar usuari" -#: contrib/admin/templates/registration/password_reset_email.html:3 -#, python-format -msgid "for your user account at %(site_name)s" -msgstr "del seu compte d'usuari a %(site_name)s." +#: contrib/admin/views/auth.py:57 +msgid "Password changed successfully." +msgstr "Canvi de clau exitós" -#: contrib/admin/templates/registration/password_reset_email.html:5 +#: contrib/admin/views/auth.py:64 #, python-format -msgid "Your new password is: %(new_password)s" -msgstr "La seva nova contrasenya és: %(new_password)s" - -#: contrib/admin/templates/registration/password_reset_email.html:7 -msgid "Feel free to change this password by going to this page:" -msgstr "Sentis lliure de canviar-la en aquesta pàgina:" - -#: contrib/admin/templates/registration/password_reset_email.html:11 -msgid "Your username, in case you've forgotten:" -msgstr "El seu nom d'usuari, en cas d'haver-lo oblidat:" +msgid "Change password: %s" +msgstr "Canviar clau: %s" -#: contrib/admin/templates/registration/password_reset_email.html:13 -msgid "Thanks for using our site!" -msgstr "Gràcies per fer us del nostre lloc!" +#: contrib/admin/views/main.py:223 +msgid "Site administration" +msgstr "Lloc administratiu" -#: contrib/admin/templates/registration/password_reset_email.html:15 +#: contrib/admin/views/main.py:271 contrib/admin/views/main.py:356 #, python-format -msgid "The %(site_name)s team" -msgstr "L'equip de %(site_name)s" +msgid "You may add another %s below." +msgstr "Pot agregar un altre %s abaix." -#: contrib/admin/templates/registration/password_reset_form.html:4 -#: contrib/admin/templates/registration/password_reset_form.html:6 -#: contrib/admin/templates/registration/password_reset_form.html:10 -#: contrib/admin/templates/registration/password_reset_done.html:4 -msgid "Password reset" -msgstr "Restablir contrasenya" +#: contrib/admin/views/main.py:289 +#, python-format +msgid "Add %s" +msgstr "Agregar %s" -#: contrib/admin/templates/registration/password_reset_form.html:12 -msgid "" -"Forgotten your password? Enter your e-mail address below, and we'll reset " -"your password and e-mail the new one to you." -msgstr "" -"Ha oblidat la seva contrasenya? Introdueixi la seva adreça de correu " -"electrònic i crearem una nova que li enviarem per correu." +#: contrib/admin/views/main.py:335 +#, python-format +msgid "Added %s." +msgstr "Agregat %s." -#: contrib/admin/templates/registration/password_reset_form.html:16 -msgid "E-mail address:" -msgstr "Adreça de correu electrònic:" +#: contrib/admin/views/main.py:335 contrib/admin/views/main.py:337 +#: contrib/admin/views/main.py:339 db/models/manipulators.py:308 +msgid "and" +msgstr "i" -#: contrib/admin/templates/registration/password_reset_form.html:16 -msgid "Reset my password" -msgstr "Restablir la meva contrasenya" +#: contrib/admin/views/main.py:337 +#, python-format +msgid "Changed %s." +msgstr "Modificat %s." -#: contrib/admin/templates/registration/password_reset_done.html:6 -#: contrib/admin/templates/registration/password_reset_done.html:10 -msgid "Password reset successful" -msgstr "Contrasenya restaber-ta amb èxit" +#: contrib/admin/views/main.py:339 +#, python-format +msgid "Deleted %s." +msgstr "Eliminat %s." -#: contrib/admin/templates/registration/password_reset_done.html:12 -msgid "" -"We've e-mailed a new password to the e-mail address you submitted. You " -"should be receiving it shortly." -msgstr "" -"Li hem enviat una contrasenya nova a l'adreça de correu electrònic que ens " -"ha indicat. L'hauria de rebre en breu." +#: contrib/admin/views/main.py:342 +msgid "No fields changed." +msgstr "Cap camp canviat." -#: contrib/admin/templates/registration/password_change_form.html:4 -#: contrib/admin/templates/registration/password_change_form.html:6 -#: contrib/admin/templates/registration/password_change_form.html:10 -#: contrib/admin/templates/registration/password_change_done.html:4 -msgid "Password change" -msgstr "Canvi de clau" +#: contrib/admin/views/main.py:345 +#, python-format +msgid "The %(name)s \"%(obj)s\" was changed successfully." +msgstr "S'ha modificat amb èxist el/la %(name)s \"%(obj)s." -#: contrib/admin/templates/registration/password_change_form.html:12 +#: contrib/admin/views/main.py:353 +#, python-format msgid "" -"Please enter your old password, for security's sake, and then enter your new " -"password twice so we can verify you typed it in correctly." +"The %(name)s \"%(obj)s\" was added successfully. You may edit it again below." msgstr "" -"Si us plau, introdueixi la seva contrasenya antiga, per seguretat, i tot " -"seguit introdueixi la seva nova contrasenya dues vegades per verificar que " -"l'ha escrit correctament." - -#: contrib/admin/templates/registration/password_change_form.html:17 -msgid "Old password:" -msgstr "Contrasenya antiga:" - -#: contrib/admin/templates/registration/password_change_form.html:19 -msgid "New password:" -msgstr "Contrasenya nova:" - -#: contrib/admin/templates/registration/password_change_form.html:21 -msgid "Confirm password:" -msgstr "Confirmar contrasenya:" - -#: contrib/admin/templates/registration/password_change_form.html:23 -msgid "Change my password" -msgstr "Canviar la meva clau:" - -#: contrib/admin/templates/registration/password_change_done.html:6 -#: contrib/admin/templates/registration/password_change_done.html:10 -msgid "Password change successful" -msgstr "Canvi de clau exitò" - -#: contrib/admin/templates/registration/password_change_done.html:12 -msgid "Your password was changed." -msgstr "La seva clau ha estat canviada." - -#: contrib/admin/templates/registration/logged_out.html:8 -msgid "Thanks for spending some quality time with the Web site today." -msgstr "Gràcies per emprar algun temps de cualitat amb el lloc web avui." - -#: contrib/admin/templates/registration/logged_out.html:10 -msgid "Log in again" -msgstr "Iniciar sessió de nou" - -#: contrib/localflavor/fi/forms.py:14 contrib/localflavor/de/forms.py:16 -#: contrib/localflavor/fr/forms.py:17 -msgid "Enter a zip code in the format XXXXX." -msgstr "Introdueixi un codi zip en el format XXXXX." - -#: contrib/localflavor/fi/forms.py:40 contrib/localflavor/fi/forms.py:45 -msgid "Enter a valid Finnish social security number." -msgstr "Introdueixi un número vàlid de la seguretat social finlandesa." - -#: contrib/localflavor/jp/forms.py:21 -msgid "Enter a postal code in the format XXXXXXX or XXX-XXXX." -msgstr "Introdueixi un codi postal en el format XXXXXXX o XX-XXXX." - -#: contrib/localflavor/jp/jp_prefectures.py:4 -msgid "Hokkaido" -msgstr "Hokkaido" - -#: contrib/localflavor/jp/jp_prefectures.py:5 -msgid "Aomori" -msgstr "Aomori" - -#: contrib/localflavor/jp/jp_prefectures.py:6 -msgid "Iwate" -msgstr "Iwate" - -#: contrib/localflavor/jp/jp_prefectures.py:7 -msgid "Miyagi" -msgstr "Miyagi" - -#: contrib/localflavor/jp/jp_prefectures.py:8 -msgid "Akita" -msgstr "Akita" - -#: contrib/localflavor/jp/jp_prefectures.py:9 -msgid "Yamagata" -msgstr "Yamagata" - -#: contrib/localflavor/jp/jp_prefectures.py:10 -msgid "Fukushima" -msgstr "Fukushima" - -#: contrib/localflavor/jp/jp_prefectures.py:11 -msgid "Ibaraki" -msgstr "Ibaraki" - -#: contrib/localflavor/jp/jp_prefectures.py:12 -msgid "Tochigi" -msgstr "Tochigi" - -#: contrib/localflavor/jp/jp_prefectures.py:13 -msgid "Gunma" -msgstr "Gunma" - -#: contrib/localflavor/jp/jp_prefectures.py:14 -msgid "Saitama" -msgstr "Saitama" +"S'ha agregat amb èxit el/la %(name)s \"%(obj)s\". Pot editar-lo de nou abaix." -#: contrib/localflavor/jp/jp_prefectures.py:15 -msgid "Chiba" -msgstr "Chiba" +#: contrib/admin/views/main.py:391 +#, python-format +msgid "Change %s" +msgstr "Modificar %s" -#: contrib/localflavor/jp/jp_prefectures.py:16 -msgid "Tokyo" -msgstr "Tokyo" +#: contrib/admin/views/main.py:476 +#, python-format +msgid "One or more %(fieldname)s in %(name)s: %(obj)s" +msgstr "Un o més %(fieldname)s en %(name)s: %(obj)s" -#: contrib/localflavor/jp/jp_prefectures.py:17 -msgid "Kanagawa" -msgstr "Kanagawa" +#: contrib/admin/views/main.py:481 +#, python-format +msgid "One or more %(fieldname)s in %(name)s:" +msgstr "Un o més %(fieldname)s en %(name)s:" -#: contrib/localflavor/jp/jp_prefectures.py:18 -msgid "Yamanashi" -msgstr "Yamanashi" +#: contrib/admin/views/main.py:514 +#, python-format +msgid "The %(name)s \"%(obj)s\" was deleted successfully." +msgstr "El/la %(name)s \"%(obj)s\".ha estat eliminat amb èxit." -#: contrib/localflavor/jp/jp_prefectures.py:19 -msgid "Nagano" -msgstr "Nagano" +#: contrib/admin/views/main.py:517 +msgid "Are you sure?" +msgstr "Està segur?" -#: contrib/localflavor/jp/jp_prefectures.py:20 -msgid "Niigata" -msgstr "Niigata" +#: contrib/admin/views/main.py:539 +#, python-format +msgid "Change history: %s" +msgstr "Modificar històric: %s" -#: contrib/localflavor/jp/jp_prefectures.py:21 -msgid "Toyama" -msgstr "Toyama" +#: contrib/admin/views/main.py:573 +#, python-format +msgid "Select %s" +msgstr "Seleccioni %s" -#: contrib/localflavor/jp/jp_prefectures.py:22 -msgid "Ishikawa" -msgstr "Ishikawa" +#: contrib/admin/views/main.py:573 +#, python-format +msgid "Select %s to change" +msgstr "Seleccioni %s per modificar" -#: contrib/localflavor/jp/jp_prefectures.py:23 -msgid "Fukui" -msgstr "Fukui" +#: contrib/admin/views/main.py:768 +msgid "Database error" +msgstr "Error de/en la base de dades" -#: contrib/localflavor/jp/jp_prefectures.py:24 -msgid "Gifu" -msgstr "Gifu" +#: contrib/admin/views/doc.py:46 contrib/admin/views/doc.py:48 +#: contrib/admin/views/doc.py:50 +msgid "tag:" +msgstr "etiqueta:" -#: contrib/localflavor/jp/jp_prefectures.py:25 -msgid "Shizuoka" -msgstr "Shizuoka" +#: contrib/admin/views/doc.py:77 contrib/admin/views/doc.py:79 +#: contrib/admin/views/doc.py:81 +msgid "filter:" +msgstr "filtre:" -#: contrib/localflavor/jp/jp_prefectures.py:26 -msgid "Aichi" -msgstr "Aichi" +#: contrib/admin/views/doc.py:135 contrib/admin/views/doc.py:137 +#: contrib/admin/views/doc.py:139 +msgid "view:" +msgstr "vista:" -#: contrib/localflavor/jp/jp_prefectures.py:27 -msgid "Mie" -msgstr "Mie" +#: contrib/admin/views/doc.py:164 +#, python-format +msgid "App %r not found" +msgstr "La aplicació %r no s'ha pogut trobar" -#: contrib/localflavor/jp/jp_prefectures.py:28 -msgid "Shiga" -msgstr "Shiga" +#: contrib/admin/views/doc.py:171 +#, python-format +msgid "Model %(name)r not found in app %(label)r" +msgstr "El model %(name)r no s'ha trobat en la aplicació %(label)r" -#: contrib/localflavor/jp/jp_prefectures.py:29 -msgid "Kyoto" -msgstr "Kyoto" +#: contrib/admin/views/doc.py:183 +#, python-format +msgid "the related `%(label)s.%(type)s` object" +msgstr "el objecte relacionat `%(label)s.%(type)s`" -#: contrib/localflavor/jp/jp_prefectures.py:30 -msgid "Osaka" -msgstr "Osaka" +#: contrib/admin/views/doc.py:183 contrib/admin/views/doc.py:205 +#: contrib/admin/views/doc.py:219 contrib/admin/views/doc.py:224 +msgid "model:" +msgstr "model:" -#: contrib/localflavor/jp/jp_prefectures.py:31 -msgid "Hyogo" -msgstr "Hyogo" +#: contrib/admin/views/doc.py:214 +#, python-format +msgid "related `%(label)s.%(name)s` objects" +msgstr "objectes relacionats `%(label)s.%(name)s`" -#: contrib/localflavor/jp/jp_prefectures.py:32 -msgid "Nara" -msgstr "Nara" +#: contrib/admin/views/doc.py:219 +#, python-format +msgid "all %s" +msgstr "tots %s" -#: contrib/localflavor/jp/jp_prefectures.py:33 -msgid "Wakayama" -msgstr "Wakayama" +#: contrib/admin/views/doc.py:224 +#, python-format +msgid "number of %s" +msgstr "nombre de %s" -#: contrib/localflavor/jp/jp_prefectures.py:34 -msgid "Tottori" -msgstr "Tottori" +#: contrib/admin/views/doc.py:229 +#, python-format +msgid "Fields on %s objects" +msgstr "Camps en objectes %s" -#: contrib/localflavor/jp/jp_prefectures.py:35 -msgid "Shimane" -msgstr "Shimane" +#: contrib/admin/views/doc.py:291 contrib/admin/views/doc.py:302 +#: contrib/admin/views/doc.py:304 contrib/admin/views/doc.py:310 +#: contrib/admin/views/doc.py:311 contrib/admin/views/doc.py:313 +msgid "Integer" +msgstr "Enter" -#: contrib/localflavor/jp/jp_prefectures.py:36 -msgid "Okayama" -msgstr "Okayama" +#: contrib/admin/views/doc.py:292 +msgid "Boolean (Either True or False)" +msgstr "Booleà (Verdader o Fals)" -#: contrib/localflavor/jp/jp_prefectures.py:37 -msgid "Hiroshima" -msgstr "Hiroshima" +#: contrib/admin/views/doc.py:293 contrib/admin/views/doc.py:312 +#, python-format +msgid "String (up to %(maxlength)s)" +msgstr "Cadena (fins a %(maxlength)s)" -#: contrib/localflavor/jp/jp_prefectures.py:38 -msgid "Yamaguchi" -msgstr "Yamaguchi" +#: contrib/admin/views/doc.py:294 +msgid "Comma-separated integers" +msgstr "Enters separats per comes" -#: contrib/localflavor/jp/jp_prefectures.py:39 -msgid "Tokushima" -msgstr "Tokushima" +#: contrib/admin/views/doc.py:295 +msgid "Date (without time)" +msgstr "Data (sense hora)" -#: contrib/localflavor/jp/jp_prefectures.py:40 -msgid "Kagawa" -msgstr "Kagawa" +#: contrib/admin/views/doc.py:296 +msgid "Date (with time)" +msgstr "Data (amb hora)" -#: contrib/localflavor/jp/jp_prefectures.py:41 -msgid "Ehime" -msgstr "Ehime" +#: contrib/admin/views/doc.py:297 +msgid "Decimal number" +msgstr "Número decimal" -#: contrib/localflavor/jp/jp_prefectures.py:42 -msgid "Kochi" -msgstr "Kochi" +#: contrib/admin/views/doc.py:298 +msgid "E-mail address" +msgstr "Adreça de correu electrònic" -#: contrib/localflavor/jp/jp_prefectures.py:43 -msgid "Fukuoka" -msgstr "Fukuoka" +#: contrib/admin/views/doc.py:299 contrib/admin/views/doc.py:300 +#: contrib/admin/views/doc.py:303 +msgid "File path" +msgstr "Ruta del fitxer" -#: contrib/localflavor/jp/jp_prefectures.py:44 -msgid "Saga" -msgstr "Saga" +#: contrib/admin/views/doc.py:301 +msgid "Floating point number" +msgstr "Número amb punt de coma flotant" -#: contrib/localflavor/jp/jp_prefectures.py:45 -msgid "Nagasaki" -msgstr "Nagasaki" +#: contrib/admin/views/doc.py:307 +msgid "Boolean (Either True, False or None)" +msgstr "Booleà (Verdader, Fals o 'None' (cap))" -#: contrib/localflavor/jp/jp_prefectures.py:46 -msgid "Kumamoto" -msgstr "Kumamoto" +#: contrib/admin/views/doc.py:308 +msgid "Relation to parent model" +msgstr "Relació amb el model pare" -#: contrib/localflavor/jp/jp_prefectures.py:47 -msgid "Oita" -msgstr "Oita" +#: contrib/admin/views/doc.py:309 +msgid "Phone number" +msgstr "Número de telèfon" -#: contrib/localflavor/jp/jp_prefectures.py:48 -msgid "Miyazaki" -msgstr "Miyazaki" +#: contrib/admin/views/doc.py:314 +msgid "Text" +msgstr "Texte" -#: contrib/localflavor/jp/jp_prefectures.py:49 -msgid "Kagoshima" -msgstr "Kagoshima" +#: contrib/admin/views/doc.py:315 +msgid "Time" +msgstr "Hora" -#: contrib/localflavor/jp/jp_prefectures.py:50 -msgid "Okinawa" -msgstr "Okinawa" +#: contrib/admin/views/doc.py:316 contrib/flatpages/models.py:7 +msgid "URL" +msgstr "URL" -#: contrib/localflavor/it/forms.py:16 -msgid "Enter a valid zip code." -msgstr "Introdueixi un codi zip vàlid." +#: contrib/admin/views/doc.py:317 +msgid "U.S. state (two uppercase letters)" +msgstr "Estat dels E.U.A. (dos lletres majúscules)" -#: contrib/localflavor/it/forms.py:41 -msgid "Enter a valid Social Security number." -msgstr "Introdueixi un número valid de la Seguretat Social." +#: contrib/admin/views/doc.py:318 +msgid "XML text" +msgstr "Texte XML" -#: contrib/localflavor/it/forms.py:68 -msgid "Enter a valid VAT number." -msgstr "Introdueixi un número de IVA (VAT) vàlid." +#: contrib/admin/views/doc.py:344 +#, python-format +msgid "%s does not appear to be a urlpattern object" +msgstr "%s no sembla ser un objecte 'urlpattern'" -#: contrib/localflavor/de/forms.py:60 +#: contrib/admin/views/decorators.py:10 contrib/auth/forms.py:60 msgid "" -"Enter a valid German identity card number in XXXXXXXXXXX-XXXXXXX-XXXXXXX-X " -"format." -msgstr "" -"Introdueixi un número de tarjeta d'identificació alemany vàlid en el format " -"XXXXXXXXXXX-XXXXXXX-XXXXXXX-X." - -#: contrib/localflavor/de/de_states.py:5 -msgid "Baden-Wuerttemberg" -msgstr "Baden-Wuerttemberg" - -#: contrib/localflavor/de/de_states.py:6 -msgid "Bavaria" -msgstr "Bavaria" - -#: contrib/localflavor/de/de_states.py:7 -msgid "Berlin" -msgstr "Berlin" - -#: contrib/localflavor/de/de_states.py:8 -msgid "Brandenburg" -msgstr "Brandenburg" - -#: contrib/localflavor/de/de_states.py:9 -msgid "Bremen" -msgstr "Bremen" - -#: contrib/localflavor/de/de_states.py:10 -msgid "Hamburg" -msgstr "Hamburg" - -#: contrib/localflavor/de/de_states.py:11 -msgid "Hessen" -msgstr "Hessen" - -#: contrib/localflavor/de/de_states.py:12 -msgid "Mecklenburg-Western Pomerania" -msgstr "Mecklenburg-Western Pomerania" - -#: contrib/localflavor/de/de_states.py:13 -msgid "Lower Saxony" -msgstr "Lower Saxony" - -#: contrib/localflavor/de/de_states.py:14 -msgid "North Rhine-Westphalia" -msgstr "North Rhine-Westphalia" - -#: contrib/localflavor/de/de_states.py:15 -msgid "Rhineland-Palatinate" -msgstr "Rhineland-Palatinate" - -#: contrib/localflavor/de/de_states.py:16 -msgid "Saarland" -msgstr "Saarland" - -#: contrib/localflavor/de/de_states.py:17 -msgid "Saxony" -msgstr "Saxony" - -#: contrib/localflavor/de/de_states.py:18 -msgid "Saxony-Anhalt" -msgstr "Saxony-Anhalt" - -#: contrib/localflavor/de/de_states.py:19 -msgid "Schleswig-Holstein" -msgstr "Schleswig-Holstein" - -#: contrib/localflavor/de/de_states.py:20 -msgid "Thuringia" -msgstr "Thuringia" - -#: contrib/localflavor/us/forms.py:18 -msgid "Enter a zip code in the format XXXXX or XXXXX-XXXX." -msgstr "Introdueixi un codi zip en el format XXXXX o XXXXX-XXXX." - -#: contrib/localflavor/us/forms.py:51 -msgid "Enter a valid U.S. Social Security number in XXX-XX-XXXX format." +"Please enter a correct username and password. Note that both fields are case-" +"sensitive." msgstr "" -"Introdueixi un número vàlid de la Seguretat Social dels E.U.A. en el format " -"XXX-XX-XXXX." - -#: contrib/localflavor/ch/forms.py:18 contrib/localflavor/no/forms.py:15 -msgid "Enter a zip code in the format XXXX." -msgstr "Introdueixi un codi zip en el format XXXX." +"Si us plau, introdueixi un nom d'usuari i contrasenya vàlids. Tingui en " +"compte que tots dos camps son sensibles a majúscules i minúscules." -#: contrib/localflavor/ch/forms.py:90 +#: contrib/admin/views/decorators.py:62 msgid "" -"Enter a valid Swiss identity or passport card number in X1234567<0 or " -"1234567890 format." +"Please log in again, because your session has expired. Don't worry: Your " +"submission has been saved." msgstr "" -"Introdueixi un número de identificació o de passaport Suïssos en els formats " -"1234567890 o X1234567<0." - -#: contrib/localflavor/ch/ch_states.py:5 -msgid "Aargau" -msgstr "Argau" - -#: contrib/localflavor/ch/ch_states.py:6 -msgid "Appenzell Innerrhoden" -msgstr "Appenzell Innerrhoden" - -#: contrib/localflavor/ch/ch_states.py:7 -msgid "Appenzell Ausserrhoden" -msgstr "Appenzell Ausserrhoden" - -#: contrib/localflavor/ch/ch_states.py:8 -msgid "Basel-Stadt" -msgstr "Basel-Stadt" - -#: contrib/localflavor/ch/ch_states.py:9 -msgid "Basel-Land" -msgstr "Basel-Land" - -#: contrib/localflavor/ch/ch_states.py:10 -msgid "Berne" -msgstr "Berne" - -#: contrib/localflavor/ch/ch_states.py:11 -msgid "Fribourg" -msgstr "Fribourg" - -#: contrib/localflavor/ch/ch_states.py:12 -msgid "Geneva" -msgstr "Geneva" - -#: contrib/localflavor/ch/ch_states.py:13 -msgid "Glarus" -msgstr "Glarus" - -#: contrib/localflavor/ch/ch_states.py:14 -msgid "Graubuenden" -msgstr "Graubuenden" - -#: contrib/localflavor/ch/ch_states.py:15 -msgid "Jura" -msgstr "Jura" - -#: contrib/localflavor/ch/ch_states.py:16 -msgid "Lucerne" -msgstr "Lucerne" - -#: contrib/localflavor/ch/ch_states.py:17 -msgid "Neuchatel" -msgstr "Neuchatel" - -#: contrib/localflavor/ch/ch_states.py:18 -msgid "Nidwalden" -msgstr "Nidwalden" - -#: contrib/localflavor/ch/ch_states.py:19 -msgid "Obwalden" -msgstr "Obwalden" - -#: contrib/localflavor/ch/ch_states.py:20 -msgid "Schaffhausen" -msgstr "Schaffhausen" - -#: contrib/localflavor/ch/ch_states.py:21 -msgid "Schwyz" -msgstr "Schwyz" - -#: contrib/localflavor/ch/ch_states.py:22 -msgid "Solothurn" -msgstr "Solothurn" - -#: contrib/localflavor/ch/ch_states.py:23 -msgid "St. Gallen" -msgstr "St. Gallen" - -#: contrib/localflavor/ch/ch_states.py:24 -msgid "Thurgau" -msgstr "Thurgau" - -#: contrib/localflavor/ch/ch_states.py:25 -msgid "Ticino" -msgstr "Ticino" - -#: contrib/localflavor/ch/ch_states.py:26 -msgid "Uri" -msgstr "Uri" - -#: contrib/localflavor/ch/ch_states.py:27 -msgid "Valais" -msgstr "Valais" - -#: contrib/localflavor/ch/ch_states.py:28 -msgid "Vaud" -msgstr "Vaud" - -#: contrib/localflavor/ch/ch_states.py:29 -msgid "Zug" -msgstr "Zug" - -#: contrib/localflavor/ch/ch_states.py:30 -msgid "Zurich" -msgstr "Zurich" - -#: contrib/localflavor/au/forms.py:18 -msgid "Enter a 4 digit post code." -msgstr "Introdueixi un codi postal de 4 dígits." +"Si us plau, identifiquis de nou doncs la seva sessió ha expirat. No es " +"preocupi, el seu enviament està emmagatzemat." -#: contrib/localflavor/is_/forms.py:16 +#: contrib/admin/views/decorators.py:69 msgid "" -"Enter a valid Icelandic identification number. The format is XXXXXX-XXXX." +"Looks like your browser isn't configured to accept cookies. Please enable " +"cookies, reload this page, and try again." msgstr "" -"Introdueixi un número de identificació d'Islàndia. El format és XXXXXX-XXXX." - -#: contrib/localflavor/is_/forms.py:30 -msgid "The Icelandic identification number is not valid." -msgstr "El número de identificació d'Islàndia no és vàlid." - -#: contrib/localflavor/br/forms.py:18 -msgid "Enter a zip code in the format XXXXX-XXX." -msgstr "Introdueixi un codi zip en el format XXXXX-XXX." - -#: contrib/localflavor/br/forms.py:30 -msgid "Phone numbers must be in XX-XXXX-XXXX format." -msgstr "El número de telèfon ha de ser en el format XX-XXXX-XXXX." - -#: contrib/localflavor/br/forms.py:72 -msgid "This field requires only numbers." -msgstr "Aquest camps requereix només números." - -#: contrib/localflavor/br/forms.py:74 -msgid "This field requires at most 11 digits or 14 characters." -msgstr "Aquest camp requereix com a màxim 11 dígits o 14 caracters." - -#: contrib/localflavor/br/forms.py:84 -msgid "Invalid CPF number." -msgstr "Número CPF invàlid." - -#: contrib/localflavor/br/forms.py:106 -msgid "This field requires at least 14 digits" -msgstr "Aquest camp requereix almenys 14 dígits." - -#: contrib/localflavor/br/forms.py:116 -msgid "Invalid CNPJ number." -msgstr "Número CNPJ invàlid." - -#: contrib/localflavor/cl/forms.py:21 -msgid "Enter valid a Chilean RUT. The format is XX.XXX.XXX-X." -msgstr "Introdueixi un RUT Xilè vàlid. El format és XX.XXX.XXX-X" - -#: contrib/localflavor/cl/forms.py:26 -msgid "Enter valid a Chilean RUT" -msgstr "Introdueixi un RUT Xilè vàlid." +"Sembla ser que el seu navegador no està configurat per acceptar " +"'cookies' (galetes). Si us plau, habiliti les 'cookies', recarregui aquesta " +"pàgina i provi-ho de nou. " -#: contrib/localflavor/no/forms.py:36 -msgid "Enter a valid Norwegian social security number." -msgstr "Introdueixi un número de la seguretat social Noruega vàlid." +#: contrib/admin/views/decorators.py:83 +msgid "Usernames cannot contain the '@' character." +msgstr "Els noms d'usuari no poden contenir el caracter '@'." -#: contrib/localflavor/uk/forms.py:18 -msgid "Enter a postcode. A space is required between the two postcode parts." +#: contrib/admin/views/decorators.py:85 +#, python-format +msgid "Your e-mail address is not your username. Try '%s' instead." msgstr "" -"Introdueixi un codi postal. És necessari un espai entre les dues parts del " -"codi postal." +"La seva adreça de correu no és el seu nom d'usuari. Provi '%s' en tot cas." #: contrib/sessions/models.py:68 msgid "session key" @@ -2015,56 +1525,9 @@ msgstr "sessió" msgid "sessions" msgstr "sessions" -#: contrib/flatpages/models.py:8 -msgid "" -"Example: '/about/contact/'. Make sure to have leading and trailing slashes." -msgstr "" -"Exemple: '/about/contact/'. Asseguri's de posar les barres al principi i al " -"final." - -#: contrib/flatpages/models.py:9 -msgid "title" -msgstr "tìtol" - -#: contrib/flatpages/models.py:10 -msgid "content" -msgstr "contingut" - -#: contrib/flatpages/models.py:11 -msgid "enable comments" -msgstr "habilitar comentaris" - -#: contrib/flatpages/models.py:12 -msgid "template name" -msgstr "nom de la plantilla" - -#: contrib/flatpages/models.py:13 -msgid "" -"Example: 'flatpages/contact_page.html'. If this isn't provided, the system " -"will use 'flatpages/default.html'." -msgstr "" -"Exemple: 'flatpages/contact_page.html'. Si no el proporciona, el sistema " -"utilitzarà 'flatpages/defaula.htmlt'." - -#: contrib/flatpages/models.py:14 -msgid "registration required" -msgstr "s'ha de estar registrat" - -#: contrib/flatpages/models.py:14 -msgid "If this is checked, only logged-in users will be able to view the page." -msgstr "Si està marcat, només els usuaris registrats podran veure la pàgina." - -#: contrib/flatpages/models.py:18 -msgid "flat page" -msgstr "pàgina estàtica" - -#: contrib/flatpages/models.py:19 -msgid "flat pages" -msgstr "pàgines estàtiques" - #: contrib/humanize/templatetags/humanize.py:17 msgid "th" -msgstr "" +msgstr "rt" #: contrib/humanize/templatetags/humanize.py:17 msgid "st" @@ -2135,17 +1598,84 @@ msgstr "vuit" msgid "nine" msgstr "nou" -#: contrib/contenttypes/models.py:36 -msgid "python model class name" -msgstr "nom de la classe del model en python" +#: contrib/redirects/models.py:7 +msgid "redirect from" +msgstr "redreçar des de" -#: contrib/contenttypes/models.py:39 -msgid "content type" -msgstr "tipus de contingut" +#: contrib/redirects/models.py:8 +msgid "" +"This should be an absolute path, excluding the domain name. Example: '/" +"events/search/'." +msgstr "" +"Aquesta ruta hauria de ser el camí absolut, excloent-ne el nom del domini. " +"Exemple '/events/search/'." -#: contrib/contenttypes/models.py:40 -msgid "content types" -msgstr "tipus de continguts" +#: contrib/redirects/models.py:9 +msgid "redirect to" +msgstr "redreçar a" + +#: contrib/redirects/models.py:10 +msgid "" +"This can be either an absolute path (as above) or a full URL starting with " +"'http://'." +msgstr "" +"Això pot ser bé una ruta absoluta (com abans) o una URL completa que comenci " +"per http:// ." + +#: contrib/redirects/models.py:13 +msgid "redirect" +msgstr "redreçament" + +#: contrib/redirects/models.py:14 +msgid "redirects" +msgstr "redreçaments" + +#: contrib/flatpages/models.py:8 +msgid "" +"Example: '/about/contact/'. Make sure to have leading and trailing slashes." +msgstr "" +"Exemple: '/about/contact/'. Asseguri's de posar les barres al principi i al " +"final." + +#: contrib/flatpages/models.py:9 +msgid "title" +msgstr "tìtol" + +#: contrib/flatpages/models.py:10 +msgid "content" +msgstr "contingut" + +#: contrib/flatpages/models.py:11 +msgid "enable comments" +msgstr "habilitar comentaris" + +#: contrib/flatpages/models.py:12 +msgid "template name" +msgstr "nom de la plantilla" + +#: contrib/flatpages/models.py:13 +msgid "" +"Example: 'flatpages/contact_page.html'. If this isn't provided, the system " +"will use 'flatpages/default.html'." +msgstr "" +"Exemple: 'flatpages/contact_page.html'. Si no el proporciona, el sistema " +"utilitzarà 'flatpages/defaula.htmlt'." + +#: contrib/flatpages/models.py:14 +msgid "registration required" +msgstr "s'ha de estar registrat" + +#: contrib/flatpages/models.py:14 +msgid "If this is checked, only logged-in users will be able to view the page." +msgstr "Si està marcat, només els usuaris registrats podran veure la pàgina." + +#: contrib/flatpages/models.py:18 +msgid "flat page" +msgstr "pàgina estàtica" + +#: contrib/flatpages/models.py:19 +msgid "flat pages" +msgstr "pàgines estàtiques" #: contrib/sites/models.py:10 msgid "domain name" @@ -2163,41 +1693,6 @@ msgstr "lloc" msgid "sites" msgstr "llocs" -#: contrib/auth/forms.py:17 contrib/auth/forms.py:138 -msgid "The two password fields didn't match." -msgstr "Els dos camps de contrasenya no coincideixen." - -#: contrib/auth/forms.py:25 -msgid "A user with that username already exists." -msgstr "Ja existeix un usuari amb aquest nom." - -#: contrib/auth/forms.py:53 -msgid "" -"Your Web browser doesn't appear to have cookies enabled. Cookies are " -"required for logging in." -msgstr "" -"El seu navegador no sembla tenir les 'cookies' (galetes) activades. Aquestes " -"són necessàries per iniciar la sessió." - -#: contrib/auth/forms.py:62 -msgid "This account is inactive." -msgstr "Aquest compte està inactiu" - -#: contrib/auth/forms.py:85 -msgid "" -"That e-mail address doesn't have an associated user account. Are you sure " -"you've registered?" -msgstr "" - -#: contrib/auth/forms.py:117 -msgid "The two 'new password' fields didn't match." -msgstr "Els dos camps de nova contrasenya no coincideixen." - -#: contrib/auth/forms.py:124 -msgid "Your old password was entered incorrectly. Please enter it again." -msgstr "" -"La seva antiga contrasenya no és correcte. Si el plau, introdueixi-la de nou." - #: contrib/auth/views.py:40 msgid "Logged out" msgstr "Sessió finalitzada" @@ -2342,365 +1837,535 @@ msgstr "Grups" msgid "message" msgstr "missatge" -#: newforms/models.py:173 newforms/fields.py:366 -msgid "Select a valid choice. That choice is not one of the available choices." +#: contrib/auth/models.py:282 +msgid "AnonymousUser" +msgstr "AnonymousUser" + +#: contrib/auth/forms.py:17 contrib/auth/forms.py:138 +msgid "The two password fields didn't match." +msgstr "Els dos camps de contrasenya no coincideixen." + +#: contrib/auth/forms.py:25 +msgid "A user with that username already exists." +msgstr "Ja existeix un usuari amb aquest nom." + +#: contrib/auth/forms.py:53 +msgid "" +"Your Web browser doesn't appear to have cookies enabled. Cookies are " +"required for logging in." msgstr "" -"Esculli una opció vàlida; Aquesta opció no és una de les opcions disponibles." +"El seu navegador no sembla tenir les 'cookies' (galetes) activades. Aquestes " +"són necessàries per iniciar la sessió." -#: newforms/models.py:186 newforms/fields.py:82 newforms/fields.py:378 -#: newforms/fields.py:454 newforms/fields.py:465 -#: db/models/fields/__init__.py:117 db/models/fields/__init__.py:274 -#: db/models/fields/__init__.py:612 db/models/fields/__init__.py:623 -#: oldforms/__init__.py:357 -msgid "This field is required." -msgstr "Aquest camp és obligatori." +#: contrib/auth/forms.py:62 +msgid "This account is inactive." +msgstr "Aquest compte està inactiu" -#: newforms/models.py:190 newforms/fields.py:382 newforms/fields.py:458 -msgid "Enter a list of values." -msgstr "Introdueixi una llista de valors." +#: contrib/auth/forms.py:85 +msgid "" +"That e-mail address doesn't have an associated user account. Are you sure " +"you've registered?" +msgstr "" +"Aquesta adreça de correu no té associada cap compte d'usuari. Està segur de " +"que s'ha registrat?" -#: newforms/models.py:196 newforms/fields.py:391 -#, python-format -msgid "Select a valid choice. %s is not one of the available choices." -msgstr "Esculli una opció vàlida; %s' no és una de les opcions vàlides." +#: contrib/auth/forms.py:117 +msgid "The two 'new password' fields didn't match." +msgstr "Els dos camps de nova contrasenya no coincideixen." -#: newforms/fields.py:105 newforms/fields.py:258 -#, python-format -msgid "Ensure this value has at most %d characters." -msgstr "Asseguris de que el seu texte té com a màxim %d caracters." +#: contrib/auth/forms.py:124 +msgid "Your old password was entered incorrectly. Please enter it again." +msgstr "" +"La seva antiga contrasenya no és correcte. Si el plau, introdueixi-la de nou." -#: newforms/fields.py:107 newforms/fields.py:260 -#, python-format -msgid "Ensure this value has at least %d characters." -msgstr "Asseguris de que el seu texte té almenys %d caracters." +#: contrib/contenttypes/models.py:36 +msgid "python model class name" +msgstr "nom de la classe del model en python" -#: newforms/fields.py:130 core/validators.py:120 -msgid "Enter a whole number." -msgstr "Introdueixi un número sencer." +#: contrib/contenttypes/models.py:39 +msgid "content type" +msgstr "tipus de contingut" -#: newforms/fields.py:132 -#, python-format -msgid "Ensure this value is less than or equal to %s." -msgstr "Aquest valor ha de ser menor o igual a %s." +#: contrib/contenttypes/models.py:40 +msgid "content types" +msgstr "tipus de continguts" -#: newforms/fields.py:134 -#, python-format -msgid "Ensure this value is greater than or equal to %s." -msgstr "Asseguris de que aquest valor sigui superior o igual a %s." +#: contrib/localflavor/ch/ch_states.py:5 +msgid "Aargau" +msgstr "Argau" -#: newforms/fields.py:167 -msgid "Enter a valid date." -msgstr "Introdueixi una data vàlida." +#: contrib/localflavor/ch/ch_states.py:6 +msgid "Appenzell Innerrhoden" +msgstr "Appenzell Innerrhoden" -#: newforms/fields.py:194 -msgid "Enter a valid time." -msgstr "Introdueixi una hora vàlida." +#: contrib/localflavor/ch/ch_states.py:7 +msgid "Appenzell Ausserrhoden" +msgstr "Appenzell Ausserrhoden" -#: newforms/fields.py:230 -msgid "Enter a valid date/time." -msgstr "Introdueixi una data/hora vàlides." +#: contrib/localflavor/ch/ch_states.py:8 +msgid "Basel-Stadt" +msgstr "Basel-Stadt" -#: newforms/fields.py:244 -msgid "Enter a valid value." -msgstr "Introdueixi un valor vàlid." +#: contrib/localflavor/ch/ch_states.py:9 +msgid "Basel-Land" +msgstr "Basel-Land" -#: newforms/fields.py:273 core/validators.py:162 -msgid "Enter a valid e-mail address." -msgstr "Introdueixi una adreça de correu vàlida." +#: contrib/localflavor/ch/ch_states.py:10 +msgid "Berne" +msgstr "Berne" -#: newforms/fields.py:291 newforms/fields.py:313 -msgid "Enter a valid URL." -msgstr "Introdueixi una URL vàlida." +#: contrib/localflavor/ch/ch_states.py:11 +msgid "Fribourg" +msgstr "Fribourg" -#: newforms/fields.py:315 -msgid "This URL appears to be a broken link." -msgstr "Aquesta URL sembla ser un enllaç trencat." +#: contrib/localflavor/ch/ch_states.py:12 +msgid "Geneva" +msgstr "Geneva" -#: db/models/manipulators.py:307 -#, python-format -msgid "%(object)s with this %(type)s already exists for the given %(field)s." -msgstr "Ja existeix un %(object)s del tipus %(type)s amb aquest %(field)s." +#: contrib/localflavor/ch/ch_states.py:13 +msgid "Glarus" +msgstr "Glarus" -#: db/models/fields/related.py:53 -#, python-format -msgid "Please enter a valid %s." -msgstr "Si us plau, introdueixi un %s vàlid." +#: contrib/localflavor/ch/ch_states.py:14 +msgid "Graubuenden" +msgstr "Graubuenden" -#: db/models/fields/related.py:642 -msgid "Separate multiple IDs with commas." -msgstr "Separi múltiples IDs amb comes." +#: contrib/localflavor/ch/ch_states.py:15 +msgid "Jura" +msgstr "Jura" -#: db/models/fields/related.py:644 -msgid "" -"Hold down \"Control\", or \"Command\" on a Mac, to select more than one." -msgstr "Premi \"Control\" o \"Command\" en un Mac per escollir més d'un." +#: contrib/localflavor/ch/ch_states.py:16 +msgid "Lucerne" +msgstr "Lucerne" -#: db/models/fields/related.py:691 -#, python-format -msgid "Please enter valid %(self)s IDs. The value %(value)r is invalid." -msgid_plural "" -"Please enter valid %(self)s IDs. The values %(value)r are invalid." -msgstr[0] "" -"Si us plau, introdueixi IDs de %(self)s vàlids. El valor %(value)r és " -"invàlid." -msgstr[1] "" -"Si us plau, introdueixi IDs de %(self)s vàlids. Els valors %(value)r són " -"invàlids." +#: contrib/localflavor/ch/ch_states.py:17 +msgid "Neuchatel" +msgstr "Neuchatel" -#: db/models/fields/__init__.py:42 -#, python-format -msgid "%(optname)s with this %(fieldname)s already exists." -msgstr "Ja existeix %(optname)s amb auqest %(fieldname)s." +#: contrib/localflavor/ch/ch_states.py:18 +msgid "Nidwalden" +msgstr "Nidwalden" -#: db/models/fields/__init__.py:369 -msgid "This value must be an integer." -msgstr "Aquest valor ha de ser un enter." +#: contrib/localflavor/ch/ch_states.py:19 +msgid "Obwalden" +msgstr "Obwalden" -#: db/models/fields/__init__.py:404 -msgid "This value must be either True or False." -msgstr "Aquest valor ha de ser True (Veritat) o False (Fals)" +#: contrib/localflavor/ch/ch_states.py:20 +msgid "Schaffhausen" +msgstr "Schaffhausen" -#: db/models/fields/__init__.py:425 -msgid "This field cannot be null." -msgstr "Aquest camp no pot ser null (estar buit)." +#: contrib/localflavor/ch/ch_states.py:21 +msgid "Schwyz" +msgstr "Schwyz" -#: db/models/fields/__init__.py:459 core/validators.py:148 -msgid "Enter a valid date in YYYY-MM-DD format." -msgstr "Introdueixi una data vàlida en el forma AAAA-MM-DD." +#: contrib/localflavor/ch/ch_states.py:22 +msgid "Solothurn" +msgstr "Solothurn" -#: db/models/fields/__init__.py:528 core/validators.py:157 -msgid "Enter a valid date/time in YYYY-MM-DD HH:MM format." -msgstr "Introdueixi un data/hora vàlida en format YYYY-MM-DD HH:MM." +#: contrib/localflavor/ch/ch_states.py:23 +msgid "St. Gallen" +msgstr "St. Gallen" -#: db/models/fields/__init__.py:632 -msgid "Enter a valid filename." -msgstr "Introdueixi un nom de fitxer vàlid." +#: contrib/localflavor/ch/ch_states.py:24 +msgid "Thurgau" +msgstr "Thurgau" -#: db/models/fields/__init__.py:753 -msgid "This value must be either None, True or False." -msgstr "Aquest valor ha de ser None (Cap), True (Veritat) o False (Fals)" +#: contrib/localflavor/ch/ch_states.py:25 +msgid "Ticino" +msgstr "Ticino" -#: views/generic/create_update.py:43 -#, python-format -msgid "The %(verbose_name)s was created successfully." -msgstr "El/La %(verbose_name)s s'ha creat amb èxit." +#: contrib/localflavor/ch/ch_states.py:26 +msgid "Uri" +msgstr "Uri" -#: views/generic/create_update.py:117 -#, python-format -msgid "The %(verbose_name)s was updated successfully." -msgstr "El/La %(verbose_name)s s'ha actualtzat amb èxit." +#: contrib/localflavor/ch/ch_states.py:27 +msgid "Valais" +msgstr "Valais" -#: views/generic/create_update.py:184 -#, python-format -msgid "The %(verbose_name)s was deleted." -msgstr "El %(verbose_name)s s'ha eliminat." +#: contrib/localflavor/ch/ch_states.py:28 +msgid "Vaud" +msgstr "Vaud" -#: oldforms/__init__.py:392 -#, python-format -msgid "Ensure your text is less than %s character." -msgid_plural "Ensure your text is less than %s characters." -msgstr[0] "Asseguris de que el seu texte té menys de %s caracter." -msgstr[1] "Asseguris de que el seu texte té menys de %s caracters." +#: contrib/localflavor/ch/ch_states.py:29 +msgid "Zug" +msgstr "Zug" -#: oldforms/__init__.py:397 -msgid "Line breaks are not allowed here." -msgstr "No es permeten salts de línia." +#: contrib/localflavor/ch/ch_states.py:30 +msgid "Zurich" +msgstr "Zurich" -#: oldforms/__init__.py:498 oldforms/__init__.py:571 oldforms/__init__.py:610 -#, python-format -msgid "Select a valid choice; '%(data)s' is not in %(choices)s." -msgstr "Esculli una opció vàlida; %(data)s' no està dintre de %(choices)s." +#: contrib/localflavor/ch/forms.py:18 contrib/localflavor/no/forms.py:15 +msgid "Enter a zip code in the format XXXX." +msgstr "Introdueixi un codi zip en el format XXXX." -#: oldforms/__init__.py:672 core/validators.py:174 core/validators.py:445 -msgid "No file was submitted. Check the encoding type on the form." +#: contrib/localflavor/ch/forms.py:90 +msgid "" +"Enter a valid Swiss identity or passport card number in X1234567<0 or " +"1234567890 format." msgstr "" -"No s'ha enviat cap fitxer. Comprovi el tipus de codificació del formulari." +"Introdueixi un número de identificació o de passaport Suïssos en els formats " +"1234567890 o X1234567<0." -#: oldforms/__init__.py:674 -msgid "The submitted file is empty." -msgstr "El fitxer enviat està buit." +#: contrib/localflavor/it/forms.py:16 +msgid "Enter a valid zip code." +msgstr "Introdueixi un codi zip vàlid." -#: oldforms/__init__.py:730 -msgid "Enter a whole number between -32,768 and 32,767." -msgstr "Introdueixi un número enter entre -32,768 i 32,767." +#: contrib/localflavor/it/forms.py:41 +msgid "Enter a valid Social Security number." +msgstr "Introdueixi un número valid de la Seguretat Social." -#: oldforms/__init__.py:740 -msgid "Enter a positive number." -msgstr "Introdueixi un número positiu." +#: contrib/localflavor/it/forms.py:68 +msgid "Enter a valid VAT number." +msgstr "Introdueixi un número de IVA (VAT) vàlid." -#: oldforms/__init__.py:750 -msgid "Enter a whole number between 0 and 32,767." -msgstr "Introdueixi un número entre 0 i 32,767." +#: contrib/localflavor/uk/forms.py:18 +msgid "Enter a postcode. A space is required between the two postcode parts." +msgstr "" +"Introdueixi un codi postal. És necessari un espai entre les dues parts del " +"codi postal." -#: conf/global_settings.py:39 -msgid "Arabic" -msgstr "Arabic" +#: contrib/localflavor/us/forms.py:18 +msgid "Enter a zip code in the format XXXXX or XXXXX-XXXX." +msgstr "Introdueixi un codi zip en el format XXXXX o XXXXX-XXXX." -#: conf/global_settings.py:40 -msgid "Bengali" -msgstr "Bengalí" +#: contrib/localflavor/us/forms.py:51 +msgid "Enter a valid U.S. Social Security number in XXX-XX-XXXX format." +msgstr "" +"Introdueixi un número vàlid de la Seguretat Social dels E.U.A. en el format " +"XXX-XX-XXXX." -#: conf/global_settings.py:41 -msgid "Bulgarian" -msgstr "Bulgar" +#: contrib/localflavor/fi/forms.py:14 contrib/localflavor/de/forms.py:16 +#: contrib/localflavor/fr/forms.py:17 +msgid "Enter a zip code in the format XXXXX." +msgstr "Introdueixi un codi zip en el format XXXXX." -#: conf/global_settings.py:42 -msgid "Catalan" -msgstr "Català" +#: contrib/localflavor/fi/forms.py:40 contrib/localflavor/fi/forms.py:45 +msgid "Enter a valid Finnish social security number." +msgstr "Introdueixi un número vàlid de la seguretat social finlandesa." -#: conf/global_settings.py:43 -msgid "Czech" -msgstr "Txec" +#: contrib/localflavor/no/forms.py:36 +msgid "Enter a valid Norwegian social security number." +msgstr "Introdueixi un número de la seguretat social Noruega vàlid." -#: conf/global_settings.py:44 -msgid "Welsh" -msgstr "Galès" +#: contrib/localflavor/cl/forms.py:21 +msgid "Enter valid a Chilean RUT. The format is XX.XXX.XXX-X." +msgstr "Introdueixi un RUT Xilè vàlid. El format és XX.XXX.XXX-X" -#: conf/global_settings.py:45 -msgid "Danish" -msgstr "Danès" +#: contrib/localflavor/cl/forms.py:26 +msgid "Enter valid a Chilean RUT" +msgstr "Introdueixi un RUT Xilè vàlid." -#: conf/global_settings.py:46 -msgid "German" -msgstr "Alemany" +#: contrib/localflavor/de/de_states.py:5 +msgid "Baden-Wuerttemberg" +msgstr "Baden-Wuerttemberg" -#: conf/global_settings.py:47 -msgid "Greek" -msgstr "Grec" +#: contrib/localflavor/de/de_states.py:6 +msgid "Bavaria" +msgstr "Bavaria" -#: conf/global_settings.py:48 -msgid "English" -msgstr "Anglès" +#: contrib/localflavor/de/de_states.py:7 +msgid "Berlin" +msgstr "Berlin" -#: conf/global_settings.py:49 -msgid "Spanish" -msgstr "Espanyol" +#: contrib/localflavor/de/de_states.py:8 +msgid "Brandenburg" +msgstr "Brandenburg" -#: conf/global_settings.py:50 -msgid "Argentinean Spanish" -msgstr "Castellà Argentí" +#: contrib/localflavor/de/de_states.py:9 +msgid "Bremen" +msgstr "Bremen" -#: conf/global_settings.py:51 -msgid "Finnish" -msgstr "Finlandès" +#: contrib/localflavor/de/de_states.py:10 +msgid "Hamburg" +msgstr "Hamburg" -#: conf/global_settings.py:52 -msgid "French" -msgstr "Francès" +#: contrib/localflavor/de/de_states.py:11 +msgid "Hessen" +msgstr "Hessen" -#: conf/global_settings.py:53 -msgid "Galician" -msgstr "Galleg" +#: contrib/localflavor/de/de_states.py:12 +msgid "Mecklenburg-Western Pomerania" +msgstr "Mecklenburg-Western Pomerania" -#: conf/global_settings.py:54 -msgid "Hungarian" -msgstr "Húngar" +#: contrib/localflavor/de/de_states.py:13 +msgid "Lower Saxony" +msgstr "Lower Saxony" -#: conf/global_settings.py:55 -msgid "Hebrew" -msgstr "Hebreu" +#: contrib/localflavor/de/de_states.py:14 +msgid "North Rhine-Westphalia" +msgstr "North Rhine-Westphalia" -#: conf/global_settings.py:56 -msgid "Icelandic" -msgstr "Islandès" +#: contrib/localflavor/de/de_states.py:15 +msgid "Rhineland-Palatinate" +msgstr "Rhineland-Palatinate" -#: conf/global_settings.py:57 -msgid "Italian" -msgstr "Italià" +#: contrib/localflavor/de/de_states.py:16 +msgid "Saarland" +msgstr "Saarland" -#: conf/global_settings.py:58 -msgid "Japanese" -msgstr "Japonès" +#: contrib/localflavor/de/de_states.py:17 +msgid "Saxony" +msgstr "Saxony" -#: conf/global_settings.py:59 -msgid "Korean" -msgstr "Coreà" +#: contrib/localflavor/de/de_states.py:18 +msgid "Saxony-Anhalt" +msgstr "Saxony-Anhalt" -#: conf/global_settings.py:60 -msgid "Kannada" -msgstr "" +#: contrib/localflavor/de/de_states.py:19 +msgid "Schleswig-Holstein" +msgstr "Schleswig-Holstein" -#: conf/global_settings.py:61 -msgid "Latvian" +#: contrib/localflavor/de/de_states.py:20 +msgid "Thuringia" +msgstr "Thuringia" + +#: contrib/localflavor/de/forms.py:60 +msgid "" +"Enter a valid German identity card number in XXXXXXXXXXX-XXXXXXX-XXXXXXX-X " +"format." msgstr "" +"Introdueixi un número de tarjeta d'identificació alemany vàlid en el format " +"XXXXXXXXXXX-XXXXXXX-XXXXXXX-X." -#: conf/global_settings.py:62 -msgid "Macedonian" -msgstr "Macedoni" +#: contrib/localflavor/au/forms.py:18 +msgid "Enter a 4 digit post code." +msgstr "Introdueixi un codi postal de 4 dígits." -#: conf/global_settings.py:63 -msgid "Dutch" -msgstr "Holandès" +#: contrib/localflavor/jp/jp_prefectures.py:4 +msgid "Hokkaido" +msgstr "Hokkaido" -#: conf/global_settings.py:64 -msgid "Norwegian" -msgstr "Norueg" +#: contrib/localflavor/jp/jp_prefectures.py:5 +msgid "Aomori" +msgstr "Aomori" -#: conf/global_settings.py:65 -msgid "Polish" -msgstr "Polac" +#: contrib/localflavor/jp/jp_prefectures.py:6 +msgid "Iwate" +msgstr "Iwate" -#: conf/global_settings.py:66 -msgid "Portugese" -msgstr "Portuguès" +#: contrib/localflavor/jp/jp_prefectures.py:7 +msgid "Miyagi" +msgstr "Miyagi" -#: conf/global_settings.py:67 -msgid "Brazilian" -msgstr "Brasileny" +#: contrib/localflavor/jp/jp_prefectures.py:8 +msgid "Akita" +msgstr "Akita" -#: conf/global_settings.py:68 -msgid "Romanian" -msgstr "Rumanès" +#: contrib/localflavor/jp/jp_prefectures.py:9 +msgid "Yamagata" +msgstr "Yamagata" -#: conf/global_settings.py:69 -msgid "Russian" -msgstr "Rús" +#: contrib/localflavor/jp/jp_prefectures.py:10 +msgid "Fukushima" +msgstr "Fukushima" -#: conf/global_settings.py:70 -msgid "Slovak" -msgstr "Eslovac" +#: contrib/localflavor/jp/jp_prefectures.py:11 +msgid "Ibaraki" +msgstr "Ibaraki" -#: conf/global_settings.py:71 -msgid "Slovenian" -msgstr "Esloveni" +#: contrib/localflavor/jp/jp_prefectures.py:12 +msgid "Tochigi" +msgstr "Tochigi" -#: conf/global_settings.py:72 -msgid "Serbian" -msgstr "Serbi" +#: contrib/localflavor/jp/jp_prefectures.py:13 +msgid "Gunma" +msgstr "Gunma" -#: conf/global_settings.py:73 -msgid "Swedish" -msgstr "Suec" +#: contrib/localflavor/jp/jp_prefectures.py:14 +msgid "Saitama" +msgstr "Saitama" -#: conf/global_settings.py:74 -msgid "Tamil" -msgstr "" +#: contrib/localflavor/jp/jp_prefectures.py:15 +msgid "Chiba" +msgstr "Chiba" -#: conf/global_settings.py:75 -msgid "Telugu" -msgstr "" +#: contrib/localflavor/jp/jp_prefectures.py:16 +msgid "Tokyo" +msgstr "Tokyo" -#: conf/global_settings.py:76 -msgid "Turkish" -msgstr "Turc" +#: contrib/localflavor/jp/jp_prefectures.py:17 +msgid "Kanagawa" +msgstr "Kanagawa" -#: conf/global_settings.py:77 -msgid "Ukrainian" -msgstr "Ucranià" +#: contrib/localflavor/jp/jp_prefectures.py:18 +msgid "Yamanashi" +msgstr "Yamanashi" -#: conf/global_settings.py:78 -msgid "Simplified Chinese" -msgstr "Xinés simplificat" +#: contrib/localflavor/jp/jp_prefectures.py:19 +msgid "Nagano" +msgstr "Nagano" -#: conf/global_settings.py:79 -msgid "Traditional Chinese" -msgstr "Xinés tradicional" +#: contrib/localflavor/jp/jp_prefectures.py:20 +msgid "Niigata" +msgstr "Niigata" + +#: contrib/localflavor/jp/jp_prefectures.py:21 +msgid "Toyama" +msgstr "Toyama" + +#: contrib/localflavor/jp/jp_prefectures.py:22 +msgid "Ishikawa" +msgstr "Ishikawa" + +#: contrib/localflavor/jp/jp_prefectures.py:23 +msgid "Fukui" +msgstr "Fukui" + +#: contrib/localflavor/jp/jp_prefectures.py:24 +msgid "Gifu" +msgstr "Gifu" + +#: contrib/localflavor/jp/jp_prefectures.py:25 +msgid "Shizuoka" +msgstr "Shizuoka" + +#: contrib/localflavor/jp/jp_prefectures.py:26 +msgid "Aichi" +msgstr "Aichi" + +#: contrib/localflavor/jp/jp_prefectures.py:27 +msgid "Mie" +msgstr "Mie" + +#: contrib/localflavor/jp/jp_prefectures.py:28 +msgid "Shiga" +msgstr "Shiga" + +#: contrib/localflavor/jp/jp_prefectures.py:29 +msgid "Kyoto" +msgstr "Kyoto" + +#: contrib/localflavor/jp/jp_prefectures.py:30 +msgid "Osaka" +msgstr "Osaka" + +#: contrib/localflavor/jp/jp_prefectures.py:31 +msgid "Hyogo" +msgstr "Hyogo" + +#: contrib/localflavor/jp/jp_prefectures.py:32 +msgid "Nara" +msgstr "Nara" + +#: contrib/localflavor/jp/jp_prefectures.py:33 +msgid "Wakayama" +msgstr "Wakayama" + +#: contrib/localflavor/jp/jp_prefectures.py:34 +msgid "Tottori" +msgstr "Tottori" + +#: contrib/localflavor/jp/jp_prefectures.py:35 +msgid "Shimane" +msgstr "Shimane" + +#: contrib/localflavor/jp/jp_prefectures.py:36 +msgid "Okayama" +msgstr "Okayama" + +#: contrib/localflavor/jp/jp_prefectures.py:37 +msgid "Hiroshima" +msgstr "Hiroshima" + +#: contrib/localflavor/jp/jp_prefectures.py:38 +msgid "Yamaguchi" +msgstr "Yamaguchi" + +#: contrib/localflavor/jp/jp_prefectures.py:39 +msgid "Tokushima" +msgstr "Tokushima" + +#: contrib/localflavor/jp/jp_prefectures.py:40 +msgid "Kagawa" +msgstr "Kagawa" + +#: contrib/localflavor/jp/jp_prefectures.py:41 +msgid "Ehime" +msgstr "Ehime" + +#: contrib/localflavor/jp/jp_prefectures.py:42 +msgid "Kochi" +msgstr "Kochi" + +#: contrib/localflavor/jp/jp_prefectures.py:43 +msgid "Fukuoka" +msgstr "Fukuoka" + +#: contrib/localflavor/jp/jp_prefectures.py:44 +msgid "Saga" +msgstr "Saga" + +#: contrib/localflavor/jp/jp_prefectures.py:45 +msgid "Nagasaki" +msgstr "Nagasaki" + +#: contrib/localflavor/jp/jp_prefectures.py:46 +msgid "Kumamoto" +msgstr "Kumamoto" + +#: contrib/localflavor/jp/jp_prefectures.py:47 +msgid "Oita" +msgstr "Oita" -#: core/validators.py:64 +#: contrib/localflavor/jp/jp_prefectures.py:48 +msgid "Miyazaki" +msgstr "Miyazaki" + +#: contrib/localflavor/jp/jp_prefectures.py:49 +msgid "Kagoshima" +msgstr "Kagoshima" + +#: contrib/localflavor/jp/jp_prefectures.py:50 +msgid "Okinawa" +msgstr "Okinawa" + +#: contrib/localflavor/jp/forms.py:21 +msgid "Enter a postal code in the format XXXXXXX or XXX-XXXX." +msgstr "Introdueixi un codi postal en el format XXXXXXX o XX-XXXX." + +#: contrib/localflavor/br/forms.py:18 +msgid "Enter a zip code in the format XXXXX-XXX." +msgstr "Introdueixi un codi zip en el format XXXXX-XXX." + +#: contrib/localflavor/br/forms.py:30 +msgid "Phone numbers must be in XX-XXXX-XXXX format." +msgstr "El número de telèfon ha de ser en el format XX-XXXX-XXXX." + +#: contrib/localflavor/br/forms.py:72 +msgid "This field requires only numbers." +msgstr "Aquest camps requereix només números." + +#: contrib/localflavor/br/forms.py:74 +msgid "This field requires at most 11 digits or 14 characters." +msgstr "Aquest camp requereix com a màxim 11 dígits o 14 caracters." + +#: contrib/localflavor/br/forms.py:84 +msgid "Invalid CPF number." +msgstr "Número CPF invàlid." + +#: contrib/localflavor/br/forms.py:106 +msgid "This field requires at least 14 digits" +msgstr "Aquest camp requereix almenys 14 dígits." + +#: contrib/localflavor/br/forms.py:116 +msgid "Invalid CNPJ number." +msgstr "Número CNPJ invàlid." + +#: contrib/localflavor/is_/forms.py:16 +msgid "" +"Enter a valid Icelandic identification number. The format is XXXXXX-XXXX." +msgstr "" +"Introdueixi un número de identificació d'Islàndia. El format és XXXXXX-XXXX." + +#: contrib/localflavor/is_/forms.py:30 +msgid "The Icelandic identification number is not valid." +msgstr "El número de identificació d'Islàndia no és vàlid." + +#: core/validators.py:65 msgid "This value must contain only letters, numbers and underscores." msgstr "Aquest valor ha de contenir només números, guions, i guions baixos." -#: core/validators.py:68 +#: core/validators.py:69 msgid "" "This value must contain only letters, numbers, underscores, dashes or " "slashes." @@ -2708,61 +2373,74 @@ msgstr "" "Aquest valor ha de contenir només lletres, números, guions, guions baixos, i " "barres (/)." -#: core/validators.py:72 +#: core/validators.py:73 msgid "This value must contain only letters, numbers, underscores or hyphens." msgstr "" "Aquest valor ha de contenir només lletres, números, guions o guions baixos" -#: core/validators.py:76 +#: core/validators.py:77 msgid "Uppercase letters are not allowed here." msgstr "No es permeten majúscules aquí." -#: core/validators.py:80 +#: core/validators.py:81 msgid "Lowercase letters are not allowed here." msgstr "No es permeten minúscules aquí." -#: core/validators.py:87 +#: core/validators.py:88 msgid "Enter only digits separated by commas." msgstr "Introdueixi només dígits separats per comes." -#: core/validators.py:99 +#: core/validators.py:100 msgid "Enter valid e-mail addresses separated by commas." msgstr "Introdueixi adreces de correu electrònic vàlides separades per comes." -#: core/validators.py:103 +#: core/validators.py:104 msgid "Please enter a valid IP address." msgstr "Per favor introdueixi una adreça IP vàlida." -#: core/validators.py:107 +#: core/validators.py:108 msgid "Empty values are not allowed here." msgstr "No s'admeten valor buits." -#: core/validators.py:111 +#: core/validators.py:112 msgid "Non-numeric characters aren't allowed here." msgstr "No s'admeten caracters no numèrics." -#: core/validators.py:115 +#: core/validators.py:116 msgid "This value can't be comprised solely of digits." msgstr "Aquest valor no pot contenir només dígits." -#: core/validators.py:124 +#: core/validators.py:125 msgid "Only alphabetical characters are allowed here." msgstr "Només s'admeted caracters alfabètics aquí." -#: core/validators.py:139 +#: core/validators.py:140 msgid "Year must be 1900 or later." msgstr "L'any ha de ser posterior al 1900" -#: core/validators.py:143 +#: core/validators.py:144 #, python-format msgid "Invalid date: %s" msgstr "Data invàlida: %s" -#: core/validators.py:153 +#: core/validators.py:149 db/models/fields/__init__.py:463 +msgid "Enter a valid date in YYYY-MM-DD format." +msgstr "Introdueixi una data vàlida en el forma AAAA-MM-DD." + +#: core/validators.py:154 msgid "Enter a valid time in HH:MM format." msgstr "Introdueixi una hora vàlida en el format HH:MM." -#: core/validators.py:178 +#: core/validators.py:158 db/models/fields/__init__.py:532 +msgid "Enter a valid date/time in YYYY-MM-DD HH:MM format." +msgstr "Introdueixi un data/hora vàlida en format YYYY-MM-DD HH:MM." + +#: core/validators.py:175 core/validators.py:453 oldforms/__init__.py:672 +msgid "No file was submitted. Check the encoding type on the form." +msgstr "" +"No s'ha enviat cap fitxer. Comprovi el tipus de codificació del formulari." + +#: core/validators.py:179 msgid "" "Upload a valid image. The file you uploaded was either not an image or a " "corrupted image." @@ -2770,28 +2448,28 @@ msgstr "" "Envii una imatge vàilda. El fitxer que ha enviat no era una imatge o estaba " "corrupte." -#: core/validators.py:185 +#: core/validators.py:186 #, python-format msgid "The URL %s does not point to a valid image." msgstr "La URL %s no apunta una imatge vàlida." -#: core/validators.py:189 +#: core/validators.py:190 #, python-format msgid "Phone numbers must be in XXX-XXX-XXXX format. \"%s\" is invalid." msgstr "" "El números de telèfon han de guardar-se en el format XXX-XXX-XXXX. \"%s\" no " "és vàlid." -#: core/validators.py:197 +#: core/validators.py:198 #, python-format msgid "The URL %s does not point to a valid QuickTime video." msgstr "La URL %s no apunta a un video QuickTime vàlid." -#: core/validators.py:201 +#: core/validators.py:202 msgid "A valid URL is required." msgstr "Es precisa d'una URL vàlida." -#: core/validators.py:215 +#: core/validators.py:216 #, python-format msgid "" "Valid HTML is required. Specific errors are:\n" @@ -2800,84 +2478,84 @@ msgstr "" "Es precisa HTML vàlid. Els errors específics sòn:\n" "%s" -#: core/validators.py:222 +#: core/validators.py:223 #, python-format msgid "Badly formed XML: %s" msgstr "XML incorrectament formatejat: %s" -#: core/validators.py:239 +#: core/validators.py:240 #, python-format msgid "Invalid URL: %s" msgstr "URL invalida: %s" -#: core/validators.py:244 core/validators.py:246 +#: core/validators.py:245 core/validators.py:247 #, python-format msgid "The URL %s is a broken link." msgstr "La URL %sés un enllaç trencat." -#: core/validators.py:252 +#: core/validators.py:253 msgid "Enter a valid U.S. state abbreviation." msgstr "Introdueixi una abreviatura vàlida d'estat d'els E.U.A.." -#: core/validators.py:266 +#: core/validators.py:267 #, python-format msgid "Watch your mouth! The word %s is not allowed here." msgid_plural "Watch your mouth! The words %s are not allowed here." msgstr[0] "Vigili la seva boca! Aquí no admetem la paraula: %s." msgstr[1] "Vigili la seva boca! Aquí no admetem les paraules: %s." -#: core/validators.py:273 +#: core/validators.py:274 #, python-format msgid "This field must match the '%s' field." msgstr "Aquest camp ha de concordar amb el camp '%s'." -#: core/validators.py:292 +#: core/validators.py:293 msgid "Please enter something for at least one field." msgstr "Si us plau, introdueixi alguna cosa alemnys en un camp." -#: core/validators.py:301 core/validators.py:312 +#: core/validators.py:302 core/validators.py:313 msgid "Please enter both fields or leave them both empty." msgstr "Si us plau, ompli els dos camps o deixi'ls tots dos en blanc." -#: core/validators.py:320 +#: core/validators.py:321 #, python-format msgid "This field must be given if %(field)s is %(value)s" msgstr "S'ha de proporcionar aquest camps si %(field)s és %(value)s" -#: core/validators.py:333 +#: core/validators.py:334 #, python-format msgid "This field must be given if %(field)s is not %(value)s" msgstr "S'ha de proporcionar aquest camps si %(field)s no és %(value)s" -#: core/validators.py:352 +#: core/validators.py:353 msgid "Duplicate values are not allowed." msgstr "No s'admeten valors duplicats." -#: core/validators.py:367 +#: core/validators.py:368 #, python-format msgid "This value must be between %(lower)s and %(upper)s." msgstr "Aquest valor ha de estar comprés entre %(lower)s i %(upper)s." -#: core/validators.py:369 +#: core/validators.py:370 #, python-format msgid "This value must be at least %s." msgstr "Aquest valor ha de ser com a mínim %s." -#: core/validators.py:371 +#: core/validators.py:372 #, python-format msgid "This value must be no more than %s." msgstr "Aquest valor ha de ser com a màxim %s." -#: core/validators.py:407 +#: core/validators.py:408 #, python-format msgid "This value must be a power of %s." msgstr "Aquest valor ha de ser una potència de %s." -#: core/validators.py:418 +#: core/validators.py:417 msgid "Please enter a valid decimal number." msgstr "Si us plau, introdueixi un número decimal vàlid." -#: core/validators.py:422 +#: core/validators.py:423 #, python-format msgid "Please enter a valid decimal number with at most %s total digit." msgid_plural "" @@ -2887,7 +2565,7 @@ msgstr[0] "" msgstr[1] "" "Si us plau, introdueixi un número decimal vàlid amb no més de %s digits." -#: core/validators.py:425 +#: core/validators.py:426 #, python-format msgid "" "Please enter a valid decimal number with a whole part of at most %s digit." @@ -2900,7 +2578,7 @@ msgstr[1] "" "Si us plau, introdueixi un número decimal vàlid amb la part entera amb com a " "màxim %s dígits." -#: core/validators.py:428 +#: core/validators.py:429 #, python-format msgid "Please enter a valid decimal number with at most %s decimal place." msgid_plural "" @@ -2912,30 +2590,34 @@ msgstr[1] "" "Si us plau, introdueixi un número decimal vàlid amb no més de %s dígits en " "la part decimal." -#: core/validators.py:438 +#: core/validators.py:437 +msgid "Please enter a valid floating point number." +msgstr "Si us plau, introdueixi un número amb punt de coma flotant vàlid." + +#: core/validators.py:446 #, python-format msgid "Make sure your uploaded file is at least %s bytes big." msgstr "Asseguris de que el fitxer que ha enviat té, com a mínim, %s bytes." -#: core/validators.py:439 +#: core/validators.py:447 #, python-format msgid "Make sure your uploaded file is at most %s bytes big." msgstr "Asseguris de que el fitxer que ha enviat té, com a màxim %s bytes." -#: core/validators.py:456 +#: core/validators.py:464 msgid "The format for this field is wrong." msgstr "El format per aquest camp és incorrecte." -#: core/validators.py:471 +#: core/validators.py:479 msgid "This field is invalid." msgstr "El camp no és vàlid." -#: core/validators.py:507 +#: core/validators.py:515 #, python-format msgid "Could not retrieve anything from %s." msgstr "No s'ha pogut obtenir res de %s." -#: core/validators.py:510 +#: core/validators.py:518 #, python-format msgid "" "The URL %(url)s returned the invalid Content-Type header '%(contenttype)s'." @@ -2943,7 +2625,7 @@ msgstr "" "La URL %(url)s ha va tornar la capcelera Content-Type '%(contenttype)s', que " "no és vàlida." -#: core/validators.py:543 +#: core/validators.py:551 #, python-format msgid "" "Please close the unclosed %(tag)s tag from line %(line)s. (Line starts with " @@ -2952,7 +2634,7 @@ msgstr "" "Si us plau, tanqui l'etiqueta %(tag)s des de la línia %(line)s. (La línia " "comença amb \"%(start)s\".)" -#: core/validators.py:547 +#: core/validators.py:555 #, python-format msgid "" "Some text starting on line %(line)s is not allowed in that context. (Line " @@ -2961,7 +2643,7 @@ msgstr "" "Part del text que comença en la línia %(line)s no està permès en aquest " "context. (La línia comença per \"%(start)s\".)" -#: core/validators.py:552 +#: core/validators.py:560 #, python-format msgid "" "\"%(attr)s\" on line %(line)s is an invalid attribute. (Line starts with \"%" @@ -2970,7 +2652,7 @@ msgstr "" "El \"%(attr)s\" de la línia %(line)s no és un atribut vàlid. (La línia " "comença per \"%(start)s\".)" -#: core/validators.py:557 +#: core/validators.py:565 #, python-format msgid "" "\"<%(tag)s>\" on line %(line)s is an invalid tag. (Line starts with \"%" @@ -2979,7 +2661,7 @@ msgstr "" "La \"<%(tag)s>\" de la línia %(line)s no és una etiqueta vàlida. (La línia " "comença per \"%(start)s\".)" -#: core/validators.py:561 +#: core/validators.py:569 #, python-format msgid "" "A tag on line %(line)s is missing one or more required attributes. (Line " @@ -2988,7 +2670,7 @@ msgstr "" "Una etiqueta de la línia %(line)s li falta un o més atributs requerits.(La " "línia comença per \"%(start)s\".)" -#: core/validators.py:566 +#: core/validators.py:574 #, python-format msgid "" "The \"%(attr)s\" attribute on line %(line)s has an invalid value. (Line " @@ -2996,3 +2678,357 @@ msgid "" msgstr "" "L'atribut \"%(attr)s\" de la línia %(line)s té un valor que no és vàlid. (La " "línia comença per \"%(start)s\".)" + +#: utils/dates.py:6 +msgid "Monday" +msgstr "Dilluns" + +#: utils/dates.py:6 +msgid "Tuesday" +msgstr "Dimarts" + +#: utils/dates.py:6 +msgid "Wednesday" +msgstr "Dimecres" + +#: utils/dates.py:6 +msgid "Thursday" +msgstr "Dijous" + +#: utils/dates.py:6 +msgid "Friday" +msgstr "Divendres" + +#: utils/dates.py:7 +msgid "Saturday" +msgstr "Dissabte" + +#: utils/dates.py:7 +msgid "Sunday" +msgstr "Diumenge" + +#: utils/dates.py:14 +msgid "January" +msgstr "Gener" + +#: utils/dates.py:14 +msgid "February" +msgstr "Febrer" + +#: utils/dates.py:14 utils/dates.py:27 +msgid "March" +msgstr "Març" + +#: utils/dates.py:14 utils/dates.py:27 +msgid "April" +msgstr "Abril" + +#: utils/dates.py:14 utils/dates.py:27 +msgid "May" +msgstr "Maig" + +#: utils/dates.py:14 utils/dates.py:27 +msgid "June" +msgstr "Juny" + +#: utils/dates.py:15 utils/dates.py:27 +msgid "July" +msgstr "Juliol" + +#: utils/dates.py:15 +msgid "August" +msgstr "Agost" + +#: utils/dates.py:15 +msgid "September" +msgstr "Setembre" + +#: utils/dates.py:15 +msgid "October" +msgstr "Octubre" + +#: utils/dates.py:15 +msgid "November" +msgstr "Novembre" + +#: utils/dates.py:16 +msgid "December" +msgstr "Desembre" + +#: utils/dates.py:19 +msgid "jan" +msgstr "gen" + +#: utils/dates.py:19 +msgid "feb" +msgstr "feb" + +#: utils/dates.py:19 +msgid "mar" +msgstr "mar" + +#: utils/dates.py:19 +msgid "apr" +msgstr "abr" + +#: utils/dates.py:19 +msgid "may" +msgstr "mai" + +#: utils/dates.py:19 +msgid "jun" +msgstr "jun" + +#: utils/dates.py:20 +msgid "jul" +msgstr "jul" + +#: utils/dates.py:20 +msgid "aug" +msgstr "ago" + +#: utils/dates.py:20 +msgid "sep" +msgstr "set" + +#: utils/dates.py:20 +msgid "oct" +msgstr "oct" + +#: utils/dates.py:20 +msgid "nov" +msgstr "nov" + +#: utils/dates.py:20 +msgid "dec" +msgstr "des" + +#: utils/dates.py:27 +msgid "Jan." +msgstr "Gen." + +#: utils/dates.py:27 +msgid "Feb." +msgstr "Feb." + +#: utils/dates.py:28 +msgid "Aug." +msgstr "Ago." + +#: utils/dates.py:28 +msgid "Sept." +msgstr "Set." + +#: utils/dates.py:28 +msgid "Oct." +msgstr "Oct." + +#: utils/dates.py:28 +msgid "Nov." +msgstr "Nov." + +#: utils/dates.py:28 +msgid "Dec." +msgstr "Des." + +#: utils/timesince.py:12 +msgid "year" +msgid_plural "years" +msgstr[0] "any" +msgstr[1] "anys" + +#: utils/timesince.py:13 +msgid "month" +msgid_plural "months" +msgstr[0] "mes" +msgstr[1] "mesos" + +#: utils/timesince.py:14 +msgid "week" +msgid_plural "weeks" +msgstr[0] "setmana" +msgstr[1] "setmanes" + +#: utils/timesince.py:15 +msgid "day" +msgid_plural "days" +msgstr[0] "dia" +msgstr[1] "dies" + +#: utils/timesince.py:16 +msgid "hour" +msgid_plural "hours" +msgstr[0] "hora" +msgstr[1] "hores" + +#: utils/timesince.py:17 +msgid "minute" +msgid_plural "minutes" +msgstr[0] "minut" +msgstr[1] "minuts" + +#: utils/timesince.py:40 +#, python-format +msgid "%d milliseconds" +msgstr "%d milisegons" + +#: utils/timesince.py:41 +#, python-format +msgid "%(number)d %(type)s" +msgstr "%(number)d %(type)s" + +#: utils/timesince.py:47 +#, python-format +msgid ", %(number)d %(type)s" +msgstr ", %(number)d %(type)s" + +#: utils/dateformat.py:40 +msgid "p.m." +msgstr "p.m." + +#: utils/dateformat.py:41 +msgid "a.m." +msgstr "a.m." + +#: utils/dateformat.py:46 +msgid "PM" +msgstr "PM" + +#: utils/dateformat.py:47 +msgid "AM" +msgstr "AM" + +#: utils/dateformat.py:95 +msgid "midnight" +msgstr "mitja nit" + +#: utils/dateformat.py:97 +msgid "noon" +msgstr "mig dia" + +#: utils/translation/trans_real.py:358 +msgid "DATE_FORMAT" +msgstr "F j, Y" + +#: utils/translation/trans_real.py:359 +msgid "DATETIME_FORMAT" +msgstr "F j, Y, H:i" + +#: utils/translation/trans_real.py:360 +msgid "TIME_FORMAT" +msgstr "H:i" + +#: utils/translation/trans_real.py:376 +msgid "YEAR_MONTH_FORMAT" +msgstr "j de/d' F del Y" + +#: utils/translation/trans_real.py:377 +msgid "MONTH_DAY_FORMAT" +msgstr "j de/d' F del Y" + +#: oldforms/__init__.py:392 +#, python-format +msgid "Ensure your text is less than %s character." +msgid_plural "Ensure your text is less than %s characters." +msgstr[0] "Asseguris de que el seu texte té menys de %s caracter." +msgstr[1] "Asseguris de que el seu texte té menys de %s caracters." + +#: oldforms/__init__.py:397 +msgid "Line breaks are not allowed here." +msgstr "No es permeten salts de línia." + +#: oldforms/__init__.py:498 oldforms/__init__.py:571 oldforms/__init__.py:610 +#, python-format +msgid "Select a valid choice; '%(data)s' is not in %(choices)s." +msgstr "Esculli una opció vàlida; %(data)s' no està dintre de %(choices)s." + +#: oldforms/__init__.py:674 +msgid "The submitted file is empty." +msgstr "El fitxer enviat està buit." + +#: oldforms/__init__.py:730 +msgid "Enter a whole number between -32,768 and 32,767." +msgstr "Introdueixi un número enter entre -32,768 i 32,767." + +#: oldforms/__init__.py:740 +msgid "Enter a positive number." +msgstr "Introdueixi un número positiu." + +#: oldforms/__init__.py:750 +msgid "Enter a whole number between 0 and 32,767." +msgstr "Introdueixi un número entre 0 i 32,767." + +#: views/generic/create_update.py:43 +#, python-format +msgid "The %(verbose_name)s was created successfully." +msgstr "El/La %(verbose_name)s s'ha creat amb èxit." + +#: views/generic/create_update.py:117 +#, python-format +msgid "The %(verbose_name)s was updated successfully." +msgstr "El/La %(verbose_name)s s'ha actualtzat amb èxit." + +#: views/generic/create_update.py:184 +#, python-format +msgid "The %(verbose_name)s was deleted." +msgstr "El %(verbose_name)s s'ha eliminat." + +#: db/models/manipulators.py:307 +#, python-format +msgid "%(object)s with this %(type)s already exists for the given %(field)s." +msgstr "Ja existeix un %(object)s del tipus %(type)s amb aquest %(field)s." + +#: db/models/fields/__init__.py:46 +#, python-format +msgid "%(optname)s with this %(fieldname)s already exists." +msgstr "Ja existeix %(optname)s amb auqest %(fieldname)s." + +#: db/models/fields/__init__.py:373 +msgid "This value must be an integer." +msgstr "Aquest valor ha de ser un enter." + +#: db/models/fields/__init__.py:408 +msgid "This value must be either True or False." +msgstr "Aquest valor ha de ser True (Veritat) o False (Fals)" + +#: db/models/fields/__init__.py:429 +msgid "This field cannot be null." +msgstr "Aquest camp no pot ser null (estar buit)." + +#: db/models/fields/__init__.py:592 +msgid "This value must be a decimal number." +msgstr "Aquest valor ha de ser un número decimal." + +#: db/models/fields/__init__.py:695 +msgid "Enter a valid filename." +msgstr "Introdueixi un nom de fitxer vàlid." + +#: db/models/fields/__init__.py:818 +msgid "This value must be either None, True or False." +msgstr "Aquest valor ha de ser None (Cap), True (Veritat) o False (Fals)" + +#: db/models/fields/related.py:53 +#, python-format +msgid "Please enter a valid %s." +msgstr "Si us plau, introdueixi un %s vàlid." + +#: db/models/fields/related.py:642 +msgid "Separate multiple IDs with commas." +msgstr "Separi múltiples IDs amb comes." + +#: db/models/fields/related.py:644 +msgid "" +"Hold down \"Control\", or \"Command\" on a Mac, to select more than one." +msgstr "Premi \"Control\" o \"Command\" en un Mac per escollir més d'un." + +#: db/models/fields/related.py:691 +#, python-format +msgid "Please enter valid %(self)s IDs. The value %(value)r is invalid." +msgid_plural "" +"Please enter valid %(self)s IDs. The values %(value)r are invalid." +msgstr[0] "" +"Si us plau, introdueixi IDs de %(self)s vàlids. El valor %(value)r és " +"invàlid." +msgstr[1] "" +"Si us plau, introdueixi IDs de %(self)s vàlids. Els valors %(value)r són " +"invàlids." diff --git a/django/conf/locale/ca/LC_MESSAGES/djangojs.mo b/django/conf/locale/ca/LC_MESSAGES/djangojs.mo Binary files differindex d12c8f8d7a..a5b908df1f 100644 --- a/django/conf/locale/ca/LC_MESSAGES/djangojs.mo +++ b/django/conf/locale/ca/LC_MESSAGES/djangojs.mo diff --git a/django/conf/locale/ca/LC_MESSAGES/djangojs.po b/django/conf/locale/ca/LC_MESSAGES/djangojs.po index ed7231988b..8167253005 100644 --- a/django/conf/locale/ca/LC_MESSAGES/djangojs.po +++ b/django/conf/locale/ca/LC_MESSAGES/djangojs.po @@ -113,8 +113,8 @@ msgstr "Demà" #: contrib/admin/media/js/admin/CollapsedFieldsets.js:34 #: contrib/admin/media/js/admin/CollapsedFieldsets.js:72 msgid "Show" -msgstr "" +msgstr "Mostrar" #: contrib/admin/media/js/admin/CollapsedFieldsets.js:63 msgid "Hide" -msgstr "" +msgstr "Ocultar" diff --git a/django/conf/locale/de/LC_MESSAGES/django.mo b/django/conf/locale/de/LC_MESSAGES/django.mo Binary files differindex 5f2eee4f33..d1981a679d 100644 --- a/django/conf/locale/de/LC_MESSAGES/django.mo +++ b/django/conf/locale/de/LC_MESSAGES/django.mo diff --git a/django/conf/locale/de/LC_MESSAGES/django.po b/django/conf/locale/de/LC_MESSAGES/django.po index 52b70bda00..3ccbefe249 100644 --- a/django/conf/locale/de/LC_MESSAGES/django.po +++ b/django/conf/locale/de/LC_MESSAGES/django.po @@ -481,8 +481,8 @@ msgid "" "database tables have been created, and make sure the database is readable by " "the appropriate user." msgstr "" -"Etwas stimmt nicht mit der Datenbankkonfiguration. Bitte sicherstellen, das " -"die richtigen Datenbanktabellen angelegt wurden und bitte sicherstellen, das " +"Etwas stimmt nicht mit der Datenbankkonfiguration. Bitte sicherstellen, dass " +"die richtigen Datenbanktabellen angelegt wurden und " "die Datenbank vom verwendeten Datenbankbenutzer auch lesbar ist." #: contrib/admin/templates/admin/login.html:17 diff --git a/django/conf/project_template/settings.py b/django/conf/project_template/settings.py index cadb5146b7..36039d7e98 100644 --- a/django/conf/project_template/settings.py +++ b/django/conf/project_template/settings.py @@ -38,8 +38,9 @@ USE_I18N = True # Example: "/home/media/media.lawrence.com/" MEDIA_ROOT = '' -# URL that handles the media served from MEDIA_ROOT. -# Example: "http://media.lawrence.com" +# URL that handles the media served from MEDIA_ROOT. Make sure to use a +# trailing slash if there is a path component (optional in other cases). +# Examples: "http://media.lawrence.com", "http://example.com/media/" MEDIA_URL = '' # URL prefix for admin media -- CSS, JavaScript and images. Make sure to use a diff --git a/django/conf/urls/defaults.py b/django/conf/urls/defaults.py index 1e87ea708a..26cdd3e1ff 100644 --- a/django/conf/urls/defaults.py +++ b/django/conf/urls/defaults.py @@ -1,4 +1,5 @@ from django.core.urlresolvers import RegexURLPattern, RegexURLResolver +from django.core.exceptions import ImproperlyConfigured __all__ = ['handler404', 'handler500', 'include', 'patterns', 'url'] @@ -22,7 +23,10 @@ def url(regex, view, kwargs=None, name=None, prefix=''): # For include(...) processing. return RegexURLResolver(regex, view[0], kwargs) else: - if prefix and isinstance(view, basestring): - view = prefix + '.' + view + if isinstance(view, basestring): + if not view: + raise ImproperlyConfigured('Empty URL pattern view name not permitted (for pattern %r)' % regex) + if prefix: + view = prefix + '.' + view return RegexURLPattern(regex, view, kwargs, name) diff --git a/django/contrib/comments/feeds.py b/django/contrib/comments/feeds.py index 34cf3d9cef..1ad638469b 100644 --- a/django/contrib/comments/feeds.py +++ b/django/contrib/comments/feeds.py @@ -23,16 +23,19 @@ class LatestFreeCommentsFeed(Feed): self._site = Site.objects.get_current() return "Latest comments on %s" % self._site.name + def get_query_set(self): + return self.comments_class.objects.filter(site__pk=settings.SITE_ID, is_public=True) + def items(self): - return self.comments_class.objects.filter(site__pk=settings.SITE_ID, is_public=True)[:40] + return self.get_query_set()[:40] class LatestCommentsFeed(LatestFreeCommentsFeed): """Feed of latest free comments on the current site""" comments_class = Comment - def items(self): - qs = LatestFreeCommentsFeed.items(self) + def get_query_set(self): + qs = super(LatestCommentsFeed, self).get_query_set() qs = qs.filter(is_removed=False) if settings.COMMENTS_BANNED_USERS_GROUP: where = ['user_id NOT IN (SELECT user_id FROM auth_users_group WHERE group_id = %s)'] diff --git a/django/core/context_processors.py b/django/core/context_processors.py index f4b288dfc4..3c826b1a7d 100644 --- a/django/core/context_processors.py +++ b/django/core/context_processors.py @@ -42,6 +42,13 @@ def i18n(request): return context_extras +def media(request): + """ + Adds media-related context variables to the context. + + """ + return {'MEDIA_URL': settings.MEDIA_URL} + def request(request): return {'request': request} diff --git a/django/core/management.py b/django/core/management.py index 26a06792b2..a273d275c1 100644 --- a/django/core/management.py +++ b/django/core/management.py @@ -1141,7 +1141,7 @@ def validate(outfile=sys.stdout, silent_success=False): return outfile.write('%s error%s found.\n' % (num_errors, num_errors != 1 and 's' or '')) except ImproperlyConfigured: - outfile.write("Skipping validation because things aren't configured properly.") + outfile.write("Skipping validation because things aren't configured properly.\n") validate.args = '' def _check_for_validation_errors(app=None): diff --git a/django/core/serializers/json.py b/django/core/serializers/json.py index 55804b8316..fa2dca7295 100644 --- a/django/core/serializers/json.py +++ b/django/core/serializers/json.py @@ -21,6 +21,8 @@ class Serializer(PythonSerializer): Convert a queryset to JSON. """ def end_serialization(self): + self.options.pop('stream', None) + self.options.pop('fields', None) simplejson.dump(self.objects, self.stream, cls=DjangoJSONEncoder, **self.options) def getvalue(self): diff --git a/django/core/serializers/python.py b/django/core/serializers/python.py index 66dbbff335..5fbb3163f7 100644 --- a/django/core/serializers/python.py +++ b/django/core/serializers/python.py @@ -37,7 +37,12 @@ class Serializer(base.Serializer): def handle_fk_field(self, obj, field): related = getattr(obj, field.name) if related is not None: - related = getattr(related, field.rel.field_name) + if field.rel.field_name == related._meta.pk.name: + # Related to remote object via primary key + related = related._get_pk_val() + else: + # Related to remote object via other field + related = getattr(related, field.rel.field_name) self._current[field.name] = related def handle_m2m_field(self, obj, field): diff --git a/django/core/serializers/pyyaml.py b/django/core/serializers/pyyaml.py index fa3dec984e..d3444280c5 100644 --- a/django/core/serializers/pyyaml.py +++ b/django/core/serializers/pyyaml.py @@ -18,6 +18,8 @@ class Serializer(PythonSerializer): Convert a queryset to YAML. """ def end_serialization(self): + self.options.pop('stream', None) + self.options.pop('fields', None) yaml.dump(self.objects, self.stream, **self.options) def getvalue(self): diff --git a/django/core/serializers/xml_serializer.py b/django/core/serializers/xml_serializer.py index 633001f5f0..3e4a6f3e79 100644 --- a/django/core/serializers/xml_serializer.py +++ b/django/core/serializers/xml_serializer.py @@ -82,7 +82,13 @@ class Serializer(base.Serializer): self._start_relational_field(field) related = getattr(obj, field.name) if related is not None: - self.xml.characters(str(getattr(related, field.rel.field_name))) + if field.rel.field_name == related._meta.pk.name: + # Related to remote object via primary key + related = related._get_pk_val() + else: + # Related to remote object via other field + related = getattr(related, field.rel.field_name) + self.xml.characters(str(related)) else: self.xml.addQuickElement("None") self.xml.endElement("field") diff --git a/django/db/backends/dummy/base.py b/django/db/backends/dummy/base.py index 6a909016fc..d0ec897407 100644 --- a/django/db/backends/dummy/base.py +++ b/django/db/backends/dummy/base.py @@ -12,6 +12,9 @@ from django.core.exceptions import ImproperlyConfigured def complain(*args, **kwargs): raise ImproperlyConfigured, "You haven't set the DATABASE_ENGINE setting yet." +def ignore(*args, **kwargs): + pass + class DatabaseError(Exception): pass @@ -21,7 +24,7 @@ class IntegrityError(DatabaseError): class DatabaseWrapper: cursor = complain _commit = complain - _rollback = complain + _rollback = ignore def __init__(self, **kwargs): pass diff --git a/django/db/models/query.py b/django/db/models/query.py index 08a7901d6f..a6e702be18 100644 --- a/django/db/models/query.py +++ b/django/db/models/query.py @@ -554,9 +554,8 @@ class QuerySet(object): class ValuesQuerySet(QuerySet): def __init__(self, *args, **kwargs): super(ValuesQuerySet, self).__init__(*args, **kwargs) - # select_related and select aren't supported in values(). + # select_related isn't supported in values(). self._select_related = False - self._select = {} def iterator(self): try: @@ -566,13 +565,28 @@ class ValuesQuerySet(QuerySet): # self._fields is a list of field names to fetch. if self._fields: - columns = [self.model._meta.get_field(f, many_to_many=False).column for f in self._fields] + #columns = [self.model._meta.get_field(f, many_to_many=False).column for f in self._fields] + if not self._select: + columns = [self.model._meta.get_field(f, many_to_many=False).column for f in self._fields] + else: + columns = [] + for f in self._fields: + if f in [field.name for field in self.model._meta.fields]: + columns.append( self.model._meta.get_field(f, many_to_many=False).column ) + elif not self._select.has_key( f ): + raise FieldDoesNotExist, '%s has no field named %r' % ( self.model._meta.object_name, f ) + field_names = self._fields else: # Default to all fields. columns = [f.column for f in self.model._meta.fields] field_names = [f.attname for f in self.model._meta.fields] select = ['%s.%s' % (backend.quote_name(self.model._meta.db_table), backend.quote_name(c)) for c in columns] + + # Add any additional SELECTs. + if self._select: + select.extend(['(%s) AS %s' % (quote_only_if_word(s[1]), backend.quote_name(s[0])) for s in self._select.items()]) + cursor = connection.cursor() cursor.execute("SELECT " + (self._distinct and "DISTINCT " or "") + ",".join(select) + sql, params) while 1: diff --git a/django/middleware/common.py b/django/middleware/common.py index 2c72c9a583..5f671dff7d 100644 --- a/django/middleware/common.py +++ b/django/middleware/common.py @@ -75,7 +75,7 @@ class CommonMiddleware(object): # Use ETags, if requested. if settings.USE_ETAGS: etag = md5.new(response.content).hexdigest() - if request.META.get('HTTP_IF_NONE_MATCH') == etag: + if response.status_code >= 200 and response.status_code < 300 and request.META.get('HTTP_IF_NONE_MATCH') == etag: response = http.HttpResponseNotModified() else: response['ETag'] = etag diff --git a/django/newforms/forms.py b/django/newforms/forms.py index 952530bbd5..902ad616ed 100644 --- a/django/newforms/forms.py +++ b/django/newforms/forms.py @@ -63,7 +63,7 @@ class BaseForm(StrAndUnicode): self.auto_id = auto_id self.prefix = prefix self.initial = initial or {} - self.__errors = None # Stores the errors after clean() has been called. + self._errors = None # Stores the errors after clean() has been called. # The base_fields class attribute is the *class-wide* definition of # fields. Because a particular *instance* of the class might want to @@ -87,12 +87,12 @@ class BaseForm(StrAndUnicode): raise KeyError('Key %r not found in Form' % name) return BoundField(self, field, name) - def _errors(self): + def _get_errors(self): "Returns an ErrorDict for self.data" - if self.__errors is None: + if self._errors is None: self.full_clean() - return self.__errors - errors = property(_errors) + return self._errors + errors = property(_get_errors) def is_valid(self): """ @@ -189,11 +189,11 @@ class BaseForm(StrAndUnicode): def full_clean(self): """ - Cleans all of self.data and populates self.__errors and self.cleaned_data. + Cleans all of self.data and populates self._errors and + self.cleaned_data. """ - errors = ErrorDict() + self._errors = ErrorDict() if not self.is_bound: # Stop further processing. - self.__errors = errors return self.cleaned_data = {} for name, field in self.fields.items(): @@ -206,16 +206,17 @@ class BaseForm(StrAndUnicode): self.cleaned_data[name] = value if hasattr(self, 'clean_%s' % name): value = getattr(self, 'clean_%s' % name)() - self.cleaned_data[name] = value + self.cleaned_data[name] = value except ValidationError, e: - errors[name] = e.messages + self._errors[name] = e.messages + if name in self.cleaned_data: + del self.cleaned_data[name] try: self.cleaned_data = self.clean() except ValidationError, e: - errors[NON_FIELD_ERRORS] = e.messages - if errors: + self._errors[NON_FIELD_ERRORS] = e.messages + if self._errors: delattr(self, 'cleaned_data') - self.__errors = errors def clean(self): """ diff --git a/django/oldforms/__init__.py b/django/oldforms/__init__.py index eed73ab156..5814eef7ff 100644 --- a/django/oldforms/__init__.py +++ b/django/oldforms/__init__.py @@ -782,7 +782,7 @@ class DecimalField(TextField): try: import decimal except ImportError: - from django.utils import decimal + from django.utils import _decimal as decimal try: return decimal.Decimal(data) except decimal.InvalidOperation, e: diff --git a/django/template/__init__.py b/django/template/__init__.py index 9811a5649d..4f2ddfc8b3 100644 --- a/django/template/__init__.py +++ b/django/template/__init__.py @@ -479,7 +479,7 @@ class TokenParser(object): while i < len(subject) and subject[i] != c: i += 1 if i >= len(subject): - raise TemplateSyntaxError, "Searching for value. Unexpected end of string in column %d: %s" % subject + raise TemplateSyntaxError, "Searching for value. Unexpected end of string in column %d: %s" % (i, subject) i += 1 s = subject[p:i] while i < len(subject) and subject[i] in (' ', '\t'): diff --git a/django/template/defaulttags.py b/django/template/defaulttags.py index 1ebb01442e..371b57e430 100644 --- a/django/template/defaulttags.py +++ b/django/template/defaulttags.py @@ -237,7 +237,7 @@ class RegroupNode(Node): return '' output = [] # list of dictionaries in the format {'grouper': 'key', 'list': [list of contents]} for obj in obj_list: - grouper = self.expression.resolve(Context({'var': obj}), True) + grouper = self.expression.resolve(obj, True) # TODO: Is this a sensible way to determine equality? if output and repr(output[-1]['grouper']) == repr(grouper): output[-1]['list'].append(obj) @@ -847,7 +847,7 @@ def regroup(parser, token): if lastbits_reversed[1][::-1] != 'as': raise TemplateSyntaxError, "next-to-last argument to 'regroup' tag must be 'as'" - expression = parser.compile_filter('var.%s' % lastbits_reversed[2][::-1]) + expression = parser.compile_filter(lastbits_reversed[2][::-1]) var_name = lastbits_reversed[0][::-1] return RegroupNode(target, expression, var_name) diff --git a/django/test/doctest.py b/django/test/_doctest.py index 3b364f0a75..8777a2cbba 100644 --- a/django/test/doctest.py +++ b/django/test/_doctest.py @@ -1,3 +1,8 @@ +# This is a slightly modified version of the doctest.py that shipped with Python 2.4 +# It incorporates changes that have been submitted the the Python ticket tracker +# as ticket #1521051. These changes allow for a DoctestRunner and Doctest base +# class to be specified when constructing a DoctestSuite. + # Module doctest. # Released to the public domain 16-Jan-2001, by Tim Peters (tim@python.org). # Major enhancements and refactoring by: diff --git a/django/test/simple.py b/django/test/simple.py index cfaa09a0a4..5f7f86f220 100644 --- a/django/test/simple.py +++ b/django/test/simple.py @@ -1,5 +1,6 @@ -import unittest, doctest +import unittest from django.conf import settings +from django.test import _doctest as doctest from django.test.utils import setup_test_environment, teardown_test_environment from django.test.utils import create_test_db, destroy_test_db from django.test.testcases import OutputChecker, DocTestRunner diff --git a/django/test/testcases.py b/django/test/testcases.py index dd1f73befd..2bc1b5a5f8 100644 --- a/django/test/testcases.py +++ b/django/test/testcases.py @@ -1,8 +1,9 @@ -import re, doctest, unittest +import re, unittest from urlparse import urlparse from django.db import transaction from django.core import management, mail from django.db.models import get_apps +from django.test import _doctest as doctest from django.test.client import Client normalize_long_ints = lambda s: re.sub(r'(?<![\w])(\d+)L(?![\w])', '\\1', s) diff --git a/django/test/utils.py b/django/test/utils.py index aa2b8321be..f5122fa96d 100644 --- a/django/test/utils.py +++ b/django/test/utils.py @@ -73,6 +73,20 @@ def _set_autocommit(connection): elif hasattr(connection.connection, "set_isolation_level"): connection.connection.set_isolation_level(0) +def get_mysql_create_suffix(): + suffix = [] + if settings.TEST_DATABASE_CHARSET: + suffix.append('CHARACTER SET %s' % settings.TEST_DATABASE_CHARSET) + if settings.TEST_DATABASE_COLLATION: + suffix.append('COLLATE %s' % settings.TEST_DATABASE_COLLATION) + return ' '.join(suffix) + +def get_postgresql_create_suffix(): + assert settings.TEST_DATABASE_COLLATION is None, "PostgreSQL does not support collation setting at database creation time." + if settings.TEST_DATABASE_CHARSET: + return "WITH ENCODING '%s'" % settings.TEST_DATABASE_CHARSET + return '' + def create_test_db(verbosity=1, autoclobber=False): if verbosity >= 1: print "Creating test database..." @@ -81,6 +95,12 @@ def create_test_db(verbosity=1, autoclobber=False): if settings.DATABASE_ENGINE == "sqlite3": TEST_DATABASE_NAME = ":memory:" else: + suffix = { + 'postgresql': get_postgresql_create_suffix, + 'postgresql_psycopg2': get_postgresql_create_suffix, + 'mysql': get_mysql_create_suffix, + 'mysql_old': get_mysql_create_suffix, + }.get(settings.DATABASE_ENGINE, lambda: '')() if settings.TEST_DATABASE_NAME: TEST_DATABASE_NAME = settings.TEST_DATABASE_NAME else: @@ -92,7 +112,7 @@ def create_test_db(verbosity=1, autoclobber=False): cursor = connection.cursor() _set_autocommit(connection) try: - cursor.execute("CREATE DATABASE %s" % backend.quote_name(TEST_DATABASE_NAME)) + cursor.execute("CREATE DATABASE %s %s" % (backend.quote_name(TEST_DATABASE_NAME), suffix)) except Exception, e: sys.stderr.write("Got an error creating the test database: %s\n" % e) if not autoclobber: @@ -104,7 +124,7 @@ def create_test_db(verbosity=1, autoclobber=False): cursor.execute("DROP DATABASE %s" % backend.quote_name(TEST_DATABASE_NAME)) if verbosity >= 1: print "Creating test database..." - cursor.execute("CREATE DATABASE %s" % backend.quote_name(TEST_DATABASE_NAME)) + cursor.execute("CREATE DATABASE %s %s" % (backend.quote_name(TEST_DATABASE_NAME), suffix)) except Exception, e: sys.stderr.write("Got an error recreating the test database: %s\n" % e) sys.exit(2) diff --git a/django/utils/feedgenerator.py b/django/utils/feedgenerator.py index aa315b5292..2c82e9a37a 100644 --- a/django/utils/feedgenerator.py +++ b/django/utils/feedgenerator.py @@ -168,6 +168,8 @@ class Rss201rev2Feed(RssFeed): (item['author_email'], item['author_name'])) elif item["author_email"]: handler.addQuickElement(u"author", item["author_email"]) + elif item["author_name"]: + handler.addQuickElement(u"dc:creator", item["author_name"], {"xmlns:dc": u"http://purl.org/dc/elements/1.1/"}) if item['pubdate'] is not None: handler.addQuickElement(u"pubDate", rfc2822_date(item['pubdate']).decode('ascii')) diff --git a/docs/add_ons.txt b/docs/add_ons.txt index 4f45d99d9a..ffc4f7420f 100644 --- a/docs/add_ons.txt +++ b/docs/add_ons.txt @@ -6,8 +6,9 @@ Django aims to follow Python's `"batteries included" philosophy`_. It ships with a variety of extra, optional tools that solve common Web-development problems. -This code lives in ``django/contrib`` in the Django distribution. Here's a -rundown of the packages in ``contrib``: +This code lives in ``django/contrib`` in the Django distribution. This document +gives a rundown of the packages in ``contrib``, along with any dependencies +those packages have. .. admonition:: Note @@ -26,6 +27,8 @@ The automatic Django administrative interface. For more information, see .. _Tutorial 2: ../tutorial02/ +Requires the auth_ and contenttypes_ contrib packages to be installed. + auth ==== @@ -144,6 +147,8 @@ See the `flatpages documentation`_. .. _flatpages documentation: ../flatpages/ +Requires the sites_ contrib package to be installed as well. + localflavor =========== diff --git a/docs/db-api.txt b/docs/db-api.txt index de612e0e3d..775913d693 100644 --- a/docs/db-api.txt +++ b/docs/db-api.txt @@ -134,6 +134,15 @@ the database until you explicitly call ``save()``. The ``save()`` method has no return value. +Updating ``ForeignKey`` fields works exactly the same way; simply assign an +object of the right type to the field in question:: + + joe = Author.objects.create(name="Joe") + entry.author = joe + entry.save() + +Django will complain if you try to assign an object of the wrong type. + How Django knows to UPDATE vs. INSERT ------------------------------------- @@ -1229,8 +1238,8 @@ whose ``headline`` contains ``'Lennon'``:: Blog.objects.filter(entry__headline__contains='Lennon') -Escaping parenthesis and underscores in LIKE statements -~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +Escaping percent signs and underscores in LIKE statements +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ The field lookups that equate to ``LIKE`` SQL statements (``iexact``, ``contains``, ``icontains``, ``startswith``, ``istartswith``, ``endswith`` @@ -1748,7 +1757,8 @@ Shortcuts As you develop views, you will discover a number of common idioms in the way you use the database API. Django encodes some of these idioms as -shortcuts that can be used to simplify the process of writing views. +shortcuts that can be used to simplify the process of writing views. These +functions are in the ``django.shortcuts`` module. get_object_or_404() ------------------- diff --git a/docs/django-admin.txt b/docs/django-admin.txt index cc2eadc365..d20db7edc9 100644 --- a/docs/django-admin.txt +++ b/docs/django-admin.txt @@ -295,7 +295,7 @@ Serving static files with the development server ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ By default, the development server doesn't serve any static files for your site -(such as CSS files, images, things under ``MEDIA_ROOT_URL`` and so forth). If +(such as CSS files, images, things under ``MEDIA_URL`` and so forth). If you want to configure Django to serve static media, read the `serving static files`_ documentation. @@ -403,9 +403,10 @@ this command to install the default apps. If you're installing the ``django.contrib.auth`` application, ``syncdb`` will give you the option of creating a superuser immediately. -``syncdb`` will also search for and install any fixture named ``initial_data``. -See the documentation for ``loaddata`` for details on the specification of -fixture data files. +``syncdb`` will also search for and install any fixture named ``initial_data`` +with an appropriate extension (e.g. ``json`` or ``xml``). See the +documentation for ``loaddata`` for details on the specification of fixture +data files. test ---- diff --git a/docs/fastcgi.txt b/docs/fastcgi.txt index 119688096f..81888bba76 100644 --- a/docs/fastcgi.txt +++ b/docs/fastcgi.txt @@ -203,7 +203,7 @@ This is probably the most common case, if you're using Django's admin site:: DocumentRoot /home/user/public_html Alias /media /home/user/python/django/contrib/admin/media RewriteEngine On - RewriteRule ^/(media.*)$ /$1 [QSA,L] + RewriteRule ^/(media.*)$ /$1 [QSA,L,PT] RewriteCond %{REQUEST_FILENAME} !-f RewriteRule ^/(.*)$ /mysite.fcgi/$1 [QSA,L] </VirtualHost> diff --git a/docs/generic_views.txt b/docs/generic_views.txt index bb5f7320f6..359a82506a 100644 --- a/docs/generic_views.txt +++ b/docs/generic_views.txt @@ -99,6 +99,9 @@ which is a dictionary of the parameters captured in the URL. dictionary is callable, the generic view will call it just before rendering the template. + * ``mimetype``: The MIME type to use for the resulting document. Defaults + to the value of the ``DEFAULT_CONTENT_TYPE`` setting. + **Example:** Given the following URL patterns:: diff --git a/docs/install.txt b/docs/install.txt index c3ccd27f76..4f5a4bbe31 100644 --- a/docs/install.txt +++ b/docs/install.txt @@ -97,7 +97,9 @@ This file should also be located in your ``site-packages`` directory. * If you're using Windows: ``C:\Python2.X\lib\site-packages`` - * If you're using MacOSX: ``/Library/Python2.X/site-packages`` + * If you're using MacOSX: ``/Library/Python2.X/site-packages`` or + ``/Library/Frameworks/Python.framework/Versions/2.X/lib/python2.X/site-packages/`` + (in later releases). Install the Django code ======================= diff --git a/docs/model-api.txt b/docs/model-api.txt index ae1c37fc8f..a6bb8a5cfc 100644 --- a/docs/model-api.txt +++ b/docs/model-api.txt @@ -269,6 +269,13 @@ For example, say your ``MEDIA_ROOT`` is set to ``'/home/media'``, and upload a file on Jan. 15, 2007, it will be saved in the directory ``/home/media/photos/2007/01/15``. +If you want to retrieve the upload file's on-disk filename, or a URL that +refers to that file, or the file's size, you can use the +``get_FOO_filename()``, ``get_FOO_url()`` and ``get_FOO_size()`` methods. +They are all documented here__. + +__ ../db-api/#get-foo-filename + Note that whenever you deal with uploaded files, you should pay close attention to where you're uploading them and what type of files they are, to avoid security holes. *Validate all uploaded files* so that you're sure the files are @@ -338,9 +345,14 @@ image. Has two extra optional arguments, ``height_field`` and ``width_field``, which, if set, will be auto-populated with the height and width of the image each time a model instance is saved. +In addition to the special ``get_FOO_*`` methods that are available for +``FileField``, an ``ImageField`` also has ``get_FOO_height()`` and +``get_FOO_width()`` methods. These are documented elsewhere_. + Requires the `Python Imaging Library`_. .. _Python Imaging Library: http://www.pythonware.com/products/pil/ +.. _elsewhere: ../db-api/#get-foo-height-and-get-foo-width ``IntegerField`` ~~~~~~~~~~~~~~~~ @@ -463,8 +475,10 @@ If ``True``, Django will store empty values as ``NULL`` in the database. Default is ``False``. Note that empty string values will always get stored as empty strings, not -as ``NULL`` -- so use ``null=True`` for non-string fields such as integers, -booleans and dates. +as ``NULL``. Only use ``null=True`` for non-string fields such as integers, +booleans and dates. For both types of fields, you will also need to set +``blank=True`` if you wish to permit empty values in forms, as the ``null`` +parameter only affects database storage (see blank_, below). Avoid using ``null`` on string-based fields such as ``CharField`` and ``TextField`` unless you have an excellent reason. If a string-based field @@ -1846,14 +1860,15 @@ rows. Example:: row = cursor.fetchone() return row -``connection`` and ``cursor`` simply use the standard `Python DB-API`_. If -you're not familiar with the Python DB-API, note that the SQL statement in -``cursor.execute()`` uses placeholders, ``"%s"``, rather than adding parameters -directly within the SQL. If you use this technique, the underlying database -library will automatically add quotes and escaping to your parameter(s) as -necessary. (Also note that Django expects the ``"%s"`` placeholder, *not* the -``"?"`` placeholder, which is used by the SQLite Python bindings. This is for -the sake of consistency and sanity.) +``connection`` and ``cursor`` mostly implement the standard `Python DB-API`_ +(except when it comes to `transaction handling`_). If you're not familiar with +the Python DB-API, note that the SQL statement in ``cursor.execute()`` uses +placeholders, ``"%s"``, rather than adding parameters directly within the SQL. +If you use this technique, the underlying database library will automatically +add quotes and escaping to your parameter(s) as necessary. (Also note that +Django expects the ``"%s"`` placeholder, *not* the ``"?"`` placeholder, which is +used by the SQLite Python bindings. This is for the sake of consistency and +sanity.) A final note: If all you want to do is a custom ``WHERE`` clause, you can just just the ``where``, ``tables`` and ``params`` arguments to the standard lookup @@ -1861,6 +1876,7 @@ API. See `Other lookup options`_. .. _Python DB-API: http://www.python.org/peps/pep-0249.html .. _Other lookup options: ../db-api/#extra-params-select-where-tables +.. _transaction handling: ../transactions/ Overriding default model methods -------------------------------- diff --git a/docs/modpython.txt b/docs/modpython.txt index 37909a09fd..388a6168f3 100644 --- a/docs/modpython.txt +++ b/docs/modpython.txt @@ -51,9 +51,17 @@ whereas ``<Location>`` points at places in the URL structure of a Web site. ``<Directory>`` would be meaningless here. Also, if you've manually altered your ``PYTHONPATH`` to put your Django project -on it, you'll need to tell mod_python:: +on it, you'll need to tell mod_python: - PythonPath "['/path/to/project'] + sys.path" +.. parsed-literal:: + + <Location "/mysite/"> + SetHandler python-program + PythonHandler django.core.handlers.modpython + SetEnv DJANGO_SETTINGS_MODULE mysite.settings + PythonDebug On + **PythonPath "['/path/to/project'] + sys.path"** + </Location> .. caution:: @@ -211,6 +219,41 @@ Here are two recommended approaches: 2. Or, copy the admin media files so that they live within your Apache document root. +Using eggs with mod_python +========================== + +If you installed Django from a Python egg_ or are using eggs in your Django +project, some extra configuration is required. Create an extra file in your +project (or somewhere else) that contains something like the following:: + + import os + os.environ['PYTHON_EGG_CACHE'] = '/some/directory' + +Here, ``/some/directory`` is a directory that the Apache webserver process can +write to. It will be used as the location for any unpacking of code the eggs +need to do. + +Then you have to tell mod_python to import this file before doing anything +else. This is done using the PythonImport_ directive to mod_python. You need +to ensure that you have specified the ``PythonInterpreter`` directive to +mod_python as described above__ (you need to do this even if you aren't +serving multiple installations in this case). Then add the ``PythonImport`` +line inside the ``Location`` or ``VirtualHost`` section. For example:: + + PythonInterpreter my_django + PythonImport /path/to/my/project/file.py my_django + +Note that you can use an absolute path here (or a normal dotted import path), +as described in the `mod_python manual`_. We use an absolute path in the +above example because if any Python path modifications are required to access +your project, they will not have been done at the time the ``PythonImport`` +line is processed. + +.. _Egg: http://peak.telecommunity.com/DevCenter/PythonEggs +.. _PythonImport: http://www.modpython.org/live/current/doc-html/dir-other-pimp.html +.. _mod_python manual: PythonImport_ +__ `Multiple Django installations on the same Apache`_ + Error handling ============== @@ -256,3 +299,5 @@ as necessary. .. _Expat Causing Apache Crash: http://www.dscpl.com.au/articles/modpython-006.html .. _mod_python FAQ entry: http://modpython.org/FAQ/faqw.py?req=show&file=faq02.013.htp .. _Getting mod_python Working: http://www.dscpl.com.au/articles/modpython-001.html + + diff --git a/docs/newforms.txt b/docs/newforms.txt index 7ec4e9560c..bb6c179648 100644 --- a/docs/newforms.txt +++ b/docs/newforms.txt @@ -686,13 +686,13 @@ For example:: <form method="post"> <ul class="myformclass"> - <li>{{ form.sender.label }} {{ form.sender.label }}</li> + <li>{{ form.sender.label }} {{ form.sender }}</li> <li class="helptext">{{ form.sender.help_text }}</li> - {% if form.sender.errors %}<ul class="errorlist">{{ form.sender.errors }}</dd>{% endif %} + {% if form.sender.errors %}<ul class="errorlist">{{ form.sender.errors }}</ul>{% endif %} - <li>{{ form.subject.label }} {{ form.subject.label }}</li> + <li>{{ form.subject.label }} {{ form.subject }}</li> <li class="helptext">{{ form.subject.help_text }}</li> - {% if form.subject.errors %}<ul class="errorlist">{{ form.subject.errors }}</dd>{% endif %} + {% if form.subject.errors %}<ul class="errorlist">{{ form.subject.errors }}</ul>{% endif %} ... </ul> diff --git a/docs/serialization.txt b/docs/serialization.txt index 3216cb061e..01afa2708c 100644 --- a/docs/serialization.txt +++ b/docs/serialization.txt @@ -44,6 +44,25 @@ This is useful if you want to serialize data directly to a file-like object .. _HTTPResponse: ../request_response/#httpresponse-objects +Subset of fields +~~~~~~~~~~~~~~~~ + +If you only want a subset of fields to be serialized, you can +specify a `fields` argument to the serializer:: + + from django.core import serializers + data = serializers.serialize('xml', SomeModel.objects.all(), fields=('name','size')) + +In this example, only the `name` and `size` attributes of each model will +be serialized. + +.. note:: + + Depending on your model, you may find that it is not possible to deserialize + a model that only serializes a subset of its fields. If a serialized object + doesn't specify all the fields that are required by a model, the deserializer + will not be able to save deserialized instances. + Deserializing data ------------------ @@ -92,10 +111,14 @@ Django "ships" with a few included serializers: ``python`` Translates to and from "simple" Python objects (lists, dicts, strings, etc.). Not really all that useful on its own, but used as a base for other serializers. + + ``yaml`` Serializes to YAML (Yet Another Markup Lanuage). This + serializer is only available if PyYAML_ is installed. ========== ============================================================== .. _json: http://json.org/ .. _simplejson: http://undefined.org/python/#simplejson +.. _PyYAML: http://www.pyyaml.org/ Notes for specific serialization formats ---------------------------------------- diff --git a/docs/settings.txt b/docs/settings.txt index bf0a9f85f6..12e6dab4bc 100644 --- a/docs/settings.txt +++ b/docs/settings.txt @@ -264,6 +264,11 @@ MySQL will connect via a Unix socket to the specified socket. For example:: If you're using MySQL and this value *doesn't* start with a forward slash, then this value is assumed to be the host. +If you're using PostgreSQL, an empty string means to use a Unix domain socket +for the connection, rather than a network connection to localhost. If you +explictly need to use a TCP/IP connection on the local machine with +PostgreSQL, specify ``localhost`` here. + DATABASE_NAME ------------- @@ -771,7 +776,8 @@ Default:: ("django.core.context_processors.auth", "django.core.context_processors.debug", - "django.core.context_processors.i18n") + "django.core.context_processors.i18n", + "django.core.context_processors.media") A tuple of callables that are used to populate the context in ``RequestContext``. These callables take a request object as their argument and return a dictionary @@ -820,26 +826,57 @@ misspelled) variables. See `How invalid variables are handled`_. .. _How invalid variables are handled: ../templates_python/#how-invalid-variables-are-handled -TEST_RUNNER ------------ +TEST_DATABASE_CHARSET +--------------------- -Default: ``'django.test.simple.run_tests'`` +**New in Django development version** -The name of the method to use for starting the test suite. See -`Testing Django Applications`_. +Default: ``None`` -.. _Testing Django Applications: ../testing/ +The character set encoding used to create the test database. The value of this +string is passed directly through to the database, so its format is +backend-specific. + +Supported for the PostgreSQL_ (``postgresql``, ``postgresql_psycopg2``) and MySQL_ (``mysql``, ``mysql_old``) backends. + +.. _PostgreSQL: http://www.postgresql.org/docs/8.2/static/multibyte.html +.. _MySQL: http://www.mysql.org/doc/refman/5.0/en/charset-database.html + +TEST_DATABASE_COLLATION +------------------------ + +**New in Django development version** + +Default: ``None`` + +The collation order to use when creating the test database. This value is +passed directly to the backend, so its format is backend-specific. + +Only supported for ``mysql`` and ``mysql_old`` backends (see `section 10.3.2`_ +of the MySQL manual for details). + +.. _section 10.3.2: http://www.mysql.org/doc/refman/5.0/en/charset-database.html TEST_DATABASE_NAME ------------------ Default: ``None`` -The name of database to use when running the test suite. If a value of +The name of database to use when running the test suite. If a value of ``None`` is specified, the test database will use the name ``'test_' + settings.DATABASE_NAME``. See `Testing Django Applications`_. .. _Testing Django Applications: ../testing/ +TEST_RUNNER +----------- + +Default: ``'django.test.simple.run_tests'`` + +The name of the method to use for starting the test suite. See +`Testing Django Applications`_. + +.. _Testing Django Applications: ../testing/ + TIME_FORMAT ----------- diff --git a/docs/templates.txt b/docs/templates.txt index 2f9f769b96..d8b511dedc 100644 --- a/docs/templates.txt +++ b/docs/templates.txt @@ -91,9 +91,12 @@ Filters can be "chained." The output of one filter is applied to the next. ``{{ text|escape|linebreaks }}`` is a common idiom for escaping text contents, then converting line breaks to ``<p>`` tags. -Some filters take arguments. A filter argument looks like this: -``{{ bio|truncatewords:"30" }}``. This will display the first 30 words of the -``bio`` variable. Filter arguments always are in double quotes. +Some filters take arguments. A filter argument looks like this: ``{{ +bio|truncatewords:30 }}``. This will display the first 30 words of the ``bio`` +variable. + +Filter arguments that contain spaces must be quoted; for example, to join a list +with commas and spaced you'd use ``{{ list|join:", " }}``. The `Built-in filter reference`_ below describes all the built-in filters. @@ -112,7 +115,7 @@ know how to write Python code. Comments ======== -To comment-out part of a template, use the comment syntax: ``{# #}``. +To comment-out part of a line in a template, use the comment syntax: ``{# #}``. For example, this template would render as ``'hello'``:: @@ -122,6 +125,12 @@ A comment can contain any template code, invalid or not. For example:: {# {% if foo %}bar{% else %} #} +This syntax can only be used for single-line comments (no newlines are +permitted between the ``{#`` and ``#}`` delimiters). If you need to comment +out a multiline portion of the template, see the ``comment`` tag, below__. + +__ comment_ + Template inheritance ==================== @@ -843,10 +852,11 @@ The first argument is a path to a view function in the format should be comma-separated values that will be used as positional and keyword arguments in the URL. All arguments required by the URLconf should be present. -For example, suppose you have a view, ``app_name.client``, whose URLconf takes -a client ID. The URLconf line might look like this:: +For example, suppose you have a view, ``app_views.client``, whose URLconf +takes a client ID (here, ``client()`` is a method inside the views file +``app_views.py``). The URLconf line might look like this:: - ('^client/(\d+)/$', 'app_name.client') + ('^client/(\d+)/$', 'app_views.client') If this app's URLconf is included into the project's URLconf under a path such as this:: @@ -855,7 +865,7 @@ such as this:: ...then, in a template, you can create a link to this view like this:: - {% url app_name.client client.id %} + {% url app_views.client client.id %} The template tag will output the string ``/clients/client/123/``. diff --git a/docs/templates_python.txt b/docs/templates_python.txt index 08a287f572..f3e2f2c64b 100644 --- a/docs/templates_python.txt +++ b/docs/templates_python.txt @@ -294,7 +294,8 @@ return a dictionary of items to be merged into the context. By default, ("django.core.context_processors.auth", "django.core.context_processors.debug", - "django.core.context_processors.i18n") + "django.core.context_processors.i18n", + "django.core.context_processors.media") Each processor is applied in order. That means, if one processor adds a variable to the context and a second processor adds a variable with the same @@ -390,6 +391,15 @@ See the `internationalization docs`_ for more. .. _LANGUAGE_CODE setting: ../settings/#language-code .. _internationalization docs: ../i18n/ +django.core.context_processors.media +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ + +If ``TEMPLATE_CONTEXT_PROCESSORS`` contains this processor, every +``RequestContext`` will contain a variable ``MEDIA_URL``, providing the +value of the `MEDIA_URL setting`_. + +.. _MEDIA_URL setting: ../settings/#media-url + django.core.context_processors.request ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ diff --git a/docs/testing.txt b/docs/testing.txt index 92edf46e09..50c4ec3046 100644 --- a/docs/testing.txt +++ b/docs/testing.txt @@ -4,7 +4,7 @@ Testing Django applications Automated testing is an extremely useful bug-killing tool for the modern Web developer. You can use a collection of tests -- a **test suite** -- to -to solve, or avoid, a number of problems: +solve, or avoid, a number of problems: * When you're writing new code, you can use tests to validate your code works as expected. @@ -147,7 +147,7 @@ doctests or unit tests are right for you. If you've been using Python for a while, ``doctest`` will probably feel more "pythonic". It's designed to make writing tests as easy as possible, so there's no overhead of writing classes or methods; you simply put tests in -docstrings. This gives the added advantage of given your modules automatic +docstrings. This gives the added advantage of giving your modules automatic documentation -- well-written doctests can kill both the documentation and the testing bird with a single stone. @@ -571,6 +571,14 @@ database settings will the same as they would be for the project normally. If you wish to use a name other than the default for the test database, you can use the ``TEST_DATABASE_NAME`` setting to provide a name. +**New in Django development version:** For fine-grained control over the +character encoding of your database, use the ``TEST_DATABASE_CHARSET`` setting. +If you're using MySQL, you can also use the ``TEST_DATABASE_COLLATION`` setting +to control the particular collation used by the test database. See the +settings_ documentation for details of these advanced settings. + +.. _settings: ../settings/ + The test database is created by the user in the ``DATABASE_USER`` setting. This user needs to have sufficient privileges to create a new database on the system. diff --git a/docs/tutorial03.txt b/docs/tutorial03.txt index 8bb63791aa..41febe021d 100644 --- a/docs/tutorial03.txt +++ b/docs/tutorial03.txt @@ -60,9 +60,10 @@ arguments from the dictionary (an optional third item in the tuple). For more on ``HTTPRequest`` objects, see the `request and response documentation`_. For more details on URLconfs, see the `URLconf documentation`_. -When you ran ``python manage.py startproject mysite`` at the beginning of +When you ran ``python django-admin.py startproject mysite`` at the beginning of Tutorial 1, it created a default URLconf in ``mysite/urls.py``. It also -automatically set your ``ROOT_URLCONF`` setting to point at that file:: +automatically set your ``ROOT_URLCONF`` setting (in ``settings.py``) to point +at that file:: ROOT_URLCONF = 'mysite.urls' diff --git a/docs/tutorial04.txt b/docs/tutorial04.txt index 6fee842f8b..5cc12c445d 100644 --- a/docs/tutorial04.txt +++ b/docs/tutorial04.txt @@ -48,6 +48,7 @@ So let's create a ``vote()`` function in ``mysite/polls/views.py``:: from django.shortcuts import get_object_or_404, render_to_response from django.http import HttpResponseRedirect + from django.core.urlresolvers import reverse from mysite.polls.models import Choice, Poll # ... def vote(request, poll_id): @@ -66,7 +67,7 @@ So let's create a ``vote()`` function in ``mysite/polls/views.py``:: # Always return an HttpResponseRedirect after successfully dealing # with POST data. This prevents data from being posted twice if a # user hits the Back button. - return HttpResponseRedirect('/polls/%s/results/' % p.id) + return HttpResponseRedirect(reverse('mysite.polls.views.results', args=(p.id,))) This code includes a few things we haven't covered yet in this tutorial: @@ -86,13 +87,29 @@ This code includes a few things we haven't covered yet in this tutorial: * After incrementing the choice count, the code returns an ``HttpResponseRedirect`` rather than a normal ``HttpResponse``. ``HttpResponseRedirect`` takes a single argument: the URL to which the - user will be redirected. You should leave off the "http://" and domain - name if you can. That helps your app become portable across domains. + user will be redirected (see the following point for how we construct + the URL in this case). As the Python comment above points out, you should always return an ``HttpResponseRedirect`` after successfully dealing with POST data. This tip isn't specific to Django; it's just good Web development practice. + * We are using the ``reverse()`` function in the ``HttpResponseRedirect`` + constructor in this example. This function helps avoid having to + hardcode a URL in the view function. It is given the name of the view + that we want to pass control to and the variable portion of the URL + pattern that points to that view. In this case, using the URLConf we set + up in Tutorial 3, this ``reverse()`` call will return a string like :: + + '/polls/3/results/' + + ... where the ``3`` is the value of ``p.id``. This redirected URL will + then call the ``'results'`` view to display the final page. Note that + you need to use the full name of the view here (including the prefix). + + For more information about ``reverse()``, see the `URL dispatcher`_ + documentation. + As mentioned in Tutorial 3, ``request`` is a ``HTTPRequest`` object. For more on ``HTTPRequest`` objects, see the `request and response documentation`_. @@ -121,6 +138,7 @@ results page that gets updated each time you vote. If you submit the form without having chosen a choice, you should see the error message. .. _request and response documentation: ../request_response/ +.. _URL dispatcher: ../url_dispatch#reverse Use generic views: Less code is better ====================================== @@ -256,4 +274,8 @@ installments: * Advanced admin features: Permissions * Advanced admin features: Custom JavaScript +In the meantime, you can read through the rest of the `Django documentation`_ +and start writing your own applications. + .. _Tutorial 3: ../tutorial03/ +.. _Django documentation: http://www.djangoproject.com/documentation/ diff --git a/docs/url_dispatch.txt b/docs/url_dispatch.txt index 39eed0625b..402b1200b5 100644 --- a/docs/url_dispatch.txt +++ b/docs/url_dispatch.txt @@ -551,3 +551,38 @@ not restricted to valid Python names. Putting a prefix on your URL names, perhaps derived from the application name, will decrease the chances of collision. We recommend something like ``myapp-comment`` instead of ``comment``. + +Utility methods +=============== + +reverse() +--------- + +If you need to use something similar to the ``{% url %}`` template tag in your +code, Django provides the ``django.core.urlresolvers.reverse()``. The +``reverse()`` function has the following signature:: + + reverse(viewname, urlconf=None, args=None, kwargs=None) + +``viewname`` is either the function name (either a function reference, or the +string version of the name, if you used that form in ``urlpatterns``) or the +`URL pattern name`_. Normally, you won't need to worry about the +``urlconf`` parameter and will only pass in the positional and keyword +arguments to use in the URL matching. For example:: + + from django.core.urlresolvers import reverse + + def myview(request): + return HttpResponseRedirect(reverse('arch-summary', args=[1945])) + +.. _URL pattern name: `Naming URL patterns`_ + +permalink() +----------- + +The ``permalink()`` decorator is useful for writing short methods that return +a full URL path. For example, a model's ``get_absolute_url()`` method. Refer +to the `model API documentation`_ for more information about ``permalink()``. + +.. _model API documentation: ../model-api/#the-permalink-decorator + diff --git a/tests/modeltests/lookup/models.py b/tests/modeltests/lookup/models.py index c634aef8a1..6af70f8351 100644 --- a/tests/modeltests/lookup/models.py +++ b/tests/modeltests/lookup/models.py @@ -131,6 +131,27 @@ True [('headline', 'Article 7'), ('id', 7)] [('headline', 'Article 1'), ('id', 1)] + +# you can use values() even on extra fields +>>> for d in Article.objects.extra( select={'id_plus_one' : 'id + 1'} ).values('id', 'id_plus_one'): +... i = d.items() +... i.sort() +... i +[('id', 5), ('id_plus_one', 6)] +[('id', 6), ('id_plus_one', 7)] +[('id', 4), ('id_plus_one', 5)] +[('id', 2), ('id_plus_one', 3)] +[('id', 3), ('id_plus_one', 4)] +[('id', 7), ('id_plus_one', 8)] +[('id', 1), ('id_plus_one', 2)] + +# however, an exception FieldDoesNotExist will still be thrown +# if you try to access non-existent field (field that is neither on the model nor extra) +>>> Article.objects.extra( select={'id_plus_one' : 'id + 1'} ).values('id', 'id_plus_two') +Traceback (most recent call last): + ... +FieldDoesNotExist: Article has no field named 'id_plus_two' + # if you don't specify which fields, all are returned >>> list(Article.objects.filter(id=5).values()) == [{'id': 5, 'headline': 'Article 5', 'pub_date': datetime(2005, 8, 1, 9, 0)}] True diff --git a/tests/modeltests/serializers/models.py b/tests/modeltests/serializers/models.py index 339303fc0a..8d44d5eae7 100644 --- a/tests/modeltests/serializers/models.py +++ b/tests/modeltests/serializers/models.py @@ -159,4 +159,8 @@ __test__ = {'API_TESTS':""" >>> article.author <Author: Agnes> +# Serializer output can be restricted to a subset of fields +>>> print serializers.serialize("json", Article.objects.all(), fields=('headline','pub_date')) +[{"pk": "1", "model": "serializers.article", "fields": {"headline": "Just kidding; I love TV poker", "pub_date": "2006-06-16 11:00:00"}}, {"pk": "2", "model": "serializers.article", "fields": {"headline": "Time to reform copyright", "pub_date": "2006-06-16 13:00:00"}}, {"pk": "3", "model": "serializers.article", "fields": {"headline": "Forward references pose no problem", "pub_date": "2006-06-16 15:00:00"}}] + """} diff --git a/tests/regressiontests/forms/tests.py b/tests/regressiontests/forms/tests.py index 8d219dc0a1..4114919c2e 100644 --- a/tests/regressiontests/forms/tests.py +++ b/tests/regressiontests/forms/tests.py @@ -3656,6 +3656,25 @@ u' id="header"' u' class="news" title="Read this"' >>> flatatt({}) u'' + +#################################### +# Test accessing errors in clean() # +#################################### + +>>> class UserForm(Form): +... username = CharField(max_length=10) +... password = CharField(widget=PasswordInput) +... def clean(self): +... data = self.cleaned_data +... if not self.errors: +... data['username'] = data['username'].lower() +... return data + +>>> f = UserForm({'username': 'SirRobin', 'password': 'blue'}) +>>> f.is_valid() +True +>>> f.cleaned_data['username'] +u'sirrobin' """ __test__ = { diff --git a/tests/regressiontests/serializers_regress/models.py b/tests/regressiontests/serializers_regress/models.py index 999b79ccaf..b441885f10 100644 --- a/tests/regressiontests/serializers_regress/models.py +++ b/tests/regressiontests/serializers_regress/models.py @@ -129,6 +129,9 @@ class M2MSelfData(models.Model): class FKDataToField(models.Model): data = models.ForeignKey(UniqueAnchor, null=True, to_field='data') +class FKDataToO2O(models.Model): + data = models.ForeignKey(O2OData, null=True) + # The following test classes are for validating the # deserialization of objects that use a user-defined # field as the primary key. @@ -202,3 +205,7 @@ class USStatePKData(models.Model): # class XMLPKData(models.Model): # data = models.XMLField(primary_key=True) +class ComplexModel(models.Model): + field1 = models.CharField(maxlength=10) + field2 = models.CharField(maxlength=10) + field3 = models.CharField(maxlength=10) diff --git a/tests/regressiontests/serializers_regress/tests.py b/tests/regressiontests/serializers_regress/tests.py index 5df4c6818a..cd27041eb2 100644 --- a/tests/regressiontests/serializers_regress/tests.py +++ b/tests/regressiontests/serializers_regress/tests.py @@ -9,6 +9,7 @@ forward, backwards and self references. import unittest, datetime +from cStringIO import StringIO from django.utils.functional import curry from django.core import serializers @@ -197,6 +198,8 @@ The end."""), (fk_obj, 451, FKDataToField, "UAnchor 2"), (fk_obj, 452, FKDataToField, None), + (fk_obj, 460, FKDataToO2O, 300), + (data_obj, 500, Anchor, "Anchor 3"), (data_obj, 501, Anchor, "Anchor 4"), (data_obj, 502, UniqueAnchor, "UAnchor 2"), @@ -276,5 +279,41 @@ def serializerTest(format, self): for (func, pk, klass, datum) in test_data: func[1](self, pk, klass, datum) +def fieldsTest(format, self): + # Clear the database first + management.flush(verbosity=0, interactive=False) + + obj = ComplexModel(field1='first',field2='second',field3='third') + obj.save() + + # Serialize then deserialize the test database + serialized_data = serializers.serialize(format, [obj], indent=2, fields=('field1','field3')) + result = serializers.deserialize(format, serialized_data).next() + + # Check that the deserialized object contains data in only the serialized fields. + self.assertEqual(result.object.field1, 'first') + self.assertEqual(result.object.field2, '') + self.assertEqual(result.object.field3, 'third') + +def streamTest(format, self): + # Clear the database first + management.flush(verbosity=0, interactive=False) + + obj = ComplexModel(field1='first',field2='second',field3='third') + obj.save() + + # Serialize the test database to a stream + stream = StringIO() + serializers.serialize(format, [obj], indent=2, stream=stream) + + # Serialize normally for a comparison + string_data = serializers.serialize(format, [obj], indent=2) + + # Check that the two are the same + self.assertEqual(string_data, stream.buffer()) + stream.close() + for format in serializers.get_serializer_formats(): setattr(SerializerTests, 'test_'+format+'_serializer', curry(serializerTest, format)) + setattr(SerializerTests, 'test_'+format+'_serializer_fields', curry(fieldsTest, format)) + setattr(SerializerTests, 'test_'+format+'_serializer_stream', curry(fieldsTest, format)) |
