summaryrefslogtreecommitdiff
path: root/django/db/models/fields
AgeCommit message (Collapse)Author
2013-11-13[1.6.x] Fixed #21410 -- prefetch_related() for ForeignKeys with related_name='+'Loic Bistuer
Regression introduced by commit 9777442. Thanks to trac username troygrosfield for the report and test case. Backpatch of cb83448891f2920c926f61826d8eae4051a3d8f2 from master. Conflicts: tests/prefetch_related/models.py
2013-10-13[1.6.x] Fixed #19560 -- Identified field in warning for naive datetime.Aymeric Augustin
Thanks gcc for the report and vajrasky for the patch. Backport of 570d9c2678d6cc564f9c70138554af8f7ce9ec49 from master.
2013-08-30[1.6.x] Fixed #20999 - Allow overriding formfield class with choices, ↵Carl Meyer
without subclass restrictions. Refs #18162. Thanks claudep and mjtamlyn for review. Backport of 7211741fc5d50425 from master.
2013-08-29[1.6.x] Fixed #14786 -- Fixed get_db_prep_lookup calling get_prep_value ↵Tim Graham
twice if prepared is False. Thanks homm for the report and Aramgutang and lrekucki for work on the patch. Backport of f19a3669b8 from master
2013-08-20[1.6.x] Fixed #20820 -- Model inheritance + m2m fixture loading regressionAnssi Kääriäinen
Tests by Tim Graham, report from jeroen.pulles@redslider.net. Backport of 1ed77e7782 from master
2013-07-26[1.6.x] Fixed related model lookup regressionAnssi Kääriäinen
It has been possible to use models of wrong type in related field lookups. For example pigs__in=[a_duck] has worked. Changes to ForeignObject broke that. It might be a good idea to restrict the model types usable in lookups. This should be done intentionally, not accidentally and without any consideration for deprecation path. Backpatch of 7cca8d56d28e321ffc395c92f82d97adaa0dcf94 from master.
2013-07-23[1.6.x] Fixed #20791 -- Reworded ForeignKey default error messageersran9
Backport of 311c1d2848 from master.
2013-07-23[1.6.x] Minor change to get_extra_descriptor_filter()Anssi Kääriäinen
Refs #20611. Backpatch of 6b4967e88368934dbbb1f289c790ab813fa59c72.
2013-07-12[1.6.x] Fixed backport of #20740Tim Graham
2013-07-12[1.6.x] Fixed #20740 -- GenericIPAddressField should pass protocol to ↵Tim Graham
formfield() Thanks Jeff250. Backport of f2cb94f1c0 from master
2013-06-29[1.6.x] Fixed #20660 -- Do not try to delete an unset FieldFileClaude Paroz
Thanks stanislas.guerra at gmail.com for the report and Baptiste Mispelon for the review. Backport of ea3fe78a9d from master.
2013-06-27Add related_query_name to ForeignKey/M2M. Refs #20244Andrew Godwin
2013-06-18Fixed #20199 -- Allow ModelForm fields to override error_messages from model ↵Loic Bistuer
fields
2013-06-18Refactored ValidationError to allow persisting error params and error codes ↵Loic Bistuer
as the exception bubbles up
2013-06-13Fixed #20594 -- Add validation to models.SlugField.Baptiste Mispelon
Thanks carbonXT for the report.
2013-06-01Fixed #20337 -- Clarified error message when database relation is not allowed.Dan Loewenherz
2013-05-27Fixed #17582 - Added message to DoesNotExist exceptions.Tim Graham
Thanks simon@ for the suggestion and JordanPowell for the initial patch.
2013-05-20Fixed #9321 -- Deprecated hard-coding of help text in model ManyToManyField ↵Ramiro Morales
fields. This is backward incompatible for custom form field/widgets that rely on the hard-coded 'Hold down "Control", or "Command" on a Mac, to select more than one.' sentence. Application that use standard model form fields and widgets aren't affected but need to start handling these help texts by themselves before Django 1.8. For more details, see the related release notes and deprecation timeline sections added with this commit.
2013-05-20Fixed #20378 -- regression in GenericRelation on abstract modelAnssi Kääriäinen
When a GenericRelation was defined on abstract model, queries on childs of the abstract model didn't work. The problem was in the way fields and in particular field.rel was copied from models to their children. The regression was likely caused by #19385. Thanks to Gavin Wahl for spotting the regression.
2013-05-17Replaced an antiquated pattern.Aymeric Augustin
Thanks Lennart Regebro for pointing it out.
2013-05-07Remove unnecessary check on __set__ parameters.Mike Fogel
2013-04-05Fixed #20207 -- Handle ManyToManyField with a unicode name correctly.Simon Charette
2013-04-01Fixed deprecation warnings introduced by ↵Simon Charette
97774429aeb54df4c09895c07cd1b09e70201f7d.
2013-03-24Fixed field.rel.field_name handlingAnssi Kääriäinen
This is a regression fix to multicolumn joins. Refs #19385.
2013-03-24Python 2.6 compatibility for #19385Anssi Kääriäinen
2013-03-24Fixed #19385 again, now with real code changesAnssi Kääriäinen
The commit of 266de5f9ae9e9f2fbfaec3b7e4b5fb9941967801 included only tests, this time also code changes included...
2013-03-24Fixed #15124 -- Changed the default for BooleanField.Aymeric Augustin
Thanks to the many contributors who updated and improved the patch over the life of this ticket.
2013-03-22Fixed #20094 - Be more careful when checking for IteratorMarc Tamlyn
Python 2.6 has some different behaviour when checking isinstance(foo, collections.Iterator).
2013-03-17Fixed #19635 -- Made fields pickleableAnssi Kääriäinen
2013-03-17Merge pull request #902 from evildmp/BLANK_CHOICE_NONEAymeric Augustin
Fixed #20043 -- Removed unused BLANK_CHOICE_NONE
2013-03-13removed unused BLANK_CHOICE_NONEDaniele Procida
2013-03-12Fixed #19964 -- Removed relabel_aliases from some structsAnssi Kääriäinen
Before there was need to have both .relabel_aliases() and .clone() for many structs. Now there is only relabeled_clone() for those structs where alias is the only mutable attribute.
2013-03-08Fixed #15363 -- Renamed and normalized to `get_queryset` the methods that ↵Loic Bistuer
return a QuerySet.
2013-03-07Added a ManyToManyField(db_constraint=False) option, this allows not ↵Alex Gaynor
creating constraints on the intermediary models.
2013-03-06Fixed #19989 -- Suppressed UnicodeWarning during BinaryField validationClaude Paroz
Thanks Aymeric Augustin for the report and Simon Charette for the review.
2013-03-02Added support for serializing BinaryFieldClaude Paroz
2013-03-02Add a BinaryField model fieldClaude Paroz
Thanks Michael Jung, Charl Botha and Florian Apolloner for review and help on the patch.
2013-02-25Fixed #19634 -- Added proper __hash__ methods.Aymeric Augustin
Classes overriding __eq__ need a __hash__ such that equal objects have the same hash. Thanks akaariai for the report and regebro for the patch.
2013-02-23Proposed fix for #18162.Tomek Paczkowski
2013-02-23Fixed #19816: pre-evaluate queryset on m2m setTomek Paczkowski
In ReverseManyRelatedObjectsDescriptor.__set__, evaluate possible queryset to avoid problems when clear() would touch data this queryset returns.
2013-02-23Fixed empty strings + to_field regression on OracleAnssi Kääriäinen
Querying the reverse side of nullable to_field relation, where both sides can contain null values resulted in incorrect results. The reason was not detecting '' as NULL. Refs #17541
2013-02-20Added a db_constraint option to ForeignKeys.Alex Gaynor
This controls whether or not a database level cosntraint is created. This is useful in a few specialized circumstances, but in general should not be used!
2013-02-16Fixed #17260 -- Added time zone aware aggregation and lookups.Aymeric Augustin
Thanks Carl Meyer for the review. Squashed commit of the following: commit 4f290bdb60b7d8534abf4ca901bd0844612dcbda Author: Aymeric Augustin <aymeric.augustin@m4x.org> Date: Wed Feb 13 21:21:30 2013 +0100 Used '0:00' instead of 'UTC' which doesn't always exist in Oracle. Thanks Ian Kelly for the suggestion. commit 01b6366f3ce67d57a58ca8f25e5be77911748638 Author: Aymeric Augustin <aymeric.augustin@m4x.org> Date: Wed Feb 13 13:38:43 2013 +0100 Made tzname a parameter of datetime_extract/trunc_sql. This is required to work around a bug in Oracle. commit 924a144ef8a80ba4daeeafbe9efaa826566e9d02 Author: Aymeric Augustin <aymeric.augustin@m4x.org> Date: Wed Feb 13 14:47:44 2013 +0100 Added support for parameters in SELECT clauses. commit b4351d2890cd1090d3ff2d203fe148937324c935 Author: Aymeric Augustin <aymeric.augustin@m4x.org> Date: Mon Feb 11 22:30:22 2013 +0100 Documented backwards incompatibilities in the two previous commits. commit 91ef84713c81bd455f559dacf790e586d08cacb9 Author: Aymeric Augustin <aymeric.augustin@m4x.org> Date: Mon Feb 11 09:42:31 2013 +0100 Used QuerySet.datetimes for the admin's date_hierarchy. commit 0d0de288a5210fa106cd4350961eb2006535cc5c Author: Aymeric Augustin <aymeric.augustin@m4x.org> Date: Mon Feb 11 09:29:38 2013 +0100 Used QuerySet.datetimes in date-based generic views. commit 9c0859ff7c0b00734afe7fc15609d43d83215072 Author: Aymeric Augustin <aymeric.augustin@m4x.org> Date: Sun Feb 10 21:43:25 2013 +0100 Implemented QuerySet.datetimes on Oracle. commit 68ab511a4ffbd2b811bf5da174d47e4dd90f28fc Author: Aymeric Augustin <aymeric.augustin@m4x.org> Date: Sun Feb 10 21:43:14 2013 +0100 Implemented QuerySet.datetimes on MySQL. commit 22d52681d347a8cdf568dc31ed032cbc61d049ef Author: Aymeric Augustin <aymeric.augustin@m4x.org> Date: Sun Feb 10 21:42:29 2013 +0100 Implemented QuerySet.datetimes on SQLite. commit f6800fd04c93722b45f9236976389e0b2fe436f5 Author: Aymeric Augustin <aymeric.augustin@m4x.org> Date: Sun Feb 10 21:43:03 2013 +0100 Implemented QuerySet.datetimes on PostgreSQL. commit 0c829c23f4cf4d6804cadcc93032dd4c26b8c65e Author: Aymeric Augustin <aymeric.augustin@m4x.org> Date: Sun Feb 10 21:41:08 2013 +0100 Added datetime-handling infrastructure in the ORM layers. commit 104d82a7778cf3f0f5d03dfa53709c26df45daad Author: Aymeric Augustin <aymeric.augustin@m4x.org> Date: Mon Feb 11 10:05:55 2013 +0100 Updated null_queries tests to avoid clashing with the __second lookup. commit c01bbb32358201b3ac8cb4291ef87b7612a2b8e6 Author: Aymeric Augustin <aymeric.augustin@m4x.org> Date: Sun Feb 10 23:07:41 2013 +0100 Updated tests of .dates(). Replaced .dates() by .datetimes() for DateTimeFields. Replaced dates with datetimes in the expected output for DateFields. commit 50fb7a52462fecf0127b38e7f3df322aeb287c43 Author: Aymeric Augustin <aymeric.augustin@m4x.org> Date: Sun Feb 10 21:40:09 2013 +0100 Updated and added tests for QuerySet.datetimes. commit a8451a5004c437190e264667b1e6fb8acc3c1eeb Author: Aymeric Augustin <aymeric.augustin@m4x.org> Date: Sun Feb 10 22:34:46 2013 +0100 Documented the new time lookups and updated the date lookups. commit 29413eab2bd1d5e004598900c0dadc0521bbf4d3 Author: Aymeric Augustin <aymeric.augustin@m4x.org> Date: Sun Feb 10 16:15:49 2013 +0100 Documented QuerySet.datetimes and updated QuerySet.dates.
2013-02-05Fixed #19689 -- Renamed `Model._meta.module_name` to `model_name`.Simon Charette
2013-01-08Fixed #17541 -- Fixed non-saved/nullable fk queryingAnssi Kääriäinen
2013-01-02Fixed #19547 -- Caching of related instances.Aymeric Augustin
When &'ing or |'ing querysets, wrong values could be cached, and crashes could happen. Thanks Marc Tamlyn for figuring out the problem and writing the patch.
2012-12-30Moved join path generation to FieldAnssi Kääriäinen
Refs #19385
2012-12-27Fixed #19525 -- Reverted dcd4383107 and 05d333ba3b.Aymeric Augustin
Refs #9893, #18515. Thanks Russell for the report.
2012-11-04use six.string_types for python3Mike Johnson
2012-11-04model_split: Fixed #19236 - fixed error for abstract models with a split methodMike Johnson