mirror of
https://github.com/django/django.git
synced 2025-10-31 09:41:08 +00:00
Changed management SQL stuff to work with mutually referential models
git-svn-id: http://code.djangoproject.com/svn/django/branches/magic-removal@1703 bcc190cf-cafb-0310-a4f2-bffc1f526a37
This commit is contained in:
@@ -85,7 +85,6 @@ class ModelBase(type):
|
||||
if hasattr(new_class, 'objects'):
|
||||
raise ValueError, "Model %s must specify a custom Manager, because it has a field named 'objects'" % name
|
||||
new_class.add_to_class('objects', Manager())
|
||||
|
||||
|
||||
# Give the class a docstring -- its definition.
|
||||
if new_class.__doc__ is None:
|
||||
|
||||
@@ -37,7 +37,7 @@ class Options:
|
||||
|
||||
def _prepare(self):
|
||||
if self.order_with_respect_to:
|
||||
self.order_with_respect_to = self.get_field(order_with_respect_to)
|
||||
self.order_with_respect_to = self.get_field(self.order_with_respect_to)
|
||||
self.ordering = ('_order',)
|
||||
else:
|
||||
self.order_with_respect_to = None
|
||||
|
||||
Reference in New Issue
Block a user