nested_admin.tests.one_deep package

Submodules

nested_admin.tests.one_deep.admin module

class InlineMixin[source]

Bases: object

extra = 0
inline_classes = ('collapse', 'open')
is_sortable = False
readonly_fields = ('readonly',)
suit_classes = ''
class NestedStackedChildInline(*args, **kwargs)[source]

Bases: nested_admin.tests.one_deep.admin.InlineMixin, nested_admin.nested.NestedStackedInline

media
model

alias of nested_admin.tests.one_deep.models.NestedStackedChild

class NestedStackedRootAdmin(model, admin_site)[source]

Bases: nested_admin.nested.NestedModelAdmin

inlines = [<class 'nested_admin.tests.one_deep.admin.NestedStackedChildInline'>]
media
class NestedTabularChildInline(*args, **kwargs)[source]

Bases: nested_admin.tests.one_deep.admin.InlineMixin, nested_admin.nested.NestedTabularInline

media
model

alias of nested_admin.tests.one_deep.models.NestedTabularChild

class NestedTabularRootAdmin(model, admin_site)[source]

Bases: nested_admin.nested.NestedModelAdmin

inlines = [<class 'nested_admin.tests.one_deep.admin.NestedTabularChildInline'>]
media
class PlainStackedChildInline(parent_model, admin_site)[source]

Bases: nested_admin.tests.one_deep.admin.InlineMixin, django.contrib.admin.options.StackedInline

media
model

alias of nested_admin.tests.one_deep.models.PlainStackedChild

class PlainStackedRootAdmin(model, admin_site)[source]

Bases: django.contrib.admin.options.ModelAdmin

inlines = [<class 'nested_admin.tests.one_deep.admin.PlainStackedChildInline'>]
media
class PlainTabularChildInline(parent_model, admin_site)[source]

Bases: nested_admin.tests.one_deep.admin.InlineMixin, django.contrib.admin.options.TabularInline

media
model

alias of nested_admin.tests.one_deep.models.PlainTabularChild

class PlainTabularRootAdmin(model, admin_site)[source]

Bases: django.contrib.admin.options.ModelAdmin

class Media[source]
css = {'all': ['one_deep/grp-normalize.css']}
inlines = [<class 'nested_admin.tests.one_deep.admin.PlainTabularChildInline'>]
media

nested_admin.tests.one_deep.models module

class ChildAbstract(*args, **kwargs)[source]

Bases: django.db.models.base.Model

class Meta[source]
abstract = False
boolean

A wrapper for a deferred-loading field. When the value is read from this object the first time, the query is executed.

position

A wrapper for a deferred-loading field. When the value is read from this object the first time, the query is executed.

readonly

A wrapper for a deferred-loading field. When the value is read from this object the first time, the query is executed.

slug

A wrapper for a deferred-loading field. When the value is read from this object the first time, the query is executed.

text

A wrapper for a deferred-loading field. When the value is read from this object the first time, the query is executed.

class NestedStackedChild(id, slug, position, boolean, readonly, text, root)[source]

Bases: nested_admin.tests.one_deep.models.ChildAbstract

exception DoesNotExist

Bases: django.core.exceptions.ObjectDoesNotExist

exception MultipleObjectsReturned

Bases: django.core.exceptions.MultipleObjectsReturned

id

A wrapper for a deferred-loading field. When the value is read from this object the first time, the query is executed.

objects = <django.db.models.manager.Manager object>
root

Accessor to the related object on the forward side of a many-to-one or one-to-one (via ForwardOneToOneDescriptor subclass) relation.

In the example:

class Child(Model):
    parent = ForeignKey(Parent, related_name='children')

child.parent is a ForwardManyToOneDescriptor instance.

root_id

A wrapper for a deferred-loading field. When the value is read from this object the first time, the query is executed.

class NestedStackedRoot(id, slug)[source]

Bases: nested_admin.tests.one_deep.models.RootAbstract

exception DoesNotExist

Bases: django.core.exceptions.ObjectDoesNotExist

exception MultipleObjectsReturned

Bases: django.core.exceptions.MultipleObjectsReturned

children

Accessor to the related objects manager on the reverse side of a many-to-one relation.

In the example:

class Child(Model):
    parent = ForeignKey(Parent, related_name='children')

parent.children is a ReverseManyToOneDescriptor instance.

Most of the implementation is delegated to a dynamically defined manager class built by create_forward_many_to_many_manager() defined below.

id

A wrapper for a deferred-loading field. When the value is read from this object the first time, the query is executed.

objects = <django.db.models.manager.Manager object>
class NestedTabularChild(id, slug, position, boolean, readonly, text, root)[source]

Bases: nested_admin.tests.one_deep.models.ChildAbstract

exception DoesNotExist

Bases: django.core.exceptions.ObjectDoesNotExist

exception MultipleObjectsReturned

Bases: django.core.exceptions.MultipleObjectsReturned

id

A wrapper for a deferred-loading field. When the value is read from this object the first time, the query is executed.

objects = <django.db.models.manager.Manager object>
root

Accessor to the related object on the forward side of a many-to-one or one-to-one (via ForwardOneToOneDescriptor subclass) relation.

In the example:

class Child(Model):
    parent = ForeignKey(Parent, related_name='children')

child.parent is a ForwardManyToOneDescriptor instance.

root_id

A wrapper for a deferred-loading field. When the value is read from this object the first time, the query is executed.

class NestedTabularRoot(id, slug)[source]

Bases: nested_admin.tests.one_deep.models.RootAbstract

exception DoesNotExist

Bases: django.core.exceptions.ObjectDoesNotExist

exception MultipleObjectsReturned

Bases: django.core.exceptions.MultipleObjectsReturned

children

Accessor to the related objects manager on the reverse side of a many-to-one relation.

In the example:

class Child(Model):
    parent = ForeignKey(Parent, related_name='children')

parent.children is a ReverseManyToOneDescriptor instance.

Most of the implementation is delegated to a dynamically defined manager class built by create_forward_many_to_many_manager() defined below.

id

A wrapper for a deferred-loading field. When the value is read from this object the first time, the query is executed.

objects = <django.db.models.manager.Manager object>
class PlainStackedChild(id, slug, position, boolean, readonly, text, root)[source]

Bases: nested_admin.tests.one_deep.models.ChildAbstract

exception DoesNotExist

Bases: django.core.exceptions.ObjectDoesNotExist

exception MultipleObjectsReturned

Bases: django.core.exceptions.MultipleObjectsReturned

id

A wrapper for a deferred-loading field. When the value is read from this object the first time, the query is executed.

objects = <django.db.models.manager.Manager object>
root

Accessor to the related object on the forward side of a many-to-one or one-to-one (via ForwardOneToOneDescriptor subclass) relation.

In the example:

class Child(Model):
    parent = ForeignKey(Parent, related_name='children')

child.parent is a ForwardManyToOneDescriptor instance.

root_id

A wrapper for a deferred-loading field. When the value is read from this object the first time, the query is executed.

class PlainStackedRoot(id, slug)[source]

Bases: nested_admin.tests.one_deep.models.RootAbstract

exception DoesNotExist

Bases: django.core.exceptions.ObjectDoesNotExist

exception MultipleObjectsReturned

Bases: django.core.exceptions.MultipleObjectsReturned

children

Accessor to the related objects manager on the reverse side of a many-to-one relation.

In the example:

class Child(Model):
    parent = ForeignKey(Parent, related_name='children')

parent.children is a ReverseManyToOneDescriptor instance.

Most of the implementation is delegated to a dynamically defined manager class built by create_forward_many_to_many_manager() defined below.

id

A wrapper for a deferred-loading field. When the value is read from this object the first time, the query is executed.

objects = <django.db.models.manager.Manager object>
class PlainTabularChild(id, slug, position, boolean, readonly, text, root)[source]

Bases: nested_admin.tests.one_deep.models.ChildAbstract

exception DoesNotExist

Bases: django.core.exceptions.ObjectDoesNotExist

exception MultipleObjectsReturned

Bases: django.core.exceptions.MultipleObjectsReturned

id

A wrapper for a deferred-loading field. When the value is read from this object the first time, the query is executed.

objects = <django.db.models.manager.Manager object>
root

Accessor to the related object on the forward side of a many-to-one or one-to-one (via ForwardOneToOneDescriptor subclass) relation.

In the example:

class Child(Model):
    parent = ForeignKey(Parent, related_name='children')

child.parent is a ForwardManyToOneDescriptor instance.

root_id

A wrapper for a deferred-loading field. When the value is read from this object the first time, the query is executed.

class PlainTabularRoot(id, slug)[source]

Bases: nested_admin.tests.one_deep.models.RootAbstract

exception DoesNotExist

Bases: django.core.exceptions.ObjectDoesNotExist

exception MultipleObjectsReturned

Bases: django.core.exceptions.MultipleObjectsReturned

children

Accessor to the related objects manager on the reverse side of a many-to-one relation.

In the example:

class Child(Model):
    parent = ForeignKey(Parent, related_name='children')

parent.children is a ReverseManyToOneDescriptor instance.

Most of the implementation is delegated to a dynamically defined manager class built by create_forward_many_to_many_manager() defined below.

id

A wrapper for a deferred-loading field. When the value is read from this object the first time, the query is executed.

objects = <django.db.models.manager.Manager object>
class RootAbstract(*args, **kwargs)[source]

Bases: django.db.models.base.Model

class Meta[source]
abstract = False
slug

A wrapper for a deferred-loading field. When the value is read from this object the first time, the query is executed.

nested_admin.tests.one_deep.tests module

class VisualComparisonTestCase(methodName='runTest')[source]

Bases: nested_admin.tests.base.BaseNestedAdminTestCase

add_inline()[source]
assertSameScreenshot(a, b, exclude=None)[source]
exclude_from_screenshots(imgs, exclude=None)[source]
get_admin_screenshot()[source]
model_names
models
root_model = None
root_models = [<class 'nested_admin.tests.one_deep.models.PlainStackedRoot'>, <class 'nested_admin.tests.one_deep.models.PlainTabularRoot'>, <class 'nested_admin.tests.one_deep.models.NestedStackedRoot'>, <class 'nested_admin.tests.one_deep.models.NestedTabularRoot'>]
classmethod setUpClass()[source]

Hook method for setting up class fixture before running tests in the class.

storage = None
classmethod tearDownClass()[source]

Hook method for deconstructing the class fixture after running all tests in the class.

test_stacked_added_item()[source]
test_stacked_empty()[source]
test_stacked_one_item()[source]
test_stacked_validation_error()[source]
test_tabular_added_item()[source]
test_tabular_empty()[source]
test_tabular_one_item()[source]
test_tabular_validation_error()[source]
window_size = (1200, 800)
class disable_string_if_invalid_for_grappelli[source]

Bases: django.test.utils.override_settings

strip_query_from_url(url)[source]

Module contents