Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix for 'ManyToOneRel' object has no attribute 'verbose_name' on Document/Images Usage page #11808

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

terrsoshi
Copy link

@terrsoshi terrsoshi commented Mar 29, 2024

Users cannot view the usage details of documents or images (where they’re being used) used at least once in any multiple Parentalkey levels models from the Wagtail admin site. This seems to be a problem in referencing the verbose_name of the correct child field due to the nested structure of multi-level ManyToOneRel fields.

More information including steps to reproduce the issue on a fresh Wagtail project can be found on #11482.

This fix should also fix an initial issue where the first field level's verbose_name is excluded from the returned string.

For example, for a field reference of ResourceItem → Document within a ResourceGroup object:
Current result: Document
This fix's result: Resource item → Document

Copy link

squash-labs bot commented Mar 29, 2024

Manage this branch in Squash

Test this branch here: https://terrsoshifixfix-manytoonerel-o-6ljq7.squash.io

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant