1
0
mirror of https://github.com/django/django.git synced 2024-12-22 09:05:43 +00:00
Commit Graph

75 Commits

Author SHA1 Message Date
Madalin Popa
d28626ecf8 Fixed #35488 -- Fixed BaseModelFormSet.validate_unique() crash due to unhashable type. 2024-06-13 16:21:53 +02:00
Christopher Cave-Ayland
95e4d6b813 Fixed #34532 -- Made formset_factory() respect Form's default_renderer.
Co-authored-by: David Smith <smithdc@gmail.com>
2023-07-24 09:09:53 +02:00
Neeraj Kumar
eed096574f Fixed #32210 -- Fixed model inlines with to_field that has a default. 2023-07-07 09:11:46 +02:00
Neeraj Kumar
b91d62cca0 Refs #24377 -- Added assertions for model inlines with primary key that has a default.
This ensures that a model field default is ignored.
2023-07-07 08:18:31 +02:00
Gregor Gärtner
f0c06f8ab7 Refs #33990 -- Renamed TransactionTestCase.assertQuerysetEqual() to assertQuerySetEqual().
Co-Authored-By: Michael Howitz <mh@gocept.com>
2022-10-08 08:07:38 +02:00
Shawn Dong
18c5ba07cc Fixed #33822 -- Fixed save() crash on model formsets when not created by modelformset_factory().
Thanks Claude Paroz for the report.

Regression in e87f57fdb8.
2022-07-05 07:19:18 +02:00
Mariusz Felisiak
7119f40c98 Refs #33476 -- Refactored code to strictly match 88 characters line length. 2022-02-07 20:37:05 +01:00
django-bot
9c19aff7c7 Refs #33476 -- Reformatted code with Black. 2022-02-07 20:37:05 +01:00
vgolubev
e87f57fdb8 Fixed #26142 -- Allowed model formsets to prevent new object creation.
Thanks Jacob Walls, David Smith, and Mariusz Felisiak for reviews.

Co-authored-by: parth <parthvin@gmail.com>
2022-01-27 20:45:21 +01:00
David Smith
eba9a9b7f7 Refs #32338 -- Added Boundfield.legend_tag(). 2021-12-09 07:16:33 +01:00
David Smith
456466d932 Fixed #31026 -- Switched form rendering to template engine.
Thanks Carlton Gibson, Keryn Knight, Mariusz Felisiak, and Nick Pope
for reviews.

Co-authored-by: Johannes Hoppe <info@johanneshoppe.com>
2021-09-20 15:50:18 +02:00
Hasan Ramezani
3f7b327562 Fixed #31235 -- Made assertQuerysetEqual() compare querysets directly.
This also replaces assertQuerysetEqual() to
assertSequenceEqual()/assertCountEqual() where appropriate.

Co-authored-by: Peter Inglesby <peter.inglesby@gmail.com>
Co-authored-by: Mariusz Felisiak <felisiak.mariusz@gmail.com>
2020-11-06 09:24:50 +01:00
Jon Dufresne
859cd7c6b4
Fixed #22276 -- Fixed crash when formset management form is invalid.
Co-authored-by: Patryk Zawadzki <patrys@room-303.com>
2020-11-05 10:40:41 +01:00
meghanabhange
848770dd2c Fixed #32042 -- Improved error messages for the number of submitted forms in formsets. 2020-09-28 07:05:34 +02:00
David Smith
162765d6c3 Fixed #9061 -- Allowed FormSets to disable deleting extra forms.
Thanks to Dan Ward for the initial patch.
2020-06-24 09:26:25 +02:00
David Smith
433dd737f9 Fixed #20347 -- Allowed customizing the maximum number of instantiated forms in formsets.
Co-authored-by: ethurgood <ethurgood@gmail.com>
2020-06-05 12:01:32 +02:00
Nick Pope
8f10ceaa90 Changed '%s' % value pattern to str(value). 2020-05-04 08:27:18 +02:00
Matt Wiens
e817ae74da Followed style guide for model attribute ordering. 2018-12-27 19:34:14 -05:00
Jon Dufresne
ef87b38ef7 Fixed #29696 -- Prevented BaseModelFormSet.initial_form_count()'s from treating data={} as unbound. 2018-08-21 10:02:03 -04:00
Demur Nodia
06a11ef6ec Fixed #26819 -- Fixed BaseModelFormSet.validate_unique() "unhashable type: list" crash. 2018-07-30 16:52:12 -04:00
Demur Nodia
c090ea97c1 Fixed nonexistent field reference in test model __str__() method. 2018-07-30 16:14:57 -04:00
Jon Dufresne
ff05de760c Fixed #29038 -- Removed closing slash from HTML void tags. 2018-01-21 02:09:10 -05:00
Jon Dufresne
d7881d2020 Fixed #22229 -- Added primary key validation to BaseModelFormSet._construct_form(). 2017-07-11 14:33:21 -04:00
Jon Dufresne
988309a1ae Added ModelFormSet test for validation of a nonexistent PK. 2017-07-11 14:28:56 -04:00
Jon Dufresne
21046e7773 Fixed #28249 -- Removed unnecessary dict.keys() calls.
iter(dict) is equivalent to iter(dict.keys()).
2017-05-27 19:08:46 -04:00
Alexander Kavanaugh
362fba87c9 Fixed #28159 -- Fixed BaseInlineFormSet._construct_form() crash when using save_as_new.
Regression in 4a246a02bd.
2017-05-03 07:45:51 -04:00
chillaranand
d6eaf7c018 Refs #23919 -- Replaced super(ClassName, self) with super(). 2017-01-25 12:23:46 -05:00
Claude Paroz
7b2f2e74ad Refs #23919 -- Removed six.<various>_types usage
Thanks Tim Graham and Simon Charette for the reviews.
2017-01-18 20:18:46 +01: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
Hiroki Kiyohara
181f492ad0 Fixed #27416 -- Prevented ModelFormSet from creating objects for invalid PKs in data. 2016-12-06 13:06:58 -05:00
za
321e94fa41 Refs #27392 -- Removed "Tests that", "Ensures that", etc. from test docstrings. 2016-11-10 21:30:21 -05:00
Jon Dufresne
2c716c1dc7 Fixed #27256 -- Changed Select widget's selected attribute to use HTML5 boolean syntax. 2016-09-21 15:12:13 -07:00
Adam Chainz
652bcc6f5f Refs #25415 -- Fixed invalid models in the test suite. 2016-09-09 17:16:42 -04:00
Jon Dufresne
4f336f6652 Fixed #26747 -- Used more specific assertions in the Django test suite. 2016-06-16 14:19:18 -04:00
Jon Dufresne
ec6121693f Fixed #22383 -- Added support for HTML5 required attribute on required form fields. 2016-04-21 19:16:38 -04:00
Tim Graham
92053acbb9 Fixed E128 flake8 warnings in tests/. 2016-04-08 10:12:33 -04:00
Tim Graham
9c5e272860 Fixed #25550 -- Deprecated direct assignment to the reverse side of a related set. 2015-10-27 07:57:15 -04:00
Claude Paroz
65a1055a36 Fixed #25431 -- Readded inline foreign keys to modelformset instances
Too much field exclusions in form's construct_instance() in _post_clean()
could lead to some unexpected missing ForeignKey values.
Fixes a regression from 45e049937. Refs #13776.
2015-09-21 21:30:49 +02:00
Dražen Odobašić
b1e33ceced Fixed #23395 -- Limited line lengths to 119 characters. 2015-09-12 11:40:50 -04:00
Flavio Curella
c2e70f0265 Fixed #21127 -- Started deprecation toward requiring on_delete for ForeignKey/OneToOneField 2015-07-27 18:28:13 -04:00
Jason Hoos
a50b66da30 Fixed #24958 -- Fixed inline forms using UUID-PK parents with auto-PK children. 2015-06-26 09:09:09 -04:00
Stanislas Guerra
4c2f546b55 Fixed #24395 -- Ensured inline ModelsForms have an updated related instance. 2015-02-24 11:49:00 -05:00
Tim Graham
1306cd1e8a Fixed #24377 -- Fixed model inline formsets with primary key's that have defaults. 2015-02-23 08:44:27 -05:00
Loic Bistuer
00a889167f Fixed #24295 -- Allowed ModelForm meta to specify form field classes.
Thanks Carl Meyer and Markus Holtermann for the reviews.
2015-02-13 19:13:05 +07:00
Tim Graham
0ed7d15563 Sorted imports with isort; refs #23860. 2015-02-06 08:16:28 -05:00
Adam Taylor
039465a6a7 Fixed typos in code comments. 2015-01-20 12:18:03 -05:00
Berker Peksag
f7969b0920 Fixed #23620 -- Used more specific assertions in the Django test suite. 2014-11-03 11:56:37 -05:00
Petras Zdanavičius
f7eee04ebe Fixed #23451 -- Fixed typo in inlineformset_factory() error message. 2014-09-08 17:22:23 -04:00
Alex Gaynor
1dcc603eff Fixed several typos in Django 2014-05-28 17:39:14 -07:00