Page Contents

Previous topic

omeroweb.feedback.templatetags package

Next topic

omeroweb.webadmin.templatetags package

This Page

omeroweb.webadmin package

Submodules

omeroweb.webadmin.custom_forms module

class omeroweb.webadmin.custom_forms.DefaultGroupField(choices=(), required=True, widget=None, label=None, initial=None, help_text=u'', *args, **kwargs)

Bases: django.forms.fields.ChoiceField

to_python(value)

Check that the field was selected.

class omeroweb.webadmin.custom_forms.ExperimenterModelChoiceField(queryset, empty_label=u'---------', cache_choices=False, required=True, widget=None, label=None, initial=None, help_text=u'', to_field_name=None, *args, **kwargs)

Bases: django.forms.models.ModelChoiceField

_get_choices()
_set_choices(value)
choices
to_python(value)

Go through all values in queryset, looking to find ‘value’. If not found raise ValidationError.

@return value: The input value

class omeroweb.webadmin.custom_forms.ExperimenterModelMultipleChoiceField(queryset, cache_choices=False, required=True, widget=<class 'django.forms.widgets.SelectMultiple'>, label=None, initial=None, help_text=None, *args, **kwargs)

Bases: omeroweb.webadmin.custom_forms.ExperimenterModelChoiceField

A MultipleChoiceField whose choices are a model QuerySet.

default_error_messages = {'invalid_choice': <django.utils.functional.__proxy__ object at 0x2ea38190>, 'list': <django.utils.functional.__proxy__ object at 0x2ea38110>}
hidden_widget

alias of MultipleHiddenInput

to_python(value)
class omeroweb.webadmin.custom_forms.ExperimenterQuerySetIterator(queryset, empty_label)

Bases: object

render(obj)
class omeroweb.webadmin.custom_forms.GroupModelChoiceField(queryset, empty_label=u'---------', cache_choices=False, required=True, widget=None, label=None, initial=None, help_text=u'', to_field_name=None, *args, **kwargs)

Bases: django.forms.models.ModelChoiceField

_get_choices()
_set_choices(value)
choices
to_python(value)
class omeroweb.webadmin.custom_forms.GroupModelMultipleChoiceField(queryset, cache_choices=False, required=True, widget=<class 'django.forms.widgets.SelectMultiple'>, label=None, initial=None, help_text=None, *args, **kwargs)

Bases: omeroweb.webadmin.custom_forms.GroupModelChoiceField

A MultipleChoiceField whose choices are a model QuerySet.

default_error_messages = {'invalid_choice': <django.utils.functional.__proxy__ object at 0x331e7f50>, 'list': <django.utils.functional.__proxy__ object at 0x331e7ed0>}
hidden_widget

alias of MultipleHiddenInput

to_python(value)
class omeroweb.webadmin.custom_forms.GroupQuerySetIterator(queryset, empty_label)

Bases: object

class omeroweb.webadmin.custom_forms.MultiEmailField(required=True, widget=None, label=None, initial=None, help_text=u'', error_messages=None, show_hidden_initial=False, validators=[], localize=False)

Bases: django.forms.fields.Field

A field to process comma seperated email into an array of stripped strings

to_python(value)

Normalize data to a list of strings.

validate(value)

Check if value consists only of valid emails.

class omeroweb.webadmin.custom_forms.OmeNameField(max_length=None, min_length=None, *args, **kwargs)

Bases: django.forms.fields.CharField

is_valid_omeName(omeName)
to_python(value)
class omeroweb.webadmin.custom_forms.ServerModelChoiceField(queryset, empty_label=u'---------', cache_choices=False, required=True, widget=None, label=None, initial=None, help_text=u'', to_field_name=None, *args, **kwargs)

Bases: django.forms.models.ModelChoiceField

_get_choices()
_set_choices(value)
choices
to_python(value)
class omeroweb.webadmin.custom_forms.ServerQuerySetIterator(queryset, empty_label)

Bases: object

omeroweb.webadmin.custom_widgets module

class omeroweb.webadmin.custom_widgets.DefaultGroupRadioFieldRenderer(name, value, attrs, choices)

Bases: django.forms.widgets.RadioFieldRenderer

An object used by RadioSelect to enable customization of radio widgets.

class omeroweb.webadmin.custom_widgets.DefaultGroupRadioInput(name, value, attrs, choice, index)

Bases: django.forms.widgets.RadioInput

An object used by RadioFieldRenderer that represents a single <input type=’radio’>.

class omeroweb.webadmin.custom_widgets.DefaultGroupRadioSelect(*args, **kwargs)

Bases: django.forms.widgets.RadioSelect

media
renderer

alias of DefaultGroupRadioFieldRenderer

omeroweb.webadmin.forms module

class omeroweb.webadmin.forms.ChangePassword(*args, **kwargs)

Bases: omeroweb.custom_forms.NonASCIIForm

base_fields = {'old_password': <django.forms.fields.CharField object at 0x331ee290>, 'password': <django.forms.fields.CharField object at 0x331ee3d0>, 'confirmation': <django.forms.fields.CharField object at 0x331ee490>}
clean_confirmation()
media
class omeroweb.webadmin.forms.ContainedExperimentersForm(*args, **kwargs)

Bases: omeroweb.custom_forms.NonASCIIForm

base_fields = {}
media
class omeroweb.webadmin.forms.EmailForm(experimenters, groups, conn, request, *args, **kwargs)

Bases: django.forms.forms.Form

Form to gather recipients, subject and message for sending email announcements

base_fields = {'everyone': <django.forms.fields.BooleanField object at 0x331ee650>, 'experimenters': <django.forms.fields.TypedMultipleChoiceField object at 0x331ee790>, 'groups': <django.forms.fields.TypedMultipleChoiceField object at 0x331ee890>, 'cc': <omeroweb.webadmin.custom_forms.MultiEmailField object at 0x331ee910>, 'subject': <django.forms.fields.CharField object at 0x331ee990>, 'message': <django.forms.fields.CharField object at 0x331eea50>, 'inactive': <django.forms.fields.BooleanField object at 0x331eead0>}
clean()
error_css_class = 'field-error'
media
required_css_class = 'field-required'
class omeroweb.webadmin.forms.EnumerationEntries(entries, *args, **kwargs)

Bases: omeroweb.custom_forms.NonASCIIForm

base_fields = {}
media
class omeroweb.webadmin.forms.EnumerationEntry(*args, **kwargs)

Bases: omeroweb.custom_forms.NonASCIIForm

base_fields = {'new_entry': <django.forms.fields.CharField object at 0x331ee550>}
media
class omeroweb.webadmin.forms.ExperimenterForm(name_check=False, email_check=False, experimenter_is_me_or_system=False, *args, **kwargs)

Bases: omeroweb.custom_forms.NonASCIIForm

base_fields = {'omename': <omeroweb.webadmin.custom_forms.OmeNameField object at 0x331e0310>, 'first_name': <django.forms.fields.CharField object at 0x331e0450>, 'middle_name': <django.forms.fields.CharField object at 0x331e0510>, 'last_name': <django.forms.fields.CharField object at 0x331e05d0>, 'email': <django.forms.fields.EmailField object at 0x331e0690>, 'institution': <django.forms.fields.CharField object at 0x331e0710>, 'administrator': <django.forms.fields.BooleanField object at 0x331e0790>, 'active': <django.forms.fields.BooleanField object at 0x331e0810>}
clean_confirmation()
clean_default_group()
clean_email()
clean_omename()
clean_other_groups()
media
class omeroweb.webadmin.forms.ForgottonPasswordForm(*args, **kwargs)

Bases: omeroweb.custom_forms.NonASCIIForm

base_fields = {'server': <omeroweb.webadmin.custom_forms.ServerModelChoiceField object at 0x331e0050>, 'username': <django.forms.fields.CharField object at 0x331e0190>, 'email': <django.forms.fields.EmailField object at 0x331e0290>}
media
class omeroweb.webadmin.forms.GroupForm(name_check=False, group_is_current_or_system=False, *args, **kwargs)

Bases: omeroweb.custom_forms.NonASCIIForm

base_fields = {'name': <django.forms.fields.CharField object at 0x331e08d0>, 'description': <django.forms.fields.CharField object at 0x331e0a10>}
clean_name()
media
class omeroweb.webadmin.forms.GroupOwnerForm(*args, **kwargs)

Bases: django.forms.forms.Form

base_fields = {'permissions': <django.forms.fields.ChoiceField object at 0x331e0b10>}
media
class omeroweb.webadmin.forms.LoginForm(*args, **kwargs)

Bases: omeroweb.custom_forms.NonASCIIForm

base_fields = {'username': <django.forms.fields.CharField object at 0x331c8d90>, 'password': <django.forms.fields.CharField object at 0x331c8f10>, 'ssl': <django.forms.fields.BooleanField object at 0x331c8f90>}
media
class omeroweb.webadmin.forms.MyAccountForm(email_check=False, *args, **kwargs)

Bases: omeroweb.custom_forms.NonASCIIForm

base_fields = {'omename': <django.forms.fields.CharField object at 0x331e0bd0>, 'first_name': <django.forms.fields.CharField object at 0x331e0d50>, 'middle_name': <django.forms.fields.CharField object at 0x331e0e10>, 'last_name': <django.forms.fields.CharField object at 0x331e0ed0>, 'email': <django.forms.fields.EmailField object at 0x331e0f90>, 'institution': <django.forms.fields.CharField object at 0x331ee050>}
clean_email()
media
class omeroweb.webadmin.forms.UploadPhotoForm(data=None, files=None, auto_id=u'id_%s', prefix=None, initial=None, error_class=<class 'django.forms.util.ErrorList'>, label_suffix=None, empty_permitted=False)

Bases: django.forms.forms.Form

base_fields = {'photo': <django.forms.fields.FileField object at 0x331ee0d0>}
clean_photo()
media

omeroweb.webadmin.models module

omeroweb.webadmin.urls module

omeroweb.webadmin.views module

A view functions is simply a Python function that takes a Web request and returns a Web response. This response can be the HTML contents of a Web page, or a redirect, or the 404 and 500 error, or an XML document, or an image... or anything.

omeroweb.webadmin.views.attach_photo(conn, newFile)
omeroweb.webadmin.views.drivespace_json(request, *args, **kwargs)

Returns a json list of {“label”:<Name>, “data”: <Value>, “groupId / userId”: <id>} for plotting disk usage by users or groups. If ‘query’ is “groups” or “users”, this is for an Admin to show all data on server divided into groups or users. Else, if groupId is not None, we return data for that group, split by user. Else, if userId is not None, we return data for that user, split by group.

omeroweb.webadmin.views.email(request, *args, **kwargs)

View to gather recipients, subject and message for sending email announcements

omeroweb.webadmin.views.experimenters(request, *args, **kwargs)
omeroweb.webadmin.views.forgotten_password(request, **kwargs)
omeroweb.webadmin.views.getActualPermissions(group)
omeroweb.webadmin.views.getSelectedExperimenters(conn, ids)
omeroweb.webadmin.views.getSelectedGroups(conn, ids)
omeroweb.webadmin.views.groups(request, *args, **kwargs)
omeroweb.webadmin.views.index(request, *args, **kwargs)
omeroweb.webadmin.views.logout(request, *args, **kwargs)
omeroweb.webadmin.views.manage_avatar(request, *args, **kwargs)
omeroweb.webadmin.views.manage_experimenter(request, *args, **kwargs)
omeroweb.webadmin.views.manage_group(request, *args, **kwargs)
omeroweb.webadmin.views.manage_group_owner(request, *args, **kwargs)
omeroweb.webadmin.views.manage_password(request, *args, **kwargs)
omeroweb.webadmin.views.mergeLists(list1, list2)
omeroweb.webadmin.views.my_account(request, *args, **kwargs)
omeroweb.webadmin.views.myphoto(request, *args, **kwargs)
omeroweb.webadmin.views.otherGroupsInitialList(groups, excluded_names=('user', 'guest'), excluded_ids=[])
omeroweb.webadmin.views.ownedGroupsInitial(conn, excluded_names=('user', 'guest', 'system'), excluded_ids=[])
omeroweb.webadmin.views.prepare_experimenter(conn, eid=None)
class omeroweb.webadmin.views.render_response_admin

Bases: omeroweb.webclient.decorators.render_response

Subclass for adding additional data to the ‘context’ dict passed to templates

prepare_context(request, context, *args, **kwargs)

We extend the webclient render_response to check if any groups are created. If not, add an appropriate message to the template context

omeroweb.webadmin.views.setActualPermissions(permissions)
omeroweb.webadmin.views.stats(request, *args, **kwargs)

omeroweb.webadmin.webadmin_utils module

omeroweb.webadmin.webadmin_utils.upgradeCheck(url)

Module contents