summaryrefslogtreecommitdiff
path: root/django/db/models/fields
AgeCommit message (Collapse)Author
2014-09-03Fixed #18757, #14462, #21565 -- Reworked database-python type conversionsMarc Tamlyn
Complete rework of translating data values from database Deprecation of SubfieldBase, removal of resolve_columns and convert_values in favour of a more general converter based approach and public API Field.from_db_value(). Now works seamlessly with aggregation, .values() and raw queries. Thanks to akaariai in particular for extensive advice and inspiration, also to shaib, manfre and timograham for their reviews.
2014-08-14Fixed #23288: deconstruct() ignoring related_nameAndrew Godwin
2014-08-05Removed code that assumed BooleanField could be null.Tim Graham
Such a field will no longer pass model validation.
2014-08-04Fixed #16311 -- Added a RelatedOnlyFieldListFilter class in admin.filters.Stanislas Guerra
2014-08-03Removed unnecessary code in ManyToManyField.deconstruct()Baptiste Mispelon
2014-08-03Added missing logic to TimeField.deconstruct().Baptiste Mispelon
If auto_now or auto_now_add was used then the serialized field in the migration contained unnecessary `editable` and `blank` arguments.
2014-08-03Fixed #23156 -- Added missing BinaryField.deconstruct() method.Baptiste Mispelon
2014-08-01Fixed #21940 -- Added kwargs to contribute_to_class() of model fields..Mitar
Thanks Kronuz for the suggestion.
2014-07-30Fixed #23112 -- Field.get_choices tries to index an iterableareski
2014-07-27Fixed #23098 -- Checked that lazy choices are not evaluated too soonFlorian Apolloner
Thanks Matthieu Agopian for the report.
2014-07-26Fixed #23101 db_table wasn't copied in deconstructAbraham Martin
Forward port of 999758fc7a2d6fcb01eb40de937d4420f884788d from stable/1.7.x
2014-07-26Fixed #22887 -- Added comment for translators on unique_for_date error messageFederico Frenguelli
2014-07-09Fixed #19671 -- Added warnings that null and validators are ignored for ↵Anubhav Joshi
ManyToManyField. Thanks Loic Bistuer and Tim Graham for help and review.
2014-07-05Fixed various minor doc typos / references.Daniel Hahler
2014-07-04Fixed #20631 -- Increased the default EmailField max_length to 254.Tim Graham
Thanks pmartin for the report.
2014-07-02Fixed #22935 -- Changed ForeignKey.default_error_messages['invalid'] to ↵Anubhav Joshi
refer to correct field. Thanks Tim Graham for suggestion and review.
2014-06-30Fixed problem with refs #10811.Anubhav Joshi
When 'to_field' is specified with a FK, then we need to check the pk value the object.
2014-06-23Fixed #22889: Unneeded to_field in fk.deconstruct causing swap issuesAndrew Godwin
2014-06-05Fixed #10811 -- Made assigning unsaved objects to FK, O2O, and GFK raise ↵Anubhav Joshi
ValueError. This prevents silent data loss. Thanks Aymeric Augustin for the initial patch and Loic Bistuer for the review.
2014-05-21Merge pull request #2679 from ramiro/t22421Ramiro Morales
Fixed #22421 -- Regression in fixtures loading.
2014-05-17Fixed #22421 -- Regression in fixtures loading.Ramiro Morales
Loading fixtures were failing since the refactoring in 244e2b71f5 for inheritance setups where the chain contains abstract models and the root ancestor contains a M2M relation. Thanks Stanislas Guerra for the report. Refs #20946.
2014-05-16Fixed #21905 -- Add info message if DateField or TimeField use a fixed valueMarkus Holtermann
2014-05-16Refs #21798 - Modified error number to provide room for future expansion.Russell Keith-Magee
2014-05-16Fixed #21798 -- Added check for DateTime mutually exclusive optionsDaniel Pyrathon
Added DateTimeCheckMixin to avoid the use of default, auto_now, and auto_now_add options together. Added the fields.E151 Error that is raised if one or more of these options are used together.
2014-05-06Fixed #22564 -- Prevented unneeded bytestrings in migrationsClaude Paroz
In some cases, this could lead to migrations written with Python 2 being incompatible with Python 3. Thanks Tim Graham for the report and Loïc Bistuer for the advices.
2014-05-06Added a bunch of missing unicode_literalsClaude Paroz
Refs #22564.
2014-04-26Fix many many typos in comments throughout the codebaseAlex Gaynor
2014-04-21Fixed queries that may return unexpected results on MySQL due to typecasting.Erik Romijn
This is a security fix; disclosure to follow shortly.
2014-04-21Appeased flake8 2.1.0.Aymeric Augustin
2014-04-13Fixed #21760 -- prefetch_related used an inefficient query for reverse FK.valtron
Regression introduced by commit 9777442. Refs #21410.
2014-03-30Fixed #19816 -- Pre-evaluate querysets used in direct relation assignments.Loic Bistuer
Since assignments on M2M or reverse FK descriptors is composed of a `clear()`, followed by an `add()`, `clear()` could potentially affect the value of the assigned queryset before the `add()` step; pre-evaluating it solves the problem. This patch fixes the issue for ForeignRelatedObjectsDescriptor, ManyRelatedObjectsDescriptor, and ReverseGenericRelatedObjectsDescriptor. It completes 6cb6e1 which addressed ReverseManyRelatedObjectsDescriptor.
2014-03-30Fixed transaction handling for a number of operations on related objects.Loic Bistuer
Thanks Anssi and Aymeric for the reviews. Refs #21174.
2014-03-26Fixed the PostGIS circular imports caused by 1506c71a95.Simon Charette
Thanks to @loic for the help and @timgraham for the review. refs #12030.
2014-03-25Fixed field deconstruction tests failures introduced by 1506c71a95.Simon Charette
refs #12030.
2014-03-25Fixed #12030 -- Validate integer field range at the model level.Simon Charette
Thanks to @timgraham for the review.
2014-03-21Removed legacy transaction management per the deprecation timeline.Aymeric Augustin
2014-03-21Removed PIL compatability layer per deprecation timeline.Tim Graham
refs #19934.
2014-03-21Removed backward compatible shims to rename get_query_set and similar ↵Tim Graham
queryset methods. Also removed the backward compatible shims introduced to rename the attributes ChangeList.root_query_set and ChangeList.query_set.
2014-03-14Fixed #22001 -- Ensure db_type is respected.Marc Tamlyn
db_parameters should respect an already existing db_type method and return that as its type string. In particular, this was causing some fields from gis to not be generated. Thanks to @bigsassy and @blueyed for their work on the patch. Also fixed #22260
2014-03-14Fixed #22272 -- Fixed regression in DecimalField when using decimal_places=0.Baptiste Mispelon
Thanks to trac user merb for the report.
2014-03-11Fixed #22217 - ManyToManyField.through_fields fixes.Akis Kesoglou
- Docs description of arguments mix up. - Keep it from erroneously masking E332 check. - Add checks E338 and E339, tweak message of E337.
2014-03-08Fix weird autodetector errorAndrew Godwin
2014-03-08Fixed #22183: Through M2Ms now correctly handledAndrew Godwin
2014-03-08Fixed #22199: Bad max_length deconstruction for FileFieldAndrew Godwin
2014-03-08Fixed #21188 -- Introduced subclasses for to-be-removed-in-django-XX warningsClaude Paroz
Thanks Anssi Kääriäinen for the idea and Simon Charette for the review.
2014-03-06Revert "Fixed #22183: Don't make a table for M2Ms with through="Andrew Godwin
This reverts commit 1562b9896f8f614ef40fd032b1ec777280b377c1.
2014-03-06Fixed #22183: Don't make a table for M2Ms with through=Andrew Godwin
2014-03-05Fixed #14549 - Removed restriction of single FKs on intermediary tablesAkis Kesoglou
Thanks to Loic Bistuer for review. Minor changes to error messages done by committer.
2014-03-05Fixed #22206 -- Passed models.TextField.max_length to forms.CharField.maxlengthChris Wilson
2014-03-04Fixed typo in internal CharField methodChris Wilson