oggie rob wrote: > You're missing the __str__ method. Not sure if that is causing the > "Error" though.
Thanks Rob, I added the __str__ method and all it does is that Admin now shows each entry as whatever the str method returns. It's useful though so thanks. But I still get the error Error: variable not passed into template?>Data > On Apr 18, 10:39 pm, Michael Lake <[EMAIL PROTECTED]> wrote: > >>Hi all >> >>In the Admin interface I'm getting the folloing error for a model: >> Error: variable not passed into template?>Data >> >>class Data(models.Model): >> experiment_id = models.CharField(maxlength=10) >> node_id = models.CharField(maxlength=10) >> content = models.TextField(blank=True) >> >> class Meta: >> verbose_name_plural = 'Data' >> >> class Admin: >> pass >> >>The Admin interface is not showing the columns of the table but just a list >>like this: >> Data object >> Data object ... >> >>I can add a row or delete a row and I can edit the rows using the admin >>interface. >>I can't see whats wrong with this particular model. >>manage syncdb runs with no errors and manage.py validate says 0 errors. >>In models.py the other models display fine in the Admin interface. >> >>Mike >>-- >>Michael Lake > > > > > > -- Michael Lake Computational Research Support Unit Science Faculty, UTS Ph: 9514 2238 --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send email to django-users@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~----------~----~----~----~------~----~------~--~---