I am having some problems with the django admin site and inline links. I’ve been going to look for solutions for two days, but nothing.
I have two models:
class Measurement(models.Model): user = models.ForeignKey(User) date = models.DateTimeField(auto_now_add=True)
And the configuration for the admin site:
class MediaInline(admin.StackedInline): model = Media extra = 0 class MeasurementAdmin(admin.ModelAdmin): inlines = [MediaInline,] admin.site.register(Media) admin.site.register(Measurement, MeasurementAdmin)
The strange thing is: the admin site shows inline lines for some Measurement objects and not for some others. The entire set of forms is invisible (it is not), even if related records are visible in the database. In addition, a ValidationError: [u'ManagementForm data is missing or has been tampered with'] exception is thrown for these objects ValidationError: [u'ManagementForm data is missing or has been tampered with'] . Has anyone dealt with this?
django django-admin
Anpher
source share