I tried adding: fieldsets = [
(None, {'fields': ['text','is_correct','explanation']}),
] to my AnswerInLine definition but that throws an ImproperlyConfigured error saying:
'AnswerInline.fieldsets[0][1]['fields']' refers to field 'is_correct' that is missing from the form.
Can anyone help out?
This is not really django specific, several objects bearing the same name in the same namespace will always lead to trouble ; )
(And this is not even python specific)
Glad you could fix it and thanks for posting your solution in case someone else has the same issue though. : )
Ok I fixed it and in case someone else falls into such a trap, here's
how I fixed it.
My Answer model had a field with name 'is_correct' and had a method
with name 'is_correct'.
I think django should be able to detect such things and raise an error
or there should be a note in the documentation warning people not to
name their model methods with model field names.
--
You received this message because you are subscribed to the Google Groups "Django users" group.
To view this discussion on the web visit https://groups.google.com/d/msg/django-users/-/fspuOAnnWwIJ.