source: OpenWorkouts-current/ow/templates/add_user.pt @ 737eb6c

currentfeature/docs
Last change on this file since 737eb6c was 1d92bf2, checked in by borja <borja@…>, 5 years ago

(#37) Allow login using email address instead of username:

  • Use user uids as keys in the root folder for referencing user objects (instead of username)
  • Use uids for referencing users all over the place (auth, permissions, traversal urls, etc)
  • Replaced the username concept with nickname. This nickname will be used as a shortcut to access "public profile" pages for users
  • Reworked lots of basic methods in the OpenWorkouts root object (s/username/nickname, marked as properties some methods like users, emails, etc)
  • Added new add_user() and delete_user() helpers to the OpenWorkouts root object
  • Fixed bug in the dashboard redirect view, causing an endless loop if an authenticated user does not exist anymore when loading a page.
  • Lots of tests fixes, adaptations and catch up.
  • Property mode set to 100644
File size: 1.6 KB
Line 
1<html xmlns="http://www.w3.org/1999/xhtml"
2      xml:lang="en"
3      xmlns:tal="http://xml.zope.org/namespaces/tal"
4      xmlns:metal="http://xml.zope.org/namespaces/metal"
5      xmlns:i18n="http://xml.zope.org/namespaces/i18n"
6      i18n:domain="OpenWorkouts"
7      metal:use-macro="load: base.pt"
8      tal:attributes="lang request.locale_name">
9
10  <metal:head-title metal:fill-slot="head-title">
11    <tal:t i18n:translate="">Add user</tal:t>
12  </metal:head-title>
13
14  <metal:title metal:fill-slot="title">
15    <tal:t i18n:translate="">Add user</tal:t>
16  </metal:title>
17
18  <metal:content metal:fill-slot="content">
19    <div id="add_user">
20      ${form.begin()}
21      ${form.csrf_token()}
22
23      <fieldset>
24        ${form.errorlist('email')}
25        <label for="email" i18n:translate="">E-Mail:</label>
26        ${form.text('email')}
27        ${form.errorlist('nickname')}
28        <label for="nickname" i18n:translate="">Nickname</label>
29        ${form.text('nickname')}
30      </fieldset>
31
32      <fieldset>
33        ${form.errorlist('firstname')}
34        <label for="firstname" i18n:translate="">Firstname:</label>
35        ${form.text('firstname')}
36        ${form.errorlist('lastname')}
37        <label for="lastname" i18n:translate="">Lastname:</label>
38        ${form.text('lastname')}
39      </fieldset>
40
41      <fieldset>
42        ${form.errorlist('group')}
43        <label for="group" i18n:translate="">Group / Admin:</label>
44        ${form.text('group')}
45      </fieldset>
46
47      ${form.submit("submit", "Save")}
48      <a href="" tal:attributes="href request.resource_url(request.root)"
49         i18n:translate="">Cancel</a>
50
51      ${form.end()}
52    </div>
53
54  </metal:content>
55
56</html>
Note: See TracBrowser for help on using the repository browser.