Christopher schrieb: > class Menu(models.Model): > display_text = models.CharField(maxlength=50) > url = models.URLField(verify_exists=False) > parent_menu_item = models.ForeignKey(Menu) > > totalimpact.menu: name 'Menu' is not defined
""" If you need to create a relationship on a model that has not yet been defined, you can use the name of the model, rather than the model object itself: """ change: parent_menu_item = models.ForeignKey(Menu) to this: parent_menu_item = models.ForeignKey("Menu") -- Mfg. Jens Diemer ---- A django powered CMS: http://www.pylucid.org --~--~---------~--~----~------------~-------~--~----~ 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 -~----------~----~----~----~------~----~------~--~---