~shanepatrickfagan/ubuntu-sso-client/refactoring_mandel

« back to all changes in this revision

Viewing changes to ubuntu_sso/utils/ui.py

  • Committer: Manuel de la Pena
  • Date: 2011-04-11 09:38:16 UTC
  • Revision ID: mandel@themacaque.com-20110411093816-rviwqhbkpg82i21e
Added the way to reset the password.

Show diffs side-by-side

added added

removed removed

Lines of Context:
39
39
                       'enter your details below.')
40
40
EMAIL1_ENTRY = _('Email address')
41
41
EMAIL2_ENTRY = _('Re-type Email address')
 
42
EMAIL_LABEL = EMAIL1_ENTRY + ':'
42
43
EMAIL_MISMATCH = _('The email addresses don\'t match, please double check '
43
44
                       'and try entering them again.')
44
45
EMAIL_INVALID = _('The email must be a valid email address.')
66
67
PASSWORD_TOO_WEAK = _('The password is too weak.')
67
68
REQUEST_PASSWORD_TOKEN_LABEL = _('To reset your %(app_name)s password,'
68
69
                                 ' enter your email address below:')
 
70
REQUEST_PASSWORD_TOKEN_WRONG_EMAIL = _('Sorry we did not recognize the email'
 
71
                                       ' address.')
 
72
REQUEST_PASSWORD_TOKEN_TECH_ERROR = _('We are very Sorry! The service that'
 
73
                                      ' signs you on is not responding right'
 
74
                                      ' now\nPlease try again or come back in'
 
75
                                      ' a few minutes.')
69
76
RESET_PASSWORD = _('Reset password')
70
77
RESET_CODE_ENTRY = _('Reset code')
71
78
RESET_EMAIL_ENTRY = _('Email address')
80
87
TC_BUTTON = _('Show Terms & Conditions')
81
88
TC_NOT_ACCEPTED = _('Agreeing to the Ubuntu One Terms & Conditions is ' \
82
89
                        'required to subscribe.')
 
90
TRY_AGAIN_BUTTON = _('Try again')
83
91
UNKNOWN_ERROR = _('There was an error when trying to complete the ' \
84
92
                      'process. Please check the information and try again.')
85
93
VERIFY_EMAIL_TITLE = _('Enter verification code')
168
176
        re.search('\d+', password) is None):
169
177
        return False
170
178
    return True
 
179
 
 
180
 
 
181
def is_correct_email(email_address):
 
182
    """Return if the email is correct."""
 
183
    return '@' in email_address
 
 
b'\\ No newline at end of file'