organizations.forms module

class organizations.forms.SelectOrganizationForm(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 = {'organization': <django.forms.models.ModelChoiceField object>}
declared_fields = {'organization': <django.forms.models.ModelChoiceField object>}
property media
class organizations.forms.OrganizationForm(*args, **kwargs)[source]

Bases: django.forms.models.ModelForm

class Meta[source]

Bases: object

model

alias of organizations.models.Organization

fields = '__all__'
base_fields = {'acronym': <django.forms.fields.CharField object>, 'address': <django.forms.fields.CharField object>, 'cf_associated_publication_ids': <django.forms.fields.JSONField object>, 'cf_balance_info': <django.forms.fields.JSONField object>, 'cf_expenditure_for_publication': <django.forms.fields.JSONField object>, 'cf_nr_associated_publications': <django.forms.fields.IntegerField object>, 'country': <django_countries.fields.LazyTypedChoiceField object>, 'crossref_json': <django.forms.fields.JSONField object>, 'css_class': <django.forms.fields.CharField object>, 'grid_json': <django.forms.fields.JSONField object>, 'logo': <django.forms.fields.ImageField object>, 'name': <django.forms.fields.CharField object>, 'name_original': <django.forms.fields.CharField object>, 'orgtype': <django.forms.fields.TypedChoiceField object>, 'parent': <django.forms.models.ModelChoiceField object>, 'status': <django.forms.fields.TypedChoiceField object>, 'superseded_by': <django.forms.models.ModelChoiceField object>}
declared_fields = {'parent': <django.forms.models.ModelChoiceField object>, 'superseded_by': <django.forms.models.ModelChoiceField object>}
property media
class organizations.forms.OrganizationEventForm(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, instance=None, use_required_attribute=None, renderer=None)[source]

Bases: django.forms.models.ModelForm

class Meta[source]

Bases: object

model

alias of organizations.models.OrganizationEvent

fields = ['organization', 'event', 'comments', 'noted_on', 'noted_by']
base_fields = {'comments': <django.forms.fields.CharField object>, 'event': <django.forms.fields.TypedChoiceField object>, 'noted_by': <django.forms.models.ModelChoiceField object>, 'noted_on': <django.forms.fields.DateTimeField object>, 'organization': <django.forms.models.ModelChoiceField object>}
declared_fields = {}
property media
class organizations.forms.ContactPersonForm(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, instance=None, use_required_attribute=None, renderer=None)[source]

Bases: django.forms.models.ModelForm

class Meta[source]

Bases: object

model

alias of organizations.models.ContactPerson

fields = '__all__'
clean_email()[source]

Check if the email is already associated to an existing ContactPerson or Contact.

base_fields = {'email': <django.forms.fields.EmailField object>, 'first_name': <django.forms.fields.CharField object>, 'last_name': <django.forms.fields.CharField object>, 'organization': <django.forms.models.ModelChoiceField object>, 'role': <django.forms.fields.CharField object>, 'title': <django.forms.fields.TypedChoiceField object>}
declared_fields = {}
property media
class organizations.forms.UpdateContactDataForm(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, instance=None, use_required_attribute=None, renderer=None)[source]

Bases: django.forms.models.ModelForm

This form is used in the scipost:update_personal_data method.

class Meta[source]

Bases: object

model

alias of organizations.models.Contact

fields = ['title']
base_fields = {'title': <django.forms.fields.TypedChoiceField object>}
declared_fields = {}
property media
class organizations.forms.ContactForm(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, instance=None, use_required_attribute=None, renderer=None)[source]

Bases: django.forms.models.ModelForm

This Contact form is mainly used for editing Contact instances.

class Meta[source]

Bases: object

model

alias of organizations.models.Contact

fields = ['title', 'key_expires']
base_fields = {'key_expires': <django.forms.fields.DateTimeField object>, 'title': <django.forms.fields.TypedChoiceField object>}
declared_fields = {}
property media
class organizations.forms.NewContactForm(*args, **kwargs)[source]

Bases: organizations.forms.ContactForm

This Contact form is used to create new Contact instances, as it will also handle possible sending and activation of User instances coming with the new Contact.

existing_user = None
clean_email()[source]

Check if User already is known in the system.

save(current_user, commit=True)[source]

If existing user is found, link it to the Organization.

base_fields = {'email': <django.forms.fields.CharField object>, 'first_name': <django.forms.fields.CharField object>, 'key_expires': <django.forms.fields.DateTimeField object>, 'last_name': <django.forms.fields.CharField object>, 'title': <django.forms.fields.ChoiceField object>}
declared_fields = {'email': <django.forms.fields.CharField object>, 'first_name': <django.forms.fields.CharField object>, 'last_name': <django.forms.fields.CharField object>, 'title': <django.forms.fields.ChoiceField object>}
property media
class organizations.forms.ContactActivationForm(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, instance=None, use_required_attribute=None, renderer=None)[source]

Bases: django.forms.models.ModelForm

class Meta[source]

Bases: object

model

alias of django.contrib.auth.models.User

fields = []
clean(*args, **kwargs)[source]

Hook for doing any extra form-wide cleaning after Field.clean() has been called on every field. Any ValidationError raised by this method will not be associated with a particular field; it will have a special-case association with the field named ‘__all__’.

clean_password()[source]
clean_password_verif()[source]
activate_user()[source]
base_fields = {'password_new': <django.forms.fields.CharField object>, 'password_verif': <django.forms.fields.CharField object>}
declared_fields = {'password_new': <django.forms.fields.CharField object>, 'password_verif': <django.forms.fields.CharField object>}
property media
class organizations.forms.ContactRoleForm(*args, **kwargs)[source]

Bases: django.forms.models.ModelForm

class Meta[source]

Bases: object

model

alias of organizations.models.ContactRole

fields = '__all__'
base_fields = {'contact': <django.forms.models.ModelChoiceField object>, 'date_from': <django.forms.fields.DateField object>, 'date_until': <django.forms.fields.DateField object>, 'kind': <django.forms.fields.MultipleChoiceField object>, 'organization': <django.forms.models.ModelChoiceField object>}
declared_fields = {}
property media