load body if no edit is defined

This commit is contained in:
j 2022-08-31 10:59:08 +02:00
commit a334dc6b4f
2 changed files with 40 additions and 31 deletions

View file

@ -7,6 +7,8 @@ from ..widgets import PrettyJSONWidget
@admin.decorators.register(models.Text)
class TextAdmin(admin.ModelAdmin):
save_on_top = True
formfield_overrides = {
JSONField: {'widget': PrettyJSONWidget}
}