From b1ffa9a9d78b0c2c5ad6ed5a1d84e380d5cfd010 Mon Sep 17 00:00:00 2001 From: seanhelvey Date: Fri, 13 Dec 2024 11:56:53 -0800 Subject: Fixed #13883 -- Rendered named choice groups with in FilteredSelectMultiple. This patch adds support for s in FilteredSelectMultiple widgets. When a popup returns a new object, if the source field contains optgroup choices, the optgroup is now also included in the response data. Additionally, this adds error handling for invalid source_model parameters to prevent crashes and display user-friendly error messages instead. Co-authored-by: Michael McLarnon --- tests/admin_widgets/tests.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'tests/admin_widgets/tests.py') diff --git a/tests/admin_widgets/tests.py b/tests/admin_widgets/tests.py index 7588c2cc32..e0ae5b7747 100644 --- a/tests/admin_widgets/tests.py +++ b/tests/admin_widgets/tests.py @@ -971,7 +971,7 @@ class RelatedFieldWidgetWrapperTests(SimpleTestCase): + href="/admin_widgets/releaseevent/add/?_to_field=album&_popup=1&_source_model=admin_widgets.videostream"> -- cgit v1.3