We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
i try registering positionField like this
class SomeModelAdmin(admin.ModelAdmin): list_display = ['position'] admin.site.register(SomeModel, SomeModelAdmin)
and I get error message:
django.core.management.base.SystemCheckError: SystemCheckError: System check identified some issues: ERRORS: <class 'project.some_models.admin.ModelAdmin'>: (admin.E108) The value of 'list_display[0]' refers to 'position', which is not a callable, an attribute of 'ModelAdmin', or an attribute or method on 'some_models.SomeModel'.
I handled the error with this:
class SomeModelAdmin(admin.ModelAdmin): list_display = ['get_position'] def get_position(self, obj): return obj.position admin.site.register(SomeModel, SomeModelAdmin)
but it's really confused because it not shown on the documentation it would be nice if the library could handle that error itself
The text was updated successfully, but these errors were encountered:
No branches or pull requests
i try registering positionField like this
and I get error message:
I handled the error with this:
but it's really confused because it not shown on the documentation
it would be nice if the library could handle that error itself
The text was updated successfully, but these errors were encountered: