Ian Foote
7414704e88
Fixed #470 -- Added support for database defaults on fields.
...
Special thanks to Hannes Ljungberg for finding multiple implementation
gaps.
Thanks also to Simon Charette, Adam Johnson, and Mariusz Felisiak for
reviews.
2023-05-12 19:11:40 +02:00
django-bot
9c19aff7c7
Refs #33476 -- Reformatted code with Black.
2022-02-07 20:37:05 +01:00
Abhijeet Viswa
babd412685
Fixed #29129 -- Skipped UPDATE when adding a model instance with inherited primary key that has a default.
2020-03-05 12:08:38 +01:00
Hasan Ramezani
85458e94e3
Fixed #29260 -- Skipped an UPDATE when adding a model instance with primary key that has a default.
2019-08-19 13:28:35 +02:00
Paulo
a7b5ad8b19
Fixed #27846 -- Made Model.refresh_from_db() clear cached relations.
2017-10-12 17:04:10 -04:00
Claude Paroz
f3c43ad1fd
Refs #23919 -- Removed python_2_unicode_compatible decorator usage
2017-01-18 13:44:34 +01:00
Claude Paroz
d7b9aaa366
Refs #23919 -- Removed encoding preambles and future imports
2017-01-18 09:55:19 +01:00
Tim Graham
54e2e688e1
Fixed #25715 -- Fixed Model.refresh_from_db() with ForeignKey w/on_delete=SET_NULL.
2015-11-21 10:34:01 -05:00
Flavio Curella
c2e70f0265
Fixed #21127 -- Started deprecation toward requiring on_delete for ForeignKey/OneToOneField
2015-07-27 18:28:13 -04:00
Anssi Kääriäinen
d8f00e1918
Added a comment for test of refs #20278 .
2014-11-20 16:26:25 -05:00
Loic Bistuer
2f3a4cd573
Removed numbering from the models.py header of some test packages.
...
This is a reliqua from the early days of the modeltests/regressiontests era.
2014-09-24 17:28:56 +07:00
Claude Paroz
e520a73eee
Harmonized some PEP 0263 coding preambles
2014-05-15 19:58:41 +02:00
Jason Myers
7a61c68c50
PEP8 cleanup
...
Signed-off-by: Jason Myers <jason@jasonamyers.com>
2013-11-02 23:50:49 -05:00
Alex Gaynor
9d740eb8b1
Fix all violators of E231
2013-10-26 12:15:03 -07:00
Anssi Kääriäinen
e973ee6a98
Fixed #20988 -- Added model meta option select_on_save
...
The option can be used to force pre 1.6 style SELECT on save behaviour.
This is needed in case the database returns zero updated rows even if
there is a matching row in the DB. One such case is PostgreSQL update
trigger that returns NULL.
Reviewed by Tim Graham.
Refs #16649
2013-08-30 09:41:07 +03:00
Anssi Kääriäinen
266c0bb23e
Fixed #20278 -- ensured .get() exceptions do not recurse infinitely
...
A regression caused by d5b93d3281
made .get() error
reporting recurse infinitely on certain rare conditions. Fixed this by
not trying to print the given lookup kwargs.
2013-05-20 18:50:40 +03:00
Florian Apolloner
89f40e3624
Merged regressiontests and modeltests into the test root.
2013-02-26 14:36:57 +01:00