aboutsummaryrefslogtreecommitdiffstats
path: root/templates/web/default/auth
diff options
context:
space:
mode:
Diffstat (limited to 'templates/web/default/auth')
-rw-r--r--templates/web/default/auth/change_password.html43
-rw-r--r--templates/web/default/auth/general.html84
-rw-r--r--templates/web/default/auth/sign_out.html8
-rw-r--r--templates/web/default/auth/token.html27
4 files changed, 162 insertions, 0 deletions
diff --git a/templates/web/default/auth/change_password.html b/templates/web/default/auth/change_password.html
new file mode 100644
index 000000000..be7c14e43
--- /dev/null
+++ b/templates/web/default/auth/change_password.html
@@ -0,0 +1,43 @@
+[% INCLUDE 'header.html', title = loc('Change Password') %]
+
+<h1>[% loc('Change Password') %]</h1>
+
+[% IF password_changed %]
+ <p id="fixed">[% loc('Your password has been changed') %]</p>
+[% END %]
+
+
+<form action="[% c.uri_for('change_password') %]" method="post" name="change_password">
+
+ <div id="fieldset">
+
+ [% IF password_error;
+
+ errors = {
+ missing => loc('Please enter a password'),
+ mismatch => loc('The passwords do not match'),
+ other => loc('Please check the passwords and try again'),
+ };
+
+ loc_password_error = errors.$password_error || errors.other; %]
+ <div class="form-error">[% loc_password_error %]</div>
+ [% END %]
+
+ <div class="form-field">
+ <label for="new_password">[% loc('Password:') %]</label>
+ <input type="password" name="new_password" value="[% new_password | html %]">
+ </div>
+ <div class="form-field">
+ <label for="confirm">[% loc('Again:') %]</label>
+ <input type="password" name="confirm" value="[% confirm | html %]">
+ </div>
+ <div class="checkbox">
+ <input type="submit" value="[% loc('Change Password') %]">
+ </div>
+
+ </div>
+
+</form>
+
+
+[% INCLUDE 'footer.html' %]
diff --git a/templates/web/default/auth/general.html b/templates/web/default/auth/general.html
new file mode 100644
index 000000000..234aadf52
--- /dev/null
+++ b/templates/web/default/auth/general.html
@@ -0,0 +1,84 @@
+[% INCLUDE 'header.html', title = loc('Sign in or create an account') %]
+
+<h1>[% loc('Sign in') %]</h1>
+
+<form action="[% c.uri_for() %]" method="post" name="general_auth">
+<input type="hidden" name="r" value="[% c.req.params.r | html %]">
+
+ [% IF email_error;
+
+ # other keys include fqdn, mxcheck if you'd like to write a custom error message
+
+ errors = {
+ missing => loc('Please enter your email'),
+ other => loc('Please check your email address is correct')
+ };
+
+ loc_email_error = errors.$email_error || errors.other;
+ END %]
+
+ [% IF loc_email_error %]
+ <div class="form-error">[% loc_email_error %]</div>
+ [% ELSIF sign_in_error %]
+ <div class="form-error">[% loc('There was a problem with your email/password combination. Passwords and user accounts are a brand <strong>new</strong> service, so you probably do not have one yet &ndash; please fill in the right hand side of this form to get one.') %]</div>
+ [% END %]
+
+ <div class="form-field">
+ <label class="n" for="email">[% loc('Your email address:') %]</label>
+ <input type="email" size="30" id="email" name="email" value="[% email | html %]">
+ </div>
+
+<div id="form_sign_in">
+ <h3>[% loc("Do you have a FixMyStreet password?") %]</h3>
+
+ <div id="form_sign_in_yes">
+
+ <p>
+ <label class="n" for="password_sign_in">[% loc('<strong>Yes</strong>, I have a password:') %]</label>
+ <input type="password" name="password_sign_in" id="password_sign_in" value="">
+ </p>
+
+ <p>
+ <input type="checkbox" id="remember_me" name="remember_me" value='1'[% ' checked' IF remember_me %]>
+ <label class="n" for="remember_me">
+ [% loc('Keep me signed in on this computer') %]
+ </label>
+ </p>
+
+ <p>
+ <input type="submit" name="sign_in" value="[% loc('Sign in') %]">
+ </p>
+
+ </div>
+ <div id="form_sign_in_no">
+
+ <p>[% loc('<strong>No</strong>, I do not, let me sign in by email:') %]</p>
+
+ <div id="fieldset">
+ <div class="form-field">
+ <label for="name">[% loc('Your name:') %]</label>
+ <input type="text" name="name" value="">
+ </div>
+
+ <div class="form-field">
+ <label for="password_register">[% loc('Enter a new password:') %]</label>
+ <input type="password" name="password_register" id="password_register" value="">
+ </div>
+ </div>
+
+ <p><small>Providing a name and password is optional, but doing so
+ will allow you to more easily report problems, leave updates and
+ manage your reports.</small></p>
+
+ <p>
+ <input type="submit" name="email_sign_in" value="[% loc('Sign in by email') %]">
+ </p>
+
+ </div>
+
+</div>
+
+</form>
+
+
+[% INCLUDE 'footer.html' %]
diff --git a/templates/web/default/auth/sign_out.html b/templates/web/default/auth/sign_out.html
new file mode 100644
index 000000000..3d8df60e4
--- /dev/null
+++ b/templates/web/default/auth/sign_out.html
@@ -0,0 +1,8 @@
+[% INCLUDE 'header.html', title => loc('Sign out') %]
+
+<h1>[% loc('You have been signed out') %]</h1>
+
+<p>Please feel free to <a href="[% c.uri_for('/auth') %]">sign in again</a>.</p>
+
+
+[% INCLUDE 'footer.html' %]
diff --git a/templates/web/default/auth/token.html b/templates/web/default/auth/token.html
new file mode 100644
index 000000000..0f44d1074
--- /dev/null
+++ b/templates/web/default/auth/token.html
@@ -0,0 +1,27 @@
+[% INCLUDE 'header.html', title => loc('Confirm account') %]
+
+[% IF token_not_found %]
+
+<h1>[% loc('Error') %]</h1>
+
+<p>We have not been able to confirm your account - sorry. This may be because:</p>
+
+<ul>
+ <li>Link too old or already used</li>
+ <li>URL not copied correctly</li>
+ [%# FIXME - add more reasons here %]
+</ul>
+
+[% ELSE %]
+
+<h1>[% loc('Please check your email') %]</h1>
+
+<p>[% loc("We have sent you an email containing a link to confirm your account.") %]</p>
+
+<p>[% loc("The confirmation email <strong>may</strong> take a few minutes to arrive &mdash; <em>please</em> be patient.") %]</p>
+
+<p>[% loc("If you use web-based email or have 'junk mail' filters, you may wish to check your bulk/spam mail folders: sometimes, our messages are marked that way.") %]</p>
+
+[% END %]
+
+[% INCLUDE 'footer.html' %]