From db38728a7a59347847fb2fc5823a14f0f059f278 Mon Sep 17 00:00:00 2001 From: Sam Date: Thu, 5 Sep 2013 18:36:15 -0500 Subject: Missed some files in last checkin so adding them now --- .../static/new/js_external/zxcvbn/.gitignore | 2 - wqflask/wqflask/templates/base.html | 12 +- .../wqflask/templates/new_security/_scripts.html | 4 +- .../templates/new_security/register_user.html | 158 +++++++++++++-------- wqflask/wqflask/views.py | 16 ++- 5 files changed, 118 insertions(+), 74 deletions(-) delete mode 100644 wqflask/wqflask/static/new/js_external/zxcvbn/.gitignore (limited to 'wqflask') diff --git a/wqflask/wqflask/static/new/js_external/zxcvbn/.gitignore b/wqflask/wqflask/static/new/js_external/zxcvbn/.gitignore deleted file mode 100644 index af1b4bc3..00000000 --- a/wqflask/wqflask/static/new/js_external/zxcvbn/.gitignore +++ /dev/null @@ -1,2 +0,0 @@ -*~ -*.js diff --git a/wqflask/wqflask/templates/base.html b/wqflask/wqflask/templates/base.html index cbed5859..7f72ff22 100644 --- a/wqflask/wqflask/templates/base.html +++ b/wqflask/wqflask/templates/base.html @@ -19,6 +19,7 @@ + {% block css %} {% endblock %} @@ -70,9 +71,9 @@
  • {% if g.identity.name=="anon" %} - Sign in + Sign in {% else %} - Sign out + Sign out {% endif %}
  • @@ -180,12 +181,13 @@ - + + + + {% block js %} {% endblock %} - - diff --git a/wqflask/wqflask/templates/new_security/_scripts.html b/wqflask/wqflask/templates/new_security/_scripts.html index 5a453dca..5fefe305 100644 --- a/wqflask/wqflask/templates/new_security/_scripts.html +++ b/wqflask/wqflask/templates/new_security/_scripts.html @@ -1,3 +1 @@ - - + diff --git a/wqflask/wqflask/templates/new_security/register_user.html b/wqflask/wqflask/templates/new_security/register_user.html index d66365f4..d203d65f 100644 --- a/wqflask/wqflask/templates/new_security/register_user.html +++ b/wqflask/wqflask/templates/new_security/register_user.html @@ -1,66 +1,104 @@ -
    -

    * Already have an account?

    +{% extends "base.html" %} +{% block title %}Register{% endblock %} +{% block content %} +
    +
    +

    Register

    +

    + It's easy and fast to make an account. +

    +
    +
    -
    - Sign in using existing account -
    - -
    - -

    Don't have an account?

    - -
    Register here
    - -
    -
    - - -
    - -
    - -
    -
    +
    + + +
    +

    Already have an account?

    + -
    - -
    - -
    -
    - -
    - -
    - -
    -
    + Sign in using existing account -
    - -
    - -
    -
    - -
    - -
    - -
    -
    + +
    + +

    Don't have an account?

    + +
    Register here
    + + +
    + +
    + +
    + +
    +
    + +
    + +
    + +
    +
    + +
    + +
    + +
    +
    + +
    + +
    + +
    +
    + + + + + +
    + +
    + +
    +
    + +
    +
    + +
    +
    + +
    + + +
    +
    -
    -
    - -
    -
    +{% endblock %} -
    +{% block js %} + + + {% include "new_security/_scripts.html" %} + + +{% endblock %} - -
    -{% include "security/_scripts.html" %} - diff --git a/wqflask/wqflask/views.py b/wqflask/wqflask/views.py index 2b16dd77..6f14ac8d 100644 --- a/wqflask/wqflask/views.py +++ b/wqflask/wqflask/views.py @@ -51,10 +51,10 @@ from wqflask import user_manager def connect_db(): g.db = sqlalchemy.create_engine(app.config['DB_URI']) -@app.before_request -def trace_it(): - from wqflask import tracer - tracer.turn_on() +#@app.before_request +#def trace_it(): +# from wqflask import tracer +# tracer.turn_on() @app.route("/") def index_page(): @@ -292,6 +292,14 @@ def manage_groups(): return render_template("admin/group_manager.html", **template_vars.__dict__) +@app.route("/n/register") +def new_register(): + return render_template("new_security/register_user.html") + +@app.route("/n/login") +def new_login(): + return render_template("new_security/login_user.html") + def json_default_handler(obj): '''Based on http://stackoverflow.com/a/2680060/1175849''' # Handle datestamps -- cgit v1.2.3