oioioi.usercontests.admin
¶
Module Contents¶
Classes¶
A formset for child objects related to a parent. |
|
Options for inline editing of |
|
Functions¶
|
Since the special usercontest version of Django admin has limited |
- oioioi.usercontests.admin.use_usercontest_admin_form(request)[source]¶
Since the special usercontest version of Django admin has limited functionality, we only want to use it for ‘regular’ users - that is users who otherwise couldn’t create their own contests. In essence, if the user can already create contests in some other way (or usercontests are disabled) this function should return False.
- class oioioi.usercontests.admin.UserRoundInlineFormset(data=None, files=None, instance=None, save_as_new=False, prefix=None, queryset=None, **kwargs)[source]¶
Bases:
oioioi.contests.admin.RoundInline.formset
A formset for child objects related to a parent.
- class oioioi.usercontests.admin.UserRoundInline(parent_model, admin_site)[source]¶
Bases:
oioioi.contests.admin.RoundInline
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.