-
Type:
Bug
-
Resolution: Unresolved
-
Priority:
Minor - P4
-
None
-
Affects Version/s: None
-
Component/s: django
-
None
-
None
-
Python Drivers
-
None
-
None
-
None
-
None
-
None
-
None
Following INTPYTHON-643, a number of layout and styling issues with EmbeddedModelField/EmbeddedModelArrayField in the Django admin remain. This description isn't meant to be exhaustive. The solution must be checked with various combinations of EmbeddedModelField/EmbeddedModelArrayField to ensure reasonable layouts.
1. Here's a screenshot for a Book model with name & author fields. Author is an embedded model with address and name fields. Its name field awkwardly floats off to the right. Address is an embedded model with street and tags field, where tag is an EmbeddedModelArrayField. Errors on subfields of Tag float to the right.

2. For the example queryable encryption models (Billing, an embedded model in PatientRecord, an embedded model in Patient), an error in the Billing model does not highlight the field (red outline) as expected and the error message floats to the right.

To register admin widgets for these fields, patch django.contrib.admin.options.FORMFIELD_FOR_DBFIELD_DEFAULTS. (Admin-only widgets should be used since the admin styling won't match user applications.)
- depends on
-
INTPYTHON-643 [Spike]: Poor UI for embedded model error messages in forms
-
- In Progress
-