oioioi.quizzes.admin
¶
Module Contents¶
Classes¶
The nested InlineFormSet for the common case (ForeignKey inlines) |
|
Options for inline editing of |
|
Options for inline editing of |
|
Options for inline editing of |
|
Options for inline editing of |
|
Options for inline editing of |
|
Encapsulate all admin options and functionality for a given model. |
|
Options for inline editing of |
|
Adds |
- class oioioi.quizzes.admin.QuizAnswerFormset(*args, **kwargs)[source]¶
Bases:
nested_admin.formsets.NestedInlineFormSet
The nested InlineFormSet for the common case (ForeignKey inlines)
- class oioioi.quizzes.admin.QuizPictureInline(*args, **kwargs)[source]¶
Bases:
nested_admin.nested.NestedStackedInline
Options for inline editing of
model
instances.Provide
fk_name
to specify the attribute name of theForeignKey
frommodel
to its parent. This is required ifmodel
has more than oneForeignKey
to its parent.- has_add_permission(request, obj=None)[source]¶
Return True if the given request has permission to add an object. Can be overridden by the user in subclasses.
- has_change_permission(request, obj=None)[source]¶
Return True if the given request has permission to change the given Django model instance, the default implementation doesn’t examine the obj parameter.
Can be overridden by the user in subclasses. In such case it should return True if the given request has permission to change the obj model instance. If obj is None, this should return True if the given request has permission to change any object of the given type.
- has_delete_permission(request, obj=None)[source]¶
Return True if the given request has permission to delete the given Django model instance, the default implementation doesn’t examine the obj parameter.
Can be overridden by the user in subclasses. In such case it should return True if the given request has permission to delete the obj model instance. If obj is None, this should return True if the given request has permission to delete any object of the given type.
- has_view_permission(request, obj=None)[source]¶
Return True if the given request has permission to view the given Django model instance. The default implementation doesn’t examine the obj parameter.
If overridden by the user in subclasses, it should return True if the given request has permission to view the obj model instance. If obj is None, it should return True if the request has permission to view any object of the given type.
- class oioioi.quizzes.admin.QuizQuestionPictureInline(*args, **kwargs)[source]¶
Bases:
QuizPictureInline
Options for inline editing of
model
instances.Provide
fk_name
to specify the attribute name of theForeignKey
frommodel
to its parent. This is required ifmodel
has more than oneForeignKey
to its parent.
- class oioioi.quizzes.admin.QuizAnswerPictureInline(*args, **kwargs)[source]¶
Bases:
QuizPictureInline
Options for inline editing of
model
instances.Provide
fk_name
to specify the attribute name of theForeignKey
frommodel
to its parent. This is required ifmodel
has more than oneForeignKey
to its parent.
- class oioioi.quizzes.admin.QuizAnswerInline(*args, **kwargs)[source]¶
Bases:
nested_admin.nested.NestedTabularInline
Options for inline editing of
model
instances.Provide
fk_name
to specify the attribute name of theForeignKey
frommodel
to its parent. This is required ifmodel
has more than oneForeignKey
to its parent.- has_add_permission(request, obj=None)[source]¶
Return True if the given request has permission to add an object. Can be overridden by the user in subclasses.
- has_change_permission(request, obj=None)[source]¶
Return True if the given request has permission to change the given Django model instance, the default implementation doesn’t examine the obj parameter.
Can be overridden by the user in subclasses. In such case it should return True if the given request has permission to change the obj model instance. If obj is None, this should return True if the given request has permission to change any object of the given type.
- has_delete_permission(request, obj=None)[source]¶
Return True if the given request has permission to delete the given Django model instance, the default implementation doesn’t examine the obj parameter.
Can be overridden by the user in subclasses. In such case it should return True if the given request has permission to delete the obj model instance. If obj is None, this should return True if the given request has permission to delete any object of the given type.
- class oioioi.quizzes.admin.QuizQuestionInline(*args, **kwargs)[source]¶
Bases:
nested_admin.nested.NestedStackedInline
Options for inline editing of
model
instances.Provide
fk_name
to specify the attribute name of theForeignKey
frommodel
to its parent. This is required ifmodel
has more than oneForeignKey
to its parent.- has_add_permission(request, obj=None)[source]¶
Return True if the given request has permission to add an object. Can be overridden by the user in subclasses.
- has_change_permission(request, obj=None)[source]¶
Return True if the given request has permission to change the given Django model instance, the default implementation doesn’t examine the obj parameter.
Can be overridden by the user in subclasses. In such case it should return True if the given request has permission to change the obj model instance. If obj is None, this should return True if the given request has permission to change any object of the given type.
- has_delete_permission(request, obj=None)[source]¶
Return True if the given request has permission to delete the given Django model instance, the default implementation doesn’t examine the obj parameter.
Can be overridden by the user in subclasses. In such case it should return True if the given request has permission to delete the obj model instance. If obj is None, this should return True if the given request has permission to delete any object of the given type.
- has_view_permission(request, obj=None)[source]¶
Return True if the given request has permission to view the given Django model instance. The default implementation doesn’t examine the obj parameter.
If overridden by the user in subclasses, it should return True if the given request has permission to view the obj model instance. If obj is None, it should return True if the request has permission to view any object of the given type.
- class oioioi.quizzes.admin.QuizModelAdmin(parent_model, admin_site)[source]¶
Bases:
nested_admin.nested.NestedModelAdmin
Encapsulate all admin options and functionality for a given model.
- has_delete_permission(request, obj=None)[source]¶
Return True if the given request has permission to delete the given Django model instance, the default implementation doesn’t examine the obj parameter.
Can be overridden by the user in subclasses. In such case it should return True if the given request has permission to delete the obj model instance. If obj is None, this should return True if the given request has permission to delete any object of the given type.
- has_change_permission(request, obj=None)[source]¶
Return True if the given request has permission to change the given Django model instance, the default implementation doesn’t examine the obj parameter.
Can be overridden by the user in subclasses. In such case it should return True if the given request has permission to change the obj model instance. If obj is None, this should return True if the given request has permission to change any object of the given type.
- has_view_permission(request, obj=None)[source]¶
Return True if the given request has permission to view the given Django model instance. The default implementation doesn’t examine the obj parameter.
If overridden by the user in subclasses, it should return True if the given request has permission to view the obj model instance. If obj is None, it should return True if the request has permission to view any object of the given type.
- class oioioi.quizzes.admin.QuizInline(parent_model, admin_site)[source]¶
Bases:
django.contrib.admin.StackedInline
Options for inline editing of
model
instances.Provide
fk_name
to specify the attribute name of theForeignKey
frommodel
to its parent. This is required ifmodel
has more than oneForeignKey
to its parent.- has_delete_permission(request, obj=None)[source]¶
Return True if the given request has permission to delete the given Django model instance, the default implementation doesn’t examine the obj parameter.
Can be overridden by the user in subclasses. In such case it should return True if the given request has permission to delete the obj model instance. If obj is None, this should return True if the given request has permission to delete any object of the given type.
- has_change_permission(request, obj=None)[source]¶
Return True if the given request has permission to change the given Django model instance, the default implementation doesn’t examine the obj parameter.
Can be overridden by the user in subclasses. In such case it should return True if the given request has permission to change the obj model instance. If obj is None, this should return True if the given request has permission to change any object of the given type.
- has_view_permission(request, obj=None)[source]¶
Return True if the given request has permission to view the given Django model instance. The default implementation doesn’t examine the obj parameter.
If overridden by the user in subclasses, it should return True if the given request has permission to view the obj model instance. If obj is None, it should return True if the request has permission to view any object of the given type.