aboutsummaryrefslogtreecommitdiffstats
path: root/fg21sim/webui/templates/login.html
diff options
context:
space:
mode:
authorAaron LI <aaronly.me@outlook.com>2016-11-15 17:36:51 +0800
committerAaron LI <aaronly.me@outlook.com>2016-11-15 17:47:21 +0800
commitbcdc84fb416820493e048fe28ca59e9090762ffb (patch)
tree95a0d85429d1ba9011001f22bd59c3e06274008e /fg21sim/webui/templates/login.html
parent823fb20c83ff9dedcc5d804f32a0f80ab1810813 (diff)
downloadfg21sim-bcdc84fb416820493e048fe28ca59e9090762ffb.tar.bz2
webui: Implement login support (password authentication)
Diffstat (limited to 'fg21sim/webui/templates/login.html')
-rw-r--r--fg21sim/webui/templates/login.html30
1 files changed, 30 insertions, 0 deletions
diff --git a/fg21sim/webui/templates/login.html b/fg21sim/webui/templates/login.html
new file mode 100644
index 0000000..51d4cd1
--- /dev/null
+++ b/fg21sim/webui/templates/login.html
@@ -0,0 +1,30 @@
+{#
+ # Copyright (c) 2016 Weitian LI <liweitianux@live.com>
+ # MIT license
+ #
+ # Login page for the Web UI of "fg21sim"
+ #}
+
+{% extends "base.html" %}
+
+{% block subtitle %}Login |{% end %}
+
+{% block main %}
+<section id="login">
+ <h2><span class="fa fa-key" aria-hidden="true"></span> Login</h2>
+ <hr />
+
+ <form action="/login" method="post">
+ {% module xsrf_form_html() %}
+ <fieldset>
+ <label for="password">Password:
+ {% if (error != "") %}
+ <span class="label label-warning">{{ error }}</span>
+ {% end %}
+ </label>
+ <input class="form-control" type="password" id="password" name="password" required />
+ <button type="submit">Login</button>
+ </fieldset>
+ </form>
+</section>
+{% end %}