##// END OF EJS Templates
templates: Migrate password reset template to pyramid.
johbo -
r32:74a48d81 default
parent child Browse files
Show More
@@ -1,70 +1,78 b''
1 1 ## -*- coding: utf-8 -*-
2 2 <%inherit file="base/root.html"/>
3 3
4 4 <%def name="title()">
5 5 ${_('Create an Account')}
6 6 %if c.rhodecode_name:
7 7 &middot; ${h.branding(c.rhodecode_name)}
8 8 %endif
9 9 </%def>
10 10 <style>body{background-color:#eeeeee;}</style>
11 11
12 12 <div class="loginbox">
13 13 <div class="header">
14 14 <div id="header-inner" class="title">
15 15 <div id="logo">
16 16 <div class="logo-wrapper">
17 17 <a href="${h.url('home')}"><img src="${h.url('/images/rhodecode-logo-white-216x60.png')}" alt="RhodeCode"/></a>
18 18 </div>
19 19 %if c.rhodecode_name:
20 20 <div class="branding"> ${h.branding(c.rhodecode_name)}</div>
21 21 %endif
22 22 </div>
23 23 </div>
24 24 </div>
25 25
26 26 <div class="loginwrapper">
27 27 <div class="left-column">
28 28 <img class="sign-in-image" src="${h.url('/images/sign-in.png')}" alt="RhodeCode"/>
29 29 </div>
30 30
31 31 <div id="register" class="right-column">
32 32 <%include file="/base/flash_msg.html"/>
33 33 <!-- login -->
34 34 <div class="sign-in-title">
35 35 <h1>${_('Reset your Password')}</h1>
36 <h4>${h.link_to(_("Go to the login page to sign in."),h.url('login'))}</h4>
36 <h4>${h.link_to(_("Go to the login page to sign in."), request.route_path('login'))}</h4>
37 37 </div>
38 38 <div class="inner form">
39 ${h.form(url('password_reset'), needs_csrf_token=False)}
39 ${h.form(request.route_path('reset_password'), needs_csrf_token=False)}
40 40 <label for="email">${_('Email Address')}:</label>
41 ${h.text('email')}
41 ${h.text('email', defaults.get('email'))}
42 %if 'email' in errors:
43 <span class="error-message">${errors.get('email')}</span>
44 <br />
45 %endif
42 46
43 %if c.captcha_active:
47 %if captcha_active:
44 48 <div class="login-captcha"
45 49 <label for="email">${_('Captcha')}:</label>
46 50 ${h.hidden('recaptcha_field')}
47 51 <div id="recaptcha"></div>
52 %if 'recaptcha_field' in errors:
53 <span class="error-message">${errors.get('recaptcha_field')}</span>
54 <br />
55 %endif
48 56 </div>
49 57 %endif
50 58
51 ${h.submit('send',_('Send password reset email'),class_="btn sign-in")}
59 ${h.submit('send', _('Send password reset email'), class_="btn sign-in")}
52 60 <div class="activation_msg">${_('Password reset link will be send to matching email address')}</div>
53 61
54 62 ${h.end_form()}
55 63 </div>
56 64 </div>
57 65 </div>
58 66 </div>
59 67
60 %if c.captcha_active:
68 %if captcha_active:
61 69 <script type="text/javascript" src="https://www.google.com/recaptcha/api/js/recaptcha_ajax.js"></script>
62 70 %endif
63 71 <script type="text/javascript">
64 72 $(document).ready(function(){
65 73 $('#email').focus();
66 %if c.captcha_active:
67 Recaptcha.create("${c.captcha_public_key}", "recaptcha", {theme: "white"});
74 %if captcha_active:
75 Recaptcha.create("${captcha_public_key}", "recaptcha", {theme: "white"});
68 76 %endif
69 77 });
70 </script> No newline at end of file
78 </script>
General Comments 0
You need to be logged in to leave comments. Login now