Forms

evileg_core.forms module

class evileg_core.forms.EActionForm(data=None, files=None, auto_id='id_%s', prefix=None, initial=None, error_class=<class 'django.forms.utils.ErrorList'>, label_suffix=None, empty_permitted=False, field_order=None, use_required_attribute=None, renderer=None)[source]

Bases: django.forms.forms.Form

base_fields = {'action': <django.forms.fields.ChoiceField object>, 'select_across': <django.forms.fields.BooleanField object>}
declared_fields = {'action': <django.forms.fields.ChoiceField object>, 'select_across': <django.forms.fields.BooleanField object>}
property media

Return all media required to render the widgets on this form.

class evileg_core.forms.EArticleForm(user=None, *args, **kwargs)[source]

Bases: evileg_core.forms.EPostForm

Form class for class, which inherits from evileg_core.models.EAbstractArticle. In this form added title field.

class Meta[source]

Bases: object

fields = ['title', 'content_markdown']
base_fields = {}
declared_fields = {}
property media

Return all media required to render the widgets on this form.

class evileg_core.forms.EDateRangeForm(request, *args, **kwargs)[source]

Bases: django.forms.forms.Form

Form with range input of dates. This form is using in Django administration panel

class Media[source]

Bases: object

css = {'all': ('admin/css/widgets.css',)}
js = ('admin/js/calendar.js', 'admin/js/admin/DateTimeShortcuts.js')
base_fields = {}
declared_fields = {}
property media

Return all media required to render the widgets on this form.

class evileg_core.forms.EPostForm(user=None, *args, **kwargs)[source]

Bases: django.forms.models.ModelForm

Form class for class, which inherits from evileg_core.models.EAbstractPost. User (author) of post should be sent to constructor.

class Meta[source]

Bases: object

fields = ['content_markdown']
base_fields = {}
declared_fields = {}
property media

Return all media required to render the widgets on this form.

save(commit=True)[source]

Save this form’s self.instance object if commit=True. Otherwise, add a save_m2m() method to the form which can be called after the instance is saved manually at a later time. Return the model instance.

class evileg_core.forms.ESectionForm(user=None, *args, **kwargs)[source]

Bases: evileg_core.forms.EArticleForm

Form class for class, which inherits from evileg_core.models.EAbstractSection.

base_fields = {}
declared_fields = {}
property media

Return all media required to render the widgets on this form.