mirror of
https://github.com/jazzband/django-eav2.git
synced 2026-03-16 22:40:26 +00:00
fix BaseEntityAdmin
This commit is contained in:
parent
883ddfabea
commit
5760f20f7a
2 changed files with 4 additions and 1 deletions
|
|
@ -8,6 +8,8 @@ We follow [Semantic Versions](https://semver.org/) starting at the `0.14.0` rele
|
|||
|
||||
### Bug Fixes
|
||||
|
||||
- Fixes missing `Add another` button for inlines in `BaseEntityAdmin`
|
||||
|
||||
## 1.2.3 (2022-08-15)
|
||||
|
||||
### Bug Fixes
|
||||
|
|
|
|||
|
|
@ -19,11 +19,12 @@ class BaseEntityAdmin(ModelAdmin):
|
|||
view and substitute some data.
|
||||
"""
|
||||
form = context['adminform'].form
|
||||
media = context["media"]
|
||||
|
||||
# Infer correct data from the form.
|
||||
fieldsets = self.fieldsets or [(None, {'fields': form.fields.keys()})]
|
||||
adminform = admin.helpers.AdminForm(form, fieldsets, self.prepopulated_fields)
|
||||
media = mark_safe(self.media + adminform.media)
|
||||
media = mark_safe(media + adminform.media)
|
||||
|
||||
context.update(adminform=adminform, media=media)
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue