kopia lustrzana https://github.com/wagtail/wagtail
b4bc681865
Fixes #8989. The previous fix #9004 failed for custom document models because ChooserViewset assigns an internal name for the ChooserBlock class based on the model name, and if this is anything other than Document it won't match the name DocumentChooserBlock that it's exposed under in wagtail.documents.blocks. Fix this by replacing the `block_class` property with a `get_block_class` method that lets us specify the class name. As a bonus, user code that defines chooser blocks no longer has to directly hack the `__module__` attribute. |
||
---|---|---|
.. | ||
adding_reports.md | ||
admin_views.md | ||
audit_log.md | ||
custom_account_settings.md | ||
custom_bulk_actions.md | ||
custom_tasks.md | ||
customising_group_views.md | ||
extending_draftail.md | ||
forms.md | ||
generic_views.md | ||
index.md | ||
rich_text_internals.md | ||
template_components.md |