hawat.blueprints.auth_dev.forms module

This module contains custom developer login form for Hawat.

class hawat.blueprints.auth_dev.forms.LoginForm(*args, **kwargs)[source]

Bases: FlaskForm

Class representing developer authentication login form. This form provides list of all currently existing user accounts in simple selectbox, so that the developer can quickly login as different user.

login = <UnboundField(SelectField, (l'User account:',), {'validators': [<wtforms.validators.DataRequired object>, <function check_login>]})>
set_choices()[source]

Load list of all user accounts and populate the choices attribute of the login selectbox.

submit = <UnboundField(SubmitField, (l'Login',), {})>
class hawat.blueprints.auth_dev.forms.RegisterUserAccountForm(*args, **kwargs)[source]

Bases: BaseUserAccountForm

Class representing user account registration form.

justification = <UnboundField(TextAreaField, (l'Justification:',), {'validators': [<wtforms.validators.DataRequired object>, <wtforms.validators.Length object>]})>
login = <UnboundField(StringField, (l'Login:',), {'validators': [<wtforms.validators.DataRequired object>, <wtforms.validators.Length object>, <function check_login>, <function check_unique_login>, <function check_null_character>]})>
memberships_wanted = <UnboundField(QuerySelectMultipleField, (l'Requested group memberships:',), {'query_factory': <function get_available_groups>})>